diff --git a/docs/zh/.translation-manifest.json b/docs/zh/.translation-manifest.json
index a18f472..acf1a6d 100644
--- a/docs/zh/.translation-manifest.json
+++ b/docs/zh/.translation-manifest.json
@@ -1,5 +1,5 @@
{
- "generatedAt": "2026-09-02T09:12:44.494Z",
+ "generatedAt": "2026-09-03T05:24:05.315Z",
"pages": {
"https://developers.openai.com/api/docs/actions/actions-library.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
@@ -145,11 +145,11 @@
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/docs/changelog.md",
- "sourceSha256": "e44f2b6cb06ee70d4abded0d87e4c8f68c8822e6bc74eb88102affb221dbd987",
+ "sourceSha256": "e04f7209134886328e6b480509459f41fa5ef134c23524c5c5974323799d8d77",
"sourceUrl": "https://developers.openai.com/api/docs/changelog.md",
"targetPath": "docs/zh/api/docs/changelog.md",
- "targetSha256": "e163d932d8975825ef648e2bef318a80d1a5010768bf8182b678c05ca5f10d29",
- "translatedAt": "2026-09-01T06:43:06.950Z"
+ "targetSha256": "ed2ad4c15f56e78367ad1efc8e8fc0c703464a61866e24f45fea2364b129960d",
+ "translatedAt": "2026-09-03T03:55:49.158Z"
},
"https://developers.openai.com/api/docs/concepts.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
@@ -365,11 +365,11 @@
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/docs/guides/background.md",
- "sourceSha256": "85c1ac845ec392362fe3a57b367331190bac520c5dd3083aca59ba1b32d2e245",
+ "sourceSha256": "f139bb5d7947e1be8e16adb1362559f917934449dfda54770b0043eaab9321e5",
"sourceUrl": "https://developers.openai.com/api/docs/guides/background.md",
"targetPath": "docs/zh/api/docs/guides/background.md",
- "targetSha256": "602b3b6d4a28e4f28e4b459bcd43f75cc3a67382d1ebbb1a126c5fe24b7c87cc",
- "translatedAt": "2026-08-31T07:03:45.912Z"
+ "targetSha256": "5cd90b6a7b4fb62f0b6edabe668094cb4f335f6a5fce30a8bd184bceee2595bf",
+ "translatedAt": "2026-09-03T03:30:53.783Z"
},
"https://developers.openai.com/api/docs/guides/batch.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
@@ -555,21 +555,21 @@
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/docs/guides/embeddings.md",
- "sourceSha256": "70ce9fdc92b2dc017477085baaa50e39a1386def8e0993948dc4f8deaa7403ad",
+ "sourceSha256": "fca76632b90b9d317682aa25e39507dc47d436225a9b74727f4a99496035c43e",
"sourceUrl": "https://developers.openai.com/api/docs/guides/embeddings.md",
"targetPath": "docs/zh/api/docs/guides/embeddings.md",
- "targetSha256": "fe76dc8349be338eb637bb2f3404098384a2e3bb283ff3ec23e30709ea43df7f",
- "translatedAt": "2026-09-01T07:06:52.207Z"
+ "targetSha256": "db686a957908b8e425457073cbe860165c1455d2c685001a83e1d5ad174b39ea",
+ "translatedAt": "2026-09-03T03:58:34.600Z"
},
"https://developers.openai.com/api/docs/guides/error-codes.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/docs/guides/error-codes.md",
- "sourceSha256": "efdc2581fd3e5d77fd69adcef7a61481ef1fae1a8f463273fcce88f09c982cf0",
+ "sourceSha256": "bc4fbbc6763eae7480c1c4b1d67bc5090e3df51269fb449e04f488ba9edc1e19",
"sourceUrl": "https://developers.openai.com/api/docs/guides/error-codes.md",
"targetPath": "docs/zh/api/docs/guides/error-codes.md",
- "targetSha256": "ea86c78b606d49147fff28b495ed480ee9715358ddd198d33fd46ec36baecb07",
- "translatedAt": "2026-09-01T07:12:47.414Z"
+ "targetSha256": "4e8378a676e58331632ee96471f86be22da4278eb1de12e073eeb4422f2d2fcb",
+ "translatedAt": "2026-09-03T04:03:49.782Z"
},
"https://developers.openai.com/api/docs/guides/evals.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
@@ -615,11 +615,11 @@
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/docs/guides/fast-mode.md",
- "sourceSha256": "de79774b0a9806df2754ace2da0e2aeabfc9254a8dab2b37d270c18ca1125e66",
+ "sourceSha256": "ffc915a2dbea8e393dc4919d902e4bc3a61cfcc1149d1fd3f9d77decf3a79ce0",
"sourceUrl": "https://developers.openai.com/api/docs/guides/fast-mode.md",
"targetPath": "docs/zh/api/docs/guides/fast-mode.md",
- "targetSha256": "47279f159a72172d4aeaaae77f4031fe54f4e3f7142d828851935b2b4a2cebff",
- "translatedAt": "2026-08-29T17:14:20.646Z"
+ "targetSha256": "024c59569ac93982c8994ffa88baa298f0bef5416b044d10f85f1e3a848b6418",
+ "translatedAt": "2026-09-03T04:05:27.407Z"
},
"https://developers.openai.com/api/docs/guides/file-inputs.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
@@ -665,11 +665,11 @@
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/docs/guides/function-calling.md",
- "sourceSha256": "4e906233eff739dc2485af824dacb87969c2349809978ac836b1ec4682c26601",
+ "sourceSha256": "581ffae7b4fb82caefaf3c5170d6900bb09e26600188c8778d35545e2065d6db",
"sourceUrl": "https://developers.openai.com/api/docs/guides/function-calling.md",
"targetPath": "docs/zh/api/docs/guides/function-calling.md",
- "targetSha256": "dfe2e6662128ee186e46e8ea4ce26151e936e8f65514a4151993c04ba6e959e0",
- "translatedAt": "2026-09-01T07:25:19.362Z"
+ "targetSha256": "25ee63b6f45621772136e590ee1452334b1aef9a2b81a2c2fdf750fd53b35d6e",
+ "translatedAt": "2026-09-03T04:10:11.540Z"
},
"https://developers.openai.com/api/docs/guides/graders.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
@@ -855,11 +855,11 @@
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/docs/guides/moderation.md",
- "sourceSha256": "a1abda74225323e7c770d922c9b3c3135f2509651d0a3d8414ad0bc0a4ca70a5",
+ "sourceSha256": "b850e84d1561b1e16f5b13dca43653654f3dfe326256726e113b0676de5408e6",
"sourceUrl": "https://developers.openai.com/api/docs/guides/moderation.md",
"targetPath": "docs/zh/api/docs/guides/moderation.md",
- "targetSha256": "8a91fdaf64a2f367769b72a6d0121d448d7942695e21eab0ca0a2f03e498054c",
- "translatedAt": "2026-09-01T08:06:44.159Z"
+ "targetSha256": "f218562d9ca2434d3946389f4a9c238ff468c3c32ae62fc727248b8b195c3e50",
+ "translatedAt": "2026-09-03T04:10:50.964Z"
},
"https://developers.openai.com/api/docs/guides/mutual-tls.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
@@ -945,11 +945,11 @@
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/docs/guides/prompt-generation.md",
- "sourceSha256": "18ff37d7c1234b7dde66c66dc75a9e33007c5063e6eab6b285191f61efeae0f8",
+ "sourceSha256": "7e81b5db262cf8bd65c3566109ae7f04b71bb5bad8ef6dd14d9ac4b1e6489d2e",
"sourceUrl": "https://developers.openai.com/api/docs/guides/prompt-generation.md",
"targetPath": "docs/zh/api/docs/guides/prompt-generation.md",
- "targetSha256": "47604f2da55ec76449ac076386ba577096e32bdb8c90a2492ec44d0ed234ec83",
- "translatedAt": "2026-09-01T08:23:48.689Z"
+ "targetSha256": "ecbfcdb2f1564dced6b7b3e4448621b876c6037fcf99b239dc3c80a6365c137d",
+ "translatedAt": "2026-09-03T04:11:56.334Z"
},
"https://developers.openai.com/api/docs/guides/prompt-guidance-gpt-5p6.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
@@ -995,11 +995,11 @@
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/docs/guides/rate-limits.md",
- "sourceSha256": "c4897bd3476fa0237eda40643e681ccf5bb6115f0845e5396574240431c414eb",
+ "sourceSha256": "dffd299ba8ab5897b97f2ef4d8aa466ce825dd032ac8afc3dc0c0e2d4f4db61a",
"sourceUrl": "https://developers.openai.com/api/docs/guides/rate-limits.md",
"targetPath": "docs/zh/api/docs/guides/rate-limits.md",
- "targetSha256": "48eb0b1a26a0ff63613909bdb0b021e739a79195777591be493103797940f0f7",
- "translatedAt": "2026-08-29T16:35:21.041Z"
+ "targetSha256": "138e6f5ab8d0689eac6ac42b584eaa3fa4a45be978f68e63da3600d50b43be24",
+ "translatedAt": "2026-09-03T03:34:05.954Z"
},
"https://developers.openai.com/api/docs/guides/rbac.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
@@ -1285,11 +1285,11 @@
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/docs/guides/structured-outputs.md",
- "sourceSha256": "2ae5881fd030b9e7af29eb2f00c87d81d11ef34f0aeab2322c1c7537e3953d49",
+ "sourceSha256": "bbe9c469209404aaf39c8e8dfde9fa9b3a51c69612aa0d9e65d37514bf5a3cc7",
"sourceUrl": "https://developers.openai.com/api/docs/guides/structured-outputs.md",
"targetPath": "docs/zh/api/docs/guides/structured-outputs.md",
- "targetSha256": "bc66072dd1b00dc04f203ad2cc9a6dc8a14efeb9ca3ee25e5ebe6129c8e51ea5",
- "translatedAt": "2026-09-01T09:07:14.635Z"
+ "targetSha256": "3a4dfe2628ca2b5e7151568a948d76cd7e1277530ad955ed7675bf4d9d2f09f7",
+ "translatedAt": "2026-09-03T04:16:02.713Z"
},
"https://developers.openai.com/api/docs/guides/supervised-fine-tuning.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
@@ -1725,11 +1725,11 @@
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/docs/guides/workload-identity-federation/x509.md",
- "sourceSha256": "ca6aec53097c6064df518bdf70e8086fced195dff4c08c611ce2ff032e686977",
+ "sourceSha256": "20fa17aa654dfbdc999b3c32edd8b69a71393f8a6bdf11bd1c5ef94d357a7b7f",
"sourceUrl": "https://developers.openai.com/api/docs/guides/workload-identity-federation/x509.md",
"targetPath": "docs/zh/api/docs/guides/workload-identity-federation/x509.md",
- "targetSha256": "4d16a4fd5635a622c6129da08d1876fe2ab594362664b50f2733132d11afb15a",
- "translatedAt": "2026-08-30T07:24:55.166Z"
+ "targetSha256": "40f55a1cc8974d0b8b4acd6323d3c67c74f4e31be69190b91251df3fe77cd447",
+ "translatedAt": "2026-09-03T04:18:03.414Z"
},
"https://developers.openai.com/api/docs/guides/your-data.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
@@ -1745,11 +1745,11 @@
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/docs/libraries.md",
- "sourceSha256": "b60e466cc95f9f0acbb3ed3c4b6b657fd4aa6496be7ceb1ff991cedff9c3afde",
+ "sourceSha256": "cb73a489a39fcd17b0d11d8c4d94d164b0096959ee359074d255430fc9a6c48f",
"sourceUrl": "https://developers.openai.com/api/docs/libraries.md",
"targetPath": "docs/zh/api/docs/libraries.md",
- "targetSha256": "f4db1fcb946793c5355947542d3b0ff56485897104213e582b63888c6ceb962c",
- "translatedAt": "2026-09-02T01:37:46.772Z"
+ "targetSha256": "0011a1cd81bca8762910bf69fb5235164992f8c1ccfed979c606baf774cd166f",
+ "translatedAt": "2026-09-03T03:38:38.119Z"
},
"https://developers.openai.com/api/docs/libraries/openai-cli.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
@@ -1815,11 +1815,11 @@
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/docs/quickstart.md",
- "sourceSha256": "37b2da97ab63d4600fd8ed1f153195aed4203586263bd6f1e2181c59abd59712",
+ "sourceSha256": "625515beb547405f1f905e58b37af4cfedff54563797a52f6adb96d4a9887f9e",
"sourceUrl": "https://developers.openai.com/api/docs/quickstart.md",
"targetPath": "docs/zh/api/docs/quickstart.md",
- "targetSha256": "f9569c360a2e99ba2a6a20cbff97d84e06fb908a58356a67ab10a5f6fc864291",
- "translatedAt": "2026-09-02T01:42:10.844Z"
+ "targetSha256": "7df435b1b9609c9baa67770eab84e7a2d541d7e0ce5aaf92bd197927455a284b",
+ "translatedAt": "2026-09-03T04:19:01.609Z"
},
"https://developers.openai.com/api/docs/supported-countries.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
@@ -2205,21 +2205,21 @@
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/reference/resources/beta/subresources/responses/streaming-events.md",
- "sourceSha256": "f4564f1ea0a2047a56551939af975e0d7a44d801cf89a9dfa80165789e4483fd",
+ "sourceSha256": "34773d1ba371a5531c0fac7f19f09695a60930c3745ae81157df1ec40e4d39b4",
"sourceUrl": "https://developers.openai.com/api/reference/resources/beta/subresources/responses/streaming-events.md",
"targetPath": "docs/zh/api/reference/resources/beta/subresources/responses/streaming-events.md",
- "targetSha256": "a506d2eb60e346194cc55528186900ed7dbca79eee3ad75c16371d7c471bb8d1",
- "translatedAt": "2026-09-02T01:50:17.651Z"
+ "targetSha256": "6a7997464251a3cef9c8422610fb97ad2f2703a93b18c9cc7e1112ea90782ca0",
+ "translatedAt": "2026-09-03T04:23:44.591Z"
},
"https://developers.openai.com/api/reference/resources/beta/subresources/responses/websocket-events.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/reference/resources/beta/subresources/responses/websocket-events.md",
- "sourceSha256": "167fc150cb5968887146b1c5589733e690327c983924b58bfa700f33982b3630",
+ "sourceSha256": "10e5a9afece3a360744f5717caba82e8e7fb9585451de22ef81ef3abc4a21149",
"sourceUrl": "https://developers.openai.com/api/reference/resources/beta/subresources/responses/websocket-events.md",
"targetPath": "docs/zh/api/reference/resources/beta/subresources/responses/websocket-events.md",
- "targetSha256": "1af3953957362a7355eb1a5bb726737b7730260b4c903a1dfb69da49d649904a",
- "translatedAt": "2026-09-02T01:55:49.469Z"
+ "targetSha256": "c0bdb1a1532c378bfedbfe4e0dfec072e06083e0f10446a3b0ae2c9246971614",
+ "translatedAt": "2026-09-03T04:28:55.631Z"
},
"https://developers.openai.com/api/reference/resources/beta/subresources/threads.md": {
"policySha256": "6e9b1538f41ab5d3db960df19d735ece2c894fe9182904cf1d818170eaeeb7c2",
@@ -2435,51 +2435,51 @@
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/reference/resources/chat.md",
- "sourceSha256": "06969eccad4d7d6f4a40227e59fc502d6f61de9ba59701a90f3d67651e9d86b0",
+ "sourceSha256": "dbb91562ec1bcdf4cdb102a92de58ac6835f1b6f47a30950acc75dbe896768ff",
"sourceUrl": "https://developers.openai.com/api/reference/resources/chat.md",
"targetPath": "docs/zh/api/reference/resources/chat.md",
- "targetSha256": "857efd71a75b29f9b871d754ee26b1bef0cfbce09a9b370a2a42876279240089",
- "translatedAt": "2026-09-02T02:08:03.027Z"
+ "targetSha256": "83592a804f55e27a5dd62200bed06820d993da065b1caa683c2e53a08c738b42",
+ "translatedAt": "2026-09-03T04:33:15.942Z"
},
"https://developers.openai.com/api/reference/resources/chat/subresources/completions/methods/retrieve.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/reference/resources/chat/subresources/completions/methods/retrieve.md",
- "sourceSha256": "fbdb40c776c12edc0fabc89ab3ca41c01463039a21ac47fe05e1735ccb99a7bf",
+ "sourceSha256": "939bcd025a2025fa36d6b3481e853507f5f5edfa4d5b368c6228430eb3abe458",
"sourceUrl": "https://developers.openai.com/api/reference/resources/chat/subresources/completions/methods/retrieve.md",
"targetPath": "docs/zh/api/reference/resources/chat/subresources/completions/methods/retrieve.md",
- "targetSha256": "f128bf92999d616c3a01d6f02a69b13df21ca59a94998cbfa4cec3ac6932a3f5",
- "translatedAt": "2026-09-02T02:09:07.774Z"
+ "targetSha256": "96f1d3232606fb1f17368df3acb6b5f9fd288d573919c22fb174151bed7ee5ed",
+ "translatedAt": "2026-09-03T04:34:02.675Z"
},
"https://developers.openai.com/api/reference/resources/chat/subresources/completions/streaming-events.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/reference/resources/chat/subresources/completions/streaming-events.md",
- "sourceSha256": "6c962133e0dd636e16b5ab4db474d0b765454f0bc5b81529be8dbea3e0aeb72b",
+ "sourceSha256": "b69404059607b96a1351ecad2d18397a4f6b0ece1fa28b05176e3ab6a62146b0",
"sourceUrl": "https://developers.openai.com/api/reference/resources/chat/subresources/completions/streaming-events.md",
"targetPath": "docs/zh/api/reference/resources/chat/subresources/completions/streaming-events.md",
- "targetSha256": "01fb8e45281d6542c5e98ceba023fd90f3783f62c422b70149bfad6ac790725e",
- "translatedAt": "2026-09-02T02:09:31.402Z"
+ "targetSha256": "1666bba69070717467feb0a476a224fe37ae348f4a3d71989b45816bf7b872fe",
+ "translatedAt": "2026-09-03T04:34:33.266Z"
},
"https://developers.openai.com/api/reference/resources/completions.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/reference/resources/completions.md",
- "sourceSha256": "baa793b7514b2e08509ce3b4720abc34d4e49de96407f3480cb1651d2da47a73",
+ "sourceSha256": "f81565d74739e513e166d734e3111f1822a839ee676f9a893561b6f02a89c5dd",
"sourceUrl": "https://developers.openai.com/api/reference/resources/completions.md",
"targetPath": "docs/zh/api/reference/resources/completions.md",
- "targetSha256": "573a49d58f1e77dcc335e48dfb225f9af6990c2277d58973961e827840028ef5",
- "translatedAt": "2026-09-02T02:11:31.969Z"
+ "targetSha256": "664d0d03754804cb54970bd5d78465788b913a71516da74b5d6667a5f9bfce47",
+ "translatedAt": "2026-09-03T04:35:21.510Z"
},
"https://developers.openai.com/api/reference/resources/completions/methods/create.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/reference/resources/completions/methods/create.md",
- "sourceSha256": "76826ac01218d5d474e783bc7a9ae00977e560075a230619918a5820c0b4e42e",
+ "sourceSha256": "ab4184ada6ead1bcf374021cc981c42ff11813fb35dae8829c3e81030793d2c6",
"sourceUrl": "https://developers.openai.com/api/reference/resources/completions/methods/create.md",
"targetPath": "docs/zh/api/reference/resources/completions/methods/create.md",
- "targetSha256": "9b00ac59f47e1fbe63f0c94f50bbedf5d392023ffee9a8d53a936bee23b57774",
- "translatedAt": "2026-09-02T02:12:58.511Z"
+ "targetSha256": "47c9551cc114c7c1fc15714dbb99e8e9b2849e8ba8dca6d22d1894c0a5bdeb7c",
+ "translatedAt": "2026-09-03T04:36:26.005Z"
},
"https://developers.openai.com/api/reference/resources/containers.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
@@ -3815,41 +3815,41 @@
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/reference/resources/responses.md",
- "sourceSha256": "b0e847f3035db84d94135b68442f6e24358fadef8306868fb98bbab82b9c011f",
+ "sourceSha256": "ec3d92f8ebd24a173caca793e2987e7bde90b46110d5287ed2bb65353aa24956",
"sourceUrl": "https://developers.openai.com/api/reference/resources/responses.md",
"targetPath": "docs/zh/api/reference/resources/responses.md",
- "targetSha256": "82503a3684e8f5f9cf22c568508159148ad8327cb2167832bd5fbe9dc586fab8",
- "translatedAt": "2026-09-02T03:31:00.844Z"
+ "targetSha256": "02ef4f29d02f38cbc7cbfe3a84aa80ca32928710103155930923b0d6fa6faa88",
+ "translatedAt": "2026-09-03T04:53:37.044Z"
},
"https://developers.openai.com/api/reference/resources/responses/methods/cancel.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/reference/resources/responses/methods/cancel.md",
- "sourceSha256": "e47089af475693c03a0e7b45a2897ebf8804cb6a424f201048fe34ee77652265",
+ "sourceSha256": "d9a64c149b7c12cc9555b8eb90617e0e893d4fed1155ac0f154fe01b4220a4c8",
"sourceUrl": "https://developers.openai.com/api/reference/resources/responses/methods/cancel.md",
"targetPath": "docs/zh/api/reference/resources/responses/methods/cancel.md",
- "targetSha256": "9de2c7444102c30c92c3c11ef43a7a9b8c7e6c1c5eafec66ddab8bb6db2bc123",
- "translatedAt": "2026-09-02T03:38:05.393Z"
+ "targetSha256": "ed86cdd8f553d55c10522957ad81a5e37ac1e10af30ef995c1911cb441bdbbf7",
+ "translatedAt": "2026-09-03T04:58:58.129Z"
},
"https://developers.openai.com/api/reference/resources/responses/methods/compact.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/reference/resources/responses/methods/compact.md",
- "sourceSha256": "81ed2fef55c1a54536cc3f7aa49a0a37fe24dd82709cf44e114376f00908cfe0",
+ "sourceSha256": "14d4a8df9b03049dae0f1eec392c3dfdfb368d2c5c97b4c7304b781a2ab559ee",
"sourceUrl": "https://developers.openai.com/api/reference/resources/responses/methods/compact.md",
"targetPath": "docs/zh/api/reference/resources/responses/methods/compact.md",
- "targetSha256": "0979081b7d652e13468dbdddb783d77872a30d35425c4de439fea2eab349b1b1",
- "translatedAt": "2026-09-02T03:43:09.866Z"
+ "targetSha256": "278d37bc1d2e4b72338af78a07d998f4a4cb7f761d86940ee00c67950550dd6a",
+ "translatedAt": "2026-09-03T05:03:09.722Z"
},
"https://developers.openai.com/api/reference/resources/responses/methods/create.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/reference/resources/responses/methods/create.md",
- "sourceSha256": "2558551c5d7f8b838207fffa06e7e89beb98e43fc57e3595c641c241f08f224b",
+ "sourceSha256": "fabaaa669f2d37c6f10386b7cca7e0f7a4d025447578b05a11071b5b12c83e3c",
"sourceUrl": "https://developers.openai.com/api/reference/resources/responses/methods/create.md",
"targetPath": "docs/zh/api/reference/resources/responses/methods/create.md",
- "targetSha256": "d1eb12838f0d4c577567a05353ef8497ced7574a06ece6ca19b026485c6b484f",
- "translatedAt": "2026-09-02T03:50:46.919Z"
+ "targetSha256": "5b86ab6405f48b090b3fbaeaa813963c07ddcbec6a83c08b52ff7aac7537fe93",
+ "translatedAt": "2026-09-03T05:09:08.737Z"
},
"https://developers.openai.com/api/reference/resources/responses/methods/delete.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
@@ -3865,21 +3865,21 @@
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/reference/resources/responses/methods/retrieve.md",
- "sourceSha256": "35223714d2aa6e0454c2b7690cdcd26690a51a05e0a9e686e7f37b9d212e8304",
+ "sourceSha256": "d6674ba8e3aaf56971727c6bb10525fd3fb84a044d875c15a8d6e831c067b891",
"sourceUrl": "https://developers.openai.com/api/reference/resources/responses/methods/retrieve.md",
"targetPath": "docs/zh/api/reference/resources/responses/methods/retrieve.md",
- "targetSha256": "20f2867dfc9b1b97b3fec3092df663c1004b9027b8de2455375f2e8d875bb5f8",
- "translatedAt": "2026-09-02T03:56:33.467Z"
+ "targetSha256": "30da34358043c5057a46905a12446f70d60e193aab5014e75435a3e25845108e",
+ "translatedAt": "2026-09-03T05:14:47.258Z"
},
"https://developers.openai.com/api/reference/resources/responses/streaming-events.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/reference/resources/responses/streaming-events.md",
- "sourceSha256": "920cb602350f5847272e48cf1df7cab859c6383258cbb5f8ccd5953a51f4b95e",
+ "sourceSha256": "a872bebc2a3a76a68232d096f0bb17d98ae5a4ad5131818d6d41e53a2f30f434",
"sourceUrl": "https://developers.openai.com/api/reference/resources/responses/streaming-events.md",
"targetPath": "docs/zh/api/reference/resources/responses/streaming-events.md",
- "targetSha256": "dc2ad1ff5b6e19254f8a605b0a862713cdbee0632e1291da4cbcb538f0819e44",
- "translatedAt": "2026-09-02T04:01:37.975Z"
+ "targetSha256": "af45e8ee9542f5229dcc0b122d03b739adc9a6fda8a58671a3530632806eadd9",
+ "translatedAt": "2026-09-03T05:19:26.051Z"
},
"https://developers.openai.com/api/reference/resources/responses/subresources/input_items/methods/list.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
@@ -3905,11 +3905,11 @@
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
"reviewStatus": "machine",
"sourcePath": "docs/en/api/reference/resources/responses/websocket-events.md",
- "sourceSha256": "5c2e7ea97db804dcc5b5287500b9f74fd5ff3fa9f25d55c97314fd8c53e13f99",
+ "sourceSha256": "94c5254565833a22d88341f3a13809e25be371d390ae6add4081213a56ea9aa5",
"sourceUrl": "https://developers.openai.com/api/reference/resources/responses/websocket-events.md",
"targetPath": "docs/zh/api/reference/resources/responses/websocket-events.md",
- "targetSha256": "e6655c9040ae7d0a6aae08563432fecfb26d0a648366c0ef944a80dcc6fec0da",
- "translatedAt": "2026-09-02T04:10:59.213Z"
+ "targetSha256": "477b5e089d1decc591f630a803fd5ab2ad5a78d2d6424d95f323f4f1473c8be1",
+ "translatedAt": "2026-09-03T05:24:05.315Z"
},
"https://developers.openai.com/api/reference/resources/uploads.md": {
"policySha256": "5d41c8a7a73acf25529f1beffa364a03666ea413b7e792e6db794b8f801777b5",
diff --git a/docs/zh/api/docs/changelog.md b/docs/zh/api/docs/changelog.md
index a157003..7e22096 100644
--- a/docs/zh/api/docs/changelog.md
+++ b/docs/zh/api/docs/changelog.md
@@ -1,132 +1,142 @@
# 更新日志
-> 完整文档索引请参阅 [llms.txt](/llms.txt)。可通过在页面 URL 末尾追加 `.md` 获取文档页面的 Markdown 版本。
+> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。在页面 URL 末尾添加 `.md` 即可获取文档页面的 Markdown 版本。
-> 该公司 OpenAI API 的最新功能与更新。
+> OpenAI API 的最新功能与更新。
即将进行的弃用列在 [弃用页面](/api/docs/deprecations).
+## 2026 年 9 月
+
+### 9 月 2 日
+
+更新
+
+已更新 API 错误,以便应用能够区分流量增长过快与临时性的模型过载。
+
+流量增长过快时,会返回 `429` 错误,对应的 `slow_down` 状态码。临时性的模型过载则返回 `503` 错误,对应的 `server_is_overloaded` 状态码。两种响应都可能会包含 `Retry-After`。当该响应头存在时,请至少按其指定的时间等待后再重试;若不存在,则使用指数退避策略。详见 [错误码指南](https://developers.openai.com/api/docs/guides/error-codes) 和 [速率限制指南](https://developers.openai.com/api/docs/guides/rate-limits).
+
## 2026 年 8 月
### 8 月 29 日
功能
-[双向 TLS(mTLS)](https://developers.openai.com/api/docs/guides/mutual-tls) 和 [X.509 工作负载身份联合](https://developers.openai.com/api/docs/guides/workload-identity-federation/x509) 现已在 OpenAI API 全面可用。你可以直接在 [Platform 控制台](https://platform.openai.com/settings/organization/security),中配置证书和 X.509 身份提供者,访问权限由你所在组织的角色和权限控制。
+[Mutual TLS(mTLS)](https://developers.openai.com/api/docs/guides/mutual-tls) 和 [X.509 工作负载身份联合](https://developers.openai.com/api/docs/guides/workload-identity-federation/x509) 现已在 OpenAI API 全面上线。可直接在 [Platform 控制台](https://platform.openai.com/settings/organization/security),中配置证书和 X.509 身份提供商,并通过你所在组织的角色与权限进行访问控制。
### Aug 26
更新 · 模型:whisper-1 · 模型:gpt-4o-transcribe · 模型:gpt-4o-mini-transcribe · 模型:gpt-4o-transcribe-diarize · API:v1/audio/transcriptions · API:v1/realtime
-宣布弃用 `whisper-1`, `gpt-4o-transcribe`, `gpt-4o-mini-transcribe`,以及 `gpt-4o-transcribe-diarize`。这些模型将于 2027-02-26 停用。请迁移到 [`gpt-live-transcribe`](https://developers.openai.com/api/docs/models/gpt-live-transcribe) 或 [`gpt-transcribe`](https://developers.openai.com/api/docs/models/gpt-transcribe)。请参阅 [转录指南](https://developers.openai.com/api/docs/guides/transcription) 和 [弃用页面](https://developers.openai.com/api/docs/deprecations).
+宣布弃用 `whisper-1`, `gpt-4o-transcribe`, `gpt-4o-mini-transcribe`,和 `gpt-4o-transcribe-diarize`。这些模型将于 2027-02-26 下线。请迁移至 [`gpt-live-transcribe`](https://developers.openai.com/api/docs/models/gpt-live-transcribe) 或 [`gpt-transcribe`](https://developers.openai.com/api/docs/models/gpt-transcribe)。请参阅 [转录指南](https://developers.openai.com/api/docs/guides/transcription) 和 [弃用页面](https://developers.openai.com/api/docs/deprecations).
-Assistants API 已于 2026 年 8 月 26 日停用。请迁移到 Responses API 与 Conversations API 并使用 [迁移指南](https://developers.openai.com/api/docs/assistants/migration).
+Assistants API 将于 2026-08-26 停用。请迁移到 Responses API 和 Conversations API,使用 [迁移指南](https://developers.openai.com/api/docs/assistants/migration).
### Aug 21
功能
-API 客户现在可以为单个请求选择区域处理,只需使用来自 Global 地理的项目中的 API 密钥,并配上相应的前缀域名即可。现有的资格、数据保留控制、端点和模型支持要求仍然适用。更多信息请参阅 [数据控制指南](https://developers.openai.com/api/docs/guides/your-data#select-a-processing-region-per-request).
+API 客户现在可以为单个请求选择区域处理,只需在使用具有 Global 地理区域的项目中的 API 密钥时,使用带有前缀的域名即可。现有的资格、数据留存控制、端点和模型支持要求仍然适用。更多信息请参阅 [数据控制指南](https://developers.openai.com/api/docs/guides/your-data#select-a-processing-region-per-request).
### Aug 21
更新 · 模型:gpt-5.6-sol
-GPT-5.6 Sol 现在的价格为每百万输入 token 4 美元,每百万输出 token 20 美元,输入价格降低 20%,输出价格降低 33%。GPT-5.6 Sol 的促销定价至少持续到 2026 年 11 月 21 日。详见 [定价详情](https://developers.openai.com/api/docs/pricing).
+GPT-5.6 Sol 现行的定价为输入 400 万美元每百万 token、输出 2000 万美元每百万 token,相比之前输入价格降低 20%,输出价格降低 33%。GPT-5.6 Sol 的促销定价至少持续至 2026-11-21。详情请参阅 [定价详情](https://developers.openai.com/api/docs/pricing).
### Aug 20
功能
-已发布 [提示缓存仪表板](https://platform.openai.com/usage?usage_section=prompt-caching) 在 OpenAI API 平台上。跟踪你的缓存命中率随时间的变化情况、每次写入的缓存读取次数,以及缓存读取、缓存写入和未缓存 token 的细分情况,以了解你的缓存效率并识别改进机会。按模型和服务层级筛选指标。
+发布了 [Prompt Caching 仪表板](https://platform.openai.com/usage?usage_section=prompt-caching) ,位于 OpenAI API 平台。你可以追踪缓存命中率随时间的变化、每次写入的缓存读取次数,以及缓存读取、缓存写入和未缓存令牌的细分,从而了解缓存效率并识别改进机会。可按模型和服务层级筛选指标。
### Aug 20
更新 · 模型:gpt-image-2 · 模型:gpt-image-2-2026-04-21 · API:v1/images/generations · API:v1/images/edits · API:v1/responses
-透明背景现已在以下场景中提供预览 `gpt-image-2` 和 `gpt-image-2-2026-04-21` 在 Images API 和 Responses API 图像生成工具中。将 `background` 设置为 `transparent` 并使用 `png` 或 `webp` 输出; `jpeg` 不支持透明背景。在以下位置了解更多信息: [图像生成指南](https://developers.openai.com/api/docs/guides/image-generation#customize-image-output).
+透明背景现已在 `gpt-image-2` 和 `gpt-image-2-2026-04-21` 的 Images API 和 Responses API 图像生成工具中提供预览。设置 `background` 为 `transparent` 并使用 `png` 或 `webp` 输出; `jpeg` 不支持透明背景。详细了解请参阅 [图像生成指南](https://developers.openai.com/api/docs/guides/image-generation#customize-image-output).
-### 8 月 13 日
+### Aug 13
公告
-宣布推出 Ultrafast 模式,这是 API 中的一项新服务层级,专为 GPT-5.6 Sol 设计,处理速度最高可达 Standard 模式的 14 倍。目前以限量预览形式向特定客户开放。注册以接收 Ultrafast 模式的最新动态 [此处](https://openai.com/form/ultrafast/).
+宣布推出 Ultrafast 模式,这是面向 GPT-5.6 Sol 的全新 API 服务等级,处理速度最高可达 Standard 的 14 倍。目前以有限预览形式向部分客户提供。注册以接收 Ultrafast 模式的更新 [此处](https://openai.com/form/ultrafast/).
-### 8月7日
+### Aug 7
功能 · 模型:gpt-5.6-cyber · 模型:gpt-daybreak-red-latest · 模型:gpt-daybreak-blue-latest · API:v1/responses
-Daybreak 现在为获得批准的防御方提供两个访问层级:Daybreak Blue 和 Daybreak Red。使用它们可在明确授权的参与中,将安全发现推进到经验证的修复。
+Daybreak 现已为获得批准的防御方提供两个访问层级:Daybreak Blue 和 Daybreak Red。你可以在明确授权的攻防任务中,将它们用于把安全发现推进到经过验证的修复环节。
-对于大多数防御性安全工作,请从 Daybreak Blue 开始。它提供对通用模型的访问,例如 GPT-5.6 Sol,用于漏洞发现、安全代码审查、检测工程、事件响应、恶意软件分析和补丁验证。阅读更多 [此处](https://developers.openai.com/api/docs/models/gpt-daybreak-blue-latest).
+对大多数防御性安全工作,请从 Daybreak Blue 开始。它可访问通用模型,例如 GPT-5.6 Sol,用于漏洞发现、安全代码审查、检测工程、事件响应、恶意软件分析与补丁验证。阅读全文 [此处](https://developers.openai.com/api/docs/models/gpt-daybreak-blue-latest).
-Daybreak Red 提供单独批准的、面向专门训练模型的访问权限,例如 [GPT-5.6 Cyber](https://developers.openai.com/api/docs/models/gpt-5.6-cyber) 用于已授权的漏洞复现、漏洞利用验证、渗透测试、红队演练和复杂系统分析。
+Daybreak Red 提供单独审批后才能使用的、面向特定用途训练的模型,例如 [GPT-5.6 Cyber](https://developers.openai.com/api/docs/models/gpt-5.6-cyber) ,用于获得授权的漏洞复现、漏洞利用验证、渗透测试、红队演练和复杂系统分析。
-这些模型需要单独的批准和资源配置。你可以申请加入 Daybreak 项目 [此处](https://openai.com/daybreak/)。更多定价详情 [此处](https://developers.openai.com/api/docs/pricing).
+这些模型需要单独的审批与配置。你可以申请加入 Daybreak 项目 [此处](https://openai.com/daybreak/)。更多定价详情 [此处](https://developers.openai.com/api/docs/pricing).
-### 8 月 6 日
+### 8月6日
更新 · 模型:chat-latest
-已更新 **chat-latest** snapshot,它指向面向 Plus 和 Pro 用户的 ChatGPT 中可用的最新模型。我们建议使用 [GPT-5.6 Sol](https://developers.openai.com/api/docs/models/gpt-5.6-sol) 用于生产环境的 API 调用,但你可以自由地使用该模型来测试聊天用例的最新改进。其底层模型快照将会定期更新。阅读更多 [此处](https://developers.openai.com/api/docs/models/chat-latest).
+已更新 **chat-latest** 快照,该快照指向 ChatGPT 中面向 Plus 和 Pro 用户开放的最新模型。我们建议在生产环境中使用 [GPT-5.6 Sol](https://developers.openai.com/api/docs/models/gpt-5.6-sol) 用于生产环境中的 API 使用,但你可以使用此模型测试聊天场景的最新改进。底层模型快照将定期更新。阅读更多 [此处](https://developers.openai.com/api/docs/models/chat-latest).
-### Aug 5
+### 8 月 5 日
更新 · Model: gpt-5.6-sol · Model: gpt-5.6-terra · Model: gpt-5.6-luna
-快速模式现已支持 GPT-5.6 Sol、GPT-5.6 Terra 和 GPT-5.6 Luna 的长上下文请求。从今天起,超过 272K tokens 的长上下文提示可以在 [快速模式](https://developers.openai.com/api/docs/guides/fast-mode),下运行,速度比标准层最高快 2.5×。详见 [定价详情](https://developers.openai.com/api/docs/pricing).
+Fast 模式现已支持 GPT-5.6 Sol、GPT-5.6 Terra 和 GPT-5.6 Luna 的长上下文请求。从今天起,超过 272K token 的长上下文提示词可以在 [Fast 模式](https://developers.openai.com/api/docs/guides/fast-mode),下运行,速度比 Standard 层级快达 2.5×。详见 [定价详情](https://developers.openai.com/api/docs/pricing).
-### 8 月 4 日
+### Aug 4
功能
-客户现在可以在 [用量和费用仪表板](https://platform.openai.com/settings/organization/usage)。中按 API 键对数据进行筛选和分组。API [用量 接口](https://developers.openai.com/api/reference/resources/admin/subresources/organization/subresources/usage) 和 [费用 API](https://developers.openai.com/api/reference/resources/admin/subresources/organization/subresources/usage/methods/costs) 也支持 API 键维度,便于以编程方式生成报表和分析。
+客户现在可以在使用情况和成本仪表板中按 API key 筛选和分组数据 [使用情况和成本仪表板](https://platform.openai.com/settings/organization/usage)。 [用量 API](https://developers.openai.com/api/reference/resources/admin/subresources/organization/subresources/usage) 和 [费用 API](https://developers.openai.com/api/reference/resources/admin/subresources/organization/subresources/usage/methods/costs) 还支持 API 密钥维度,用于以编程方式进行报告与分析。
-## 2026 年 7 月
+## 2026年7月
-### 7 月 30 日
+### 7月30日
更新 · 模型:gpt-5.6-sol · 模型:gpt-5.6-terra · 模型:gpt-5.6-luna · API:v1/responses · API:v1/chat/completions
-从 7 月 30 日起,GPT-5.6 Luna 的价格下调 80%,GPT-5.6 Terra 的价格下调 20%。详见 [定价详情](https://developers.openai.com/api/docs/pricing).
+自 7 月 30 日起,GPT-5.6 Luna 的价格降低 80%,GPT-5.6 Terra 的价格降低 20%。详见 [定价详情](https://developers.openai.com/api/docs/pricing).
-我们还推出了 [快速模式](https://developers.openai.com/api/docs/guides/fast-mode) 功能(在 API 中),用于替代原有的 Priority Processing 服务。针对 GPT-5.6 Sol,Fast 模式现在可在标准处理速度基础上提供最高 2.5 倍的提速,定价为标准处理的两倍。该变更向后兼容:标记为 priority 的请求将自动使用 Fast 模式。
+我们同时推出 [Fast 模式](https://developers.openai.com/api/docs/guides/fast-mode) ,应用于 API,取代此前的 Priority Processing 服务。针对 GPT-5.6 Sol,Fast 模式现以两倍价格提供最高 2.5 倍于标准处理的速度。该变更向后兼容:标记为 priority 的请求将自动使用 Fast 模式。
-### 7月29日
+### 7月 29日
功能
-发布了官方的 [OpenAI Terraform provider](https://developers.openai.com/api/docs/guides/terraform) 用于将 OpenAI API 平台资源作为基础设施即代码进行管理。
+发布了官方 [OpenAI Terraform provider](https://developers.openai.com/api/docs/guides/terraform) 用于以基础设施即代码的方式管理 OpenAI API Platform 资源。
-配置和管理项目、用户、组、角色、访问分配、服务账户、证书、邀请以及项目级速率限制。使用标准 Terraform 工作流来审查和应用更改、导入现有资源,并检测和协调配置漂移。从 [Terraform Registry](https://registry.terraform.io/providers/openai/openai/latest).
+预置和管理项目、用户、组、角色、访问分配、服务账户、证书、邀请和项目级速率限制。使用标准 Terraform 工作流审查和应用更改、导入现有资源,以及检测和协调配置漂移。从 [Terraform Registry](https://registry.terraform.io/providers/openai/openai/latest).
-### 7 月 28 日
+### Jul 28
功能 · 模型:gpt-transcribe · 模型:gpt-live-transcribe · API:v1/audio/transcriptions · API:v1/realtime
-发布 [GPT Transcribe](https://developers.openai.com/api/docs/models/gpt-transcribe) 用于准确转录文件,以及为已提交的 Realtime 轮次生成最终转录文本,并支持 [GPT Live Transcribe](https://developers.openai.com/api/docs/models/gpt-live-transcribe) 用于低延迟流式转录。
+已发布 [GPT Transcribe](https://developers.openai.com/api/docs/models/gpt-transcribe) 用于精确的文件转写以及已提交 Realtime 轮次的最终转写文本,以及 [GPT Live Transcribe](https://developers.openai.com/api/docs/models/gpt-live-transcribe) 用于低延迟流式转写。
-这两个模型均支持自由格式转录上下文、关键词提示以及多种预期输入语言。支持的输出和工作流比较请参阅 [转录指南](https://developers.openai.com/api/docs/guides/transcription).
+这两个模型都支持自由形式的转写上下文、关键词提示以及多种预期的输入语言。在 [转录指南](https://developers.openai.com/api/docs/guides/transcription).
-### Jul 22
+### 7月22日
功能
-为 OpenAI API 平台的组织和项目新增硬性支出上限。设置月度上限,当追踪到的支出达到上限时,受影响的 API 请求将返回 `429` 错误。使用支出提醒,在流量中断之前接收通知。更多信息请参阅 [支出上限指南](https://developers.openai.com/api/docs/guides/spend-limits).
+为 OpenAI API 平台上的组织和项目添加了硬性支出限额。可设置月度上限,当跟踪的支出达到该上限时,受影响的 API 请求将返回 `429` 错误。请使用支出提醒在流量中断前进行通知。详情请参阅 [支出限额指南](https://developers.openai.com/api/docs/guides/spend-limits).
### Jul 9
-特性 · 模型:gpt-5.6-sol · 模型:gpt-5.6-terra · 模型:gpt-5.6-luna · API:v1/responses · API:v1/chat/completions · API:v1/batch
+功能 · 模型: gpt-5.6-sol · 模型: gpt-5.6-terra · 模型: gpt-5.6-luna · API: v1/responses · API: v1/chat/completions · API: v1/batch
-已发布 [GPT-5.6 模型系列](https://developers.openai.com/api/docs/guides/latest-model),包括面向前沿能力的 GPT-5.6 Sol、在智能与成本之间取得平衡的 GPT-5.6 Terra,以及面向高吞吐高效工作负载的 GPT-5.6 Luna。 `gpt-5.6` 别名将请求路由到 `gpt-5.6-sol`.
+发布了 [GPT-5.6 模型系列](https://developers.openai.com/api/docs/guides/latest-model),包括 GPT-5.6 Sol 用于前沿能力、GPT-5.6 Terra 在智能和成本之间取得平衡,以及GPT-5.6 Luna 用于高效、大规模的工作负载。 `gpt-5.6` 别名会将请求路由到 `gpt-5.6-sol`.
-GPT-5.6 新增了 [可编程工具调用](https://developers.openai.com/api/docs/guides/tools-programmatic-tool-calling), [显式提示缓存控制](https://developers.openai.com/api/docs/guides/prompt-caching), [持久化推理, `max` 推理强度与 Pro 模式](https://developers.openai.com/api/docs/guides/reasoning),以及 [面向 Responses API 的多智能体编排(测试版)](https://developers.openai.com/api/docs/guides/responses-multi-agent)。GPT-5.6 还支持按原始尺寸接收图像,同时提供 `original` 或 `auto` 图像细节选项。
+GPT-5.6 新增 [可编程工具调用](https://developers.openai.com/api/docs/guides/tools-programmatic-tool-calling), [显式提示缓存控制](https://developers.openai.com/api/docs/guides/prompt-caching), [持久化推理, `max` 推理力度和 Pro 模式](https://developers.openai.com/api/docs/guides/reasoning),和 [多智能体编排现已在 Responses API 中提供 Beta 版](https://developers.openai.com/api/docs/guides/responses-multi-agent)。GPT-5.6 还支持以原始尺寸接收图像,并提供 `original` 或 `auto` 图像细节选项。
-### 7月6日
+### Jul 6
-Feature · Model: gpt-realtime-2.1 · Model: gpt-realtime-2.1-mini · API: v1/realtime
+特性 · 模型:gpt-realtime-2.1 · 模型:gpt-realtime-2.1-mini · API:v1/realtime
-发布 [GPT-Realtime-2.1](https://developers.openai.com/api/docs/models/gpt-realtime-2.1),一款更新的实时推理模型,具有改进的字母数字识别、静音与噪声处理以及打断行为。同时发布了 [GPT-Realtime-2.1 mini](https://developers.openai.com/api/docs/models/gpt-realtime-2.1-mini),一款速度更快、成本更低的实时语音应用蒸馏推理模型。
+已发布 [GPT-Realtime-2.1](https://developers.openai.com/api/docs/models/gpt-realtime-2.1),这是一款经过更新的实时推理模型,提升了字母数字识别、静音与噪声处理以及打断表现。同时还发布了 [GPT-Realtime-2.1 mini](https://developers.openai.com/api/docs/models/gpt-realtime-2.1-mini),这是一款更快、成本更低的蒸馏推理模型,适用于实时语音应用。
## 2026 年 6 月
@@ -134,170 +144,170 @@ Feature · Model: gpt-realtime-2.1 · Model: gpt-realtime-2.1-mini · API: v1/re
更新 · 模型:chat-latest
-已更新 `chat-latest` snapshot,它指向 ChatGPT 当前使用的最新 Instant 模型。我们建议利用 [GPT-5.5](https://developers.openai.com/api/docs/models/gpt-5.5) 用于生产环境的 API 调用,但你可以自由地使用该模型来测试聊天用例的最新改进。其底层模型快照将会定期更新。阅读更多 [此处](https://developers.openai.com/api/docs/models/chat-latest).
+已更新 `chat-latest` 快照,指向 ChatGPT 当前使用的最新 Instant 模型。我们建议利用 [GPT-5.5](https://developers.openai.com/api/docs/models/gpt-5.5) 用于生产环境中的 API 使用,但你可以使用此模型测试聊天场景的最新改进。底层模型快照将定期更新。阅读更多 [此处](https://developers.openai.com/api/docs/models/chat-latest).
### Jun 23
功能
-已在 OpenAI API 平台上发布安全使用仪表板。安全仪表板会根据请求中发送的用于识别最终用户的值,显示被阻止的 Responses 请求。 `safety_identifier` 请访问 [安全仪表板](https://platform.openai.com/usage/safety).
+在 OpenAI API 平台发布了 Safety Usage Dashboard。Safety 面板根据以下内容展示被拦截的 Responses 请求 `safety_identifier` 请求中发送的用于识别最终用户的值。访问 [Safety 面板](https://platform.openai.com/usage/safety).
-### Jun 9
+### 6月9日
-特性 · API: v1/responses
+功能 · API: v1/responses
-网页搜索现在可以与常规文本结果一起返回图像结果。当你的应用需要当前或基于网络的视觉内容(例如产品照片、地标、地点、事件或视觉参考)时,请使用图像搜索。更多信息请参阅 [网页搜索 指南](https://developers.openai.com/api/docs/guides/tools-web-search).
+网页搜索现在可以在常规文本结果之外同时返回图片结果。当你的应用需要来自网络且基于现实的视觉内容(例如产品照片、地标、地点、事件或视觉参考)时,可使用图片搜索。更多信息请参阅 [网页搜索 指南](https://developers.openai.com/api/docs/guides/tools-web-search).
### Jun 5
-更新日志
+更新
-发布了重新设计的 OpenAI API 平台导航,请访问 [此处](https://platform.openai.com/login).
+发布了重新设计的 OpenAI API 平台导航,访问 [此处](https://platform.openai.com/login).
### Jun 4
-功能 · 模型:omni-moderation-latest · API:v1/responses · API:v1/chat/completions
+功能 · 模型:omni-moderation-latest · API: v1/responses · API: v1/chat/completions
-已为 Responses API 和 Chat Completions API 添加审核评分。在生成请求中传入 `moderation` 对象,即可在同一响应中同时获得模型输入和生成输出的审核结果。
+已在 Responses API 和 Chat Completions API 中新增审核评分。在生成请求中传入 `moderation` 对象,即可在同一响应中获取模型输入与生成输出的审核结果。
-了解更多,请参阅 [审核指南](https://developers.openai.com/api/docs/guides/moderation#moderate-generated-content).
+详见 [审核指南](https://developers.openai.com/api/docs/guides/moderation#moderate-generated-content).
### Jun 3
-更新日志
+更新
-宣布弃用可复用的提示对象、Evals 平台以及 智能体 Builder。请参阅 [弃用页面](https://developers.openai.com/api/docs/deprecations) 以了解停用时间表和迁移指南。
+宣布弃用可复用的提示对象、Evals 平台以及智能体构建器(智能体 Builder)。请参阅 [弃用页面](https://developers.openai.com/api/docs/deprecations) 以了解停用时间表和迁移指南。
-### Jun 2
+### 6月2日
-更新日志
+更新
-自 2026 年 6 月 2 日起,符合条件的容器会话将按分钟计费,最低计费时长为 5 分钟,而不再按完整的 20 分钟会话费率计费。底层每分钟费率保持不变。
+自 2026 年 6 月 2 日起,符合条件的容器会话将按分钟计费,最低计费 5 分钟,而不再按完整的 20 分钟会话费率计费。底层的按分钟费率将保持不变。
此次更新旨在为较短会话提供更精细的计费方式,并降低客户的实际成本。
-你可以在我们的 [API 定价文档中找到当前的内置工具定价](https://developers.openai.com/api/docs/pricing#built-in-tools).
+你可以在我们的 [API 计费文档中查看当前的内置工具定价](https://developers.openai.com/api/docs/pricing#built-in-tools).
### Jun 1
Feature · Model: gpt-5.4 · Model: gpt-5.5 · API: v1/responses
-OpenAI 模型现已通过兼容 OpenAI 的 Responses API 端点在 Amazon Bedrock 中可用。支持的模型和功能因 AWS 区域而异。 [了解更多](https://developers.openai.com/api/docs/guides/amazon-bedrock).
+OpenAI 模型现已通过兼容 OpenAI 的 Responses API 端点在 Amazon Bedrock 中可用。受支持的模型和功能因 AWS 区域而异。 [了解详情](https://developers.openai.com/api/docs/guides/amazon-bedrock).
## 2026 年 5 月
### 5 月 29 日
-更新 · API: v1/responses · API: v1/chat/completions · API: v1/batch
+更新 · API:v1/responses · API:v1/chat/completions · API:v1/batch
-对于未启用 ZDR 的组织, `prompt_cache_retention` 现在默认为 `24h` 而非 `in_memory`,默认启用扩展的提示缓存。 [了解更多](https://developers.openai.com/api/docs/guides/prompt-caching#extended-prompt-cache-retention).
+对于未启用 ZDR 的组织, `prompt_cache_retention` 现在默认为 `24h` 而不是 `in_memory`,从而默认启用扩展提示缓存。 [了解详情](https://developers.openai.com/api/docs/guides/prompt-caching#extended-prompt-cache-retention).
### May 28
更新 · 模型:chat-latest
-发布 `chat-latest` 指向当前 ChatGPT 中使用的最新 Instant 模型的快照。我们建议使用 [GPT-5.5](https://developers.openai.com/api/docs/models/gpt-5.5) 用于生产环境的 API 调用,但你可以自由地使用该模型来测试聊天用例的最新改进。其底层模型快照将会定期更新。阅读更多 [此处](https://developers.openai.com/api/docs/models/chat-latest).
+已发布 `chat-latest` 指向 ChatGPT 当前使用的最新 Instant 模型的快照。建议使用 [GPT-5.5](https://developers.openai.com/api/docs/models/gpt-5.5) 用于生产环境中的 API 使用,但你可以使用此模型测试聊天场景的最新改进。底层模型快照将定期更新。阅读更多 [此处](https://developers.openai.com/api/docs/models/chat-latest).
### May 26
功能
-发布 [工作负载身份联合](https://developers.openai.com/api/docs/guides/workload-identity-federation)。受信工作负载可以使用外部颁发的身份令牌换取短期的 OpenAI 访问令牌,无需存储长期 API 密钥。
+已发布 [工作负载身份联合](https://developers.openai.com/api/docs/guides/workload-identity-federation)。受信工作负载可以将外部签发的身份令牌交换为短期 OpenAI 访问令牌,而无需存储长期 API 密钥。
### May 26
-更新日志
+更新
-新增了 [Admin API](https://developers.openai.com/api/docs/guides/admin-apis) 用于管理支出提醒、模型许可名单、数据保留设置以及托管工具权限的能力,并可查询细粒度的账单明细项。
+新增了 [Admin API](https://developers.openai.com/api/docs/guides/admin-apis) 功能,可用于管理支出提醒、模型允许列表、数据保留设置以及 托管工具 权限,并支持查询精细化的账单明细项。
### May 19
功能
-发布 [Secure MCP Tunnel](https://developers.openai.com/api/docs/guides/secure-mcp-tunnels) 面向企业客户。Secure MCP Tunnel 可让受支持的 OpenAI 产品(包括 ChatGPT 网页版、Codex、Responses API 以及 AgentKit)通过客户自托管的方式连接私有或本地部署的 MCP 服务器 `tunnel-client` 而无需将这些服务器暴露在公共互联网上。
+已发布 [Secure MCP Tunnel](https://developers.openai.com/api/docs/guides/secure-mcp-tunnels) 面向企业客户。Secure MCP Tunnel 可让受支持的 OpenAI 产品(包括 ChatGPT web、Codex、Responses API 以及 AgentKit)通过客户自托管的 `tunnel-client` 连接到私有或本地 MCP 服务器,而无需将这些服务器暴露到公网。
### May 19
-更新日志
+更新
-现在你可以管理多个 IP 白名单,并将每个白名单应用于项目级别或整个组织。若要进行配置,请前往 [Settings > Security > IP allowlist](https://platform.openai.com/settings/organization/security/ip-allowlist).
+你现在可以管理多个 IP 白名单,并将每个白名单应用于项目级别或整个组织。若要配置它们,请前往 [Settings > Security > IP allowlist](https://platform.openai.com/settings/organization/security/ip-allowlist).
-### May 12
+### 5月12日
-更新 · 模型:dall-e-2 · 模型:dall-e-3 · API:v1/realtime
+Update · Model: dall-e-2 · Model: dall-e-3 · API: v1/realtime
已弃用的 DALL·E 模型快照以及 Realtime API Beta。
-DALL·E 模型快照 `dall-e-2` 和 `dall-e-3` 已于 2026 年 5 月 12 日被弃用并从 API 中移除。建议使用 `gpt-image-2`, `gpt-image-1`,或 `gpt-image-1-mini` 代替。
+DALL·E 模型快照 `dall-e-2` 和 `dall-e-3` 已于 2026 年 5 月 12 日在 API 中被弃用并移除。我们建议使用 `gpt-image-2`, `gpt-image-1`,或者 `gpt-image-1-mini` 取而代之的是。
-Realtime API Beta 已于 2026 年 5 月 12 日被弃用并从 API 中移除。如果你仍在使用 beta 接口,请迁移到已发布的 Realtime API。请参阅 [迁移指南](https://developers.openai.com/api/docs/guides/realtime#beta-to-ga-migration) 以及完整的 [弃用页面](https://developers.openai.com/api/docs/deprecations).
+Realtime API Beta 已于 2026/05/12 被弃用并从 API 中移除。如果你仍在使用 beta 接口,请迁移到已发布的 Realtime API。请参阅 [迁移指南](https://developers.openai.com/api/docs/guides/realtime#beta-to-ga-migration) 和完整的 [弃用页面](https://developers.openai.com/api/docs/deprecations).
### 5 月 11 日
-特性 · API: v1/responses
+功能 · API: v1/responses
-新增 `return_token_budget` 了适用于 Responses API 的 [网页搜索 工具](https://developers.openai.com/api/docs/guides/tools-web-search#run-longer-web-research)。可用于选择启用更长时间的 GPT-5+ 推理网页搜索运行,以满足高强度研究和评估工作负载的需求。
+新增 `return_token_budget` 面向 Responses API 的 [网页搜索 工具](https://developers.openai.com/api/docs/guides/tools-web-search#run-longer-web-research),可用于选择加入更长时间的 GPT-5+ 推理 网页搜索 运行,适用于高投入度的研究与评估工作负载。
-### 5 月 7 日
+### 5月7日
-特性 · 模型:gpt-realtime-2 · 模型:gpt-realtime-translate · 模型:gpt-realtime-whisper · API:v1/realtime · API:v1/realtime/translations · API:v1/realtime/transcription_sessions
+功能 · 模型:gpt-realtime-2 · 模型:gpt-realtime-translate · 模型:gpt-realtime-whisper · API:v1/realtime · API:v1/realtime/translations · API:v1/realtime/transcription_sessions
-发布 [GPT-Realtime-2](https://developers.openai.com/api/docs/models/gpt-realtime-2),一款面向语音到语音智能体的全新实时语音模型,支持可配置推理,以及 [GPT-Realtime-Translate](https://developers.openai.com/api/docs/models/gpt-realtime-translate) 用于流式语音翻译,以及 [GPT-Realtime-Whisper](https://developers.openai.com/api/docs/models/gpt-realtime-whisper) 用于流式语音转文本。
+已发布 [GPT-Realtime-2](https://developers.openai.com/api/docs/models/gpt-realtime-2),这是一款新的实时语音模型,支持为语音到语音 智能体 配置推理能力,并新增了 [GPT-Realtime-Translate](https://developers.openai.com/api/docs/models/gpt-realtime-translate) 用于流式语音翻译,以及 [GPT-Realtime-Whisper](https://developers.openai.com/api/docs/models/gpt-realtime-whisper) 用于流式语音转文字。
-已更新 [实时与音频指南](https://developers.openai.com/api/docs/guides/realtime),新增了专属的 [实时翻译指南](https://developers.openai.com/api/docs/guides/realtime-translation),更新了 [实时转录](https://developers.openai.com/api/docs/guides/realtime-transcription) 以支持流式转录,并将实时提示词相关指导移入 [使用实时模型](https://developers.openai.com/api/docs/guides/realtime-models-prompting).
+已更新 [实时 接口 和音频指南](https://developers.openai.com/api/docs/guides/realtime),新增了专用的 [实时翻译指南](https://developers.openai.com/api/docs/guides/realtime-translation),更新了 [实时转录](https://developers.openai.com/api/docs/guides/realtime-transcription) 以支持流式转录,并将实时提示指南移至 [使用实时模型](https://developers.openai.com/api/docs/guides/realtime-models-prompting).
-### 5 月 7 日
+### 5月7日
功能
-已发布 [OpenAI Developers 适用于 Codex 的插件](https://developers.openai.com/learn/developers-codex-plugin)。这可帮助你在 Codex 中借助 OpenAI Platform 访问和 OpenAI API 设置指引来构建 AI 应用和智能体。
+发布了 [适用于 Codex 的 OpenAI Developers 插件](https://developers.openai.com/learn/developers-codex-plugin)。这可帮助你借助 OpenAI Platform 访问和 OpenAI API 设置指南,在 Codex 中构建 AI 应用和 智能体。
### May 6
-更新日志
+更新
-更新后的 Agents SDK 现已提供 TypeScript 版本,支持沙箱 智能体 并内置开源 harness。了解更多信息 [此处](https://developers.openai.com/api/docs/guides/agents).
+更新后的 Agents SDK 现已支持 TypeScript,并内置了对沙箱 智能体 的支持以及开源 harness。了解更多 [此处](https://developers.openai.com/api/docs/guides/agents).
-### 5 月 5 日
+### 5月5日
更新 · 模型:chat-latest
-发布 `chat-latest` 指向当前 ChatGPT 中使用的最新 Instant 模型的快照。我们建议使用 [GPT-5.5](https://developers.openai.com/api/docs/guides/latest-model?model=gpt-5.5) 用于生产环境的 API 使用,但你可以自由使用此模型来测试我们在聊天用例方面的最新改进。底层模型快照将定期更新。了解更多 [此处](https://developers.openai.com/api/docs/models/chat-latest).
+已发布 `chat-latest` 指向 ChatGPT 当前使用的最新 Instant 模型的快照。建议使用 [GPT-5.5](https://developers.openai.com/api/docs/guides/latest-model?model=gpt-5.5) 用于生产环境 API 使用,但欢迎使用此模型来测试我们在聊天用例方面的最新改进。底层模型快照将定期更新。了解更多 [此处](https://developers.openai.com/api/docs/models/chat-latest).
-### 5月4日
+### 5 月 4 日
-更新日志
+更新
-Admin API 现已在面向 Node、Python、Go、Ruby 和 Java 的 OpenAI SDK 中受支持。请参阅 [Admin API 指南](https://developers.openai.com/api/docs/guides/admin-apis) 了解设置步骤和示例。
+Admin API 现已在面向 Node、Python、Go、Ruby 和 Java 的 OpenAI SDK 中受支持。详见 [Admin API 指南](https://developers.openai.com/api/docs/guides/admin-apis) 了解设置步骤和示例。
## 2026 年 4 月
### 4 月 24 日
-特性 · 模型:gpt-5.5 · 模型:gpt-5.5-pro · API:v1/responses · API:v1/chat/completions · API:v1/batch
+Feature · 模型:gpt-5.5 · 模型:gpt-5.5-pro · API:v1/responses · API:v1/chat/completions · API:v1/batch
-发布 [GPT-5.5](https://developers.openai.com/api/docs/models/gpt-5.5),一款面向复杂专业工作的全新前沿模型,已加入 Chat Completions 和 Responses API,并上线了 [GPT-5.5 Pro](https://developers.openai.com/api/docs/models/gpt-5.5-pro) ,面向 Responses API 中那些能从更多算力中受益的更困难问题。
+已发布 [GPT-5.5](https://developers.openai.com/api/docs/models/gpt-5.5),这是一个面向复杂专业工作的全新前沿模型,已在 Chat Completions 和 Responses API 中提供,并发布了 [GPT-5.5 Pro](https://developers.openai.com/api/docs/models/gpt-5.5-pro) ,用于 Responses API 请求,以应对受益于更多算力的更棘手问题。
-GPT-5.5 支持 1M token 上下文窗口、图像输入、结构化输出、函数调用、提示缓存、Batch、tool search、内置 computer use、hosted shell、apply patch、Skills、MCP,以及 网页搜索。主要更新包括:
+GPT-5.5 支持 1M token 上下文窗口、图像输入、结构化输出、函数调用、提示缓存、Batch、工具搜索、内置计算机使用、托管 shell、应用补丁、Skills、MCP 以及网页搜索。主要更新包括:
- 推理力度现在默认为 `medium`.
- 当 `image_detail` 未设置或设置为 `auto`,时,模型现在使用 [原始行为](https://developers.openai.com/api/docs/guides/latest-model?model=gpt-5.5#behavioral-changes).
-- GPT-5.5 的缓存功能仅适用于扩展提示缓存。不支持内存提示缓存。
-了解更多信息 [此处](https://developers.openai.com/api/docs/guides/latest-model?model=gpt-5.5#behavioral-changes).
+- GPT-5.5 的缓存仅适用于扩展提示缓存。不支持内存中的提示缓存。
+了解更多 [请参阅此处](https://developers.openai.com/api/docs/guides/latest-model?model=gpt-5.5#behavioral-changes).
### Apr 21
功能 · 模型:gpt-image-2 · API:v1/images/generations · API:v1/images/edits · API:v1/batch
-发布 [GPT Image 2](https://developers.openai.com/api/docs/models/gpt-image-2),一款用于图像生成与编辑的先进图像生成模型。GPT Image 2 支持灵活的图像尺寸、高保真图像输入、基于 token 的图像定价,以及享有 50% 折扣的 Batch API 支持。
+已发布 [GPT Image 2](https://developers.openai.com/api/docs/models/gpt-image-2),一款用于图像生成和编辑的最先进的图像生成模型。GPT Image 2 支持灵活的图像尺寸、高保真图像输入、基于 token 的图像定价,以及 Batch API 支持,可享受 50% 折扣。
### 4 月 15 日
-更新日志
+更新
-已更新 [Agents SDK](https://developers.openai.com/api/docs/guides/agents) 新增了多项能力,包括:
+已更新 [Agents SDK](https://developers.openai.com/api/docs/guides/agents) 带来全新功能,包括:
- 在受控沙箱中运行 智能体;
-- 检查并定制开源 harness;以及
-- 控制记忆的创建时机和存储位置。
+- 检查并定制开源测试框架;以及
+- 控制记忆的创建时机以及存储位置。
## 2026 年 3 月
@@ -305,50 +315,50 @@ GPT-5.5 支持 1M token 上下文窗口、图像输入、结构化输出、函
功能 · 模型:gpt-5.4-mini · 模型:gpt-5.4-nano · API:v1/responses · API:v1/chat/completions
-发布 [GPT-5.4 mini](https://developers.openai.com/api/docs/models/gpt-5.4-mini) 和 [GPT-5.4 nano](https://developers.openai.com/api/docs/models/gpt-5.4-nano) 接入 Chat Completions 和 Responses API。GPT-5.4 mini 以更快、更高效的模型形态带来 GPT-5.4 级别的能力,适用于高吞吐量的工作负载;而 GPT-5.4 nano 则针对简单的高吞吐量任务进行了优化,在这些场景中,速度和成本最为关键。
+已发布 [GPT-5.4 mini](https://developers.openai.com/api/docs/models/gpt-5.4-mini) 和 [GPT-5.4 nano](https://developers.openai.com/api/docs/models/gpt-5.4-nano) 到 Chat Completions 和 Responses API。GPT-5.4 mini 将 GPT-5.4 级别的能力带到更快、更高效的模型中,适用于高吞吐量工作负载;而 GPT-5.4 nano 针对简单的高吞吐量任务进行了优化,在这些场景中速度和成本最为关键。
-GPT-5.4 mini 支持 [tool search](https://developers.openai.com/api/docs/guides/tools-tool-search)、内置 [computer use](https://developers.openai.com/api/docs/guides/tools-computer-use),以及 [compaction](https://developers.openai.com/api/docs/guides/compaction)。GPT-5.4 nano 支持 compaction,但不支持 tool search 或 computer use。
+GPT-5.4 mini 支持 [tool search](https://developers.openai.com/api/docs/guides/tools-tool-search),内置 [computer use](https://developers.openai.com/api/docs/guides/tools-computer-use),和 [compaction](https://developers.openai.com/api/docs/guides/compaction)。GPT-5.4 nano 支持 compaction,但不支持 tool search 或 computer use。
### Mar 16
-更新 · 模型:gpt-5.3-chat-latest
+更新 · Model: gpt-5.3-chat-latest
-已更新 [gpt-5.3-chat-latest](https://developers.openai.com/api/docs/models/gpt-5.3-chat-latest) 指向当前 ChatGPT 所用最新模型的 slug。
+已更新 [gpt-5.3-chat-latest](https://developers.openai.com/api/docs/models/gpt-5.3-chat-latest) slug 指向 ChatGPT 当前使用的最新模型。
-### Mar 13
+### 3 月 13 日
修复 · 模型:gpt-5.4 · API:v1/responses · API:v1/chat/completions
-我们更新了图像编码器,修复了以下方面的一个小 bug: `input_image` GPT-5.4 中的输入处理。某些图像理解用例现在可能会获得质量提升。无需任何操作。
+更新了我们的图像编码器,修复了一个关于 `input_image` GPT-5.4 输入的小问题。部分图像理解用例现在可能会看到质量提升。无需执行任何操作。
-### Mar 12
+### 3 月 12 日
-Feature · Model: sora-2 · Model: sora-2-pro · API: v1/videos · API: v1/videos/characters · API: v1/videos/extensions · API: v1/batch
+功能 · 模型:sora-2 · 模型:sora-2-pro · API:v1/videos · API:v1/videos/characters · API:v1/videos/extensions · API:v1/batch
-扩展了 Sora API,新增可复用的角色引用、最长可达以下时长的生成: `20` 秒,以及, `1080p` 输出、 `sora-2-pro`、视频扩展功能,并提供 Batch API 对 `POST /v1/videos`. `1080p` 生成的计费按 `sora-2-pro` 支持,按 `$0.70` /秒计费。了解更多 [此处](https://developers.openai.com/api/docs/guides/video-generation).
+扩展了 Sora API,新增可复用的角色参考,最长生成时长可达 `20` 秒, `1080p` 输出用于 `sora-2-pro`、视频扩展,以及 Batch API 对 `POST /v1/videos`. `1080p` 生成任务的支持, `sora-2-pro` 按秒计费。了解更多 `$0.70` 。了解更多 [此处](https://developers.openai.com/api/docs/guides/video-generation).
-### Mar 12
+### 3 月 12 日
-Update · Model: sora-2 · Model: sora-2-pro · API: v1/videos/edits · API: v1/videos/{video_id}/remix
+更新 · 模型:sora-2 · 模型:sora-2-pro · API:v1/videos/edits · API:v1/videos/{video_id}/remix
-新增 `POST /v1/videos/edits` 用于编辑已有视频。该接口将取代 `POST /v1/videos/{video_id}/remix`,后者将在 `6` 个月后弃用。了解更多 [此处](https://developers.openai.com/api/docs/guides/video-generation#edit-existing-videos).
+新增 `POST /v1/videos/edits` ,用于编辑现有视频。这将取代 `POST /v1/videos/{video_id}/remix`,该接口将在 `6` 个月后弃用。了解更多 [此处](https://developers.openai.com/api/docs/guides/video-generation#edit-existing-videos).
-### 3 月 5 日
+### Mar 5
-功能 · 模型:gpt-5.4 · 模型:gpt-5.4-pro · API: v1/responses · API: v1/chat/completions
+特性 · 模型:gpt-5.4 · 模型:gpt-5.4-pro · API:v1/responses · API:v1/chat/completions
-发布 [GPT-5.4](https://developers.openai.com/api/docs/models/gpt-5.4),这是我们面向专业工作的最新前沿模型,已上线 Chat Completions 和 Responses API,并发布了 [GPT-5.4 Pro](https://developers.openai.com/api/docs/models/gpt-5.4-pro) 到 Responses API,用于需要更多算力的更棘手问题。
+已发布 [GPT-5.4](https://developers.openai.com/api/docs/models/gpt-5.4),我们面向专业工作的最新前沿模型,已在 Chat Completions 和 Responses API 中推出,并发布了 [GPT-5.4 Pro](https://developers.openai.com/api/docs/models/gpt-5.4-pro) 到 Responses API 中,用于需要更多算力的更难问题。
同时发布:
-- [工具搜索](https://developers.openai.com/api/docs/guides/tools-tool-search) 在 Responses API 中,模型可在运行时再加载大型工具集,从而减少 token 使用量、保持缓存性能并降低延迟。
-- 内置 [计算机使用](https://developers.openai.com/api/docs/guides/tools-computer-use) 通过 Responses API 在 GPT-5.4 中提供支持 `computer` 用于基于截图进行 UI 交互的工具。
-- 支持 100 万 token 上下文窗口,并原生支持 [压缩](https://developers.openai.com/api/docs/guides/compaction) 适用于长时间运行的 智能体 工作流。
+- [Tool search](https://developers.openai.com/api/docs/guides/tools-tool-search) 在 Responses API 中,该功能允许模型将大型工具集合延迟到运行时再加载,从而降低 token 使用量、保持缓存性能并改善延迟。
+- 内置 [Computer use](https://developers.openai.com/api/docs/guides/tools-computer-use) 通过 Responses API 在 GPT-5.4 中提供 `computer` 用于基于截图的 UI 交互的工具。
+- 100 万 token 的上下文窗口以及原生 [Compaction](https://developers.openai.com/api/docs/guides/compaction) 支持,可用于运行时间更长的 智能体 工作流。
-### 3 月 3 日
+### 3月3日
功能 · 模型:gpt-5.3-chat-latest · API:v1/chat/completions · API:v1/responses
-发布 `gpt-5.3-chat-latest` 到 Chat Completions 和Responses API。该模型指向当前 ChatGPT 中使用的 GPT-5.3 Instant 快照。了解更多 [此处](https://developers.openai.com/api/docs/models/gpt-5.3-chat-latest).
+已发布 `gpt-5.3-chat-latest` 到 Chat Completions 和 Responses API。该模型指向 ChatGPT 当前使用的 GPT-5.3 Instant 快照。了解更多 [此处](https://developers.openai.com/api/docs/models/gpt-5.3-chat-latest).
## 2026 年 2 月
@@ -356,135 +366,135 @@ Update · Model: sora-2 · Model: sora-2-pro · API: v1/videos/edits · API: v1/
功能 · API: v1/responses · API: v1/chat/completions
-扩展了 `input_file` 对更多文档、演示文稿、电子表格、代码和文本文件类型的支持。了解详情 [此处](https://developers.openai.com/api/docs/guides/file-inputs).
+扩展 `input_file` 支持更多文档、演示文稿、电子表格、代码和文本文件类型。了解详情 [此处](https://developers.openai.com/api/docs/guides/file-inputs).
### 2 月 24 日
-特性 · API: v1/responses
+功能 · API: v1/responses
-发布 `phase` 在 Responses API 中。它将助手消息标记为中间评论(`commentary`) 或最终回答(`final_answer`)。阅读详情 [此处](https://developers.openai.com/api/docs/%3Chttps://developers.openai.com/api/reference/resources/responses/methods/create#(resource)%20responses%20%3E%20(model)%20easy_input_message%20%3E%20(schema)%20%3E%20(property)%20phase>).
+已发布 `phase` 至 Responses API。它将助手消息标记为中间评论(`commentary`)或最终答案(`final_answer`)。阅读详情 [此处](https://developers.openai.com/api/docs/%3Chttps://developers.openai.com/api/reference/resources/responses/methods/create#(resource)%20responses%20%3E%20(model)%20easy_input_message%20%3E%20(schema)%20%3E%20(property)%20phase>).
### 2 月 24 日
功能 · 模型:gpt-5.3-codex · API: v1/responses
-发布 `gpt-5.3-codex` 到 Responses API。阅读详情 [此处](https://developers.openai.com/api/docs/models/gpt-5.3-codex).
+已发布 `gpt-5.3-codex` 至 Responses API。阅读详情 [此处](https://developers.openai.com/api/docs/models/gpt-5.3-codex).
### Feb 23
-特性 · API: v1/responses
+功能 · API: v1/responses
-为 Responses API 推出了 WebSocket 模式。了解更多 [此处](https://developers.openai.com/api/docs/guides/websocket-mode/).
+为 Responses API 推出 WebSocket 模式。了解更多 [此处](https://developers.openai.com/api/docs/guides/websocket-mode/).
### Feb 23
功能 · 模型:gpt-realtime-1.5 · 模型:gpt-audio-1.5 · API:v1/realtime · API:v1/chat/completions
-发布 [GPT-Realtime-1.5](https://developers.openai.com/api/docs/models/gpt-realtime-1.5) 添加到 Realtime API。
+已发布 [GPT-Realtime-1.5](https://developers.openai.com/api/docs/models/gpt-realtime-1.5) 接入 Realtime API。
-发布 `gpt-audio-1.5` 添加到 Chat Completions API。了解更多 [此处](https://developers.openai.com/api/docs/models/gpt-audio-1.5).
+已发布 `gpt-audio-1.5` 接入 Chat Completions API。阅读更多 [此处](https://developers.openai.com/api/docs/models/gpt-audio-1.5).
-### 2 月 10 日
+### Feb 10
-功能 · 模型:gpt-image-1.5 · 模型:gpt-image-1 · 模型:gpt-image-1-mini · 模型:chatgpt-image-latest · API:v1/batch
+Feature · Model: gpt-image-1.5 · Model: gpt-image-1 · Model: gpt-image-1-mini · Model: chatgpt-image-latest · API: v1/batch
-[批量 API](https://developers.openai.com/api/docs/guides/batch) 现在支持 GPT Image 模型: `gpt-image-1.5`, `chatgpt-image-latest`, `gpt-image-1`,以及 `gpt-image-1-mini`.
+[Batch API](https://developers.openai.com/api/docs/guides/batch) 现已在 GPT Image 模型中支持: `gpt-image-1.5`, `chatgpt-image-latest`, `gpt-image-1`,和 `gpt-image-1-mini`.
-### 2 月 10 日
+### Feb 10
-更新 · 模型:gpt-5.2-chat-latest
+Update · Model: gpt-5.2-chat-latest
-已更新 [gpt-5.2-chat-latest](https://developers.openai.com/api/docs/models/gpt-5.2-chat-latest) 指向当前 ChatGPT 所用最新模型的 slug。
+已更新 [gpt-5.2-chat-latest](https://developers.openai.com/api/docs/models/gpt-5.2-chat-latest) slug 指向 ChatGPT 当前使用的最新模型。
-### 2 月 10 日
+### Feb 10
-特性 · API: v1/responses
+功能 · API: v1/responses
-已上线 [服务端 压缩](https://developers.openai.com/api/docs/guides/compaction#server-side-compaction) 功能,位于 Responses API 中。
+已推出 [服务端 上下文压缩](https://developers.openai.com/api/docs/guides/compaction#server-side-compaction) 功能,支持在 Responses API 中使用。
-### 2 月 10 日
+### Feb 10
-特性 · API: v1/responses
+功能 · API: v1/responses
-已上线对 [Skills](https://developers.openai.com/api/docs/guides/tools-skills) 的支持,可在 Responses API 中使用。我们在本地执行和基于容器的托管执行两种方式下均支持 Skills。
+已推出对 [Skills](https://developers.openai.com/api/docs/guides/tools-skills) 功能的支持,支持在 Responses API 中使用。Skills 同时支持本地执行和基于托管容器的执行。
-### 2 月 10 日
+### Feb 10
-特性 · API: v1/responses
+功能 · API: v1/responses
-已上线全新的 [Hosted Shell](https://developers.openai.com/api/docs/guides/tools-shell#hosted-shell-quickstart) 工具,并支持容器中的网络功能。
+全新推出 [Hosted Shell](https://developers.openai.com/api/docs/guides/tools-shell#hosted-shell-quickstart) 工具,并支持容器中的网络功能。
-### 2月9日
+### Feb 9
-Feature · Model: gpt-image-1.5 · Model: gpt-image-1 · Model: gpt-image-1-mini · Model: chatgpt-image-latest · API: v1/images/edits
+功能 · 模型:gpt-image-1.5 · 模型:gpt-image-1 · 模型:gpt-image-1-mini · 模型:chatgpt-image-latest · API:v1/images/edits
-新增对 `application/json` 请求的支持,适用于 `/v1/images/edits` 上的 GPT 图像模型。JSON 请求使用 `images` (以及可选的 `mask`)配合 `image_url` 或 `file_id` 引用,而不是 multipart 上传。
+新增对 `application/json` 请求的支持, `/v1/images/edits` 适用于 GPT 图像模型。JSON 请求使用 `images` (以及可选的 `mask`),通过 `image_url` 或 `file_id` 引用而非 multipart 上传。
-### 2月 3 日
+### 2 月 3 日
-更新 · 模型:gpt-5.2 · 模型:gpt-5.2-codex
+更新 · Model:gpt-5.2 · Model:gpt-5.2-codex
-我们已为 API 客户优化了推理栈, [GPT-5.2](https://platform.openai.com/docs/models/gpt-5.2) 和 [GPT-5.2-Codex](https://platform.openai.com/docs/models/gpt-5.2-codex) 现在运行速度提升约 40%。模型及其权重未发生变化。
+我们已为 API 客户优化了推理栈,并且 [GPT-5.2](https://platform.openai.com/docs/models/gpt-5.2) 和 [GPT-5.2-Codex](https://platform.openai.com/docs/models/gpt-5.2-codex) 现在的运行速度提升了约 40%。模型和模型权重保持不变。
-## January, 2026
+## 2026 年 1 月
-### Jan 15
+### 1 月 15 日
公告
-已公布 [Open Responses](https://www.openresponses.org/): an open-source spec for building multi-provider, interoperable LLM interfaces built on top of the original OpenAI Responses API.
+已发布 [Open Responses](https://www.openresponses.org/):一个开源规范,用于在原有的 OpenAI Responses API 之上构建多提供商、可互操作的 LLM 接口。
### Jan 14
Feature · Model: gpt-5.2-codex · API: v1/responses
-发布 `gpt-5.2-codex` 到 Responses API。GPT-5.2-Codex 是为 Codex 或类似环境中的智能体编码任务而优化的 GPT-5.2 版本。了解更多 [此处](https://platform.openai.com/docs/models/gpt-5.2-codex).
+已发布 `gpt-5.2-codex` 到 Responses API。GPT-5.2-Codex 是 GPT-5.2 的一个版本,针对 Codex 或类似环境中的智能体编码任务进行了优化。阅读更多 [此处](https://platform.openai.com/docs/models/gpt-5.2-codex).
### Jan 13
功能 · API:v1/realtime
-为 Realtime API 新增了专用 SIP IP 段。 `sip.api.openai.com` 它会进行 GeoIP 路由,并将 SIP 流量引导至最近的区域。 [了解更多](https://developers.openai.com/api/docs/guides/realtime-sip#dedicated-sip-ip-ranges).
+为 Realtime API 添加了专用的 SIP IP 范围。 `sip.api.openai.com` 会进行 GeoIP 路由,并将 SIP 流量定向到最近的区域。 [了解详情](https://developers.openai.com/api/docs/guides/realtime-sip#dedicated-sip-ip-ranges).
### Jan 13
-更新 · 模型:gpt-realtime-mini · 模型:gpt-audio-mini
+更新 · Model: gpt-realtime-mini · Model: gpt-audio-mini
-已更新 [`gpt-realtime-mini`](https://developers.openai.com/api/docs/models/gpt-realtime-mini) 和 [`gpt-audio-mini`](https://platform.openai.com/docs/models/gpt-audio-mini) 的 slug 指向 2025-12-15 快照。如果你需要之前的模型快照,请使用 `gpt-realtime-mini-2025-10-06` 和 `gpt-audio-mini-2025-10-06`.
+已更新 [`gpt-realtime-mini`](https://developers.openai.com/api/docs/models/gpt-realtime-mini) 和 [`gpt-audio-mini`](https://platform.openai.com/docs/models/gpt-audio-mini) slug 已指向 2025-12-15 快照。如果你需要之前的模型快照,请使用 `gpt-realtime-mini-2025-10-06` 和 `gpt-audio-mini-2025-10-06`.
### Jan 13
-更新 · 模型:sora-2
+更新 · Model: sora-2
-已更新 [sora-2](https://platform.openai.com/docs/models/sora-2) 的 slug 指向 `sora-2-2025-12-08`。如果你需要之前的模型快照,请使用 `sora-2-2025-10-06`.
+已更新 [sora-2](https://platform.openai.com/docs/models/sora-2) slug 已指向 `sora-2-2025-12-08`。如果你需要之前的模型快照,请使用 `sora-2-2025-10-06`.
### Jan 13
-更新 · 模型:gpt-4o-mini-tts · 模型:gpt-4o-mini-transcribe
+更新 · Model: gpt-4o-mini-tts · Model: gpt-4o-mini-transcribe
-已更新 `gpt-4o-mini-tts` 和 `gpt-4o-mini-transcribe` 的 slug 指向 `2025-12-15` 快照。如果你需要之前的模型快照,请使用 `gpt-4o-mini-tts-2025-03-20` 和 `gpt-4o-mini-transcribe-2025-03-20`。我们目前推荐使用 `gpt-4o-mini-transcribe` 而非 `gpt-4o-transcribe` ,以获得最佳效果。
+已更新 `gpt-4o-mini-tts` 和 `gpt-4o-mini-transcribe` slug 已指向 `2025-12-15` 快照。如果你需要之前的模型快照,请使用 `gpt-4o-mini-tts-2025-03-20` 和 `gpt-4o-mini-transcribe-2025-03-20`。我们目前推荐使用 `gpt-4o-mini-transcribe` 而非 `gpt-4o-transcribe` 以获得最佳效果。
-### Jan 9
+### 1月9日
-修复 · Model: gpt-image-1.5 · Model: chatgpt-image-latest
+修复 · 模型:gpt-image-1.5 · 模型:chatgpt-image-latest
-修复了一个问题,其中 `gpt-image-1.5` 和 `chatgpt-image-latest` 在通过 `/v1/images/edits`,进行图像编辑时错误地使用了高保真度,即使 `fidelity` 被明确设置为 `low` (默认值)。
+修复了一个问题,该问题中 `gpt-image-1.5` 和 `chatgpt-image-latest` 在通过以下方式进行的图像编辑中错误地使用了高保真度 `/v1/images/edits`,即使在 `fidelity` 被显式设置为 `low` (默认值)时也是如此。
## 2025 年 12 月
### 12 月 19 日
-Update · Model: gpt-image-1.5 · Model: chatgpt-image-latest
+更新 · 模型:gpt-image-1.5 · 模型:chatgpt-image-latest
新增 `gpt-image-1.5` 和 `chatgpt-image-latest` 到 Responses API 图像生成工具。
### 12月16日
-功能 · 模型:gpt-image-1.5 · 模型:chatgpt-image-latest
+特性 · 模型:gpt-image-1.5 · 模型:chatgpt-image-latest
-发布 [gpt-image-1.5](https://platform.openai.com/docs/models/gpt-image-1.5) 和 [chatgpt-image-latest](https://platform.openai.com/docs/models/chatgpt-image-latest),我们最新、最先进的图像生成模型。阅读更多 [此处](https://platform.openai.com/docs/guides/image-generation).
+已发布 [gpt-image-1.5](https://platform.openai.com/docs/models/gpt-image-1.5) 和 [chatgpt-image-latest](https://platform.openai.com/docs/models/chatgpt-image-latest),我们最新且最先进的图像生成模型。了解更多 [此处](https://platform.openai.com/docs/guides/image-generation).
-### 12 月 15 日
+### 12月15日
功能 · 模型:gpt-realtime-mini · 模型:gpt-audio-mini · 模型:gpt-4o-mini-transcribe · 模型:gpt-4o-mini-tts
@@ -494,78 +504,78 @@ Update · Model: gpt-image-1.5 · Model: chatgpt-image-latest
- gpt-4o-mini-transcribe-2025-12-15
- gpt-4o-mini-tts-2025-12-15
-此次发布还包括对 [自定义语音](https://platform.openai.com/docs/guides/text-to-speech#custom-voices) 面向符合条件的客户开放。
+本次发布还包括对 [自定义语音](https://platform.openai.com/docs/guides/text-to-speech#custom-voices) 的支持(面向符合条件的客户)。
-### Dec 11
+### 12月11日
功能 · 模型:gpt-5.2 · 模型:gpt-5.2-chat-latest · API: v1/responses · API: v1/chat/completions
-发布 [GPT-5.2](https://platform.openai.com/docs/models/gpt-5.2),GPT-5 模型系列中全新的旗舰模型。GPT-5.2 在以下方面相较前代 GPT-5.1 有改进:
+已发布 [GPT-5.2](https://platform.openai.com/docs/models/gpt-5.2),GPT-5 模型家族中最新旗舰模型。GPT-5.2 在以下方面相较此前的 GPT-5.1 有改进:
- 通用智能
- 指令遵循
- 准确性与 token 效率
-- 多模态——尤其是视觉
-- 代码生成——尤其是前端 UI 创建
-- 工具调用与API中的上下文管理
+- 多模态,尤其是视觉
+- 代码生成,尤其是前端 UI 创建
+- API 中的工具调用与上下文管理
- 电子表格的理解与创建。
-5.2 的新增内容包括新的 xhigh 推理强度级别、简洁的推理摘要,以及使用压缩技术实现的新上下文管理。
+5.2 的新内容:新增 xhigh 推理强度等级、精炼的推理摘要,以及基于压缩的全新上下文管理。
-### Dec 11
+### 12月11日
-功能 · API: v1/responses/compact
+特性 · API:v1/responses/compact
-发布 [客户端压缩](https://platform.openai.com/docs/guides/conversation-state#compaction-advanced)。对于使用 Responses API 的长时间对话,你可以使用该 `/responses/compact` 端点来缩小每轮发送的上下文。
+已发布 [客户端压缩](https://platform.openai.com/docs/guides/conversation-state#compaction-advanced)。对于使用 Responses API 进行的长时间对话,你可以使用该 `/responses/compact` 端点来压缩你每轮发送的上下文。
### Dec 4
-功能 · 模型:gpt-5.1-codex-max · API:v1/responses
+Feature · Model:gpt-5.1-codex-max · API:v1/responses
-发布 `gpt-5.1-codex-max` 到 Responses API。GPT-5.1-Codex 是我们最智能的编码模型,专为长时长的智能体编码任务而优化。了解更多 [此处](https://platform.openai.com/docs/models/gpt-5.1-codex-max).
+已发布 `gpt-5.1-codex-max` 到 Responses API。GPT-5.1-Codex 是我们最智能的编码模型,专为长周期、智能体编码任务而优化。了解更多 [此处](https://platform.openai.com/docs/models/gpt-5.1-codex-max).
-## November, 2025
+## 2025 年 11 月
-### Nov 20
+### 11 月 20 日
功能 · API:v1/realtime
-在 Realtime API 中新增了对 DTMF 按键的支持。现在你可以在使用 Realtime 旁路连接时接收 DTMF 事件。请参阅 [相关文档](https://platform.openai.com/docs/api-reference/realtime-server-events/input_audio_buffer/dtmf_event_received) 了解更多信息。
+Realtime API 中新增了对 DTMF 按键的支持。现在,你在使用 Realtime 侧带连接时可以接收 DTMF 事件。详见 [相关文档](https://platform.openai.com/docs/api-reference/realtime-server-events/input_audio_buffer/dtmf_event_received) 。
-### 11月 13日
+### Nov 13
-特性 · 模型: gpt-5.1 · 模型: gpt-5.1-codex · 模型: gpt-5.1-chat-latest · 模型: gpt-5.1-codex-mini · API: v1/responses · API: v1/chat/completions
+特性 · 模型:gpt-5.1 · 模型:gpt-5.1-codex · 模型:gpt-5.1-chat-latest · 模型:gpt-5.1-codex-mini · API: v1/responses · API: v1/chat/completions
-发布 [GPT-5.1](https://developers.openai.com/api/docs/models/gpt-5.1), GPT-5 模型系列中全新的旗舰模型。GPT-5.1 经过训练,在以下方面尤为擅长:
+已发布 [GPT-5.1](https://developers.openai.com/api/docs/models/gpt-5.1),GPT-5 模型系列中全新的旗舰模型。GPT-5.1 在以下方面经过特别优化:
-- 在所需思考较少时可引导输出并获得更快响应
+- 在无需过多思考时可获得更强的可控性与更快的响应
- 代码生成与编程相关用例
- 智能体工作流
-请注意,GPT-5.1 默认启用一种新的 `none` 推理设置,以便在所需思考较少时更快地响应——这与 GPT-5 中之前的 `medium` 默认设置不同。
+请注意,GPT-5.1 默认采用了一种新的 `none` 推理设置,以便在所需思考更少时更快地响应——这与之前 GPT-5 中的 `medium` 默认设置不同。
-### 11月 13日
+### Nov 13
功能
-发布 [增强型基于角色的访问控制(RBAC)](https://platform.openai.com/docs/guides/rbac#page-top)。基于角色的访问控制(RBAC)让你可以决定组织及项目中谁能执行哪些操作——既可以通过 API,也可以在 Dashboard 中进行。
+已发布 [增强型基于角色的访问控制(RBAC)](https://platform.openai.com/docs/guides/rbac#page-top)。基于角色的访问控制(RBAC)让你可以决定在你的组织和项目中谁能执行哪些操作——既可以通过 API,也可以在 Dashboard 中进行。
-### 11月 13日
+### Nov 13
功能 · 模型:gpt-5.1-codex · 模型:gpt-5.1-codex-mini · API:v1/responses
-发布 `gpt-5.1-codex` 和 `gpt-5.1-codex-mini` 到 Responses API。GPT-5.1-Codex 是 GPT-5.1 的一个版本,专为 Codex 或类似环境中的智能体编码任务而优化。了解更多 [此处](https://platform.openai.com/docs/models/gpt-5.1-codex).
+已发布 `gpt-5.1-codex` 和 `gpt-5.1-codex-mini` 到 Responses API。GPT-5.1-Codex 是为 Codex 或类似环境中的智能体编码任务而优化的 GPT-5.1 版本。了解更多 [此处](https://platform.openai.com/docs/models/gpt-5.1-codex).
-### 11月 13日
+### Nov 13
功能
-发布 [扩展的提示缓存保留](https://platform.openai.com/docs/guides/prompt-caching#extended-prompt-cache-retention)。扩展的提示缓存保留可使缓存的前缀保持更长时间,最长可达 24 小时。扩展提示缓存的工作原理是:当内存已满时,将键/值张量卸载到 GPU 本地存储,从而显著增加可用于缓存的存储容量。
+已发布 [扩展提示缓存保留](https://platform.openai.com/docs/guides/prompt-caching#extended-prompt-cache-retention)。扩展提示缓存保留可使缓存的前缀保持更长时间的活跃状态,最长可达 24 小时。扩展提示缓存的工作原理是:当显存占满时,将键/值张量卸载到 GPU 本地存储,从而显著增加可用于缓存的存储容量。
## 2025 年 10 月
### 10 月 29 日
-功能 · Model: gpt-oss-safeguard-120b · Model: gpt-oss-safeguard-20b
+功能特性 · 模型: gpt-oss-safeguard-120b · 模型: gpt-oss-safeguard-20b
gpt-oss-safeguard-120b 和 gpt-oss-safeguard-20b 是基于 gpt-oss 构建的安全推理模型。阅读更多 [此处](https://huggingface.co/collections/openai/gpt-oss-safeguard).
@@ -573,57 +583,57 @@ gpt-oss-safeguard-120b 和 gpt-oss-safeguard-20b 是基于 gpt-oss 构建的安
功能
-发布 [企业密钥管理 (EKM)](https://platform.openai.com/docs/guides/your-data#enterprise-key-management-ekm)。企业密钥管理 (EKM) 允许你使用由你自己的外部密钥管理系统 (KMS) 管理的密钥来加密你在 OpenAI 的客户内容。
+已发布 [Enterprise Key Management (EKM)](https://platform.openai.com/docs/guides/your-data#enterprise-key-management-ekm). Enterprise Key Management (EKM) 允许你使用由你自己的外部密钥管理系统 (KMS) 管理的密钥,对 OpenAI 上的客户内容进行加密。
### Oct 24
功能
-发布 [英国数据驻留](https://platform.openai.com/docs/guides/your-data#data-residency-controls).
+已发布 [UK 数据驻留](https://platform.openai.com/docs/guides/your-data#data-residency-controls).
### Oct 6
-Feature · Model: gpt-5-pro · Model: gpt-realtime-mini · Model: gpt-audio-mini · Model: gpt-image-1-mini · Model: sora-2 · Model: sora-2-pro · API: v1/responses · API: v1/batch · API: v1/chat/completions · API: v1/videos · API: v1/realtime · API: v1/images/generations
+功能 · 模型:gpt-5-pro · 模型:gpt-realtime-mini · 模型:gpt-audio-mini · 模型:gpt-image-1-mini · 模型:sora-2 · 模型:sora-2-pro · API:v1/responses · API:v1/batch · API:v1/chat/completions · API:v1/videos · API:v1/realtime · API:v1/images/generations
-在 DevDay 上发布了几项新功能 [OpenAI DevDay](https://openai.com/devday/):
+在 [OpenAI DevDay](https://openai.com/devday/):
-发布 [GPT-5 Pro](https://developers.openai.com/api/docs/models/gpt-5-pro),这是 [GPT-5](https://developers.openai.com/api/docs/models/gpt-5) 的一个版本,使用更多算力进行更深入的思考,从而提供始终更优的答案。
+已发布 [GPT-5 Pro](https://developers.openai.com/api/docs/models/gpt-5-pro),这是 [GPT-5](https://developers.openai.com/api/docs/models/gpt-5) 的一个版本,使用更多算力来更深入地思考,并提供始终更优的答案。
-发布 [GPT-Realtime mini](https://developers.openai.com/api/docs/models/gpt-realtime-mini) 和 [gpt-audio-mini](https://developers.openai.com/api/docs/models/gpt-audio-mini) ,以实现更具性价比的语音对话性能。
+已发布 [GPT-Realtime mini](https://developers.openai.com/api/docs/models/gpt-realtime-mini) 和 [gpt-audio-mini](https://developers.openai.com/api/docs/models/gpt-audio-mini) ,用于更具性价比的语音到语音性能。
-发布 [gpt-image-1-mini](https://developers.openai.com/api/docs/models/gpt-image-1-mini) ,以实现更具性价比的图像生成与编辑。
+已发布 [gpt-image-1-mini](https://developers.openai.com/api/docs/models/gpt-image-1-mini) ,用于更具性价比的图像生成和编辑。
-已上线 [v1/videos](https://developers.openai.com/api/docs/guides/video-generation) ,以通过我们最新的 [Sora 2](https://developers.openai.com/api/docs/models/sora-2) 和 [Sora 2 Pro](https://developers.openai.com/api/docs/models/sora-2-pro) 模型实现丰富、细腻且动态的视频生成与再创作。
+已推出 [v1/videos](https://developers.openai.com/api/docs/guides/video-generation) ,可使用我们最新的 [Sora 2](https://developers.openai.com/api/docs/models/sora-2) 和 [Sora 2 Pro](https://developers.openai.com/api/docs/models/sora-2-pro) 模型实现丰富、细腻且动态的视频生成与重混。
-已上线 [智能体 Builder](https://developers.openai.com/api/docs/guides/agent-builder) ,用于通过可视化方式创建自定义的多智能体工作流。
+已推出 [智能体 Builder](https://developers.openai.com/api/docs/guides/agent-builder) ,可通过可视化方式创建自定义的多智能体工作流。
-已上线 [ChatKit](https://developers.openai.com/api/docs/guides/chatkit),一个可嵌入的聊天界面,用于部署智能体。
+已推出 [ChatKit](https://developers.openai.com/api/docs/guides/chatkit),一个可嵌入的聊天界面,用于部署智能体。
-发布 [追踪评估、数据集和提示优化工具](https://developers.openai.com/api/docs/guides/agent-evals).
+已发布 [追踪评估、数据集和提示优化工具](https://developers.openai.com/api/docs/guides/agent-evals).
-[Evals](https://developers.openai.com/api/docs/guides/evals):发布第三方模型支持。
+[评估](https://developers.openai.com/api/docs/guides/evals): 发布第三方模型支持。
-已上线 [服务健康仪表板](https://platform.openai.com/settings/organization/service-health).
+已推出 [服务健康仪表板](https://platform.openai.com/settings/organization/service-health).
### Oct 1
功能
-发布 [IP 允许列表](https://platform.openai.com/settings/organization/security/ip-allowlist)。IP 允许列表功能仅允许你指定的 IP 地址或地址段访问 API。
+已发布 [IP 允许列表](https://platform.openai.com/settings/organization/security/ip-allowlist)。IP 允许列表将 API 访问限制为仅允许你指定的 IP 地址或地址段。
## 2025 年 9 月
### 9 月 26 日
-特性 · API: v1/responses
+功能 · API: v1/responses
-新增对将图像和文件作为 [工具调用输出](https://developers.openai.com/api/docs/docs/guides/function-calling#how-it-works) 在 Responses API 中。
+新增了对将图片和文件作为 [工具调用输出](https://developers.openai.com/api/docs/docs/guides/function-calling#how-it-works) 的支持,在 Responses API 中。
-### 9月23日
+### Sep 23
-Feature · Model: gpt-5-codex · API: v1/responses
+Feature · Model:gpt-5-codex · API:v1/responses
-推出专用模型 [gpt-5-codex](https://developers.openai.com/api/docs/models/gpt-5-codex),专为配合 [Codex CLI](https://github.com/openai/codex).
+推出专用模型 [gpt-5-codex](https://developers.openai.com/api/docs/models/gpt-5-codex),专为 [Codex CLI](https://github.com/openai/codex).
## 2025 年 8 月
@@ -635,25 +645,25 @@ OpenAI Realtime API 现已正式发布。了解更多 [请参阅我们的 Realti
### Aug 21
-特性 · API: v1/responses
+功能 · API: v1/responses
-新增对 [连接器](https://developers.openai.com/api/docs/guides/tools-connectors-mcp) 到 Responses API。连接器是 OpenAI 维护的 MCP 封装,用于 Google 应用、Dropbox 等流行服务,可让模型读取这些服务中存储的数据。
+新增对 [连接器](https://developers.openai.com/api/docs/guides/tools-connectors-mcp) 到 Responses API。连接器是 OpenAI 为 Google 应用、Dropbox 等热门服务维护的 MCP 封装,可用于让模型读取存储在这些服务中的数据。
### Aug 20
功能 · API:v1/conversations · API:v1/responses · API:v1/assistants
-发布了 Conversations API,允许你使用 Responses API 创建和管理长时间对话。请参阅 [迁移指南](https://developers.openai.com/api/docs/assistants/migration) ,查看并排对比并了解如何从 Assistants API 集成迁移到 Responses 和 Conversations。
+发布了 Conversations API,它允许你使用 Responses API 创建和管理长时间运行的对话。请参阅 [迁移指南](https://developers.openai.com/api/docs/assistants/migration) 以查看对比说明,并了解如何从 Assistants API 集成迁移到 Responses 和 Conversations。
-### 8月7日
+### Aug 7
功能 · API:v1/chat/completions · API:v1/responses
-在 API 中发布了 GPT-5 系列模型,包括 [`gpt-5`](https://developers.openai.com/api/docs/models/gpt-5), [`gpt-5-mini`](https://developers.openai.com/api/docs/models/gpt-5-mini),以及 [`gpt-5-nano`](https://developers.openai.com/api/docs/models/gpt-5-nano).
+在 API 中发布了 GPT-5 系列模型,包括 [`gpt-5`](https://developers.openai.com/api/docs/models/gpt-5), [`gpt-5-mini`](https://developers.openai.com/api/docs/models/gpt-5-mini),和 [`gpt-5-nano`](https://developers.openai.com/api/docs/models/gpt-5-nano).
-推出了 `minimal` [推理努力程度](https://developers.openai.com/api/docs/guides/reasoning) 取值,以在 GPT-5 模型(支持推理)中优化快速响应。
+引入了 `minimal` [推理强度](https://developers.openai.com/api/docs/guides/reasoning) 取值,以优化 GPT-5 模型(支持推理)的快速响应。
-引入 `custom` [工具调用](https://developers.openai.com/api/docs/guides/function-calling#custom-tools) 类型,允许在工具调用时使用自由格式的输入和输出。
+引入了 `custom` [工具调用](https://developers.openai.com/api/docs/guides/function-calling#custom-tools) 类型,允许在工具调用时向模型传入自由形式的输入并从模型获取自由形式的输出。
## June, 2025
@@ -661,66 +671,66 @@ OpenAI Realtime API 现已正式发布。了解更多 [请参阅我们的 Realti
功能
-已上线对 [Priority processing](https://platform.openai.com/docs/guides/priority-processing)。Priority processing 在保持按量付费灵活性的同时,显著降低并稳定了延迟,相较 Standard processing 优势明显。
+已推出对 [Priority processing](https://platform.openai.com/docs/guides/priority-processing). 与 Standard 处理相比,Priority processing 可显著降低延迟并保持更稳定的延迟表现,同时保留按量付费的灵活性。
### 6 月 24 日
-Feature · Model: o3-deep-research · Model: o3-deep-research-2025-06-26 · Model: o4-mini-deep-research · Model: o4-mini-deep-research-2025-06-26 · API: v1/responses
+功能 · Model: o3-deep-research · Model: o3-deep-research-2025-06-26 · Model: o4-mini-deep-research · Model: o4-mini-deep-research-2025-06-26 · API: v1/responses
-发布 [o3-deep-research](https://developers.openai.com/api/docs/models/o3-deep-research) 和 [o4-mini-deep-research](https://developers.openai.com/api/docs/models/o4-mini-deep-research),是我们 o 系列推理模型的深度研究变体,专为深度分析和研究任务而优化。详情请参阅 [深度研究指南](https://developers.openai.com/api/docs/guides/deep-research).
+已发布 [o3-deep-research](https://developers.openai.com/api/docs/models/o3-deep-research) 和 [o4-mini-deep-research](https://developers.openai.com/api/docs/models/o4-mini-deep-research),是我们 o 系列推理模型的深度研究变体,针对深度分析与研究任务进行了优化。更多信息请参阅 [深度研究指南](https://developers.openai.com/api/docs/guides/deep-research).
-新增对异步事件处理的支持,详见 [webhooks](https://developers.openai.com/api/docs/guides/webhooks). [降低并简化了定价](https://developers.openai.com/api/docs/pricing) ,适用于 网页搜索 工具。新增对 [网页搜索 工具](https://developers.openai.com/api/docs/guides/tools-web-search).
+新增对通过 [webhooks](https://developers.openai.com/api/docs/guides/webhooks). [进行异步事件处理的支持。](https://developers.openai.com/api/docs/pricing) 降价并简化了 网页搜索 工具的定价。新增对 [网页搜索 工具](https://developers.openai.com/api/docs/guides/tools-web-search).
-### Jun 13
+### 6月13日
-特性 · API: v1/responses
+功能 · API: v1/responses
-[新的可复用提示](https://developers.openai.com/chat/edit) 现已在仪表板和 [Responses API](https://developers.openai.com/api/reference/resources/responses/methods/create)。中提供。通过 API,你现在可以通过 `prompt` 参数引用在仪表板中创建的模板(带有提示 `id`,可选 `version`),并提供动态 `variables` ,其中可包含字符串、图像或文件输入。可复用提示在 Chat Completions 中不可用。 [了解更多](https://developers.openai.com/api/docs/guides/text?api-mode=responses#reusable-prompts).
+[新可复用提示词](https://developers.openai.com/chat/edit) 现已在控制台和 [Responses API](https://developers.openai.com/api/reference/resources/responses/methods/create)。中提供。通过 API,你现在可以引用在控制台中创建的模板,引用方式为 `prompt` 参数(使用 prompt `id`,可选 `version`)并提供动态 `variables` 内容,可以包含字符串、图像或文件输入。Chat Completions 不支持可复用的 prompt。 [了解详情](https://developers.openai.com/api/docs/guides/text?api-mode=responses#reusable-prompts).
-### 6月10日
+### 6 月 10 日
Feature · Model: o3-pro · API: v1/responses · API: v1/batch
-发布 [o3-pro](https://developers.openai.com/api/docs/models/o3-pro),这是 [o3](https://developers.openai.com/api/docs/models/o3) 推理模型的一个版本,使用更多算力来回答难题,具有更出色的推理能力和一致性。 [o3 模型的价格也已下调](https://developers.openai.com/api/docs/pricing) ,适用于所有 API 请求,包括批量和 flex 处理。
+已发布 [o3-pro](https://developers.openai.com/api/docs/models/o3-pro),这是 [o3](https://developers.openai.com/api/docs/models/o3) 推理模型的版本,使用更多算力来回答难题,具有更好的推理能力和一致性。 [o3 模型的价格也已下调](https://developers.openai.com/api/docs/pricing) ,适用于所有 API 请求,包括 batch 和 flex 处理。
### Jun 4
Feature · API: v1/fine_tuning
-为以下模型新增了 [直接偏好优化](https://developers.openai.com/api/docs/guides/direct-preference-optimization) 的微调支持 `gpt-4.1-2025-04-14`, `gpt-4.1-mini-2025-04-14`,以及 `gpt-4.1-nano-2025-04-14`.
+新增使用 [直接偏好优化](https://developers.openai.com/api/docs/guides/direct-preference-optimization) 的微调支持,适用于以下模型 `gpt-4.1-2025-04-14`, `gpt-4.1-mini-2025-04-14`,和 `gpt-4.1-nano-2025-04-14`.
### Jun 3
Feature · API: v1/chat/completions · API: v1/realtime
-为以下模型提供了新的模型快照: [gpt-4o-audio-preview](https://developers.openai.com/api/docs/models/gpt-4o-audio-preview) 和 [gpt-4o-realtime-preview](https://developers.openai.com/api/docs/models/gpt-4o-realtime-preview)。发布了 [Agents SDK for TypeScript](https://openai.github.io/openai-agents-js).
+提供了新的模型快照 [gpt-4o-audio-preview](https://developers.openai.com/api/docs/models/gpt-4o-audio-preview) 和 [gpt-4o-realtime-preview](https://developers.openai.com/api/docs/models/gpt-4o-realtime-preview)。发布了 [Agents SDK for TypeScript](https://openai.github.io/openai-agents-js).
## 2025 年 5 月
### 5 月 20 日
-特性 · API: v1/responses
+功能 · API: v1/responses
-为 Responses API 中新的内置工具添加了支持,包括 [远程 MCP 服务器](https://developers.openai.com/api/docs/guides/tools-connectors-mcp) 和 [代码解释器](https://developers.openai.com/api/docs/guides/tools-code-interpreter). [详细了解工具](https://developers.openai.com/api/docs/guides/tools).
+在 Responses API 中新增了对内置工具的支持,包括 [远程 MCP 服务器](https://developers.openai.com/api/docs/guides/tools-connectors-mcp) 和 [代码解释器](https://developers.openai.com/api/docs/guides/tools-code-interpreter). [了解有关工具的更多信息](https://developers.openai.com/api/docs/guides/tools).
### 5 月 20 日
功能 · API: v1/responses · API: v1/chat/completions
-新增了对使用 `strict` 模式的支持,可在非微调模型上使用并行工具调用时用于工具架构。
-新增了 [架构特性](https://developers.openai.com/api/docs/guides/structured-outputs?api-mode=responses#supported-schemas),包括对 `email` 以及其他模式的字符串校验,并可为数字和数组指定取值范围。
+新增了对在并行工具调用中使用非微调模型时为工具架构使用 `strict` 模式的支持。
+新增了 [架构功能](https://developers.openai.com/api/docs/guides/structured-outputs?api-mode=responses#supported-schemas),的支持,包括对 `email` 进行字符串验证,以及为其他模式指定数值和数组的范围。
-### May 15
+### 5 月 15 日
-Feature · Model: codex-mini-latest · API: v1/responses · API: v1/chat/completions
+特性 · 模型:codex-mini-latest · API: v1/responses · API: v1/chat/completions
-已上线 [codex-mini-latest](https://developers.openai.com/api/docs/models/codex-mini-latest) 在 API 中,针对以下用途进行了优化 [Codex CLI](https://github.com/openai/codex).
+已推出 [codex-mini-latest](https://developers.openai.com/api/docs/models/codex-mini-latest) 在 API 中,针对配合使用进行了优化 [Codex CLI](https://github.com/openai/codex).
-### 5 月 7 日
+### 5月7日
-Feature · API: v1/fine-tuning · API: v1/responses · API: v1/chat/completions
+特性 · API: v1/fine-tuning · API: v1/responses · API: v1/chat/completions
-已上线对 [reinforcement fine-tuning](https://developers.openai.com/api/docs/guides/reinforcement-fine-tuning)。了解可用的 [fine-tuning methods](https://developers.openai.com/api/docs/guides/model-optimization). [gpt-4.1-nano](https://developers.openai.com/api/docs/models/gpt-4.1-nano) 现已支持微调。
+已推出对 [reinforcement fine-tuning](https://developers.openai.com/api/docs/guides/reinforcement-fine-tuning)。了解可用的 [微调方法](https://developers.openai.com/api/docs/guides/model-optimization). [gpt-4.1-nano](https://developers.openai.com/api/docs/models/gpt-4.1-nano) 现已支持微调。
## 2025 年 4 月
@@ -728,94 +738,94 @@ Feature · API: v1/fine-tuning · API: v1/responses · API: v1/chat/completions
功能
-已上线对 [增强的 API 预算告警与自动充值限额](https://platform.openai.com/settings/organization/limits).
+已推出对 [增强的 API 预算提醒与自动充值限额](https://platform.openai.com/settings/organization/limits).
-### 4 月 23 日
+### Apr 23
-功能 · API: v1/images/generations · API: v1/images/edits
+特性 · API: v1/images/generations · API: v1/images/edits
-新增了一个图像生成模型, `gpt-image-1`。该模型为图像生成设立了新标准,具备更出色的质量与指令遵循能力。
+新增了图像生成模型, `gpt-image-1`。该模型为图像生成树立了新标准,具有更高的质量和指令遵循能力。
-更新了图像生成与编辑接口,以支持该模型 `gpt-image-1` 特有的新参数。
+更新了图像生成与编辑接口,以支持该 `gpt-image-1` 模型特有的新参数。
### 4 月 16 日
功能 · API:v1/chat/completions · API:v1/responses
-新增两款 o 系列推理模型, `o3` 和 `o4-mini`。它们在数学、科学和编程、视觉推理任务以及技术写作方面树立了新的标准。
+新增两款 o 系列推理模型, `o3` 和 `o4-mini`。它们在数学、科学、编码、视觉推理任务和技术写作方面树立了新的标准。
-发布了 Codex,我们的代码生成命令行工具。
+推出了 Codex,即我们的代码生成 CLI 工具。
### 4 月 14 日
功能 · 模型:gpt-4.1 · 模型:gpt-4.1-mini · 模型:gpt-4.1-nano · API:v1/responses · API:v1/chat/completions · API:v1/fine_tuning
-新增 [`gpt-4.1`](https://developers.openai.com/api/docs/models/gpt-4.1), [`gpt-4.1-mini`](https://developers.openai.com/api/docs/models/gpt-4.1-mini),以及 [`gpt-4.1-nano`](https://developers.openai.com/api/docs/models/gpt-4.1-nano) 模型接入 API。这些新模型在指令遵循、编码以及更大上下文窗口(最高 1M tokens)方面均有改进。 `gpt-4.1` 和 `gpt-4.1-mini` 可用于监督微调。已宣布弃用 [`gpt-4.5-preview`](https://developers.openai.com/api/docs/deprecations).
+新增 [`gpt-4.1`](https://developers.openai.com/api/docs/models/gpt-4.1), [`gpt-4.1-mini`](https://developers.openai.com/api/docs/models/gpt-4.1-mini),和 [`gpt-4.1-nano`](https://developers.openai.com/api/docs/models/gpt-4.1-nano) 模型到 API。这些新模型在指令遵循、编码以及更大的上下文窗口(最高 1M tokens)方面有所改进。 `gpt-4.1` 和 `gpt-4.1-mini` 可用于监督微调。已宣布弃用 [`gpt-4.5-preview`](https://developers.openai.com/api/docs/deprecations).
-## March, 2025
+## 2025 年 3 月
-### Mar 20
+### 3 月 20 日
-更新 · API: v1/audio
+更新 · API:v1/audio
-新增 `gpt-4o-mini-tts`, `gpt-4o-transcribe`, `gpt-4o-mini-transcribe`,以及 `whisper-1` 模型接口已迁移至 Audio API。
+新增 `gpt-4o-mini-tts`, `gpt-4o-transcribe`, `gpt-4o-mini-transcribe`,和 `whisper-1` models 接口添加到 Audio API。
### Mar 19
-特性 · 模型:o1-pro · API:v1/responses · API:v1/batch
+功能 · 模型:o1-pro · API: v1/responses · API: v1/batch
-发布 [o1-pro](https://developers.openai.com/api/docs/models/o1-pro),这是 [o1](https://developers.openai.com/api/docs/models/o1) 推理模型的一个版本,使用更多算力来回答难题,具有更出色的推理能力和一致性。
+已发布 [o1-pro](https://developers.openai.com/api/docs/models/o1-pro),这是 [o1](https://developers.openai.com/api/docs/models/o1) 推理模型的版本,使用更多算力来回答难题,具有更好的推理能力和一致性。
### Mar 11
功能 · 模型:gpt-4o-search-preview · 模型:gpt-4o-mini-search-preview · 模型:computer-use-preview · API: v1/chat/completions · API: v1/assistants · API: v1/responses
-发布了多个新模型和新工具,以及面向智能体工作流的新 API:
+发布了多个新模型和工具,以及一个面向智能体工作流的新 API:
- 发布了 [Responses API](https://developers.openai.com/api/docs/guides/migrate-to-responses),这是一个用于创建和使用智能体与工具的新API。
- - 为Responses API发布了一组内置工具: [网页搜索](https://developers.openai.com/api/docs/guides/tools-web-search), [文件搜索](https://developers.openai.com/api/docs/guides/tools-file-search),以及 [计算机使用](https://developers.openai.com/api/docs/guides/tools-computer-use).
- - 发布了 [Agents SDK](https://developers.openai.com/api/docs/guides/agents),一个用于设计、构建和部署智能体的编排框架。
- - 宣布了新模型: `gpt-4o-search-preview`, `gpt-4o-mini-search-preview`, `computer-use-preview`.
- - 宣布计划将所有 [Assistants API](https://developers.openai.com/api/docs/assistants/migration) 功能迁移到更易用的 [Responses API](https://developers.openai.com/api/docs/guides/migrate-to-responses),Assistants 预计将于 2026 年下线(实现完全功能对等之后)。
+ - 为 Responses API 发布了一组内置工具: [网页搜索](https://developers.openai.com/api/docs/guides/tools-web-search), [文件搜索](https://developers.openai.com/api/docs/guides/tools-file-search),以及 [computer use](https://developers.openai.com/api/docs/guides/tools-computer-use).
+ - 发布了 [Agents SDK](https://developers.openai.com/api/docs/guides/agents),这是一个用于设计、构建和部署智能体的编排框架。
+ - 发布了新模型: `gpt-4o-search-preview`, `gpt-4o-mini-search-preview`, `computer-use-preview`.
+ - 宣布计划将所有 [Assistants API](https://developers.openai.com/api/docs/assistants/migration) 功能迁移到更易使用的 [Responses API](https://developers.openai.com/api/docs/guides/migrate-to-responses),Assistants 预计将于 2026 年下线(在实现完全功能对等之后)。
-### 3 月 3 日
+### 3月3日
-功能 · API:v1/fine_tuning/jobs
+功能 · API: v1/fine_tuning/jobs
-新增 `metadata` 字段支持至微调任务。
+新增 `metadata` 字段支持到微调任务。
## 2025 年 2 月
### 2 月 27 日
-特性 · 模型:GPT-4.5 · API:v1/chat/completions · API:v1/assistants · API:v1/batch
+特性 · 模型:GPT-4.5 · API: v1/chat/completions · API: v1/assistants · API: v1/batch
-发布了 [GPT-4.5](https://developers.openai.com/api/docs/models/gpt-4-5)——迄今为止我们最大且能力最强的对话模型。GPT-4.5 较高的“情商”和对用户意图的理解使其在创意任务和智能体规划方面表现更佳。
+发布了 [GPT-4.5](https://developers.openai.com/api/docs/models/gpt-4-5)—的研究预览版本——这是我们迄今为止最大、能力最强的聊天模型。GPT-4.5 具备高“情商”和对用户意图的理解能力,在创意任务和智能体规划方面表现更佳。
### 2 月 25 日
功能
-推出了 [API 用量仪表板更新](https://help.openai.com/en/articles/10478918-api-usage-dashboard)。此次更新响应了对更多数据筛选条件的请求,例如项目选择、日期选择器以及更细粒度的时间区间。同时还更好地支持跨不同产品和服务层级查看用量。
+已上线 [API 用量仪表盘更新](https://help.openai.com/en/articles/10478918-api-usage-dashboard). 此更新回应了用户对更多数据筛选器的需求,例如项目选择、日期选择器以及更细粒度的时间区间。同时也更好地支持跨不同产品和服务层级查看用量。
-### 2 月 5 日
+### Feb 5
功能
-在欧洲推出数据驻留。了解更多 [此处](https://platform.openai.com/docs/guides/your-data).
+在欧洲推出数据驻留。阅读更多 [此处](https://platform.openai.com/docs/guides/your-data).
-## January, 2025
+## 2025 年 1 月
-### Jan 31
+### 1 月 31 日
-Feature · Model: o3-mini · Model: o3-mini-2025-01-31 · API: v1/chat/completions
+功能 · 模型:o3-mini · 模型:o3-mini-2025-01-31 · API:v1/chat/completions
-已上线 [o3-mini](https://developers.openai.com/api/docs/models/o3-mini),这是一款针对科学、数学和编程任务优化的全新小型推理模型。
+已推出 [o3-mini](https://developers.openai.com/api/docs/models/o3-mini),这是一款全新的小型推理模型,针对科学、数学和编码任务进行了优化。
### Jan 21
功能 · 模型:o1
-扩展了对 [o1 模型](https://platform.openai.com/docs/models/o1)。的访问权限。o1 系列模型通过强化学习训练,能够执行复杂推理。
+扩展对 [o1 模型](https://platform.openai.com/docs/models/o1)。的访问。o1 系列模型通过强化学习训练,能够执行复杂推理。
## 2024 年 12 月
@@ -823,79 +833,79 @@ Feature · Model: o3-mini · Model: o3-mini-2025-01-31 · API: v1/chat/completio
功能
-已上线 [Admin API 密钥轮换](https://developers.openai.com/api/reference/resources/admin/subresources/organization/subresources/admin_api_keys),允许客户以编程方式轮换其 admin 接口 密钥。
+已推出 [Admin API Key Rotations](https://developers.openai.com/api/reference/resources/admin/subresources/organization/subresources/admin_api_keys),使客户能够以编程方式轮换其管理员 接口 密钥。
-已更新 [Admin API 邀请](https://developers.openai.com/api/reference/resources/admin/subresources/organization/subresources/invites),允许客户在邀请用户加入组织的同时,以编程方式将他们邀请到项目。
+已更新 [Admin API Invites](https://developers.openai.com/api/reference/resources/admin/subresources/organization/subresources/invites),使客户能够在用户被邀请加入组织的同时,以编程方式将其邀请到项目。
### Dec 17
功能 · 模型:o1 · 模型:gpt-4o · 模型:gpt-4o-mini · API:v1/fine_tuning · API:v1/chat/completions · API:v1/realtime
-新增模型: [o1](https://developers.openai.com/api/docs/models/o1), [gpt-4o-realtime](https://developers.openai.com/api/docs/models/gpt-4o-realtime-preview), [gpt-4o-audio](https://developers.openai.com/api/docs/models/gpt-4o-audio-preview) 和 [更多](https://developers.openai.com/api/docs/models).
+为以下模型添加了新模型 [o1](https://developers.openai.com/api/docs/models/o1), [gpt-4o-realtime](https://developers.openai.com/api/docs/models/gpt-4o-realtime-preview), [gpt-4o-audio](https://developers.openai.com/api/docs/models/gpt-4o-audio-preview) 和 [更多](https://developers.openai.com/api/docs/models).
-为 [Realtime API](https://developers.openai.com/api/docs/guides/realtime).
+为以下功能添加了 WebRTC 连接方式 [Realtime API](https://developers.openai.com/api/docs/guides/realtime).
-新增 [`reasoning_effort` 参数](https://developers.openai.com/api/reference/resources/chat#chat-create-reasoning_effort) 添加了 WebRTC 连接方式,适用于 o1 模型。
+新增 [`reasoning_effort` 参数](https://developers.openai.com/api/reference/resources/chat#chat-create-reasoning_effort) 用于 o1 模型。
-新增 [`developer` message role](https://developers.openai.com/api/reference/resources/chat#chat-create-messages) 适用于 o1 模型。请注意,o1-preview 和 o1-mini 不支持 system 或 developer 消息。
+新增 [`developer` message role](https://developers.openai.com/api/reference/resources/chat#chat-create-messages) 用于 o1 模型。注意 o1-preview 和 o1-mini 不支持 system 或 developer 消息。
-推出了使用 [直接偏好优化(DPO)](https://developers.openai.com/api/docs/guides/model-optimization#preference).
+推出了基于 [直接偏好优化 (DPO)](https://developers.openai.com/api/docs/guides/model-optimization#preference).
-的偏好微调。推出了适用于 Go 和 Java 的 beta 版 SDK。 [了解更多](https://developers.openai.com/api/docs/libraries).
+推出了适用于 Go 和 Java 的 beta 版 SDK。 [了解详情](https://developers.openai.com/api/docs/libraries).
-新增 [Realtime API](https://developers.openai.com/api/docs/guides/realtime) 在 [Python SDK](https://github.com/openai/openai-python).
+新增 [Realtime API](https://developers.openai.com/api/docs/guides/realtime) 支持,应用于 [Python SDK](https://github.com/openai/openai-python).
### Dec 4
功能
-已上线 [用量 接口](https://developers.openai.com/api/reference/resources/admin/subresources/organization/subresources/usage),中新增支持,使客户能够以编程方式查询 OpenAI API 各方面的活动与支出。
+已推出 [用量 API](https://developers.openai.com/api/reference/resources/admin/subresources/organization/subresources/usage),使客户能够以编程方式查询各个 OpenAI API 的活动和支出。
## November, 2024
-### Nov 20
+### 11 月 20 日
-Update · API: v1/chat/completions
+更新 · API:v1/chat/completions
-发布 [gpt-4o-2024-11-20](https://developers.openai.com/api/docs/models/gpt-4o),我们 gpt-4o 系列中最新推出的模型。
+已发布 [gpt-4o-2024-11-20](https://developers.openai.com/api/docs/models/gpt-4o),我们 gpt-4o 系列中的最新模型。
-### 11月 4日
+### Nov 4
-功能 · API: v1/chat/completions
+功能 · API:v1/chat/completions
-发布 [Predicted Outputs](https://developers.openai.com/api/docs/guides/predicted-outputs),可显著降低响应中有大量内容事先已知的模型响应延迟。这种情况在仅对文档和代码文件进行小幅改动后重新生成内容时最为常见。
+已发布 [预测输出](https://developers.openai.com/api/docs/guides/predicted-outputs),对于模型响应的大部分内容事先已知的情形,可显著降低延迟。这在仅对文档和代码文件进行少量修改后重新生成内容时尤为常见。
-## 2024年10月
+## 2024 年 10 月
-### 10月30日
+### 10 月 30 日
Feature · Model: gpt-4o-realtime-preview · Model: gpt-4o-audio-preview · API: v1/chat/completions
-在以下位置新增了五种语音类型 [Realtime API](https://developers.openai.com/api/docs/guides/realtime) 和 [Chat Completions API](https://developers.openai.com/api/docs/guides/audio).
+在以下 接口 中新增了五种新的语音类型: [Realtime API](https://developers.openai.com/api/docs/guides/realtime) 和 [Chat Completions API](https://developers.openai.com/api/docs/guides/audio).
-### 10月17日
+### Oct 17
功能 · 模型:gpt-4o-audio-preview · API:v1/chat/completions
-发布 [全新 `gpt-4o-audio-preview` 模型](https://developers.openai.com/api/docs/guides/audio) 用于聊天补全,同时支持音频输入和输出。使用与 [Realtime API](https://developers.openai.com/api/docs/guides/realtime).
+已发布 [全新 `gpt-4o-audio-preview` 模型](https://developers.openai.com/api/docs/guides/audio) 用于 Chat Completions,同时支持音频输入和输出。它使用与 [Realtime API](https://developers.openai.com/api/docs/guides/realtime).
### Oct 1
功能 · API:v1/realtime · API:v1/chat/completions · API:v1/fine_tuning
-在 DevDay 上发布了几项新功能 [OpenAI 旧金山 DevDay](https://openai.com/devday/):
+在 [OpenAI 在旧金山举办的 DevDay](https://openai.com/devday/):
-[Realtime API](https://developers.openai.com/api/docs/guides/realtime):使用 WebSockets 接口在应用中构建快速的语音到语音体验。
+[Realtime API](https://developers.openai.com/api/docs/guides/realtime):使用 WebSockets 接口在你的应用中快速构建语音到语音体验。
-[模型蒸馏](https://developers.openai.com/api/docs/guides/supervised-fine-tuning#distilling-from-a-larger-model):使用大型前沿模型的输出微调高性价比模型的平台。
+[模型蒸馏](https://developers.openai.com/api/docs/guides/supervised-fine-tuning#distilling-from-a-larger-model):利用来自前沿大模型的输出,对低成本模型进行微调的平台。
-[图像微调](https://developers.openai.com/api/docs/guides/model-optimization#vision):使用图像和文本微调 GPT-4o 以提升视觉能力。
+[图像微调](https://developers.openai.com/api/docs/guides/model-optimization#vision):使用图像和文本对 GPT-4o 进行微调,以提升视觉能力。
-[Evals](https://developers.openai.com/api/docs/guides/evals):创建并运行自定义评估,以衡量模型在特定任务上的表现。
+[评估](https://developers.openai.com/api/docs/guides/evals):创建并运行自定义评估,衡量模型在特定任务上的表现。
-[提示词缓存](https://developers.openai.com/api/docs/guides/prompt-caching):对近期出现过的输入 token 提供折扣和更快的处理速度。
+[提示词缓存](https://developers.openai.com/api/docs/guides/prompt-caching):对最近出现过的输入 token 提供折扣并加快处理速度。
-[在 Playground 中生成](https://developers.openai.com/chat/edit):在 Playground 中使用生成按钮轻松生成提示词、函数定义和结构化输出架构。
+[在 Playground 中生成](https://developers.openai.com/chat/edit):在 Playground 中使用 Generate 按钮轻松生成提示词、函数定义和结构化输出 schema。
## 2024 年 9 月
@@ -903,13 +913,13 @@ Feature · Model: gpt-4o-realtime-preview · Model: gpt-4o-audio-preview · API:
功能 · 模型:omni-moderation-latest · API:v1/moderations
-发布 [全新 `omni-moderation-latest` 审核模型](https://developers.openai.com/api/docs/guides/moderation),该模型同时支持图像和文本(针对部分类别),并新增了两个仅文本的危害类别,且评分更准确。
+已发布 [全新 `omni-moderation-latest` 审核模型](https://developers.openai.com/api/docs/guides/moderation),它同时支持图像和文本(针对部分类别),新增了两个仅限文本的危害类别,并提供了更准确的评分。
### Sep 12
-功能 · 模型:o1-preview · 模型:o1-mini · API:v1/chat/completions
+功能 · 模型: o1-preview · 模型: o1-mini · API: v1/chat/completions
-发布 [o1-preview 和 o1-mini](https://developers.openai.com/api/docs/guides/reasoning),是新型的大语言模型,通过强化学习训练,可执行复杂的推理任务。
+已发布 [o1-preview 和 o1-mini](https://developers.openai.com/api/docs/guides/reasoning),通过强化学习训练的新一代大型语言模型,用于执行复杂推理任务。
## 2024 年 8 月
@@ -917,153 +927,153 @@ Feature · Model: gpt-4o-realtime-preview · Model: gpt-4o-audio-preview · API:
功能 · API: v1/assistants
-Assistants API 现已支持 [包括 文件搜索 工具使用的 文件搜索 结果,以及自定义排序行为](https://developers.openai.com/api/docs/assistants/migration#improve-file-search-result-relevance-with-chunk-ranking).
+Assistants API 现已支持 [包括 文件搜索 工具所使用的 文件搜索 结果,以及自定义排序行为](https://developers.openai.com/api/docs/assistants/migration#improve-file-search-result-relevance-with-chunk-ranking).
### Aug 20
功能 · 模型:gpt-4o · API: v1/fine_tuning
-正式发布 [`gpt-4o-2024-08-06` 微调](https://developers.openai.com/api/docs/guides/model-optimization)—所有 API 用户现在都可以微调最新的 GPT-4o 模型。
+正式发布 [`gpt-4o-2024-08-06` fine-tuning](https://developers.openai.com/api/docs/guides/model-optimization)——所有 API 用户现在都可以对最新的 GPT-4o 模型进行微调。
-### 8 月 15 日
+### Aug 15
更新 · 模型:gpt-4o · API:v1/chat/completions
-发布 [的动态模型 `chatgpt-4o-latest`](https://developers.openai.com/api/docs/models/chatgpt-4o-latest)——该模型将指向 ChatGPT 使用的最新 GPT-4o 模型。
+已发布 [动态模型 `chatgpt-4o-latest`](https://developers.openai.com/api/docs/models/chatgpt-4o-latest)——此模型将指向 ChatGPT 使用的最新 GPT-4o 模型。
-### 8 月 6 日
+### 8月6日
-更新日志
+更新
-已上线 [结构化输出](https://developers.openai.com/api/docs/guides/structured-outputs)——模型输出现在能够可靠地遵循开发者提供的 JSON Schema。
+已推出 [结构化输出](https://developers.openai.com/api/docs/guides/structured-outputs)——模型输出现在能够可靠地遵循开发者提供的 JSON Schema。
-发布 [gpt-4o-2024-08-06](https://developers.openai.com/api/docs/models/gpt-4o),我们 gpt-4o 系列中最新推出的模型。
+已发布 [gpt-4o-2024-08-06](https://developers.openai.com/api/docs/models/gpt-4o),我们 gpt-4o 系列中的最新模型。
### Aug 1
-更新日志
+更新
-已上线 [管理与审计日志 API](https://developers.openai.com/api/reference/overview),允许客户以编程方式管理其组织并使用审计日志监控变更。审计日志必须在 [settings](https://platform.openai.com/settings/organization/general).
+已推出 [管理与审计日志 API](https://developers.openai.com/api/reference/overview),允许客户以编程方式管理其组织并通过审计日志监控变更。必须在 [设置](https://platform.openai.com/settings/organization/general).
## 2024 年 7 月
### 7 月 24 日
-更新日志
+更新
-已上线 [自助式 SSO 配置](https://help.openai.com/en/articles/9641482-api-platform-single-sign-on-sso-integration-for-existing-enterprise-customers),使采用自定义或无限量计费方案的企业客户能够针对其所需的 IDP 设置身份验证。
+已推出 [自助 SSO 配置](https://help.openai.com/en/articles/9641482-api-platform-single-sign-on-sso-integration-for-existing-enterprise-customers),允许采用定制和无限计费方案的企业客户针对其所需的 IDP 设置身份验证。
### Jul 23
-更新日志
+更新
-已上线 [GPT-4o mini 微调](https://developers.openai.com/api/docs/guides/model-optimization),可为特定用例带来更高的性能。
+已推出 [GPT-4o mini 的微调](https://developers.openai.com/api/docs/guides/model-optimization),从而在特定用例下实现更高的性能。
-### 7月18日
+### Jul 18
-更新日志
+更新
-发布 [GPT-4o mini](https://developers.openai.com/api/docs/models/gpt-4o-mini),一款经济实惠的智能小模型,适用于快速、轻量的任务。
+已发布 [GPT-4o mini](https://developers.openai.com/api/docs/models/gpt-4o-mini), 一款经济实惠的智能小模型,适合快速、轻量级的任务。
### Jul 17
-更新日志
+更新
-发布 [Uploads](https://developers.openai.com/api/reference/resources/uploads) 以分块方式上传大文件。
+已发布 [Uploads](https://developers.openai.com/api/reference/resources/uploads) 可分块上传大文件。
## 2024 年 6 月
### 6 月 6 日
-更新日志
+更新
-[并行函数调用](https://developers.openai.com/api/docs/guides/function-calling#configure-parallel-function-calling) 可以在 Chat Completions 和 Assistants API 中通过传递来禁用 `parallel_tool_calls=false`.
+[并行函数调用](https://developers.openai.com/api/docs/guides/function-calling#configure-parallel-function-calling) 可以在 Chat Completions 和 Assistants API 中通过传入 `parallel_tool_calls=false`.
-[.NET SDK](https://developers.openai.com/api/docs/libraries#dotnet-library) 以 Beta 形式发布。
+[.NET SDK](https://developers.openai.com/api/docs/libraries#dotnet-library) 来禁用,该 开发工具包 已发布 Beta 版。
### Jun 3
-更新日志
+更新
-新增对 [文件搜索 自定义](https://developers.openai.com/api/docs/assistants/migration#customizing-file-search-settings).
+新增对 [文件搜索 customizations](https://developers.openai.com/api/docs/assistants/migration#customizing-file-search-settings).
-## 2024 年 5 月
+## 2024年5月
-### May 15
+### 5 月 15 日
-更新日志
+更新
新增对 [归档项目](https://developers.openai.com/projects) 。只有组织所有者才能访问此功能。
新增对 [设置成本限制](https://platform.openai.com/settings/organization/general) 按项目为按量付费客户提供。
-### May 13
+### 5月 13 日
-更新日志
+更新
-发布 [GPT-4o](https://developers.openai.com/api/docs/models/gpt-4o) 可在 API 中使用。GPT-4o 是我们最快且性价比最高的旗舰模型。
+已发布 [GPT-4o](https://developers.openai.com/api/docs/models/gpt-4o) 在 API 中。GPT-4o 是我们最快且最具性价比的旗舰模型。
-### 5 月 9 日
+### 5月9日
-更新日志
+更新
-新增对 [image inputs to the Assistants API。](https://developers.openai.com/api/docs/assistants/migration)
+新增对 [向 Assistants API 提供图片输入。](https://developers.openai.com/api/docs/assistants/migration)
-### 5 月 7 日
+### 5月7日
-更新日志
+更新
-新增对 [fine-tuned models to the Batch API](https://developers.openai.com/api/docs/guides/batch#model-availability) .
+新增对 [向 Batch API 提供微调模型](https://developers.openai.com/api/docs/guides/batch#model-availability) .
### May 6
-更新日志
+更新
-新增 [`stream_options: {"include_usage": true}`](https://developers.openai.com/api/reference/resources/chat#chat-create-stream_options) parameter to the Chat Completions and Completions APIs。设置该参数后,开发者在使用流式传输时可以访问使用情况统计信息。
+新增 [`stream_options: {"include_usage": true}`](https://developers.openai.com/api/reference/resources/chat#chat-create-stream_options) 向 Chat Completions 和 Completions API 添加该参数。在使用流式传输时,设置此参数可使开发者访问用量统计信息。
-### 5月 2日
+### May 2
-更新日志
+更新
-新增 [a new endpoint](https://developers.openai.com/api/reference/resources/beta/subresources/threads/subresources/messages/methods/delete) 用于从 Assistants API 的线程中删除消息。
+新增 [一个新端点](https://developers.openai.com/api/reference/resources/beta/subresources/threads/subresources/messages/methods/delete) 用于在 Assistants API 中删除某个线程里的消息。
-## 2024 年 4 月
+## April, 2024
-### 4 月 29 日
+### Apr 29
-更新日志
+更新
-新增了一个 [函数调用选项 `tool_choice: "required"`](https://developers.openai.com/api/docs/guides/function-calling#function-calling-behavior) 至 Chat Completions 和 Assistants API。
+新增了 [函数调用选项 `tool_choice: "required"`](https://developers.openai.com/api/docs/guides/function-calling#function-calling-behavior) 到 Chat Completions 和 Assistants API 中。
-新增了 [Batch API 使用指南](https://developers.openai.com/api/docs/guides/batch) 以及 Batch API 对 [嵌入模型](https://developers.openai.com/api/docs/guides/batch#model-availability)
+新增了 [Batch API 使用指南](https://developers.openai.com/api/docs/guides/batch) 以及 Batch API 对 [embeddings 模型](https://developers.openai.com/api/docs/guides/batch#model-availability)
-### Apr 17
+### 4 月 17 日
-更新日志
+更新
-引入了一系列 [Assistants API 的更新](https://developers.openai.com/api/docs/assistants/migration) ,包括一个新的 文件搜索 工具,每个助手支持最多 10,000 个文件、新的 token 控制以及 tool choice 支持。
+推出了一系列 [对 Assistants API 的更新](https://developers.openai.com/api/docs/assistants/migration) ,包括一个新的 文件搜索 工具(每个智能体最多支持 10,000 个文件)、新的 token 控制以及 tool choice 支持。
### 4 月 16 日
-更新日志
+更新
-引入 [基于项目的层级结构](https://platform.openai.com/settings/organization/general) 用于按项目组织工作,包括创建 [API 密钥](https://developers.openai.com/api/reference/overview) 并按项目维度管理速率和成本限额(成本限额仅对企业客户开放)。
+引入了 [基于项目层级结构](https://platform.openai.com/settings/organization/general) 以按项目组织工作,包括创建 [API 密钥](https://developers.openai.com/api/reference/overview) 并按项目管理和费用限制(费用限制仅对企业客户可用)。
### 4 月 15 日
-更新日志
+更新
-发布 [批量 API](https://developers.openai.com/api/docs/guides/batch)
+已发布 [Batch API](https://developers.openai.com/api/docs/guides/batch)
### 4 月 9 日
-更新日志
+更新
-发布 [GPT-4 Turbo with Vision](https://developers.openai.com/api/docs/models/gpt-4-turbo) 在 API 中正式可用
+已发布 [GPT-4 Turbo with Vision](https://developers.openai.com/api/docs/models/gpt-4-turbo) 已在 API 中正式发布
### Apr 4
-更新日志
+更新
新增对 [seed](https://developers.openai.com/api/reference/resources/fine_tuning) 在微调 API 中
@@ -1073,98 +1083,98 @@ Assistants API 现已支持 [包括 文件搜索 工具使用的 文件搜索
### Apr 1
-更新日志
+更新
-新增对 [按 run_id 筛选 Messages](https://developers.openai.com/api/reference/resources/beta/subresources/threads/subresources/messages/methods/list#messages-listmessages-run_id) 在 Assistants API 中
+新增对 [按 run_id 过滤消息](https://developers.openai.com/api/reference/resources/beta/subresources/threads/subresources/messages/methods/list#messages-listmessages-run_id) 在 Assistants API 中
-## March, 2024
+## 2024 年 3 月
-### Mar 29
+### 3 月 29 日
-更新日志
+更新
-新增对 [temperature](https://developers.openai.com/api/reference/resources/beta/subresources/threads/subresources/runs/methods/create#runs-createrun-temperature) 和 [assistant message creation](https://developers.openai.com/api/reference/resources/beta/subresources/threads/subresources/messages/methods/create#messages-createmessage-role) 在 Assistants API 中
+新增对 [temperature](https://developers.openai.com/api/reference/resources/beta/subresources/threads/subresources/runs/methods/create#runs-createrun-temperature) 和 [助手消息创建](https://developers.openai.com/api/reference/resources/beta/subresources/threads/subresources/messages/methods/create#messages-createmessage-role) 在 Assistants API 中
### Mar 14
-更新日志
+更新
-新增对 [流式传输](https://developers.openai.com/api/docs/assistants/migration) 在 Assistants API 中
+新增对 [streaming](https://developers.openai.com/api/docs/assistants/migration) 在 Assistants API 中
-## 2024 年 2 月
+## February, 2024
-### 2月9日
+### Feb 9
-更新日志
+更新
-新增 [`timestamp_granularities` 参数](https://developers.openai.com/api/docs/guides/speech-to-text#timestamps) 到 Audio API
+新增 [`timestamp_granularities` 参数](https://developers.openai.com/api/docs/guides/speech-to-text#timestamps) 向 Audio API
-### Feb 1
+### 2 月 1 日
-更新日志
+更新
-发布 [gpt-3.5-turbo-0125,更新后的 GPT-3.5 Turbo 模型](https://developers.openai.com/api/docs/models/gpt-3-5-turbo)
+已发布 [gpt-3.5-turbo-0125,更新后的 GPT-3.5 Turbo 模型](https://developers.openai.com/api/docs/models/gpt-3-5-turbo)
-## 2024 年 1 月
+## January, 2024
-### 1 月 25 日
+### Jan 25
-更新日志
+更新
-发布了 Embedding V3 模型和更新后的 GPT-4 Turbo 预览版
+发布了 Embedding V3 模型和更新的 GPT-4 Turbo 预览版
-新增 [`dimensions` 参数](https://developers.openai.com/api/reference/resources/embeddings/methods/create#embeddings-create-dimensions) 至 Embeddings API
+新增 [`dimensions` 参数](https://developers.openai.com/api/reference/resources/embeddings/methods/create#embeddings-create-dimensions) 到 Embeddings API
-## December, 2023
+## 2023年12月
-### Dec 20
+### 12月20日
-更新日志
+更新
-新增 [`additional_instructions` 参数](https://developers.openai.com/api/reference/resources/beta/subresources/threads/subresources/runs/methods/create#runs-createrun-additional_instructions) 在 Assistants API 中运行创建操作
+新增 [`additional_instructions` 参数](https://developers.openai.com/api/reference/resources/beta/subresources/threads/subresources/runs/methods/create#runs-createrun-additional_instructions) 用于在 Assistants API 中运行创建操作
-### 12 月 15 日
+### 12月15日
-更新日志
+更新
新增 [`logprobs` 和 `top_logprobs` 参数](https://developers.openai.com/api/reference/resources/chat#chat-create-logprobs) 到 Chat Completions API
### Dec 14
-更新日志
+更新
-Changed [函数参数](https://developers.openai.com/api/reference/resources/chat#chat-create-tools) 工具调用中的参数设为可选
+已更改 [function 参数](https://developers.openai.com/api/reference/resources/chat#chat-create-tools) 参数在工具调用上为可选
-## November, 2023
+## 2023年11月
-### Nov 30
+### 11月30日
-更新日志
+更新
-发布 [OpenAI Deno SDK](https://deno.land/x/openai)
+已发布 [OpenAI Deno SDK](https://deno.land/x/openai)
-### Nov 6
+### 11月6日
-更新日志
+更新
-发布 [GPT-4 Turbo 预览版](https://developers.openai.com/api/docs/models/gpt-4-turbo), [已更新的 GPT-3.5 Turbo](https://developers.openai.com/api/docs/models/gpt-3-5-turbo), [GPT-4 Turbo with Vision](https://developers.openai.com/api/docs/guides/images-vision), [Assistants API](https://developers.openai.com/api/docs/assistants/migration), [API 中的 DALL·E 3](https://developers.openai.com/api/docs/models/dall-e-3),以及 [文本转语音 API](https://developers.openai.com/api/docs/guides/text-to-speech)
+已发布 [GPT-4 Turbo Preview](https://developers.openai.com/api/docs/models/gpt-4-turbo), [已更新的 GPT-3.5 Turbo](https://developers.openai.com/api/docs/models/gpt-3-5-turbo), [GPT-4 Turbo with Vision](https://developers.openai.com/api/docs/guides/images-vision), [Assistants API](https://developers.openai.com/api/docs/assistants/migration), [API 中的 DALL·E 3](https://developers.openai.com/api/docs/models/dall-e-3),和 [文本转语音 API](https://developers.openai.com/api/docs/guides/text-to-speech)
已弃用 Chat Completions `functions` 参数 [改用 `tools`](https://developers.openai.com/api/reference/resources/chat#chat-create-tools)
-发布 [OpenAI Python SDK V1.0](https://developers.openai.com/api/docs/libraries#python-library)
+已发布 [OpenAI Python SDK V1.0](https://developers.openai.com/api/docs/libraries#python-library)
-## 2023年10月
+## 2023 年 10 月
-### 10月16日
+### 10 月 16 日
-更新日志
+更新
-新增 [`encoding_format` 参数](https://developers.openai.com/api/reference/resources/embeddings/methods/create#embeddings-create-encoding_format) 至 Embeddings API
+新增 [`encoding_format` 参数](https://developers.openai.com/api/reference/resources/embeddings/methods/create#embeddings-create-encoding_format) 到 Embeddings API
-新增 `max_tokens` 至 [Moderation models](https://developers.openai.com/api/docs/models/text-moderation-latest)
+新增 `max_tokens` 到 [内容审核模型](https://developers.openai.com/api/docs/models/text-moderation-latest)
### Oct 6
-更新日志
+更新
-新增 [function calling support](https://developers.openai.com/api/docs/guides/model-optimization#fine-tuning-examples) 至微调 API
+新增 [函数调用支持](https://developers.openai.com/api/docs/guides/model-optimization#fine-tuning-examples) 到微调 API
diff --git a/docs/zh/api/docs/guides/background.md b/docs/zh/api/docs/guides/background.md
index 65d2322..d2377ae 100644
--- a/docs/zh/api/docs/guides/background.md
+++ b/docs/zh/api/docs/guides/background.md
@@ -1,22 +1,22 @@
-# 后台模式
+# Background mode
-> 如需完整的文档索引,请参阅 [llms.txt](/llms.txt). 文档页面的 Markdown 版本可通过在页面 URL 后追加 `.md` 获得。
+> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。文档页面的 Markdown 版本可通过在页面 URL 后追加 `.md` 来获取。
-像 智能体 [Codex](https://openai.com/index/introducing-codex/) 和 [Deep Research](https://openai.com/index/introducing-deep-research/) 都表明推理模型可能要花费数分钟来解决复杂问题。后台模式可让你在 GPT-5.2 和 GPT-5.2 Pro 等模型上可靠地执行长时间运行的任务,无需担心超时或其他连接问题。
+智能体,例如 [Codex](https://openai.com/index/introducing-codex/) 和 [Deep Research](https://openai.com/index/introducing-deep-research/) 表明推理模型可能需要数分钟才能解决复杂问题。后台模式使你能够在 GPT-5.2 和 GPT-5.2 Pro 等模型上可靠地执行长时间运行的任务,而无需担心超时或其他连接问题。
-后台模式会异步启动这些任务,开发者可以轮询响应对象来随时查看状态。若要在后台启动响应生成,请发起一个 API 请求,并附带 `background` 设置为 `true`:
+后台模式会异步启动这些任务,开发者可以轮询响应对象以随时查看状态。要在后台启动响应生成,请发出包含以下内容的 API 请求 `background` 设置为 `true`:
-零数据留存 (ZDR) 项目发起的后台请求会使用
- `store=false`。运行。响应数据会临时存储到磁盘约 10
- 分钟,以便异步执行和轮询。
+属于零数据保留 (ZDR) 项目的后台请求将使用
+ `store=false`。运行。响应数据会临时存储到磁盘上约 10
+ 分钟,以支持异步执行和轮询。
对于使用 [Modified Abuse
Monitoring](https://developers.openai.com/api/docs/guides/your-data#modified-abuse-monitoring),的项目,包括
-增强版 Modified Abuse Monitoring,前台请求遵循标准
-留存策略,当 `store` 省略或设置为 `true`。时。后台响应仅在
-被显式提供时,才会在轮询期 `store=true` 之后继续保留。
-如果 `store` 省略或设置为 `false` 对于后台请求,响应
-会在约 10 分钟后被删除。
+增强版 Modified Abuse Monitoring,当
+被省略或被设置为 `store` 时,前台请求遵循标准的 `true`。保留策略。后台响应仅在显式提供
+时,才会在轮询期结束后继续保留。 `store=true` 时被显式提供。
+如果 `store` 时,前台请求遵循标准的 `false` 对于后台请求,响应
+将在大约 10 分钟后被删除。
在后台生成响应
@@ -139,9 +139,9 @@ puts(response.status)
## 轮询后台响应
-要检查后台请求的状态,请使用针对 Responses 的 GET 端点。当请求处于 queued 或 in_progress 状态时持续轮询。一旦离开这些状态,就表示它已到达最终(终态)状态。
+要检查后台请求的状态,请使用 响应接口 的 GET 端点。在请求处于 queued 或 in_progress 状态时持续轮询。当请求离开这些状态时,即表示已进入最终(终止)状态。
-获取在后台执行的 response
+检索在后台执行的响应
```bash
curl https://api.openai.com/v1/responses/resp_123 \
@@ -309,7 +309,7 @@ puts(response.output_text)
## 取消后台响应
-你也可以像这样取消一个进行中的响应:
+你也可以按如下方式取消一个进行中的响应:
取消正在进行的响应
@@ -396,15 +396,15 @@ puts(response.status)
```
-重复取消是幂等的,后续调用只会返回最终的 `Response` 对象。
+重复取消是幂等的——后续调用只会简单地返回最终的 `Response` 对象。
## 流式传输后台响应
-你可以创建一个后台 Response,并立即开始从中流式传输事件。如果你预计客户端会中断流,并希望保留稍后恢复的选项,这会很有用。要实现这一点,需要在创建 Response 时同时指定 `background` 和 `stream` 设置为 `true`。你需要跟踪一个 “cursor”(游标),它对应于每个流式事件中收到的 `sequence_number` 。
+你可以创建一个后台 Response 并立即开始从中流式传输事件。如果你预期客户端会中断流式传输,并希望保留稍后重新接续的选项,这会很有用。方法是创建一个同时设置了以下两个选项的 Response: `background` 和 `stream` 设置为 `true`。你需要跟踪每个流式事件中收到的 `sequence_number` 的“游标”。
目前,从后台响应中收到首个 token 的时间
- 高于从同步响应中收到的时间。我们将在未来几周内着力缩短
- 这一延迟差距。
+ 高于同步响应。我们正在努力在未来几周内
+ 缩小这一延迟差距。
生成并流式传输后台响应
@@ -687,7 +687,7 @@ last_sequence_number = -1
response_id = ""
stream.each do |event|
puts(event.type)
- last_sequence_number = event.sequence_number
+ last_sequence_number = event.sequence_number || last_sequence_number
if event.is_a?(OpenAI::Models::Responses::ResponseCreatedEvent)
response_id = event.response.id
end
@@ -706,5 +706,5 @@ puts("Response #{response_id}; last sequence number #{last_sequence_number}")
1. 后台请求可以使用 `store=false`,但响应数据会被临时
存储以支持异步执行和轮询。
-2. 若要取消同步响应,请终止连接
-3. 仅当使用以下方式创建后台响应时,才能从该响应开启新的流 `stream=true`.
\ No newline at end of file
+2. 要取消同步响应,请终止连接
+3. 只有使用以下方式创建的后台响应才能开启新的流式传输 `stream=true`.
\ No newline at end of file
diff --git a/docs/zh/api/docs/guides/embeddings.md b/docs/zh/api/docs/guides/embeddings.md
index 199b65f..79bf6e2 100644
--- a/docs/zh/api/docs/guides/embeddings.md
+++ b/docs/zh/api/docs/guides/embeddings.md
@@ -1,25 +1,25 @@
-# Vector embeddings
+# 向量嵌入
-> 如需完整文档索引,请参阅 [llms.txt](/llms.txt)。可通过在页面 URL 末尾追加 `.md` 来获取文档页面的 Markdown 版本。
+> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。在页面 URL 末尾添加 `.md` 即可获取该页面的 Markdown 版本。
## 什么是嵌入?
OpenAI 的文本嵌入用于衡量文本字符串之间的相关性。嵌入通常用于:
-- **搜索** (结果按与查询字符串的相关性排序)
-- **聚类** (按相似度对文本字符串进行分组)
-- **推荐** (推荐具有相关文本字符串的条目)
-- **异常检测** (识别与其他内容相关性较低的离群值)
-- **多样性度量** (分析相似度分布)
-- **分类** (按最相似的标签对文本字符串进行分类)
+- **Search** (结果按与查询字符串的相关性排序)
+- **Clustering** (将文本字符串按相似度分组)
+- **Recommendations** (推荐具有相关文本字符串的条目)
+- **Anomaly detection** (识别相关性较低的异常值)
+- **Diversity measurement** (分析相似度分布)
+- **Classification** (按最相似的标签对文本字符串进行分类)
-嵌入(embedding)是一个由浮点数组成的向量(列表)。两点之间的 [距离](#which-distance-function-should-i-use) 可以衡量它们的相似程度。距离越小表示相似度越高,距离越大表示相似度越低。
+嵌入(embedding)是由浮点数组成的向量(即列表)。两个向量之间的 [距离](#which-distance-function-should-i-use) 用于衡量它们之间的相关程度:距离越小,相关性越高;距离越大,相关性越低。
-请访问我们的 [定价页面](https://openai.com/api/pricing/) 了解有关嵌入定价的信息。请求费用按输入中的 [tokens](https://platform.openai.com/tokenizer) 数量计费,输入 [input](https://developers.openai.com/api/reference/resources/embeddings/methods/create#embeddings/create-input).
+请访问我们的 [定价页面](https://openai.com/api/pricing/) 以了解嵌入的计费方式。请求费用根据 [tokens](https://platform.openai.com/tokenizer) 中 [输入](https://developers.openai.com/api/reference/resources/embeddings/methods/create#embeddings/create-input).
## 如何获取嵌入
-若要获取 embedding,请将你的文本字符串发送到 [embeddings API 端点](https://developers.openai.com/api/reference/resources/embeddings) ,并附带 embedding 模型名称(例如。, `text-embedding-3-small`):
+要获取 embedding,请将你的文本字符串发送到 [embeddings API 端点](https://developers.openai.com/api/reference/resources/embeddings) ,并附上 embedding 模型名称(例如。, `text-embedding-3-small`):
示例:获取 embeddings
@@ -130,7 +130,7 @@ curl https://api.openai.com/v1/embeddings \
```
-响应中包含 embedding 向量(浮点数列表)以及一些额外的元数据。你可以提取该 embedding 向量,将其保存到向量数据库中,并用于许多不同的应用场景。
+响应中包含 embedding 向量(浮点数列表)以及一些额外的元数据。你可以将 embedding 向量提取出来,存入向量数据库,并用于许多不同的应用场景。
```json
{
@@ -153,15 +153,15 @@ curl https://api.openai.com/v1/embeddings \
}
```
-默认情况下,embedding 向量的长度为 `1536` , `text-embedding-3-small` 或 `3072` , `text-embedding-3-large`。若要在不丢失其概念表示能力的前提下降低 embedding 的维度,请传入 [dimensions 参数](https://developers.openai.com/api/reference/resources/embeddings/methods/create#embeddings-create-dimensions)。有关 embedding 维度的更多详细信息,请参阅 [embedding 应用场景部分](#use-cases).
+默认情况下,embedding 向量的长度为 `1536` ( `text-embedding-3-small` 或 `3072` ( `text-embedding-3-large`)。如果希望在保留其概念表示能力的前提下降低 embedding 的维度,请传入 [dimensions 参数](https://developers.openai.com/api/reference/resources/embeddings/methods/create#embeddings-create-dimensions)。有关 embedding 维度的更多详情,请参阅 [embedding 使用场景章节](#use-cases).
-## Embedding 模型
+## Embedding models
-OpenAI 提供两款强大的第三代嵌入模型(在模型 ID 中以 `-3` 表示)。阅读 embedding v3 [公告博客文章](https://openai.com/blog/new-embedding-models-and-api-updates) 了解更多详情。
+OpenAI 提供了两款强大的第三代嵌入模型(在模型 ID 中以 `-3` 表示)。阅读 embedding v3 [公告博客文章](https://openai.com/blog/new-embedding-models-and-api-updates) 以了解更多详情。
按输入 token 计费。以下为每美元可处理的文本页数示例(假设每页约 800 个 token):
-| 模型 | ~ 每美元页数 | 在 [MTEB](https://github.com/embeddings-benchmark/mteb) 评测 | 最大输入 |
+| Model | ~ 每美元可处理页数 | 在以下基准上的性能 [MTEB](https://github.com/embeddings-benchmark/mteb) 评估 | 最大输入 |
| ---------------------- | ------------------ | ------------------------------------------------------------------------ | --------- |
| text-embedding-3-small | 62,500 | 62.3% | 8192 |
| text-embedding-3-large | 9,615 | 64.6% | 8192 |
@@ -169,11 +169,11 @@ OpenAI 提供两款强大的第三代嵌入模型(在模型 ID 中以 `-3` 表
## 用例
-这里我们展示一些有代表性的使用案例,使用 [Amazon fine-food reviews 数据集](https://www.kaggle.com/snap/amazon-fine-food-reviews).
+下面我们将展示一些典型的用例,使用的是 [Amazon fine-food reviews 数据集](https://www.kaggle.com/snap/amazon-fine-food-reviews).
### 获取嵌入
-该数据集共包含截至 2012 年 10 月 Amazon 用户留下的 568,454 条食品评论。我们使用其中最近的 1000 条评论的子集进行示例展示。这些评论为英文,且通常带有正面或负面倾向。每条评论都有一个 `ProductId`, `UserId`, `Score`、评论标题(`Summary`)和评论正文(`Text`)。例如:
+该数据集共包含截至 2012 年 10 月由 Amazon 用户留下的 568,454 条食品评论。我们使用其中最近的 1000 条评论的子集进行示例说明。这些评论均为英文,且倾向于正面或负面评价。每条评论都有一个 `ProductId`, `UserId`, `Score`、评论标题(`Summary`)以及评论正文(`Text`)。例如:
@@ -186,7 +186,7 @@ OpenAI 提供两款强大的第三代嵌入模型(在模型 ID 中以 `-3` 表
-下面,我们将评论摘要和评论文本合并为单个组合文本。模型会对该组合文本进行编码,并输出一个向量嵌入。
+下面,我们将评论摘要和评论文本合并为一个合并后的文本。模型对该合并文本进行编码,并输出一个向量嵌入。
@@ -268,8 +268,30 @@ try (var writer = Files.newBufferedWriter(output)) {
System.out.println(output);
```
+```ruby
+require "fileutils"
+require "json"
+require "openai"
+
+client = OpenAI::Client.new
+reviews = ["A rich cup of coffee.", "A bright herbal tea."]
-若要从已保存的文件中加载数据,你可以运行以下命令:
+response = client.embeddings.create(
+ model: "text-embedding-3-small",
+ input: reviews.map { |review| review.tr("\n", " ") }
+)
+
+csv_field = ->(value) { %("#{value.gsub('"', '""')}") }
+rows = response.data.map.with_index do |embedding, index|
+ [csv_field.call(reviews.fetch(index)), csv_field.call(JSON.generate(embedding.embedding))].join(",")
+end
+
+FileUtils.mkdir_p("output")
+File.write("output/embedded_1k_reviews.csv", (["combined,ada_embedding"] + rows).join("\n") + "\n")
+```
+
+
+若要从已保存的文件加载数据,你可以运行以下代码:
```python
import pandas as pd
@@ -285,11 +307,11 @@ df["ada_embedding"] = df.ada_embedding.apply(eval).apply(np.array)
-使用更大的嵌入(例如将其存储在向量库中以供检索)通常比使用更小的嵌入成本更高,并且会消耗更多计算资源、内存和存储空间。
+使用更大的 embedding,例如将其存储在向量库中以供检索,通常会比使用更小的 embedding 花费更多成本,并消耗更多算力、内存和存储。
-我们的两个新嵌入模型都采用了 [一种技术](https://arxiv.org/abs/2205.13147) 训练而成,使开发者能够在使用嵌入时权衡性能与成本。具体而言,开发者可以缩短嵌入(即从序列末尾删除一些数字),而嵌入不会因此失去其表示概念的能力,只需传入 [`dimensions` API 参数](https://developers.openai.com/api/reference/resources/embeddings/methods/create#embeddings-create-dimensions)。例如,在 MTEB 基准测试中, `text-embedding-3-large` 嵌入可以缩短至 256 的维度,同时性能仍优于 `text-embedding-ada-002` 维度为 1536 的未缩短嵌入。你可以在我们的 [embeddings v3 发布博文](https://openai.com/blog/new-embedding-models-and-api-updates#:~:text=Native%20support%20for%20shortening%20embeddings).
+我们两款新的 embedding 模型都采用了 [一种技术进行训练](https://arxiv.org/abs/2205.13147) ,该技术允许开发者在使用 embedding 时权衡性能和成本。具体而言,开发者可以通过传入 dimensions 参数缩短 embedding(例如从末尾删除一些数值),而 embedding 仍保留其概念表示特性。 [`dimensions` API 参数](https://developers.openai.com/api/reference/resources/embeddings/methods/create#embeddings-create-dimensions)。例如,在 MTEB 基准上,一个 `text-embedding-3-large` 维度的 embedding 可以被缩短到 256 维,同时性能仍然优于未缩短的 `text-embedding-ada-002` 维 embedding(尺寸为 1536)。你可以阅读我们的 [embeddings v3 发布博客文章](https://openai.com/blog/new-embedding-models-and-api-updates#:~:text=Native%20support%20for%20shortening%20embeddings).
-中详细了解更改维度如何影响性能。通常,创建嵌入时使用 `dimensions` 参数是推荐的做法。在某些情况下,你可能需要在生成嵌入后更改其维度。手动更改维度时,必须确保按如下所示对嵌入的维度进行归一化。
+,了解更改维度如何影响性能的更多信息。一般而言,在创建 embedding 时使用 dimensions `dimensions` 参数是推荐的做法。在某些情况下,你可能需要在生成 embedding 之后更改其维度。手动更改维度时,必须确保按如下所示对 embedding 的各维度进行归一化。
```javascript
import OpenAI from "openai";
@@ -388,8 +410,26 @@ Console.WriteLine(
);
```
+```ruby
+require "openai"
+
+client = OpenAI::Client.new
+
+response = client.embeddings.create(
+ model: "text-embedding-3-small",
+ input: "Testing 123",
+ encoding_format: :float
+)
+
+shortened = response.data.fetch(0).embedding.first(256)
+magnitude = Math.sqrt(shortened.sum { |value| value**2 })
+normalized = shortened.map { |value| magnitude.zero? ? 0 : value / magnitude }
+
+puts(normalized)
+```
+
-动态更改维度可以实现非常灵活的使用方式。例如,使用只支持最长 1024 维嵌入的向量数据存储时,开发者现在仍可以使用我们最好的嵌入模型 `text-embedding-3-large` 并为 `dimensions` API 参数指定 1024 的值,从而将嵌入从 3072 维缩短,以牺牲部分精度换取更小的向量大小。
+动态更改维度可带来非常灵活的使用方式。例如,当使用的向量数据库仅支持最长 1024 维的 embedding 时,开发者现在仍然可以使用我们最好的 embedding 模型 `text-embedding-3-large` ,并为 dimensions 指定 1024 值, `dimensions` API 参数,这将 embedding 从 3072 维缩短下来,以牺牲部分精度换取更小的向量尺寸。
@@ -406,7 +446,7 @@ Console.WriteLine(
Question_answering_using_embeddings.ipynb
- 在许多常见情况下,模型并未在包含你希望在响应用户查询时可用的事实和信息的训练数据上进行训练。如下所示,一种解决方法是将额外信息放入模型的上下文窗口中。这在许多用例中有效,但会导致更高的 token 成本。在本 notebook 中,我们将探讨这种方法与基于嵌入的搜索之间的权衡。
+ 在许多常见情况下,模型并未在包含你想要在生成用户查询响应时可供访问的关键事实和信息的训练数据上进行训练。如以下示例所示,一种解决方案是将额外信息放入模型的上下文窗口中。这种方法在许多用例中有效,但会导致更高的 token 成本。在本 notebook 中,我们将探讨这种方法与基于 embeddings 的搜索之间的权衡。
```javascript
import OpenAI from "openai";
@@ -488,6 +528,35 @@ client.chat().completions().create(params).choices().stream()
.forEach(System.out::println);
```
+```ruby
+require "openai"
+
+client = OpenAI::Client.new
+article = "At the 2022 Winter Olympics, Great Britain won women's curling and Sweden won men's curling."
+question = <<~QUESTION
+ Use the article below to answer the question. If the answer cannot be found, say "I don't know."
+
+ Article:
+ #{article}
+
+ Question: Which athletes won the gold medal in curling at the 2022 Winter Olympics?
+QUESTION
+
+response = client.chat.completions.create(
+ model: "gpt-4.1-mini",
+ messages: [
+ {
+ role: :system,
+ content: "You answer questions about the 2022 Winter Olympics."
+ },
+ {role: :user, content: question}
+ ],
+ temperature: 0
+)
+
+puts(response.choices.fetch(0).message.content)
+```
+
@@ -504,7 +573,7 @@ client.chat().completions().create(params).choices().stream()
Semantic_text_search_using_embeddings.ipynb
- 为了检索最相关的文档,我们使用查询与各文档嵌入向量之间的余弦相似度,并返回得分最高的文档。
+ 为了检索最相关的文档,我们计算查询与每个文档的嵌入向量之间的余弦相似度,并返回得分最高的文档。
```javascript
import OpenAI from "openai";
@@ -600,6 +669,39 @@ IntStream.range(0, reviews.size())
.forEach(System.out::println);
```
+```ruby
+require "openai"
+
+client = OpenAI::Client.new
+reviews = [
+ "A rich cup of coffee.",
+ "Smooth beans in tomato sauce.",
+ "Dark chocolate with orange."
+]
+
+response = client.embeddings.create(
+ model: "text-embedding-3-small",
+ input: reviews + ["delicious beans"]
+)
+
+query = response.data.fetch(-1).embedding
+similarity = lambda do |embedding|
+ dot_product = embedding.zip(query).sum { |value, query_value| value * query_value }
+ magnitude = Math.sqrt(embedding.sum { |value| value**2 })
+ query_magnitude = Math.sqrt(query.sum { |value| value**2 })
+ dot_product / (magnitude * query_magnitude)
+end
+
+results = reviews.map.with_index do |review, index|
+ {
+ review: review,
+ score: similarity.call(response.data.fetch(index).embedding)
+ }
+end.sort_by { |result| -result.fetch(:score) }.first(3)
+
+puts(results)
+```
+
@@ -607,7 +709,7 @@ IntStream.range(0, reviews.size())
-#### 使用 embeddings 进行代码搜索
+#### 使用嵌入进行代码搜索
@@ -616,9 +718,9 @@ IntStream.range(0, reviews.size())
Code_search.ipynb
- 代码搜索的工作方式与基于嵌入的文本搜索类似。我们提供了一种方法,可以从给定代码仓库中的所有 Python 文件中提取 Python 函数。每个函数随后会按以下方式建立索引: `text-embedding-3-small` 模型。
+ 代码搜索的工作方式与基于嵌入的文本搜索类似。我们提供一种方法,可以从给定仓库中的所有 Python 文件中提取 Python 函数。然后每个函数都会被该 model 索引。 `text-embedding-3-small` model。
-要执行代码搜索,我们使用相同的模型将自然语言形式的查询进行嵌入。然后计算得到的查询嵌入与各个函数嵌入之间的余弦相似度。余弦相似度最高的结果最为相关。
+为了执行代码搜索,我们使用同一个 model 将自然语言形式的查询进行嵌入。然后我们计算所得查询嵌入与各个函数嵌入之间的余弦相似度。余弦相似度最高的结果最为相关。
```javascript
import OpenAI from "openai";
@@ -713,14 +815,46 @@ IntStream.range(0, functions.size())
.forEach(System.out::println);
```
+```ruby
+require "openai"
+client = OpenAI::Client.new
+functions = [
+ "function add(a, b) { return a + b; }",
+ "function complete(prompt) { return prompt; }"
+]
+response = client.embeddings.create(
+ model: "text-embedding-3-small",
+ input: functions + ["Completions API tests"]
+)
+
+query = response.data.fetch(-1).embedding
+similarity = lambda do |embedding|
+ dot_product = embedding.zip(query).sum { |value, query_value| value * query_value }
+ magnitude = Math.sqrt(embedding.sum { |value| value**2 })
+ query_magnitude = Math.sqrt(query.sum { |value| value**2 })
+ dot_product / (magnitude * query_magnitude)
+end
+
+results = functions.map.with_index do |source, index|
+ {
+ source: source,
+ score: similarity.call(response.data.fetch(index).embedding)
+ }
+end.sort_by { |result| -result.fetch(:score) }
+
+puts(results)
+```
-#### Recommendations using embeddings
+
+
+
+#### 使用 embeddings 进行推荐
@@ -729,9 +863,9 @@ IntStream.range(0, functions.size())
Recommendation_using_embeddings.ipynb
- 因为嵌入向量之间距离越小代表相似度越高,所以嵌入可以用于推荐。
+ 由于嵌入向量之间距离越短代表相似度越高,因此嵌入可用于推荐。
-下面我们演示一个基础的推荐器。它接收一个字符串列表和一个“来源”字符串,计算它们的嵌入,然后返回一个按相似度从高到低排序的字符串排名。作为具体示例,下面的关联 notebook 将该函数的一个版本应用于 [AG 新闻数据集](http://groups.di.unipi.it/~gulli/AG_corpus_of_news_articles.html) (采样至 2,000 条新闻描述),以返回与任意给定来源文章最相似的 5 篇文章。
+下面我们演示一个基础的推荐器。它接收一个字符串列表和一个“源”字符串,计算它们的嵌入,然后返回按相似度从高到低排序的字符串排名。作为具体示例,下面链接的 notebook 将此函数的一个版本应用于 [AG 新闻数据集](http://groups.di.unipi.it/~gulli/AG_corpus_of_news_articles.html) (采样至 2,000 条新闻文章描述),以返回与任意给定源文章最相似的前 5 篇文章。
```javascript
import OpenAI from "openai";
@@ -837,6 +971,40 @@ var nearestNeighbors =
System.out.println(nearestNeighbors);
```
+```ruby
+require "openai"
+
+client = OpenAI::Client.new
+strings = [
+ "A cheetah is a fast land animal.",
+ "A peregrine falcon is a fast bird.",
+ "A tortoise moves slowly."
+]
+
+response = client.embeddings.create(
+ model: "text-embedding-3-small",
+ input: strings
+)
+
+query = response.data.fetch(0).embedding
+similarity = lambda do |embedding|
+ dot_product = embedding.zip(query).sum { |value, query_value| value * query_value }
+ magnitude = Math.sqrt(embedding.sum { |value| value**2 })
+ query_magnitude = Math.sqrt(query.sum { |value| value**2 })
+ dot_product / (magnitude * query_magnitude)
+end
+
+recommendations = response.data.map.with_index do |embedding, index|
+ {
+ index: index,
+ text: strings.fetch(index),
+ similarity: similarity.call(embedding.embedding)
+ }
+end.sort_by { |recommendation| -recommendation.fetch(:similarity) }
+
+puts(recommendations)
+```
+
@@ -853,17 +1021,17 @@ System.out.println(nearestNeighbors);
Visualizing_embeddings_in_2D.ipynb
- embeddings 的维度大小取决于底层模型的复杂度。为了可视化这些高维数据,我们使用 t-SNE 算法将其变换为二维数据。
+ embeddings 的大小会随底层模型的复杂度而变化。为了对高维数据进行可视化,我们使用 t-SNE 算法将数据转换为二维。
-我们根据评论者给出的星级对每条评论进行着色:
+我们根据评论者给出的星级评分对每条评论进行着色:
-- 一星:红色
-- 二星:深橙色
-- 三星:金色
-- 四星:青绿色
-- 五星:深绿色
+- 1 星:红色
+- 2 星:深橙色
+- 3 星:金黄色
+- 4 星:青绿色
+- 5 星:深绿色
-可视化结果似乎生成了大约 3 个聚类,其中一个聚类主要包含负面评论。
+该可视化似乎大致生成了 3 个聚类,其中一个主要包含负面评价。
```python
import numpy as np
@@ -898,7 +1066,7 @@ plt.title("Amazon ratings visualized in language using t-SNE")
-#### Embedding 用作 ML 算法的文本特征编码器
+#### 将 Embedding 用作机器学习算法的文本特征编码器
@@ -907,11 +1075,11 @@ plt.title("Amazon ratings visualized in language using t-SNE")
Regression_using_embeddings.ipynb
- 在机器学习模型中,嵌入可以作为通用的自由文本特征编码器使用。如果某些相关输入是自由文本,加入嵌入将提升任何机器学习模型的性能。嵌入也可以在 ML 模型中用作分类特征编码器。当分类变量的名称具有实际含义且数量较多(例如职位名称)时,这种方式的价值最大。对于这一任务,相似性嵌入的表现通常优于搜索嵌入。
+ 在机器学习模型中,嵌入可以用作通用的自由文本特征编码器。如果部分相关输入是自由文本,引入嵌入将提升任何机器学习模型的性能。嵌入还可以在机器学习模型中用作类别特征编码器。当类别变量的名称有意义且数量较多(例如职位名称)时,这种做法价值最大。对于此任务,相似度嵌入通常比搜索嵌入表现更好。
-我们观察到,嵌入表示一般非常丰富且信息密集。例如,使用 SVD 或 PCA 对输入进行降维,即便只降低 10%,通常也会导致下游特定任务的性能下降。
+我们观察到,嵌入表示通常非常丰富且信息密集。例如,即使使用 SVD 或 PCA 将输入维度降低 10%,通常也会导致特定任务的下游性能下降。
-这段代码将数据拆分为训练集和测试集,供以下两个用例——回归和分类——使用。
+此代码将数据拆分为训练集和测试集,供以下两个用例(即回归和分类)使用。
```python
from sklearn.model_selection import train_test_split
@@ -924,9 +1092,9 @@ X_train, X_test, y_train, y_test = train_test_split(
#### 使用嵌入特征进行回归
-嵌入为预测数值提供了一种简洁优雅的方式。在本例中,我们根据评论文本预测评论者的星级评分。由于嵌入中蕴含了丰富的语义信息,即使评论数量很少,预测效果也相当不错。
+Embedding 是一种预测数值的优雅方式。在本示例中,我们根据评论的文本来预测评价者的星级评分。由于 Embedding 中蕴含的语义信息非常丰富,即使评论数量很少,预测效果也相当不错。
-我们假设评分是一个介于 1 到 5 之间的连续变量,并允许算法预测任意浮点值。该机器学习算法会最小化预测值与真实评分之间的距离,最终达到 0.39 的平均绝对误差,这意味着预测平均偏差不到半颗星。
+我们假设评分是介于 1 到 5 之间的连续变量,并允许算法预测任意浮点值。该机器学习算法会最小化预测值与真实评分之间的距离,最终达到 0.39 的平均绝对误差,这意味着平均而言预测偏差不到半颗星。
```python
from sklearn.ensemble import RandomForestRegressor
@@ -943,7 +1111,7 @@ preds = rfr.predict(X_test)
-#### 使用 embedding 特征进行分类
+#### 使用嵌入特征进行分类
@@ -952,9 +1120,9 @@ preds = rfr.predict(X_test)
Classification_using_embeddings.ipynb
- 这一次,我们不再让它预测 1 到 5 之间的任意值,而是尝试将评论的星数精确分类到 5 个区间,从 1 星到 5 星。
+ 这一次,我们不再让算法预测 1 到 5 之间的任意值,而是尝试将评论的精确星级分类到 5 个桶中,范围从 1 星到 5 星。
-训练完成后,模型在预测 1 星和 5 星评论时表现明显优于 2-4 星评论,这可能是由于极端情感表达的评论更容易区分。
+训练完成后,模型对 1 星和 5 星评论的预测效果远好于更细微的评论(2-4 星),这可能是因为极端情感的表述更为明显。
```python
from sklearn.ensemble import RandomForestClassifier
@@ -981,7 +1149,7 @@ preds = clf.predict(X_test)
Zero-shot_classification_with_embeddings.ipynb
- 我们可以在没有任何已标注训练数据的情况下,使用嵌入进行零样本分类。对于每个类别,我们嵌入该类别的名称或对该类别的简短描述。要以零样本方式对一段新文本进行分类,我们将其嵌入与所有类别嵌入进行比较,并预测相似度最高的类别。
+ 我们可以在没有任何标注训练数据的情况下,使用嵌入进行零样本分类。对于每个类别,我们会嵌入该类别的名称或简短描述。要以零样本方式对新的文本进行分类时,我们会将其嵌入与所有类别的嵌入进行比较,并预测相似度最高的类别。
```javascript
import OpenAI from "openai";
@@ -1050,6 +1218,31 @@ double positive = cosineSimilarity(review, embeddings.get(1).embedding());
System.out.println(positive > negative ? "positive" : "negative");
```
+```ruby
+require "openai"
+
+client = OpenAI::Client.new
+labels = ["negative", "positive"]
+
+response = client.embeddings.create(
+ model: "text-embedding-3-small",
+ input: labels + ["The coffee arrived quickly and tastes great."]
+)
+
+review = response.data.fetch(-1).embedding
+similarity = lambda do |embedding|
+ dot_product = embedding.zip(review).sum { |value, review_value| value * review_value }
+ magnitude = Math.sqrt(embedding.sum { |value| value**2 })
+ review_magnitude = Math.sqrt(review.sum { |value| value**2 })
+ dot_product / (magnitude * review_magnitude)
+end
+
+negative, positive = response.data.first(2).map do |embedding|
+ similarity.call(embedding.embedding)
+end
+puts((positive > negative) ? "positive" : "negative")
+```
+
@@ -1057,7 +1250,7 @@ System.out.println(positive > negative ? "positive" : "negative");
-#### 获取用于冷启动推荐的用户和商品嵌入
+#### 获取用于冷启动推荐的用户与商品嵌入
@@ -1066,9 +1259,9 @@ System.out.println(positive > negative ? "positive" : "negative");
User_and_product_embeddings.ipynb
- 我们可以通过对用户的所有评论取平均来获得该用户的嵌入表示。类似地,我们可以通过对某款产品的所有评论取平均来获得该产品的嵌入表示。为了展示这种方法的有效性,我们使用了 5 万条评论的子集,以便覆盖每个用户和每款产品的更多评论。
+ 我们可以通过对用户的所有评论取平均来得到该用户的 embedding。类似地,我们可以通过对某个产品的所有评论取平均来得到该产品的 embedding。为了展示这种方法的实用性,我们使用了 5 万条评论的子集,以便覆盖每位用户和每个产品的更多评论。
-我们在单独的测试集上评估这些嵌入表示的效果,在该测试集中,我们将用户嵌入和产品嵌入之间的相似度绘制为评分的函数。有趣的是,基于这种方法,甚至在用户收到产品之前,我们就能比随机猜测更准确地预测他们是否会喜欢该产品。
+我们在单独的测试集上评估这些 embedding 的实用性,将用户 embedding 和产品 embedding 的相似度绘制为评分的函数。有趣的是,基于这种方法,甚至在用户收到产品之前,我们就能比随机猜测更准确地预测他们是否会喜欢该产品。
```python
user_embeddings = df.groupby("UserId").ada_embedding.apply(np.mean)
@@ -1082,7 +1275,7 @@ prod_embeddings = df.groupby("ProductId").ada_embedding.apply(np.mean)
-#### 聚类
+#### Clustering
@@ -1091,9 +1284,9 @@ prod_embeddings = df.groupby("ProductId").ada_embedding.apply(np.mean)
Clustering.ipynb
- 聚类是处理大量文本数据的一种方法。Embeddings 对此任务非常有用,因为它们为每段文本提供了语义上有意义的向量表示。因此,通过无监督的方式,聚类将揭示我们数据集中隐藏的分组。
+ 聚类是处理大规模文本数据的一种方式。向量嵌入很适合这项任务,因为它们能为每段文本提供语义上有意义的向量表示。因此,聚类能够以无监督的方式发现我们数据集中隐藏的分组。
-在本示例中,我们发现了四个不同的簇:一个聚焦于狗粮,一个聚焦于负面评价,另外两个聚焦于正面评价。
+在示例中,我们发现了四个不同的聚类:一个聚焦于狗粮,一个聚焦于负面评论,另外两个聚焦于正面评论。
```python
import numpy as np
@@ -1114,7 +1307,7 @@ df["Cluster"] = kmeans.labels_
## FAQ
-### 如何在嵌入字符串前判断其包含多少 tokens?
+### 如何在嵌入字符串之前判断它包含多少个 token?
在 Python 中,你可以使用 OpenAI 的分词器将字符串拆分为 token [`tiktoken`](https://github.com/openai/tiktoken).
@@ -1135,27 +1328,27 @@ num_tokens_from_string("tiktoken is great!", "cl100k_base")
```
-对于第三代嵌入模型(如 `text-embedding-3-small`),请使用 `cl100k_base` 编码。
+对于第三代 embedding 模型(例如 `text-embedding-3-small`),请使用 `cl100k_base` 编码。
-更多详情和示例代码见 OpenAI Cookbook 指南 [如何使用 tiktoken 计算 token 数](https://developers.openai.com/cookbook/examples/how_to_count_tokens_with_tiktoken).
+更多详情和示例代码请参阅 OpenAI Cookbook 指南 [如何使用 tiktoken 计算 token 数](https://developers.openai.com/cookbook/examples/how_to_count_tokens_with_tiktoken).
### 如何快速检索 K 个最近的嵌入向量?
-如果需要快速搜索大量向量,我们推荐使用向量数据库。你可以在我们的 Cookbook 中找到使用向量数据库和 OpenAI API [的示例](https://developers.openai.com/cookbook/examples/vector_databases/readme) ,这些示例托管在 GitHub 上。
+如需在大量向量中快速检索,推荐使用向量数据库。你可以在 Cookbook 中找到结合向量数据库与 OpenAI API 的示例 [我们的 Cookbook](https://developers.openai.com/cookbook/examples/vector_databases/readme) 在 GitHub 上。
### 我应该使用哪种距离函数?
-我们推荐使用 [余弦相似度](https://en.wikipedia.org/wiki/Cosine_similarity)。距离函数的选择通常影响不大。
+我们推荐 [余弦相似度](https://en.wikipedia.org/wiki/Cosine_similarity)。距离函数的选择通常影响不大。
-OpenAI embeddings 已归一化为长度 1,这意味着:
+OpenAI embeddings are normalized to length 1, which means that:
- 余弦相似度可以通过仅使用点积来略微加快计算速度
-- 余弦相似度和欧氏距离将产生相同的排序结果
+- 余弦相似度和欧氏距离将产生完全相同的排序结果
-### 我可以在网上分享我的嵌入吗?
+### 我可以在网上分享我的 embeddings 吗?
-是的,客户拥有我们模型输入和输出的所有权,嵌入(embeddings)的情况也不例外。你需要确保你输入到我们 API 的内容不违反任何适用法律或我们的 [使用条款](https://openai.com/policies/terms-of-use).
+是的,客户拥有我们模型输入和输出的所有权,包括嵌入的情况。你需要确保你输入到我们 API 的内容不违反任何适用法律或我们的 [使用条款](https://openai.com/policies/terms-of-use).
-### V3 嵌入模型是否了解近期发生的事件?
+### V3 embedding 模型是否了解近期发生的事件?
-不, `text-embedding-3-large` 并且 `text-embedding-3-small` 模型缺乏对 2021 年 9 月之后发生的事件的了解。这通常不会像对文本生成模型那样造成太大的限制,但在某些极端情况下可能会降低性能。
\ No newline at end of file
+不, `text-embedding-3-large` 和 `text-embedding-3-small` 模型缺乏对 2021 年 9 月之后发生的事件的了解。这通常不像对文本生成模型那样构成很大的限制,但在某些边缘情况下可能会降低性能。
\ No newline at end of file
diff --git a/docs/zh/api/docs/guides/error-codes.md b/docs/zh/api/docs/guides/error-codes.md
index 07f07ff..5e2c1f8 100644
--- a/docs/zh/api/docs/guides/error-codes.md
+++ b/docs/zh/api/docs/guides/error-codes.md
@@ -1,53 +1,53 @@
# 错误代码
-> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。在页面 URL 后追加 `.md` 即可获取该页面的 Markdown 版本。
+> 如需查看完整的文档索引,请参阅 [llms.txt](/llms.txt)。在页面 URL 末尾附加 `.md` 即可获取该页面的 Markdown 版本。
-本指南概述了你可能会遇到的错误代码,这些错误代码来自 [API](https://developers.openai.com/api/docs/concepts) 以及我们的 [官方 Python 库](https://developers.openai.com/api/docs/libraries#install-an-official-sdk)。概览中提到的每个错误代码都有专门的章节提供进一步的指导。
+本指南包含你可能从 [Responses [API](https://developers.openai.com/api/docs/concepts) 以及我们的 [官方 Python 库](https://developers.openai.com/api/docs/libraries#install-an-official-sdk)。看到的错误代码概述。概览中提到的每个错误代码都有专门的章节提供进一步指导。
## API 错误
-| 代码 | 概述 |
-| ---------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
-| 400 - 无效 `service_tier` 参数 | **原因:** 所请求或解析的服务等级不允许用于该项目。
**解决方案:** 将 `service_tier` 设置为该项目允许的等级,或更新 [项目设置](https://platform.openai.com/settings/). |
-| 401 - 身份验证无效 | **原因:** 身份验证无效
**解决方案:** 确保使用了正确的 [API 密钥](https://platform.openai.com/settings/organization/api-keys) 以及对应的请求组织。 |
-| 401 - 提供的 API 密钥不正确 | **原因:** 所使用的请求 API 密钥不正确。
**解决方案:** 确认使用的 API 密钥正确,清除浏览器缓存,或 [生成新密钥](https://platform.openai.com/settings/organization/api-keys). |
-| 401 - 你必须是某个组织的成员才能使用 API | **原因:** 你的账号未隶属于任何组织。
**解决方案:** 联系我们以加入新组织,或请你的组织管理员 [邀请你加入组织](https://platform.openai.com/settings/organization/people). |
-| 401 - IP 未获授权 | **原因:** 你请求的 IP 与你的项目或组织配置的 IP 白名单不匹配。
**解决方案:** 从正确的 IP 发送请求,或更新你的 [IP 白名单设置](https://platform.openai.com/settings/organization/security/ip-allowlist). |
-| 403 - 国家、地区或区域不受支持 | **原因:** 你正在从不受支持的国家、地区或区域访问 API。
**解决方案:** 请参阅 [此页面](https://developers.openai.com/api/docs/supported-countries) 了解详细信息。 |
-| 429 - 信用余额已用完 | **代码:** `credit_balance_exhausted`
**原因:** 你的组织没有剩余的预付信用额度。
**解决方案:** [充值信用额度](https://platform.openai.com/settings/organization/billing) 以继续使用 API。 |
-| 429 - 请求已达到速率限制 | **原因:** 你发送请求的速度过快。
**解决方案:** 请放慢请求速度,并遵循 `Retry-After` header 中获取该值(如果存在)。请参阅 [速率限制指南](https://developers.openai.com/api/docs/guides/rate-limits). |
-| 429 - 已达到组织支出限额 | **代码:** `organization_spend_limit_exceeded`
**原因:** 你的组织已达到其强制支出限额。
**解决方案:** 调高或移除你的 [组织支出限额](https://platform.openai.com/settings/organization/limits). |
-| 429 - 已达到项目支出限额 | **代码:** `project_spend_limit_exceeded`
**原因:** 你的项目已达到其强制支出限额。
**解决方案:** 调高或移除你的 [项目设置](https://platform.openai.com/settings/). |
-| 429 - 已达到组织用量限额 | **代码:** `organization_usage_limit_exceeded`
**原因:** 你的组织已达到 OpenAI 分配的用量限额。
**解决方案:** 申请更高的 [已批准用量限额](https://platform.openai.com/settings/organization/limits) 或 [联系支持团队](https://help.openai.com/). |
-| 500 - 服务端在处理你的请求时发生错误 | **原因:** 我们的服务端出现问题。
**解决方案:** 请稍后重试,如果问题仍然存在,请联系我们。请查看 [状态页面](https://status.openai.com/). |
-| 503 - 引擎当前过载,请稍后重试 | **原因:** 我们的服务器正经历高流量。
**解决方案:** 请稍候片刻后重试你的请求。 |
-| 503 - 请求过快 | **原因:** 你的请求速率突然增加,正在影响服务可靠性。
**解决方案:** 请将请求速率降低至原有水平,保持稳定至少 15 分钟,然后再逐步提升。 |
+| Code | Overview |
+| ------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
+| 400 - 无效 `service_tier` 参数 | **原因:** 所请求或解析的服务等级不允许用于该项目。
**解决方案:** 将 `service_tier` 设置为该项目允许的等级,或在 [项目设置](https://platform.openai.com/settings/). |
+| 401 - 身份验证无效 | **原因:** 身份验证无效
**解决方案:** 确保使用了正确的 [API 密钥](https://platform.openai.com/settings/organization/api-keys) 和请求组织。 |
+| 401 - 提供的 API 密钥不正确 | **原因:** 请求所使用的 API 密钥不正确。
**解决方案:** 确保使用的 API 密钥正确,清除浏览器缓存,或 [生成新的密钥](https://platform.openai.com/settings/organization/api-keys). |
+| 401 - 你必须是某个组织的成员才能使用 API | **原因:** 你的账户不属于任何组织。
**解决方案:** 联系我们以加入新组织,或让你的组织管理员 [邀请你加入组织](https://platform.openai.com/settings/organization/people). |
+| 401 - IP 未授权 | **原因:** 你的请求 IP 与项目或组织配置的 IP 白名单不匹配。
**解决方案:** 从正确的 IP 发送请求,或更新你的 [IP 白名单设置](https://platform.openai.com/settings/organization/security/ip-allowlist). |
+| 403 - 国家、地区或领土不受支持 | **原因:** 你正在从不受支持的国家、地区或领土访问 API。
**解决方案:** 请参阅 [此页面](https://developers.openai.com/api/docs/supported-countries) 了解更多信息。 |
+| 429 - 信用额度已用尽 | **代码:** `credit_balance_exhausted`
**原因:** 你的组织没有剩余的预付信用额度。
**解决方案:** [充值信用额度](https://platform.openai.com/settings/organization/billing) 以继续使用 API。 |
+| 429 - 请求达到速率限制 | **原因:** 你发送请求的速率过快。
**解决方案:** 调整请求节奏,并遵循 `Retry-After` header(如果存在)。阅读 [速率限制指南](https://developers.openai.com/api/docs/guides/rate-limits). |
+| 429 - 请求过快 | **类型:** `rate_limit_error`
**代码:** `slow_down`
**原因:** 你的请求速率增长过快。
**解决方案:** 遵循 `Retry-After` header(如果存在),降低请求速率,并逐步提高。 |
+| 429 - 已达到组织支出上限 | **代码:** `organization_spend_limit_exceeded`
**原因:** 你的组织已达到强制支出上限。
**解决方案:** 提高或移除你的 [组织支出上限](https://platform.openai.com/settings/organization/limits). |
+| 429 - 已达到项目支出上限 | **代码:** `project_spend_limit_exceeded`
**原因:** 你的项目已达到强制支出上限。
**解决方案:** 在你的 [项目设置](https://platform.openai.com/settings/). |
+| 429 - 已达到组织用量上限 | **代码:** `organization_usage_limit_exceeded`
**原因:** 你的组织已达到OpenAI分配的用量上限。
**解决方案:** 申请更高的 [批准用量上限](https://platform.openai.com/settings/organization/limits) 或 [联系支持](https://help.openai.com/). |
+| 500 - 服务器在处理你的请求时发生错误 | **原因:** 我们服务器上的问题。
**解决方案:** 稍等片刻后重试请求,如果问题仍然存在,请联系我们。请查看 [状态页面](https://status.openai.com/). |
+| 503 - 模型暂时过载 | **类型:** `service_unavailable_error`
**代码:** `server_is_overloaded`
**原因:** 所请求的模型暂时过载。
**解决方案:** 遵循 `Retry-After` 响应头(如果存在),然后重试请求。 |
-对于与计费有关的错误,请检查 `error.code` 以确定具体原因。更广泛的 `error.type` 仍然可以 `insufficient_quota`.
+对于与计费相关的错误,请检查 `error.code` 以确定具体原因。范围更大的 `error.type` 仍然可以 `insufficient_quota`.
-重试计费、支出或配额错误不会恢复 API 访问权限。请先更新相关额度或限额,然后再发送另一个请求。
+重试计费、支出或配额相关错误不会恢复 API 访问权限。请在发送下一个请求之前更新相关的额度或限额。
-## WebSocket mode errors
+## WebSocket 模式错误
-如果你正在使用 [the Responses API WebSocket 模式](https://developers.openai.com/api/docs/guides/websocket-mode),你可能会遇到以下这些额外的错误:
+如果你正在使用 [Responses API 的 WebSocket 模式](https://developers.openai.com/api/docs/guides/websocket-mode),你可能会遇到以下这些额外的错误:
-- `previous_response_not_found`: `previous_response_id` 无法从当前状态解析。请使用完整的输入上下文重试,并 `previous_response_id` 设置为 `null`.
-- `websocket_connection_limit_reached`:连接已达到 60 分钟的上限。请打开新的 WebSocket 连接并继续。
+- `previous_response_not_found`: `previous_response_id` 无法根据当前可用状态解析。请使用完整的输入上下文重试,并 `previous_response_id` 设置为 `null`.
+- `websocket_connection_limit_reached`: 连接已达到 60 分钟的上限。请新建 WebSocket 连接并继续。
### 400 - Invalid service_tier argument
-当请求选择或解析到项目中不允许的 API 服务层级时,接口 会返回消息 "Invalid service_tier argument: The requested service tier is not allowed for this project."。 `invalid_request_error` ,且 `error.param` 设置为 `service_tier` 时,会触发该错误。
+当请求选择或解析到该项目不允许的 service tier 时,API 会返回消息 "Invalid service_tier argument: The requested service tier is not allowed for this project.",并伴 `invalid_request_error` 随 `error.param` 设置为 `service_tier` 当请求选择或解析到该项目不允许的服务层级时。
-项目限制适用于 `default`, `flex`,以及 `priority` 服务层级。 `fast` 服务层级会被评估为 `priority`。如果请求省略 `service_tier` 或将其设置为 `auto` ,但最终解析到了不允许的层级,也可能会返回此错误。Scale Tier 不受此项目策略影响。
+项目限制适用于 `default`, `flex`,以及 `priority` 服务层级。 `fast` 服务层级评估为 `priority`。省略 `service_tier` 或将其设置为 `auto` 的请求如果解析到被禁用的层级,也可能返回此错误。Scale Tier 不受此项目策略限制。
-解决此错误的方法:
+若要解决此错误:
-- 请在 [项目设置](https://platform.openai.com/settings/).
-- 中 `service_tier` 查看允许的服务层级,并将。
-- 设置为项目允许的 `auto` 层级。如果请求使用 `service_tier`,或省略了该字段,请更新项目设置,使解析得到的层级在允许范围内。
+- 在 [项目设置](https://platform.openai.com/settings/).
+- 将 `service_tier` 设置为该项目允许的层级。
+- 如果请求使用了 `auto` 或省略了 `service_tier`,请更新项目设置,使解析后的层级被允许。
@@ -55,19 +55,19 @@
-### 401 - Invalid Authentication
+### 401 - 身份验证无效
此错误消息表明你的身份验证凭据无效。出现这种情况可能有多种原因,例如:
-- 你正在使用已撤销的 API 密钥。
-- 你正在使用的 API 密钥与请求组织或项目所分配的密钥不同。
-- 你正在使用一个 API 密钥,该密钥不具有你所调用端点所需的权限。
+- 你正在使用一个已被吊销的 API 密钥。
+- 你正在使用的 API 密钥与发起请求的组织或项目所分配的密钥不同。
+- 你正在使用的 API 密钥没有调用该端点所需的权限。
-若要解决此错误,请按照以下步骤操作:
+要解决此错误,请按以下步骤操作:
-- 请确认你在请求头中使用的 API 密钥和组织 ID 正确无误。你可以在 [你的账户设置](https://platform.openai.com/settings/organization/api-keys) 中找到你的 API 密钥和组织 ID,或在 [通用设置](https://platform.openai.com/settings/organization/general) 中选择所需项目后找到对应项目的密钥。
-- 如果不确定你的 API 密钥是否有效,可以 [生成一个新的](https://platform.openai.com/settings/organization/api-keys). 确保在请求中使用新的 API 密钥替换旧密钥,并遵循我们的 [最佳实践指南](https://help.openai.com/en/articles/5112595-best-practices-for-api-key-safety).
+- 检查你的请求头中使用的 API 密钥和组织 ID 是否正确。你可以在 [账户设置](https://platform.openai.com/settings/organization/api-keys) 中找到你的 API 密钥和组织 ID,也可以通过 [通用设置](https://platform.openai.com/settings/organization/general) 找到特定项目相关的密钥。方法是选择相应的项目。
+- 如果你不确定你的 API 密钥是否有效,可以 [生成一个新的](https://platform.openai.com/settings/organization/api-keys)。请确保在请求中使用新的 API 密钥替换旧的密钥,并遵循我们的 [最佳实践指南](https://help.openai.com/en/articles/5112595-best-practices-for-api-key-safety).
@@ -78,18 +78,18 @@
### 401 - 提供的 API 密钥不正确
-此错误信息表明你在请求中使用的 API 密钥不正确。出现这种情况可能有多种原因,例如:
+此错误消息表明你在请求中使用的 API 密钥不正确。可能由多种原因造成,例如:
- 你的 API 密钥中存在拼写错误或多余的空格。
- 你正在使用属于其他组织或项目的 API 密钥。
-- 你正在使用已被删除或停用的 API 密钥。
+- 你正在使用一个已被删除或停用的 API 密钥。
- 旧的、已撤销的 API 密钥可能在本地被缓存。
-若要解决此错误,请按照以下步骤操作:
+要解决此错误,请按以下步骤操作:
- 尝试清除浏览器的缓存和 Cookie,然后重试。
- 检查你在请求头中使用的 API 密钥是否正确。
-- 如果你不确定自己的 API 密钥是否正确,可以 [生成一个新的](https://platform.openai.com/settings/organization/api-keys)。请确保在代码库中替换旧的 API 密钥,并按照我们的 [最佳实践指南](https://help.openai.com/en/articles/5112595-best-practices-for-api-key-safety).
+- 如果你不确定你的 API 密钥是否正确,你可以 [生成一个新的](https://platform.openai.com/settings/organization/api-keys)。请确保在代码库中替换旧的 API 密钥,并遵循我们的 [最佳实践指南](https://help.openai.com/en/articles/5112595-best-practices-for-api-key-safety).
@@ -97,21 +97,21 @@
-### 401 - 你必须是组织的成员才能使用 API
+### 401 - You must be a member of an organization to use the API
-该错误消息表明你的账户不属于任何组织。这可能由多种原因导致,例如:
+此错误信息表明你的账户不属于任何组织。这可能由多种原因导致,例如:
- 你已离开或被移出之前的组织。
- 你已离开或被移出之前的项目。
- 你的组织已被删除。
-若要解决此错误,请按照以下步骤操作:
+要解决此错误,请按以下步骤操作:
-- 如果你已离开或被移出之前的组织,可以申请新建一个组织,或接受现有组织的邀请。
-- 如需申请新建组织,请通过 help.openai.com 与我们联系。
-- 现有组织所有者可以通过 [Team 页面](https://platform.openai.com/settings/organization/people) 邀请你加入他们的组织,也可以从 [Settings 页面](https://platform.openai.com/settings/organization/general).
-- 如果你已离开或被移出之前的项目,可以请组织或项目所有者重新添加你,或创建一个新项目。
+- 如果你已离开或被移出之前的组织,你可以申请一个新组织,或受邀加入现有组织。
+- 若要申请新组织,请通过 help.openai.com 与我们联系。
+- 现有组织所有者可以通过 [Team 页面](https://platform.openai.com/settings/organization/people) 邀请你加入他们的组织,也可以从 [Settings 页面](https://platform.openai.com/settings/organization/general).
+- 如果你已离开或被移出之前的项目,你可以让你的组织所有者或项目所有者将你重新加入,或创建一个新项目。
@@ -119,12 +119,12 @@
-### 429 - 信用额度已用尽
+### 429 - 信用额度已用完
-该 `credit_balance_exhausted` 错误表明你的组织的预付信用额度已用完。
+该 `credit_balance_exhausted` 错误表明你所在组织的预付信用余额已用尽。
-若要恢复 API 访问权限, [在你的账单设置中添加额度](https://platform.openai.com/settings/organization/billing).
+如需恢复 API 访问权限, [请前往账单设置添加额度](https://platform.openai.com/settings/organization/billing).
@@ -135,20 +135,20 @@
### 429 - 请求已达到速率限制
-此错误消息表明你已达到 API 的分配速率限制。这意味着你在短时间内提交了过多 token 或请求,已超过允许的请求数。出现这种情况可能有多种原因,例如:
+该错误信息表示你已触及所分配 API 的速率限制。这意味着你在短时间内提交了过多 token 或请求,已超出允许的请求数量。出现这种情况可能有多种原因,例如:
-- 你在使用循环或脚本发起频繁或并发的请求。
+- 你正在使用循环或脚本发出频繁或并发的请求。
- 你正在与其他用户或应用共享你的 API 密钥。
-- 你正在使用限速较低地免费套餐。
-- 你已达到所在项目所设定的上限
+- 你正在使用限速较低的免费套餐。
+- 你已达到所在项目定义的上限
-若要解决此错误,请按照以下步骤操作:
+要解决此错误,请按以下步骤操作:
-- 请控制请求节奏,避免进行不必要或重复的调用。
-- 如果响应中携带 `Retry-After` 头,请至少等待该头指定的时间后再重试;如果没有该头,请使用带抖动的指数退避策略并限制重试次数。每个官方 SDK 都会在符合条件时遵循该头。详情请参阅我们的 [限速指南](https://developers.openai.com/api/docs/guides/rate-limits).
-- 如果你所在组织与他人共享,请注意限额是按组织而非按用户施加的。建议了解团队其他成员的使用情况,因为这也会计入限额。
-- 如果你正在使用免费或低阶套餐,建议升级到限速更高的按量付费套餐。你可以在我们的 [限速指南](https://developers.openai.com/api/docs/guides/rate-limits).
-- 联系你的组织所有者以提高所在项目的限速
+- 控制请求节奏,避免进行不必要或重复的调用。
+- 如果响应中存在 `Retry-After` 标头,请至少等待其指定的时间后再重试。如果缺失该标头,请使用带抖动的指数退避策略,并限制重试次数。每个官方 SDK 在符合条件的重试中已经遵循此标头。更多信息请参阅我们的 [速率限制指南](https://developers.openai.com/api/docs/guides/rate-limits).
+- 如果你与他人共享组织,请注意限额是按组织而非按用户计算的。值得检查团队其他成员的使用情况,因为这也会计入限额。
+- 如果你正在使用免费或低阶套餐,请考虑升级到提供更高速率限制的按量付费套餐。你可以参阅我们的 [速率限制指南](https://developers.openai.com/api/docs/guides/rate-limits).
+- 联系你的组织所有者以提高所在项目的速率限制
@@ -156,76 +156,72 @@
-### 429 - 已达到组织消费上限
+### 429 - 限速
-该 `organization_spend_limit_exceeded` 错误表示你的组织已达到强制的每月 [支出上限](https://developers.openai.com/api/docs/guides/spend-limits)。该上限适用于组织内所有项目的API流量。
+一个 `429` response with the `rate_limit_error` type and `slow_down` code indicates that your request rate increased faster than the service can safely handle. It can occur even when your traffic is within its requests-per-minute and tokens-per-minute limits.
-要恢复 API 访问权限,请在你的 [组织限额设置](https://platform.openai.com/settings/organization/limits)。中提高或移除该限制。否则,访问权限将在每月限额重置后恢复。
+As a rule of thumb, once your traffic reaches 1 million input tokens per minute (TPM), increase it by no more than 50% every 15 minutes. The exact point at which the ramp-rate limit applies can vary by model and traffic conditions.
+若要解决此错误:
+- 如果响应中存在 `Retry-After` header 存在时,至少等待其指定的时长后再重试。如果缺少 header,则增大重试之间的延迟,并加入一个小的随机延迟。
+- 降低请求速率,然后逐步提高。
+- 保持流量模式稳定,以降低再次发生 `slow_down` 错误的几率。
+按量付费流量经常触达速率提升上限的企业客户可以考虑 [Scale Tier](https://openai.com/api-scale-tier/) ,以在符合条件的模型上获得更可预期的容量。对于 GPT-5.6 及更高版本的模型,请参阅 [Reserved Tier](https://openai.com/api-reserved-tier/)。这些容量选项不能取代上述恢复步骤:请继续遵守 `Retry-After` 中的相关内容(如果存在),并逐步提升流量。
-### 429 - 已达到项目支出上限
-该 `project_spend_limit_exceeded` 错误表示你的项目已达到强制执行的每月 [支出上限](https://developers.openai.com/api/docs/guides/spend-limits)。其他项目可以继续运行,除非它们自身或组织层级也达到了相应上限。
-要恢复 API 访问权限,请在你的 [项目设置](https://platform.openai.com/settings/)。中提高或移除该限制。否则,访问权限将在每月限额重置后恢复。
+### 429 - 已达到组织支出限额
+该 `organization_spend_limit_exceeded` 错误表明你的组织已达到强制执行的每月 [支出上限](https://developers.openai.com/api/docs/guides/spend-limits)。该上限适用于组织内所有项目的 API 流量。
+要恢复 API 访问权限,请在你的 [组织限额设置](https://platform.openai.com/settings/organization/limits)。中提高或移除该上限。否则,访问将在每月限额重置后恢复。
-### 429 - 已达到组织使用上限
-该 `organization_usage_limit_exceeded` 错误表示你的组织已达到 OpenAI 分配的每月 [用量上限](https://developers.openai.com/api/docs/guides/rate-limits#usage-tiers). 该限制与组织及项目层级的消费额度相互独立,由你自行配置。
-若要恢复 API 的访问权限,请申请更高的 [已批准的使用上限](https://platform.openai.com/settings/organization/limits) 或 [联系支持团队](https://help.openai.com/).
+### 429 - 项目支出限额已达上限
+该 `project_spend_limit_exceeded` 错误表示你的项目已达到其强制月度 [支出上限](https://developers.openai.com/api/docs/guides/spend-limits)。其他项目可以继续运行,除非它们自己的限额或组织限额也已达到。
+要恢复 API 访问权限,请在你的 [项目设置](https://platform.openai.com/settings/)。中提高或移除该上限。否则,访问将在每月限额重置后恢复。
-### 503 - 引擎当前负载过高,请稍后重试
-该错误信息表示我们的服务器当前流量较高,暂时无法处理你的请求。出现这种情况可能有多种原因,例如:
-- 我们的服务出现了突然的需求激增或飙升。
-- 我们的服务器正在执行计划内或计划外的维护或更新。
-- 我们的服务器发生了意外或不可避免的停机或事故。
+### 429 - 已达到组织使用上限
-若要解决此错误,请按照以下步骤操作:
-- 短暂等待后重试你的请求。我们建议使用指数退避策略,或遵循响应头和速率限制的合理重试逻辑。你可以在我们的速率限制 [最佳实践](https://help.openai.com/en/articles/6891753-rate-limit-advice).
-- 查看我们的 [状态页面](https://status.openai.com/) ,了解有关我们服务和服务器的任何更新或公告。
-- 如果在合理时间后你仍然遇到此错误,请联系我们以获取进一步帮助。对于由此带来的不便,我们深表歉意,并感谢你的耐心和理解。
+该 `organization_usage_limit_exceeded` 错误表明你的组织已达到 OpenAI 分配的每月 [使用上限](https://developers.openai.com/api/docs/guides/rate-limits#usage-tiers). 该限额与你配置的组织及项目支出限额相互独立。
+若要恢复 API 访问权限,请申请更高的 [已批准的使用上限](https://platform.openai.com/settings/organization/limits) 或 [联系支持团队](https://help.openai.com/).
-### 503 - Slow Down
+### 503 - 模型暂时过载
-该错误可能在使用按量付费模型时发生,这些模型由所有 OpenAI 用户共享。这表示你的流量显著增加,导致模型过载,并触发了临时限流以维持服务稳定性。
-若要解决此错误,请按照以下步骤操作:
+一个 `503` response with the `service_unavailable_error` type and `server_is_overloaded` 错误代码表示所请求的模型当前没有足够的容量来处理你的请求。
-- 将请求速率恢复到原有水平,稳定保持至少 15 分钟,然后逐步提升。
-- 保持一致的流量模式,以尽可能降低被限流的可能性。如果你的请求量保持稳定,很少会遇到此错误。
-- 考虑升级到 [Scale Tier](https://openai.com/api-scale-tier/) ,以获得有保障的容量和性能,从而在高需求时段获得更可靠的访问。
+如果响应中包含 `Retry-After` 头,请至少等待其指定的时长后再重试。如果该头缺失,请增大重试之间的间隔。如果错误仍然存在,请查看 [状态页](https://status.openai.com/) 以了解当前是否有正在发生的事件。
@@ -233,34 +229,34 @@
## Python 库错误类型
-| 类型 | 概述 |
+| 类型 | Overview |
| ------------------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
-| APIConnectionError | **原因:** 无法连接到我们的服务。
**解决方案:** 检查你的网络设置、代理配置、SSL 证书或防火墙规则。 |
-| APITimeoutError | **原因:** 请求超时。
**解决方案:** 稍等片刻后重试你的请求,如果问题仍然存在,请联系我们。 |
-| AuthenticationError | **原因:** 你的 API key 或 token 无效、已过期或已被吊销。
**解决方案:** 检查你的 API key 或 token,确认其正确且处于启用状态。你可能需要在你的账户控制台中重新生成一个。 |
-| BadRequestError | **原因:** 你的请求格式有误或缺少某些必需参数,例如 token 或输入。
**解决方案:** 错误消息应当会就你所遇到的具体错误给出建议。请参阅你所调用的 [文档](https://developers.openai.com/api/reference/overview) 了解你正在调用的特定 API 方法,并确保你发送的参数有效且完整。你可能还需要检查请求数据的编码、格式或大小。 |
-| ConflictError | **原因:** 该资源已被其他请求更新。
**解决方案:** 尝试再次更新该资源,并确保没有其他请求在尝试更新它。 |
-| InternalServerError | **原因:** 我们这边出现了问题。
**解决方案:** 稍等片刻后重试你的请求,如果问题仍然存在,请联系我们。 |
+| APIConnectionError | **原因:** 连接到我们的服务时出现问题。
**解决方案:** 检查你的网络设置、代理配置、SSL 证书或防火墙规则。 |
+| APITimeoutError | **原因:** 请求超时。
**解决方案:** 短暂等待后重试你的请求,如果问题仍然存在,请联系我们。 |
+| AuthenticationError | **原因:** 你的 API 密钥或令牌无效、已过期或已被撤销。
**解决方案:** 检查你的 API 密钥或令牌,确保它正确且处于启用状态。你可能需要在你的账户控制台中重新生成一个。 |
+| BadRequestError | **原因:** 你的请求格式有误或缺少某些必需参数,例如令牌或输入。
**解决方案:** 错误消息应会提示你所犯的具体错误。请查阅 [文档](https://developers.openai.com/api/reference/overview) ,了解你正在调用的具体 API 方法,并确保你发送的参数有效且完整。你可能还需要检查请求数据的编码、格式或大小。 |
+| ConflictError | **原因:** 该资源已被另一个请求更新。
**解决方案:** 尝试再次更新该资源,并确保没有其他请求正在尝试更新它。 |
+| InternalServerError | **原因:** 我们这边出现了问题。
**解决方案:** 短暂等待后重试你的请求,如果问题仍然存在,请联系我们。 |
| NotFoundError | **原因:** 请求的资源不存在。
**解决方案:** 请确认你使用的是正确的资源标识符。 |
| PermissionDeniedError | **原因:** 你没有访问所请求资源的权限。
**解决方案:** 请确认你使用的是正确的 API key、组织 ID 和资源 ID。 |
-| RateLimitError | **原因:** 你已触及分配的速率上限。
**解决方案:** 请合理控制请求节奏,并遵循 `Retry-After` 标头(出现的话)。每个官方 SDK 已对符合条件的重试遵守该标头。更多信息请参阅我们的 [速率限制指南](https://developers.openai.com/api/docs/guides/rate-limits). |
-| UnprocessableEntityError | **原因:** 请求格式正确,但无法处理该请求。
**解决方案:** 请重试该请求。 |
+| RateLimitError | **原因:** 你已达到分配的速率限制。
**解决方案:** 请合理控制请求节奏并遵循 `Retry-After` 提示(出现时使用)。每个官方 SDK 已自动遵循此响应头处理符合条件的重试。更多信息请参阅我们的 [速率限制指南](https://developers.openai.com/api/docs/guides/rate-limits). |
+| UnprocessableEntityError | **原因:** 请求格式正确但无法处理。
**解决方案:** 请重试该请求。 |
### APIConnectionError
-一个 `APIConnectionError` 表示你的请求无法到达我们的服务器或未能建立安全连接。这可能是由网络问题、代理配置、SSL 证书或防火墙规则引起的。
+一个 `APIConnectionError` 表示你的请求未能到达我们的服务器或未能建立安全连接。这可能是由于网络问题、代理配置、SSL 证书或防火墙规则导致的。
如果遇到 `APIConnectionError`,请尝试以下步骤:
-- 检查你的网络设置,确保拥有稳定且快速的互联网连接。你可能需要切换到其他网络、使用有线连接,或减少占用带宽的设备或应用程序数量。
-- 检查你的代理配置,确保其与我们的服务兼容。你可能需要更新代理设置、使用其他代理,或完全绕过代理。
-- 检查你的 SSL 证书,确保它们有效且为最新版本。你可能需要安装或续期证书、更换证书颁发机构,或禁用 SSL 验证。
+- 检查你的网络设置,确保拥有稳定且快速的互联网连接。你可能需要切换到其他网络、使用有线连接,或减少占用带宽的设备或应用数量。
+- 检查你的代理配置,确保它与我们的服务兼容。你可能需要更新代理设置、使用其他代理,或完全绕过代理。
+- 检查你的 SSL 证书,确保它们有效且为最新版本。你可能需要安装或续订证书、使用其他证书颁发机构,或禁用 SSL 验证。
- 检查你的防火墙规则,确保它们没有阻止或过滤我们的服务。你可能需要修改防火墙设置。
- 在适用的情况下,检查你的容器是否具有发送和接收流量的正确权限。
-- 如果问题仍然存在,请参阅我们针对持续性错误的后续步骤部分。
+- 如果问题仍然存在,请参阅我们关于持续性错误的下一步操作部分。
@@ -271,13 +267,13 @@
### APITimeoutError
-一个 `APITimeoutError` 错误表示你的请求耗时过长,我们的服务端关闭了连接。这可能是由于网络问题、我们的服务负载过高,或者请求较为复杂需要更多处理时间。
+一个 `APITimeoutError` error 表示你的请求耗时过长,服务器已关闭连接。这可能由网络问题、我们的服务负载过高,或请求过于复杂需要更多处理时间所导致。
-如果遇到此错误 `APITimeoutError` 错误,请尝试以下步骤:
+如果遇到 `APITimeoutError` 错误,请尝试以下步骤:
-- 稍等几秒后重试请求。有时网络拥塞或服务负载会下降,第二次尝试时请求可能会成功。
-- 检查你的网络设置,确保拥有稳定且快速的互联网连接。你可能需要切换到其他网络、使用有线连接,或减少占用带宽的设备或应用程序数量。
-- 如果问题仍然存在,请参阅我们针对持续性错误的后续步骤部分。
+- 等待几秒后重试请求。有时,网络拥塞或我们的服务负载可能会减轻,第二次尝试时请求可能会成功。
+- 检查你的网络设置,确保拥有稳定且快速的互联网连接。你可能需要切换到其他网络、使用有线连接,或减少占用带宽的设备或应用数量。
+- 如果问题仍然存在,请参阅我们关于持续性错误的下一步操作部分。
@@ -288,12 +284,12 @@
### AuthenticationError
-一个 `AuthenticationError` 表示你的 API 密钥或令牌无效、已过期或已被吊销。这可能是由于拼写错误、格式问题或安全漏洞所致。
+一个 `AuthenticationError` 表示你的 API 密钥或令牌无效、已过期或已被吊销。这可能是由于拼写错误、格式错误或安全漏洞导致的。
如果遇到 `AuthenticationError`,请尝试以下步骤:
-- 检查你的 API 密钥或令牌,确认其正确且处于启用状态。你可能需要在 API 密钥控制台重新生成一个密钥,确保没有多余的空格或字符,或者如果有多个密钥或令牌,则换用其他可用的密钥或令牌。
-- 确保遵循了正确的格式。
+- 检查你的 API 密钥或令牌,确保其正确且处于激活状态。如果需要,可以从 API Key 控制台重新生成一个密钥,确保没有多余的空格或字符,或者在拥有多个密钥或令牌时使用其他可用的那个。
+- 确保你已遵循正确的格式。
@@ -305,15 +301,15 @@
-一个 `BadRequestError` (formerly `InvalidRequestError`) 表示你的请求格式有误或缺少某些必填参数,例如 token 或输入。这可能是由于代码中存在拼写错误、格式错误或逻辑错误所致。
+一个 `BadRequestError` (formerly `InvalidRequestError`)表示你的请求格式错误或缺少某些必需参数,例如令牌或输入。这可能是由于代码中存在拼写错误、格式错误或逻辑错误。
如果遇到 `BadRequestError`,请尝试以下步骤:
-- 仔细阅读错误消息并确定具体的错误。错误消息应提示你哪个参数无效或缺失,以及期望的值或格式是什么。
-- 查阅相关 [API 参考](https://developers.openai.com/api/reference/overview) ,确认你正在调用的具体 API 方法,并确保你发送的参数有效且完整。你可能需要核对参数名称、类型、值和格式,并确保它们与文档一致。
-- 检查请求数据的编码、格式或大小,并确保它们与我们的服务兼容。你可能需要将数据编码为 UTF-8,将数据格式化为 JSON,或者在数据过大时进行压缩。
-- 使用 Postman 或 curl 等工具测试你的请求,并确保它按预期工作。你可能需要调试你的代码,并修复请求逻辑中的任何错误或不一致之处。
-- 如果问题仍然存在,请参阅我们针对持续性错误的后续步骤部分。
+- 仔细阅读错误信息,明确具体的错误原因。错误信息应会告知你是哪个参数无效或缺失,以及期望的值或格式是什么。
+- 查看 [API 参考](https://developers.openai.com/api/reference/overview) 针对你调用的具体 API 方法,确保你发送的参数有效且完整。你可能需要检查参数的名称、类型、值和格式,并确保它们与文档一致。
+- 检查你请求数据的编码、格式或大小,确保它们与我们的服务兼容。如果数据过大,你可能需要将数据编码为 UTF-8、以 JSON 格式组织数据,或对数据进行压缩。
+- 使用 Postman 或 curl 等工具测试你的请求,确保它按预期工作。你可能需要调试你的代码并修复请求逻辑中的任何错误或不一致之处。
+- 如果问题仍然存在,请参阅我们关于持续性错误的下一步操作部分。
@@ -324,17 +320,17 @@
### InternalServerError
-一个 `InternalServerError` 表示在处理你的请求时,我们这边出现了问题。这可能是由于临时错误、缺陷或系统故障导致的。
+一个 `InternalServerError` 表明在处理你的请求时,我们这边出现了问题。这可能是由于临时错误、缺陷或系统故障导致的。
-对于由此带来的不便,我们深表歉意,并会尽快解决相关问题。你可以 [查看我们的系统状态页面](https://status.openai.com/) 以获取更多信息。
+我们对由此带来的不便表示歉意,并会尽快解决这些问题。你可以 [查看我们的系统状态页面](https://status.openai.com/) 以获取更多信息。
如果遇到 `InternalServerError`,请尝试以下步骤:
-- 等待几秒后重试你的请求。有时问题会很快自行消除,第二次请求就可能成功。
-- 查看我们的状态页面,了解是否有正在发生的事件或维护可能影响我们的服务。如果有正在处理的事件,请关注最新进展,并等到事件解决后再重试你的请求。
-- 如果问题仍然存在,请参阅我们的“持续性错误后续步骤”部分。
+- 稍等几秒后重试你的请求。有时问题可能会很快解决,第二次重试时请求就会成功。
+- 查看我们的状态页,了解是否有任何可能影响我们服务的事故或维护。如果当前有进行中的事故,请关注更新并等待问题解决后再重试你的请求。
+- 如果问题仍然存在,请查看我们的“持续性错误后续步骤”部分。
-我们的支持团队将调查该问题并尽快回复你。由于需求量大,我们的支持队列等待时间可能较长。你也可以 [在我们的社区论坛中发帖](https://community.openai.com) ,但请务必省略任何敏感信息。
+我们的支持团队将调查该问题并尽快回复你。由于需求量较大,我们的支持队列等待时间可能会比较长。你也可以 [在我们的社区论坛中发帖](https://community.openai.com) ,但请务必省略任何敏感信息。
@@ -345,35 +341,35 @@
### RateLimitError
-一个 `RateLimitError` 表示你已达到分配到的速率上限。这说明你在给定时间段内发送了过多 token 或请求,我们的服务已暂时阻止你继续发送。
+一个 `RateLimitError` 表示你已触及分配的速率限制。这意味着你在给定时间段内发送了过多令牌或请求,我们的服务已暂时阻止你继续发送。
-我们设置速率上限是为了确保资源使用的公平与高效,并防止服务被滥用或过载。
+我们设置速率限制是为了确保资源被公平、高效地使用,并防止服务被滥用或过载。
-如果遇到此错误 `RateLimitError`,请尝试以下步骤:
+如果遇到 `RateLimitError`,请尝试以下步骤:
-- 减少发送的令牌或请求,或降低请求速度。你可能需要降低请求的频率或数量,对令牌进行批处理,或在重试时使用指数退避,当 `Retry-After` 不存在时。你可以阅读我们的 [速率限制指南](https://developers.openai.com/api/docs/guides/rate-limits) 了解更多信息。
-- 当 `Retry-After` 存在时,请在重试前至少等待其指定的时间。官方 Python 库已经对符合条件的重试遵守了该响应头。
-- 你也可以在账户仪表板中查看 API 使用情况统计。
+- 减少发送的令牌或请求数量,或降低请求速度。你可以降低请求的频率或数量、将令牌分批发送,或者在重试时使用指数退避。 `Retry-After` 不存在时,你可以阅读我们的 [速率限制指南](https://developers.openai.com/api/docs/guides/rate-limits) 了解更多详情。
+- 当 `Retry-After` 存在时,至少等待其指定的时间后再重试。官方 Python 库已对符合条件的重试遵守此响应头。
+- 你也可以在账户仪表板中查看你的 API 使用统计信息。
-### 持久性错误
+### 持续性错误
如果问题仍然存在, [通过聊天联系我们的支持团队](https://help.openai.com/en/) 并向他们提供以下信息:
- 你正在使用的模型
-- 你收到的错误信息和错误代码
+- 你收到的错误消息和错误代码
- 你发送的请求数据和请求头
- 你请求的时间戳和时区
-- 任何其他可能有助于我们诊断问题的相关细节
+- 任何其他有助于我们排查问题的相关细节
-我们的支持团队将调查该问题并尽快回复你。由于需求量大,我们的支持队列等待时间可能较长。你也可以 [在我们的社区论坛中发帖](https://community.openai.com) ,但请务必省略任何敏感信息。
+我们的支持团队将调查该问题并尽快回复你。由于需求量较大,我们的支持队列等待时间可能会比较长。你也可以 [在我们的社区论坛中发帖](https://community.openai.com) ,但请务必省略任何敏感信息。
### 处理错误
-建议你通过编程方式处理 API 返回的错误。为此,你可以参考如下代码片段:
+建议你以编程方式处理 API 返回的错误。为此,你可以参考如下代码片段:
```javascript
import OpenAI from "openai";
diff --git a/docs/zh/api/docs/guides/fast-mode.md b/docs/zh/api/docs/guides/fast-mode.md
index c74dcde..8bd31d1 100644
--- a/docs/zh/api/docs/guides/fast-mode.md
+++ b/docs/zh/api/docs/guides/fast-mode.md
@@ -1,19 +1,19 @@
# Fast mode
-> 完整文档索引请参阅 [llms.txt](/llms.txt)。可通过在页面 URL 后追加 `.md` 来获取文档页面的 Markdown 版本。
+> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。文档页面的 Markdown 版本可通过在页面 URL 末尾追加 `.md` 获取。
-Fast 模式可提供最高 2.5 倍的更快速度以及更稳定的延迟,同时保持按需付费的灵活性。Fast 模式非常适合对延迟有严格要求、流量稳定且面向用户的高价值应用。
+Fast 模式可提速高达 2.5 倍,并能保持更稳定的延迟,同时保留按量付费的灵活性。对于高价值、面向用户且流量稳定、对延迟要求极高的应用,Fast 模式是理想之选。
-Priority processing 已于 2026-07-30 更名为 Fast 模式。我们还提升了
- Fast 模式的运行速度,使其相比 `gpt-5.6-sol` 最高可达 2.5 倍
- 快于 Standard 处理。你可以在请求中使用以下任一参数 `service_tier: "priority"`
- 或 `service_tier: "fast"` 来访问该功能:API 请求。
+Priority 处理已于 2026 年 7 月 30 日更名为 Fast 模式。我们还提升了
+ Fast 模式的运行速度,达到 `gpt-5.6-sol` 最高 2.5 倍
+ 比 Standard 处理速度更快。你可以使用以下任一方式 `service_tier: "priority"`
+ 或 `service_tier: "fast"` 在你的 API 请求中使用,以访问此功能。
## 配置 Fast 模式
-你可以通过请求参数或项目设置,将对 Responses API 或 Chat Completions API 发起的请求配置为使用 Fast 模式。
+你可以通过请求参数或项目设置,将发往 Responses API 或 Chat Completions API 的请求配置为使用 Fast 模式。
-若要为单个请求启用 Fast 模式,请设置 [`service_tier` 参数](https://platform.openai.com/docs/api-reference/responses/create#responses-create-service_tier) 为 `fast`。在项目设置中将 `service_tier` 为 `priority` 可为支持的模型提供相同的行为。
+要为单个请求启用 Fast 模式,请设置 [`service_tier` 参数](https://platform.openai.com/docs/api-reference/responses/create#responses-create-service_tier) 为 `fast`。设置 `service_tier` 为 `priority` 可为支持的模型提供相同的行为。
使用 Fast 模式创建响应
@@ -114,66 +114,66 @@ curl https://api.openai.com/v1/responses \
```
-若要在项目级别启用,请打开 **设置**,选择 **通用** 下的 **项目**,并将 **项目服务层级** 为 **Fast**。未指定 `service_tier` 的请求将默认使用 Fast 模式。该项目的请求将随时间逐步迁移到 Fast 模式。
+要在项目级别启用,请打开 **Settings**,在 **General** 下选择 **Project**,并将 **Project Service Tier** 为 **Fast**。未指定 `service_tier` 的请求随后将默认为 Fast 模式。该项目的请求会随时间逐步切换到 Fast 模式。
-该 `service_tier` 字段在 [Responses](https://platform.openai.com/docs/api-reference/responses/object#responses/object-service_tier) 或 [Chat Completions](https://platform.openai.com/docs/api-reference/chat/object#chat/object-service_tier) response 对象标识了用于处理请求的层级。对于 GPT-5.6 及更早的模型,response 返回 `priority` 请求是否指定 `priority` 或 `fast`.
+该 `service_tier` 字段(在 [Responses](https://platform.openai.com/docs/api-reference/responses/object#responses/object-service_tier) 或 [Chat Completions](https://platform.openai.com/docs/api-reference/chat/object#chat/object-service_tier) response 对象用于标识处理请求所使用的层级。对于 GPT-5.6 及更早的模型,响应会返回 `priority` 请求是否指定了 `priority` 或 `fast`.
-## 速率限制与爬升速率
+## 速率限制与速率爬升
-**基线限制**
+**基线限额**
-快速模式的消耗计入速率限制的方式与标准处理相同。使用你通常的重试逻辑,并在两次尝试之间稍作等待。对于同一模型,标准处理与快速模式共享同一速率限制。
+Fast 模式的消耗计入速率限额的方式与 Standard 处理相同。使用你通常的重试逻辑并在两次尝试之间等待。对于给定的模型,Standard 处理和 Fast 模式共享相同的速率限额。
-**爬坡速率限制**
+**速率增幅限制**
-如果你的流量增长过快,系统可能会将部分快速模式请求降级为标准速度并按标准费率计费。发生这种情况时,响应中会包含 `service_tier: "default"`。如果你每分钟发送至少 100 万个 token(TPM),并在 15 分钟内将 TPM 提升超过 50%,则可能触发爬坡速率限制。
+如果你的流量增速过快,系统可能会将部分 Fast 模式请求降级为标准速度并按标准费率计费。发生这种情况时,响应中会包含 `service_tier: "default"`。一般来说,当你的流量达到每分钟 100 万个输入 token(TPM)时,每 15 分钟的增加幅度不应超过 50%。速率增幅限制的具体触发点可能因模型和流量状况而异。
-为避免触发爬坡速率限制:
+为避免触发速率增幅限制:
-- 在更换模型或快照时逐步增加流量。
-- 使用功能开关在数小时内逐步迁移流量,而不是瞬时切换。
-- 避免在 Fast 模式下运行大规模的抽取、转换和加载 (ETL) 或批处理任务。
+- 更换模型或快照时逐步提升流量。
+- 使用特性开关在数小时内迁移流量,而非瞬时切换。
+- 避免在 Fast 模式下运行大规模的抽取、转换和加载 (ETL) 或批处理作业。
## 使用注意事项
-- Fast 模式按 token 在 Standard 处理基础上收取额外费用。详见 [定价页面](https://developers.openai.com/api/docs/pricing?latest-pricing=fast) 了解详情及支持的模型。
-- 缓存输入折扣仍适用于 Fast 模式请求。
+- Fast 模式在按 token 计费上比 Standard 处理收取溢价。详见 [定价页面](https://developers.openai.com/api/docs/pricing?latest-pricing=fast) 了解详情和支持的模型。
+- 缓存输入折扣仍然适用于 Fast 模式请求。
- Fast 模式支持多模态请求,包括图像输入。
-- 要在用量面板中查看 Fast 模式请求,请选择按服务层级分组。对于 GPT-5.6 及更早的模型,这些请求会显示为 `priority` ,即使你指定了 `fast`.
-- GPT-5.6 模型支持长上下文。Fast 模式不支持微调模型或嵌入。
+- 要在用量面板中查看 Fast 模式请求,请选择按服务层级分组。对于 GPT-5.6 及更早的模型,这些请求会显示为 `priority` 即使你指定了 `fast`.
+- GPT-5.6 模型支持长上下文。Fast 模式不支持微调模型或嵌入模型。
-## 常见问题解答
+## 常见问题
-有关账户和政策信息,请参阅 [快速模式常见问题解答](https://help.openai.com/en/articles/11647665-priority-processing-faq).
+有关账户和政策信息,请参阅 [Fast mode FAQ](https://help.openai.com/en/articles/11647665-priority-processing-faq).
### 快速模式在所有地区都可用吗?
可用性取决于各司法管辖区的法律法规。如果你对所在地区的可用性有疑问,请联系你的客户总监。
-### Fast 模式如何与 Scale Tier 交互?
+### 快速模式如何与规模层级交互?
-Scale Tier 和 Fast 模式是分开的。Fast 模式请求单独计费,不计入已购买的 Scale Tier TPM 套餐。Scale Tier 溢出流量不会自动转入 Fast 模式。
+Scale Tier 与 Fast 模式相互独立。Fast 模式请求单独计费,不计入已购买的 Scale Tier TPM 套餐额度。Scale Tier 的溢出流量不会自动迁移到 Fast 模式。
### Fast 模式如何计费?
-Fast 模式相比 Standard 处理按 token 收取额外费用。所有处理模式都会计入你的年度 Enterprise 消费承诺,符合条件的输入缓存 token 可享受与 Standard 处理相同的折扣。
+Fast 模式相比 Standard 处理按 token 收取溢价。所有处理模式都计入你的年度 Enterprise 消费承诺,符合条件的缓存输入 token 享受与 Standard 处理相同的折扣。
-对于 GPT-5.6 Sol,Fast 模式的价格是相应 Standard 费率的两倍。短上下文请求的输入 token 价格为每 100 万 token 8 美元,输出 token 价格为每 100 万 token 40 美元;长上下文请求的输入 token 价格为每 100 万 token 16 美元,输出 token 价格为每 100 万 token 60 美元。GPT-5.6 Sol 的促销定价至少有效至 2026 年 11 月 21 日。详见 [定价详情](https://developers.openai.com/api/docs/pricing?latest-pricing=fast).
+对于 GPT-5.6 Sol,Fast 模式的费用是相应 Standard 费率的两倍。短上下文请求的输入 token 价格为每百万 8 美元,输出 token 价格为每百万 40 美元;长上下文请求的输入 token 价格为每百万 16 美元,输出 token 价格为每百万 60 美元。GPT-5.6 Sol 的促销定价至少在 2026 年 11 月 21 日之前有效。详见 [定价详情](https://developers.openai.com/api/docs/pricing?latest-pricing=fast).
-要查看用量,请打开用量仪表板,选择 Responses 或 Chat Completions,并按服务层级分组。要查看成本,请按条目分组。
+要查看用量,请打开用量仪表板,选择 Responses 或 Chat Completions,然后按服务层级分组。要查看成本,请按明细科目分组。
-### 哪些模型和模态支持 Fast 模式?
+### 哪些模型和模态支持快速模式?
-Fast 模式支持 Standard 处理所具备的多模态能力,包括图像输入。GPT-5.6 模型支持长上下文。Fast 模式不支持微调模型或 embeddings。未来推出的 GPT 模型可能会支持 Fast 模式,但并非每个模型都能保证获得支持。
+Fast 模式支持 Standard 处理所提供的多模态能力,包括图像输入。GPT-5.6 模型支持长上下文。Fast 模式不支持微调模型或嵌入。未来推出的 GPT 模型可能会支持 Fast 模式,但并不保证每个模型都支持。
-### 增速限制是在项目还是组织之间共享?
+### 速率提升限制是跨项目还是跨组织共享?
-是的,你所有的流量都会计入同一个 ramp rate 限制。如果你经常遇到 ramp rate 限制,可以考虑购买 Scale Tier 配额。
+是的,所有你的流量都会计入同一个 ramp rate 限制。如果经常遇到 ramp rate 限制,可以考虑购买 Scale Tier 配额。
-### 如果 Fast 模式未达到其延迟目标会怎样?
+### 如果 Fast 模式未达到其延迟目标,会发生什么?
-如果你有任何疑问或顾虑,请联系你的客户总监。Fast 模式和 Scale Tier 享有同等的服务级别协议待遇,当未达成相应目标时,符合条件的企业协议可能会提供服务积分。
+如果你有任何问题或疑虑,请联系你的客户总监。Fast 模式和 Scale Tier 享有相同的服务等级协议(SLA)待遇,当未达成相应目标时,符合条件的 Enterprise 协议可提供服务积分。
-### Fast 模式是否与数据驻留、零数据保留(Zero Data Retention)和 BAA 兼容?
+### Fast 模式是否与数据驻留、零数据保留和 BAA 兼容?
-是的。Fast 模式兼容数据驻留、零数据留存(Zero Data Retention)以及业务伙伴协议(BAA)。现有的端点、工具、资格和合同要求仍然适用。请参阅 [数据指南](https://developers.openai.com/api/docs/guides/your-data) 了解详情。
\ No newline at end of file
+是的。Fast 模式与数据驻留、零数据保留 (Zero Data Retention) 以及业务合作协议 (BAA) 兼容。现有的 endpoint、工具、资格和合同要求仍然适用。请参阅 [数据指南](https://developers.openai.com/api/docs/guides/your-data) 了解详情。
\ No newline at end of file
diff --git a/docs/zh/api/docs/guides/function-calling.md b/docs/zh/api/docs/guides/function-calling.md
index e560a2e..c3d57fc 100644
--- a/docs/zh/api/docs/guides/function-calling.md
+++ b/docs/zh/api/docs/guides/function-calling.md
@@ -1,32 +1,32 @@
# Function calling
-> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。可通过在页面 URL 后追加 `.md` 来获取文档页面的 Markdown 版本。
+> 完整的文档索引请参阅 [llms.txt](/llms.txt)。文档页面的 Markdown 版本可通过在页面 URL 后追加 `.md` 获取。
-**Function calling** (也称为 **tool calling**)为 OpenAI 模型与外部系统对接、访问训练数据之外的数据提供了一种强大而灵活的方式。本指南将介绍如何将模型连接到由你的应用提供的数据与操作。我们将展示如何使用函数工具(由 JSON schema 定义)以及支持自由文本输入与输出的自定义工具。
+**函数调用** (也称为 **工具调用**)为 OpenAI 模型提供了一种强大且灵活的方式来与外部系统对接,并访问其训练数据之外的数据。本指南介绍如何将模型连接到你的应用程序所提供的数据和操作。我们将展示如何使用函数工具(由 JSON schema 定义)以及支持自由文本输入和输出的自定义工具。
-如果你的应用包含大量函数或庞大的 schema,可以将 function calling 与 [tool search](https://developers.openai.com/api/docs/guides/tools-tool-search) 结合使用,以延迟加载很少使用的工具,仅在模型需要时才加载它们。仅 `gpt-5.4` 及更高版本的模型支持 `tool_search`.
+如果你的应用程序拥有许多函数或庞大的 schema,可以将函数调用与 [工具搜索](https://developers.openai.com/api/docs/guides/tools-tool-search) 搭配使用,以延迟加载不常用的工具,仅在模型需要时再加载它们。仅 `gpt-5.4` 及更高版本的模型支持 `tool_search`.
## 工作原理
-我们先来了解几个关于工具调用的关键术语。在对工具调用形成统一的词汇之后,我们将通过一些实际示例向你展示其实现方式。
+我们先了解几个关于工具调用的关键术语。在对工具调用建立共同词汇后,我们将通过一些实际示例演示如何操作。
-### 工具 - 我们提供给模型的功能
+### 工具 - 我们赋予模型的功能
-一个 **function** 或 **tool** 在抽象意义上指的是我们告诉模型它可以使用的某项功能。当模型为某个提示生成响应时,它可能会判定需要使用 tool 所提供的数据或功能来完成该提示的指令。
+一个 **function** 或 **工具** 在抽象意义上表示我们让模型知道它可以访问的一项功能。当模型为提示生成响应时,它可能会判断需要工具提供的数据或功能才能遵循提示中的指令。
-你可以向模型提供以下工具:
+你可以让模型访问以下工具:
-- 获取指定位置的今日天气
-- 根据用户 ID 访问账户详情
+- 获取某个位置的当日天气
+- 访问指定用户 ID 的账户详细信息
- 为丢失的订单发起退款
-或者任何你希望模型在响应提示时能够了解或执行的其他内容。
+或者任何你希望模型在响应提示时能够知道或执行的其他内容。
-当我们使用提示向模型发起 API 请求时,可以包含模型可以考虑使用的工具列表。例如,如果我们希望模型能够回答世界上某个地方的当前天气问题,我们可能会为它提供 `get_weather` tool that takes `location` 作为参数。
+当我们向模型发出一个 API 请求并附带提示时,可以包含一个模型可以考虑使用的工具列表。例如,如果我们希望模型能够回答世界上某个地方的当前天气问题,我们可能会为其提供一个 `get_weather` 接受 `location` 作为参数的工具。
@@ -34,13 +34,13 @@
-### 工具调用 - 模型发出的使用工具的请求
+### 工具调用 - 模型使用工具的请求
-一个 **function call** 或 **tool call** 指的是模型在检查提示后,如果我们希望它遵循提示中的指令,就可以从模型获得的一种特殊响应,它会判断需要调用我们为其提供的某个工具。
+一个 **function call** 或 **工具调用** 指的是模型在检查提示词后,如果认为需要调用我们提供给它的某个工具才能遵循提示词中的指令,所返回的一种特殊响应。
-如果模型在 API 请求中收到类似“巴黎的天气怎么样?”这样的提示,它可能会针对该提示以对 `get_weather` 工具的 tool call 进行响应,并将 `Paris` 作为 `location` 参数。
+如果模型在一次 API 请求中收到类似“巴黎的天气怎么样?”这样的提示词,它可以针对该提示词返回一个针对 `get_weather` 工具的调用, `Paris` 并以 `location` 作为参数。
@@ -52,14 +52,14 @@
-一个 **function call output** 或 **tool call output** 指工具使用模型工具调用的输入所生成的响应。工具调用输出可以是结构化的 JSON 或纯文本,并且应包含对特定模型工具调用的引用(在接下来的示例中通过 `call_id` 引用)。
-为了完成我们的天气示例:
+一个 **function call output** 或 **工具调用输出** 指工具使用模型工具调用的输入所生成的响应。工具调用输出可以是结构化 JSON 或纯文本,并且应包含对特定模型工具调用的引用(在后文中通过 `call_id` 引用)。
+为完成我们的天气示例:
-- 模型可访问一个 `get_weather` **工具** ,它接受 `location` 作为参数。
-- 对于像 "what's the weather in Paris?" 这样的提示,模型会返回一个 **工具调用** ,其中包含一个值为 `location` 的参数 `Paris`
-- 该 **工具调用输出** 可能会返回一个 JSON 对象(例如。, `{"temperature": "25", "unit": "C"}`,表示当前温度为 25 度), [图像内容](https://developers.openai.com/api/docs/guides/images-vision),或 [文件内容](https://developers.openai.com/api/docs/guides/file-inputs).
+- 该模型可以访问一个 `get_weather` **tool** ,它接受 `location` 作为参数。
+- 当收到诸如 "what's the weather in Paris?" 这样的提示时,模型会返回一个 **tool call** ,其中包含一个 `location` 参数,参数值为 `Paris`
+- 该 **tool call output** 可能会返回一个 JSON 对象(例如, `{"temperature": "25", "unit": "C"}`,表示当前温度为 25 度), [Image contents](https://developers.openai.com/api/docs/guides/images-vision),或 [File contents](https://developers.openai.com/api/docs/guides/file-inputs).
-随后,我们将所有工具定义、原始提示、模型的工具调用以及工具调用输出一起发送回模型,最终获得类似下面的文本响应:
+然后,我们将所有工具定义、原始提示、模型的工具调用以及工具调用输出一起发回模型,最终收到类似下面的文本响应:
```
The weather in Paris today is 25C.
@@ -75,9 +75,9 @@ The weather in Paris today is 25C.
-- 函数是一种通过 JSON schema 定义的特定类型的工具。函数定义允许模型将数据传递给应用程序,你的代码可以在其中访问数据或执行模型建议的操作。
-- 除了函数工具之外,还有自定义工具(在本指南中介绍),它们支持自由文本输入和输出。
-- 还有 [内置工具](https://developers.openai.com/api/docs/guides/tools) 是 OpenAI 平台的一部分。这些工具使模型能够 [搜索网页](https://developers.openai.com/api/docs/guides/tools-web-search), [执行代码](https://developers.openai.com/api/docs/guides/tools-code-interpreter),访问 [MCP 服务器](https://developers.openai.com/api/docs/guides/tools-connectors-mcp),等功能。
+- 函数是一种特殊的工具,由 JSON schema 定义。函数定义允许模型将数据传递给应用程序,由你的代码访问数据或执行模型建议的操作。
+- 除了函数工具之外,还有自定义工具(在本指南中介绍),它们可处理自由文本输入和输出。
+- 还有 [内置工具](https://developers.openai.com/api/docs/guides/tools) 是 OpenAI 平台的一部分。这些工具使模型能够 [搜索网页](https://developers.openai.com/api/docs/guides/tools-web-search), [执行代码](https://developers.openai.com/api/docs/guides/tools-code-interpreter)、访问 [MCP 服务器](https://developers.openai.com/api/docs/guides/tools-connectors-mcp),的功能,等等。
@@ -85,21 +85,21 @@ The weather in Paris today is 25C.
### 工具调用流程
-工具调用是你的应用与模型之间通过 OpenAI API 进行的多轮对话。工具调用流程包含五个高层步骤:
+工具调用是你的应用程序与模型之间通过 OpenAI API 进行的多步对话。工具调用流程包含五个高层步骤:
-1. 使用模型可能调用的工具发起请求
-1. 接收来自模型的工具调用
-1. 使用工具调用的输入在应用端执行代码
-1. 使用工具输出向模型发起第二次请求
-1. 接收来自模型的最终响应(或更多工具调用)
+1. 向模型发起请求,附带上模型可以调用的工具
+1. 接收模型返回的工具调用
+1. 在应用端使用工具调用的输入执行代码
+1. 将工具输出附加进请求,再次向模型发起请求
+1. 从模型接收最终响应(或更多工具调用)

-使用 Responses,你的应用可以根据任务需要,对该流程中任意次数的工具调用进行延续。如果你想要一个能够围绕该循环封装可复用编排的框架,请参阅 [Responses API 与 Agents SDK 的比较](https://developers.openai.com/api/docs/guides/agents#agents-sdk-vs-responses-api).
+使用 Responses,你的应用可以按照任务需求对这个流程执行任意轮次的工具调用。如果你想要一个围绕该循环封装可复用编排逻辑的框架,请参阅 [Responses API 与 Agents SDK 的对比](https://developers.openai.com/api/docs/guides/agents#agents-sdk-vs-responses-api).
## 函数工具示例
-让我们看一个用于的端到端工具调用流程 `get_horoscope` 获取某个星座每日运势的函数。
+让我们看一个完整的工具调用流程,针对一个 `get_horoscope` 为某个星座获取每日运势的函数。
@@ -298,7 +298,8 @@ func main() {
if err := json.Unmarshal([]byte(call.Arguments), &arguments); err != nil {
panic(err)
}
- functionOutput = responses.ResponseInputItemParamOfFunctionCallOutput(call.CallID, getHoroscope(arguments.Sign))
+ functionOutput = responses.ResponseInputItemParamOfFunctionCallOutput(getHoroscope(arguments.Sign))
+ functionOutput.OfFunctionCallOutput.CallID = openai.String(call.CallID)
}
if functionOutput.OfFunctionCallOutput == nil {
panic("the model did not call get_horoscope")
@@ -459,23 +460,23 @@ puts(response.output_text)
-请注意,对于像 GPT-5 或 o4-mini 这样的推理模型,模型响应中与工具调用一起返回的任何推理项
- 也必须与工具
- 调用输出一起传回。
+请注意,对于像 GPT-5 或 o4-mini 这样的推理模型,任何推理项
+ 在模型包含工具调用的响应中返回的内容,也必须与工具
+ 调用的输出一起传回。
## 定义函数
-函数通常在每个 `tools` 的 tools 参数中声明API 请求。借助 [tool search](https://developers.openai.com/api/docs/guides/tools-tool-search),你的应用还可以在交互的后续阶段延迟加载函数。无论采用哪种方式,每个可调用的函数都使用相同的 schema 结构。函数定义包含以下属性:
+函数通常在每次请求的 `tools` 每个 API 请求的参数。例如: [工具搜索](https://developers.openai.com/api/docs/guides/tools-tool-search),你的应用也可以在交互过程中稍后加载延迟函数。无论采用哪种方式,每个可调用的函数都使用相同的 schema 结构。函数定义具有以下属性:
| 字段 | 描述 |
| ------------- | ------------------------------------------------------------------------------- |
-| `type` | 此字段应始终为 `function` |
-| `name` | 函数名称(例如 `get_weather`) |
+| `type` | 应始终为 `function` |
+| `name` | 函数的名称(例如 `get_weather`) |
| `description` | 关于何时以及如何使用该函数的详细信息 |
-| `parameters` | [JSON schema](https://json-schema.org/) ,用于定义函数的输入参数 |
-| `strict` | 是否对该函数调用强制启用严格模式 |
+| `parameters` | [JSON 架构](https://json-schema.org/) 定义函数的输入参数 |
+| `strict` | 是否对该函数调用强制使用严格模式 |
-下面是一个函数定义的示例 `get_weather` function
+下面是一个函数的示例定义, `get_weather` function
```json
{
@@ -502,11 +503,11 @@ puts(response.output_text)
}
```
-因为 `parameters` 由一个 [JSON schema](https://json-schema.org/),定义,你可以利用它的许多丰富特性,例如属性类型、枚举、描述、嵌套对象以及递归对象。
+因为 `parameters` 由一个 [JSON schema](https://json-schema.org/),你可以利用它的许多丰富特性,例如属性类型、枚举、描述、嵌套对象以及递归对象。
## 定义命名空间
-使用命名空间按领域对相关工具进行分组,例如 `crm`, `billing`,或者 `shipping`。命名空间有助于组织类似的工具,在模型必须在为不同系统或用途服务的工具之间进行选择时尤其有用,例如一个用于 CRM 的搜索工具和另一个用于支持工单系统的搜索工具。
+使用命名空间按领域对相关工具进行分组,例如 `crm`, `billing`,或 `shipping`。命名空间有助于组织类似的工具,当模型必须在服务于不同系统或用途的工具之间进行选择时尤为有用,例如一个用于你的 CRM 的搜索工具和另一个用于你的支持工单系统的搜索工具。
```json
{
@@ -547,41 +548,41 @@ puts(response.output_text)
## Tool search
-如果需要让模型能够使用庞大的工具生态系统,你可以使用 `tool_search`。延迟加载其中部分或全部工具。 `tool_search` 该工具可让模型搜索相关工具,将其添加到模型上下文中,然后使用这些工具。只有 `gpt-5.4` 及更高版本的模型支持此功能。请阅读 [工具搜索指南](https://developers.openai.com/api/docs/guides/tools-tool-search) 了解更多信息。
+如果你需要让模型访问大量的工具生态,可以延迟加载其中部分或全部工具,使用 `tool_search`。即可。该 `tool_search` 工具可让模型搜索相关工具,将其加入模型上下文,然后使用它们。仅 `gpt-5.4` 及更高版本的模型支持该功能。阅读 [工具搜索指南](https://developers.openai.com/api/docs/guides/tools-tool-search) 以了解更多信息。
### 定义函数的最佳实践
-1. **编写清晰且详细的函数名称、参数说明和指令。**
- - **明确描述函数用途和每个参数** (及其格式),以及输出所表示的内容。
- - **使用系统提示来描述何时(以及何时不应)使用每个函数。** 通常,应向模型明确说明 _究竟_ 该做什么。
- - **加入示例和边界情况,**,尤其应借此纠正反复出现的故障。(**注意:** 添加示例可能会影响 [推理模型](https://developers.openai.com/api/docs/guides/reasoning).)
- - **对于延迟加载工具,请在函数描述中提供详细指南,并保持命名空间描述简洁。** 命名空间帮助模型选择要加载的内容;函数描述则帮助模型正确使用已加载的工具。
+1. **编写清晰且详尽的函数名称、参数说明和调用指引。**
+ - **明确描述函数用途以及每个参数** (及其格式),以及输出所表示的内容。
+ - **通过系统提示词说明何时(以及何时不应)使用各个函数。** 通常,应明确告知模型 _究竟_ 该做什么。
+ - **包含示例和边界情况**,尤其是用来纠正反复出现的失败。(**注意:** 为 [推理模型](https://developers.openai.com/api/docs/guides/reasoning).)
+ - **对于延迟加载的工具,将详细指引放在函数描述中,并保持命名空间描述简洁。** 命名空间帮助模型决定加载什么;函数描述帮助模型正确使用已加载的工具。
-1. **应用软件工程最佳实践。**
- - **确保函数易于理解和使用,符合**. ([最小惊讶原则](https://en.wikipedia.org/wiki/Principle_of_least_astonishment))
- - **使用枚举** 和对象结构,使无效状态无法表示。(例如, `toggle_light(on: bool, off: bool)` 允许无效调用)
- - **通过实习生测试。** 一名实习生 / 人类在不借助任何额外信息、只凭你提供给模型的资料时,能否正确使用该函数?(如果不能,他们会向你提出哪些问题?把答案补充到提示词里。)
+1. **遵循软件工程最佳实践。**
+ - **让函数清晰直观,遵循**. ([最少意外原则](https://en.wikipedia.org/wiki/Principle_of_least_astonishment))
+ - **使用枚举** 和对象结构使无效状态不可表示。(例如。 `toggle_light(on: bool, off: bool)` 允许无效调用)
+ - **通过实习生测试。** 一名实习生/人类仅凭你给模型的内容,能否正确使用该函数?(如果不能,他们会问你哪些问题?把答案补充到提示中。)
-1. **在可能的情况下,把负担从模型转移到代码上。**
- - **不要让模型填写你已经知道的参数。** 例如,如果你已经基于前一个菜单得到一个 `order_id` ,就不要让模型再提供一个 `order_id` 参数 —— 改为不设参数, `submit_refund()` 而通过代码传入 `order_id` 。
- - **合并那些总是按顺序调用的函数。** 例如,如果你总是在 `mark_location()` 之后调用 `query_location()`,那就直接把标记逻辑合并到查询函数调用里。
+1. **在可能的情况下,把负担从模型转移到代码中。**
+ - **不要让模型填写你已经知道的参数。** 例如,如果你已经根据前一个菜单得到了一个 `order_id` ,就不要设置 `order_id` 参数 —— 改为不设参数 `submit_refund()` ,用代码传入 `order_id` 。
+ - **合并那些总是被依次调用的函数。** 例如,如果你总是在 `mark_location()` 之后调用 `query_location()`,直接把标记逻辑移进查询函数调用里即可。
-1. **为获得更高的准确率,初始可用的函数数量要尽量少。**
- - **用不同数量的函数评估你的表现。** 测试不同函数数量下的效果。
- - **目标是单次对话开始时可用的函数少于 20 个,** 不过这只是一个软性建议。
- - **使用工具搜索** 来延后加载工具集中较大或不常用的部分,而不是一次性全部暴露出来。
+1. **为获得更高的准确率,保持初始可用函数的数量较少。**
+ - **用不同数量的函数评估你的性能** 。
+ - **目标是每个轮次开始时可用的函数少于 20 个** ,不过这只是一个软性建议。
+ - **使用工具搜索** 来推迟较大或不常用的工具面,而不是一次性全部暴露出来。
1. **利用 OpenAI 资源。**
- - **生成并迭代函数模式** 在 [Playground](https://platform.openai.com/playground).
+ - **生成并迭代函数架构** 在 [Playground](https://platform.openai.com/playground).
- **考虑 [微调](https://developers.openai.com/api/docs/guides/model-optimization) 以提高函数调用准确性** ,适用于大量函数或困难任务。([cookbook](https://developers.openai.com/cookbook/examples/fine_tuning_for_function_calling))
-### Token 使用情况
+### Token 使用量
-在底层,函数会以模型训练时所用的语法注入到系统消息中。这意味着可调用的函数定义会计入模型的上下文限制,并按输入 token 计费。如果你遇到 token 限制,建议限制预先加载的函数数量,尽可能缩短描述,或使用 [tool search](https://developers.openai.com/api/docs/guides/tools-tool-search) 以便按需延迟加载工具。
+在底层,函数会以模型训练时使用的语法被注入系统消息中。这意味着可调用的函数定义会占用模型的上下文长度,并按输入 token 计费。如果你遇到 token 上限问题,建议限制一次性加载的函数数量、尽可能缩短描述,或者使用 [工具搜索](https://developers.openai.com/api/docs/guides/tools-tool-search) 以便延迟加载的工具仅在需要时才被加载。
-也可以使用 [微调](https://developers.openai.com/api/docs/guides/model-optimization#fine-tuning-examples) 来减少使用的 token 数量,前提是你的工具规范中定义了较多的函数。
+也可以使用 [微调](https://developers.openai.com/api/docs/guides/model-optimization#fine-tuning-examples) 如果你的工具规范中定义了许多函数,则可以使用它来减少所使用的 token 数量。
## 处理函数调用
@@ -589,7 +590,7 @@ puts(response.output_text)
-响应 `output` 数组包含一个条目,其中 `type` 的值为 `function_call`。每个带有 `call_id` (稍后用于提交函数结果), `name`,以及 JSON 编码的 `arguments`.
+响应 `output` 数组包含一个条目,其 `type` 的值为 `function_call`。每个包含 `call_id` (稍后用于提交函数结果)、 `name`,以及 JSON 编码的 `arguments`.
包含多个函数调用的示例响应
@@ -620,7 +621,7 @@ puts(response.output_text)
```
-如果使用 [tool search](https://developers.openai.com/api/docs/guides/tools-tool-search),你还可能会看到 `tool_search_call` 和 `tool_search_output` 条目位于 `function_call`。之前。一旦函数被加载,以与此页相同的方式处理函数调用。
+如果你使用的是 [工具搜索](https://developers.openai.com/api/docs/guides/tools-tool-search),你还可能会看到 `tool_search_call` 和 `tool_search_output` 条目出现在 `function_call`。之前。函数加载完成后,按照此处所示的相同方式处理函数调用。
执行函数调用并追加结果
@@ -680,7 +681,9 @@ for _, output := range response.Output {
if err != nil {
panic(err)
}
- input = append(input, responses.ResponseInputItemParamOfFunctionCallOutput(toolCall.CallID, result))
+ toolOutput := responses.ResponseInputItemParamOfFunctionCallOutput(result)
+ toolOutput.OfFunctionCallOutput.CallID = openai.String(toolCall.CallID)
+ input = append(input, toolOutput)
}
```
@@ -753,7 +756,7 @@ end
-在上面的示例中,我们有一个假设的 `call_function` 来路由每个调用。以下是一种可能的实现:
+在上面的示例中,我们有一个假设性的 `call_function` 来路由每个调用。以下是一个可能的实现:
执行函数调用并追加结果
@@ -813,17 +816,17 @@ end
### 格式化结果
-你在 `function_call_output` 消息中传入的结果通常应为一个字符串,格式由你决定(JSON、错误码、纯文本等)。模型会按需解析该字符串。
+你在 `function_call_output` message 中传入的结果通常应为一个字符串,具体格式由你自行决定(例如 JSON、错误码、纯文本等)。模型会按需解释该字符串。
-对于返回图像或文件的函数,你可以传入 [图像或文件对象数组](https://developers.openai.com/api/reference/resources/responses/methods/create#responses_create-input-input_item_list-item-function_tool_call_output-output) 来代替字符串。
+对于返回图片或文件的函数,你可以传入一个 [由图片或文件对象组成的数组](https://developers.openai.com/api/reference/resources/responses/methods/create#responses_create-input-input_item_list-item-function_tool_call_output-output) ,而不是字符串。
-如果你的函数没有返回值(例如。 `send_email`),只需返回一个字符串来表示成功或失败(例如。 `"success"`)
+如果你的函数没有返回值(例如。 `send_email`),只需返回一个表示成功或失败的字符串(例如。 `"success"`)
-### 将结果纳入响应
+### 将结果整合到响应中
-在将结果附加到你的 `input`,之后,你可以将它们发送回模型以获得最终响应。
+将结果追加到你的 `input`,之后,你可以将它们发送回模型以获取最终响应。
将结果发送回模型
@@ -966,20 +969,20 @@ puts(response.output_text)
### 工具选择
-默认情况下,模型会确定使用工具的时机和数量。你可以使用以下参数强制指定特定行为: `tool_choice` 参数。
+默认情况下,模型会决定何时使用工具以及使用多少个工具。你可以通过以下参数强制指定特定行为: `tool_choice` 参数。
-1. **Auto:** (_Default_) 调用零个、一个或多个函数。 `tool_choice: "auto"`
-1. **Required:** 调用一个或多个函数。
+1. **自动:** (_默认_) 调用零个、一个或多个函数。 `tool_choice: "auto"`
+1. **必填:** 调用一个或多个函数。
`tool_choice: "required"`
-1. **强制函数:** 仅调用一个特定函数。
+1. **强制函数:** 仅调用一个特定的函数。
`tool_choice: {"type": "function", "name": "get_weather"}`
-1. **允许的工具:** 将模型可以进行的工具调用限制为模型可用工具的子集。
- the tools available to the model.
+1. **允许的工具:** 将模型可以调用的工具限制为
+ 模型可用工具的一个子集。
**何时使用 allowed_tools**
-你可能希望配置一个 `allowed_tools` 列表,以便你只想在模型请求中提供部分工具,但又不修改传入的工具列表,这样就可以最大化利用
-的缓存节省效果。 [提示词缓存](https://developers.openai.com/api/docs/guides/prompt-caching).
+你可能需要在以下情况配置 `allowed_tools` 列表:当你希望只在部分模型请求中提供某些工具,但又不想修改传入的工具列表时,
+这样你可以在不破坏现有工具集合的前提下,仅开放部分工具的访问,同时最大化地利用 [提示缓存](https://developers.openai.com/api/docs/guides/prompt-caching).
```json
"tool_choice": {
@@ -993,48 +996,48 @@ puts(response.output_text)
}
```
-你还可以将 `tool_choice` 设置为 `"none"` ,以模拟不传入任何函数的行为。
+你也可以将 `tool_choice` 设置为 `"none"` 以模拟不传入任何函数时的行为。
-使用工具搜索时, `tool_choice` 仍然作用于当前这一轮中可调用的工具。这在你加载了部分工具并希望将模型约束在该子集内时最为有用。
+当你使用工具搜索时, `tool_choice` 仍然适用于当前回合中可调用的工具。这在你已加载一部分工具并希望将模型限制在该子集内时最为有用。
### 并行函数调用
-在从 GPT-5 开始的支持模型上,当内置工具
- 可用 [内置工具](https://developers.openai.com/api/docs/guides/tools) 时,可以并行调用函数。内
- 置工具不能包含在并行函数调用批次中。
+从 GPT-5 开始的受支持模型中,如果
+ 那么 [内置工具](https://developers.openai.com/api/docs/guides/tools) 也可用,则函数可以并行调用。内置
+ 工具不能包含在并行函数调用批次中。
-模型可能选择在单次轮次中调用多个函数。你可以通过设置 `parallel_tool_calls` 设置为 `false`,来防止这种情况,该参数可确保恰好调用零个或一个工具。
+模型可以选择在单轮中调用多个函数。你可以通过设置 `parallel_tool_calls` 设置为 `false`,来防止这种情况,从而确保恰好调用零个或一个工具。
-**注意:** 目前,如果你使用的是微调模型,并且模型在单次轮次中调用了多个函数,那么 [严格模式](#strict-mode) 将针对这些调用被禁用。
+**注意:** 目前,如果你使用微调模型,并且该模型在单轮中调用多个函数,那么 [严格模式](#strict-mode) 将在这些调用中被禁用。
-**针对的说明 `gpt-4.1-nano-2025-04-14`:** 该 `gpt-4.1-nano` 快照有时会包含同一工具的多个工具调用(如果启用了并行工具调用)。建议在使用此 nano 快照时禁用此功能。
+**注意 `gpt-4.1-nano-2025-04-14`:** 此快照 `gpt-4.1-nano` 有时可能为同一工具包含多个工具调用(如果启用了并行工具调用)。使用此 nano 快照时,建议禁用此功能。
### 严格模式
-设置 `strict` 设置为 `true` 可以确保函数调用可靠地遵循函数模式,而不是仅尽力而为。我们建议始终启用严格模式。
+设置 `strict` 设置为 `true` 可以确保函数调用可靠地遵循函数 schema,而不是仅作为尽力而为的行为。我们建议始终启用严格模式。
-在底层,严格模式通过利用我们的 [结构化输出](https://developers.openai.com/api/docs/guides/structured-outputs) 功能来实现,因此会带来一些要求:
+在底层,严格模式通过利用我们的 [结构化输出](https://developers.openai.com/api/docs/guides/structured-outputs) 功能来实现,因此会引入一些要求:
-1. `additionalProperties` 必须设置为 `false` 用于 中的每个对象 `parameters`.
-1. 中的所有字段 `properties` 必须标记为 `required`.
+1. `additionalProperties` 必须设置为 `false` 用于数组中的每个对象 `parameters`.
+1. 所有字段在 `properties` 必须标记为 `required`.
-你可以通过添加 `null` 将其标记为 `type` 选项(见下方示例)。
+你可以通过添加 `null` 来标记 `type` 为可选字段(参见下面的示例)。
-如果你发送 `strict: true` 并且你的 schema 不满足上述要求,
-请求将被拒绝,并返回有关缺失约束的详细信息。如果
-你省略 `strict`, the default depends on the API,默认值取决于该 接口:Responses 请求会
-在可能的情况下尝试将你的 schema 规范化到 strict 模式;如果无法
-兼容 strict 模式,则回退到非 strict 的尽力而为函数调用。当发生回退时,响应中的
-tool 字段会显示。Chat Completions 请求默认仍然是非 strict 模式。如果要退出
-`strict: false`。Chat Completions 请求默认仍然是非 strict 模式。如果要退出
-Responses 中的 strict 模式并保持非 strict 的尽力而为函数
-调用,请显式设置 `strict: false`.
+如果你发送 `strict: true` 且你的 schema 不满足上述要求,
+请求将被拒绝,并返回有关缺失约束的详细信息。如果你省略
+,默认值取决于API:Responses 请求将 `strict`,尝试在可能的情况下将你的 schema 规范化为严格模式,并在 schema 无法
+与严格模式兼容时回退到非严格的尽力而为式函数调用。当发生回退时,响应中的工具将显示
+。Chat Completions 请求默认仍然保持非严格模式。如果要在 Responses 中选择退出严格模式并保持非严格的尽力而为式函数
+调用,请显式设置
+`strict: false`。
+严格模式已启用
+严格模式已禁用 `strict: false`.
-已启用 strict 模式
+在
```json
{
@@ -1072,7 +1075,7 @@ Responses 中的 strict 模式并保持非 strict 的尽力而为函数
-已禁用 strict 模式
+中生成的所有 schema
```json
{
@@ -1105,27 +1108,27 @@ Responses 中的 strict 模式并保持非 strict 的尽力而为函数
-在
- [playground](https://platform.openai.com/playground) 中生成的所有 schema 都启用了 strict 模式。
+playground
+ [均启用了严格模式。](https://platform.openai.com/playground) 虽然我们建议你启用严格模式,但它有一些限制:
-虽然我们建议你启用 strict 模式,但它存在一些限制:
+虽然我们建议你启用严格模式,但它有一些限制:
-1. 部分 JSON schema 功能不受支持。(详见 [支持的 schema](https://developers.openai.com/api/docs/guides/structured-outputs?context=with_parse#supported-schemas).)
+1. JSON schema 的部分功能不受支持。(参见 [受支持的 schema](https://developers.openai.com/api/docs/guides/structured-outputs?context=with_parse#supported-schemas).)
-特别是针对微调后的模型:
+针对微调模型:
-1. Schema 会在第一次请求时经历额外的处理(之后会被缓存)。如果你的 Schema 在每次请求时都不同,可能会导致更高的延迟。
-2. Schema 会被缓存以提升性能,并且不符合 [零数据保留](https://developers.openai.com/api/docs/models#how-we-use-your-data).
+1. 架构会在首次请求时进行额外处理(之后会缓存结果)。如果你的架构在每次请求之间都不同,可能会导致更高的延迟。
+2. 架构会因性能原因被缓存,并且不符合 [零数据保留](https://developers.openai.com/api/docs/models#how-we-use-your-data).
-## 流式传输
+## Streaming
-你可以借助流式输出来展示调用进度:在模型填充参数时显示它正在调用的函数,甚至可以实时展示参数内容。
+你可以通过流式传输来展示进度,显示模型在填充参数过程中调用了哪个函数,甚至可以实时显示这些参数。
-流式函数调用与流式常规响应非常相似:你设置 `stream` 设置为 `true` 并获取不同的 `event` 对象。
+流式传输函数调用与流式传输常规响应非常相似:你设置 `stream` 设置为 `true` 并获取不同的 `event` 对象。
-流式函数调用
+流式传输函数调用
```javascript
import { OpenAI } from "openai";
@@ -1314,26 +1317,26 @@ stream.each { |event| puts(event.type) }
```
-不过,这里你聚合的不是分块到一个 `content` 字符串,而是将分块聚合到一个已编码的 `arguments` JSON 对象。
+不过,你不是将分块聚合为单个 `content` 字符串,而是将分块聚合为一个已编码的 `arguments` JSON 对象。
-当模型调用一个或多个函数时,会为每次函数调用发出一个类型为 `response.output_item.added` 的事件,其中包含以下字段:
+当模型调用一个或多个函数时,会为每个函数调用发出一个类型为 `response.output_item.added` 的事件,该事件包含以下字段:
| 字段 | 描述 |
| -------------- | ------------------------------------------------------------------------------------------------------------ |
-| `response_id` | 该函数调用所属响应的 id |
-| `output_index` | 响应中输出项的索引。它表示响应中的各个函数调用。 |
-| `item` | 包含的进行中函数调用项 `name`, `arguments` 和 `id` 字段 |
+| `response_id` | 该函数调用所属响应的 ID |
+| `output_index` | 响应中输出项的索引。这表示响应中的各个函数调用。 |
+| `item` | 进行中的函数调用项,其中包含 `name`, `arguments` 和 `id` 字段 |
-之后你将收到一系列类型为 `response.function_call_arguments.delta` 的事件,其中会包含 `delta` 字段的 `arguments` 字段。这些事件包含以下字段:
+之后你将收到一系列类型为 `response.function_call_arguments.delta` 的事件,其中将包含 `delta` 的 `arguments` 字段。这些事件包含以下字段:
| 字段 | 描述 |
| -------------- | ------------------------------------------------------------------------------------------------------------ |
-| `response_id` | 该函数调用所属响应的 id |
-| `item_id` | 该增量所属的函数调用项的 id |
-| `output_index` | 响应中输出项的索引。它表示响应中的各个函数调用。 |
-| `delta` | 字段的增量 `arguments` 字段。 |
+| `response_id` | 该函数调用所属响应的 ID |
+| `item_id` | 该增量所属的函数调用项的 ID |
+| `output_index` | 响应中输出项的索引。这表示响应中的各个函数调用。 |
+| `delta` | 该 `arguments` 字段的增量。 |
-下方代码片段演示了如何将 `delta`聚合为一个最终的 `tool_call` 对象。
+下面是一段代码片段,演示如何将 `delta`汇总为最终的 `tool_call` 对象。
累积 tool_call 增量
@@ -1527,7 +1530,7 @@ puts(final_tool_calls.sort.to_h.values)
```
-累积后的 final_tool_calls[0]
+已累积的 final_tool_calls[0]
```json
{
@@ -1540,21 +1543,21 @@ puts(final_tool_calls.sort.to_h.values)
```
-当模型完成函数调用后,会发出一个类型为 `response.function_call_arguments.done` 的事件。该事件包含完整的函数调用,涵盖以下字段:
+当模型完成函数调用后,将发出类型为 `response.function_call_arguments.done` 的事件。该事件包含完整的函数调用,并带有以下字段:
| 字段 | 描述 |
| -------------- | ------------------------------------------------------------------------------------------------------------ |
-| `response_id` | 该函数调用所属响应的 id |
-| `output_index` | 响应中输出项的索引。它表示响应中的各个函数调用。 |
-| `item` | 包含以下的函数调用项 `name`, `arguments` 和 `id` 字段。 |
+| `response_id` | 该函数调用所属响应的 ID |
+| `output_index` | 响应中输出项的索引。这表示响应中的各个函数调用。 |
+| `item` | 包含一个的函数调用项 `name`, `arguments` 和 `id` 字段的增量。 |
-## Custom tools
+## 自定义工具
-自定义工具的工作方式与 JSON schema 驱动的函数工具大体相同。但你不需要向模型提供关于工具所需输入的显式说明,模型可以将任意字符串作为输入传回给你的工具。这对于避免将响应不必要地包装在 JSON 中,或对响应应用自定义语法非常有用(详见下文)。
+自定义工具的工作方式与由 JSON schema 驱动的函数工具大体相同。但你不需要向模型提供关于工具所需输入的明确指令,模型可以将任意字符串作为输入传回给你的工具。这对于避免不必要地将响应包装在 JSON 中,或对响应应用自定义语法(详见下文)非常有用。
-以下代码示例展示了如何创建一个自定义工具,该工具期望接收一个包含 Python 代码的文本字符串作为响应。
+下面的代码示例展示了如何创建一个自定义工具,该工具期望接收一段包含 Python 代码的文本字符串作为响应。
自定义工具调用示例
@@ -1662,7 +1665,7 @@ puts(response.output)
```
-和之前一样, `output` 数组将包含模型生成的工具调用。只不过这一次,工具调用的输入以纯文本形式给出。
+与之前一样, `output` 数组将包含模型生成的工具调用。只不过这一次,工具调用的输入以纯文本形式给出。
```json
[
@@ -1683,11 +1686,11 @@ puts(response.output)
]
```
-### Context-free grammars
+### 上下文无关文法
-一个 [context-free grammar](https://en.wikipedia.org/wiki/Context-free_grammar) (CFG) 是一组用于定义如何在给定格式中生成有效文本的规则。对于自定义工具,你可以提供一个 CFG,用于约束模型传入自定义工具的文本。
+一个 [context-free grammar](https://en.wikipedia.org/wiki/Context-free_grammar) (CFG)是一组用于定义如何在给定格式中生成有效文本的规则。对于自定义工具,你可以提供一个 CFG 来约束模型为该自定义工具输入的文本。
-你可以使用以下 `grammar` 参数来提供自定义 CFG:在配置自定义工具时使用。目前,我们在定义语法时支持两种 CFG 语法: `lark` 和 `regex`.
+你可以在配置自定义工具时通过 `grammar` 参数提供自定义 CFG。目前,我们在定义语法时支持两种 CFG 语法: `lark` 和 `regex`.
#### Lark CFG
@@ -1870,7 +1873,7 @@ puts(response.output)
```
-工具的输出随后应当符合你所定义的 Lark CFG:
+工具的输出应当符合你所定义的 Lark CFG:
```json
[
@@ -1891,68 +1894,68 @@ puts(response.output)
]
```
-文法使用以下工具的一种变体来指定: [Lark](https://lark-parser.readthedocs.io/en/stable/index.html). 模型采样使用 [LLGuidance](https://github.com/guidance-ai/llguidance/blob/main/docs/syntax.md)。进行约束。Lark 的部分功能不受支持:
+文法通过以下方式的变体来指定 [Lark](https://lark-parser.readthedocs.io/en/stable/index.html)。模型采样通过 [LLGuidance](https://github.com/guidance-ai/llguidance/blob/main/docs/syntax.md)。进行约束。Lark 的部分功能不受支持:
-- 词法分析器正则中的环视
-- 惰性修饰符(`*?`, `+?`, `??`)在词法分析器正则中
+- 词法分析器正则表达式中的环视
+- 惰性修饰符(`*?`, `+?`, `??`)在词法分析器正则表达式中
- 终结符的优先级
- 模板
-- 导入(除内置的 `%import` common 外)
+- 导入(内置 `%import` common 之外)
- `%declare`s
我们建议使用 [Lark IDE](https://www.lark-parser.org/ide/) 来试验自定义语法。
-### 保持语法简洁
+### 保持语法简单
-尽量让语法尽可能简单。如果语法过于复杂,OpenAI API 可能会返回错误,因此在 API 中使用之前,你应该确保所需的语法是兼容的。
+尽量让你的语法尽可能简单。如果语法过于复杂,OpenAI API 可能会返回错误,因此你应该在 API 中使用之前确保你期望的语法是兼容的。
-Lark 语法可能难以做到尽善尽美。简单的语法通常表现最稳定,而复杂的语法往往需要反复迭代语法定义本身、提示词和工具描述,避免模型偏离训练分布。
+Lark 语法要达到完美可能会比较棘手。虽然简单的语法表现最为可靠,但复杂的语法通常需要反复迭代语法定义本身、提示词和工具描述,以确保模型不会偏离分布。
-### 正确与错误的模式
+### 正确与错误模式
-正确(单个、有界的终结符):
+正确(单一、有界的终结符):
```
start: SENTENCE
SENTENCE: /[A-Za-z, ]*(the hero|a dragon|an old man|the princess)[A-Za-z, ]*(fought|saved|found|lost)[A-Za-z, ]*(a treasure|the kingdom|a secret|his way)[A-Za-z, ]*\./
```
-不要这样做(在规则/终结符之间拆分)。这试图让规则在终结符之间划分自由文本。词法分析器会贪婪地匹配自由文本片段,你会失去控制:
+不要这样做(在规则或终结符之间拆分)。这会试图让规则在终结符之间划分自由文本。词法分析器会贪婪地匹配自由文本片段,你会失去控制:
```
start: sentence
sentence: /[A-Za-z, ]+/ subject /[A-Za-z, ]+/ verb /[A-Za-z, ]+/ object /[A-Za-z, ]+/
```
-小写规则不会影响终结符如何从输入中切分——只有终结符定义才会影响。当你需要“锚点之间的自由文本”时,将其定义为一个巨大的正则表达式终结符,这样词法分析器就会按照你预期的结构恰好匹配一次。
+小写规则不会影响终结符如何从输入中切分——只有终结符定义才会。当你需要“锚点之间的自由文本”时,把它做成一个巨大的正则终结符,这样词法分析器就能按你期望的结构精确匹配一次。
### 终端与规则
-Lark 用 terminals 表示词法分析器中的词元(按惯例, `UPPERCASE`),用 rules 表示解析器中的产生式(按惯例, `lowercase`)。保持语法简单且显式,并清晰区分 terminals 和 rules 的职责,是停留在受支持子集内、避免意外的最实用的方法。
+Lark 用终结符表示词法单元(按照约定, `UPPERCASE`),用规则表示语法产生式(按照约定, `lowercase`)。要保持在所支持的子集范围内并避免意外,最实用的方法是让你的语法保持简洁、明确,并清晰地划分终结符与规则的关注点。
-terminals 使用的正则表达式语法是 [Rust regex crate 的语法](https://docs.rs/regex/latest/regex/#syntax),而不是 Python 的 `re` [模块](https://docs.python.org/3/library/re.html).
+终结符使用的正则语法是 [Rust regex crate 语法](https://docs.rs/regex/latest/regex/#syntax),而不是 Python 的 `re` [re 模块](https://docs.python.org/3/library/re.html).
-### 核心要点与最佳实践
+### 核心思路与最佳实践
**词法分析器在解析器之前运行**
-终结符由词法分析器(采用贪婪匹配 / 最长匹配优先)在任何 CFG 规则逻辑之前进行匹配。如果你试图通过把一个终结符拆分成多个规则来“塑形”它,词法分析器无法被这些规则引导——它只能由终结符正则表达式来引导。
+终结符由词法分析器匹配(采用贪心策略/最长匹配优先),然后才会应用任何 CFG 规则逻辑。如果你想通过把终结符拆分到多条规则中来“塑形”它,词法分析器不会受这些规则引导——它只遵循终结符的正则表达式。
-**在从自由形式的片段中切分文本时,优先使用单个终结符**
+**在从自由格式片段中切分文本时,优先使用单个终结符**
-如果需要在任意文本中识别某个嵌入的模式(例如,在锚点之间带有“任意内容”的自然语言),应将其表达为单个终结符。不要试图把自由文本终结符与解析器规则交错在一起;贪婪的词法分析器不会遵循你期望的边界,模型极有可能会超出训练分布。
+如果你需要识别嵌入在任意文本中的模式(例如,自然语言中锚点之间“任意内容”),请将其表达为单个终结符。不要尝试把自由文本终结符与解析器规则交错使用:贪心的词法分析器不会按你设想的边界切分,模型很可能因此超出分布。
-**使用规则来组合离散的 token**
+**使用规则来组合离散 token**
-当你把界限分明的终结符(数字、关键字、标点)组合成更大的结构时,规则是理想的选择。但规则并不适合用来约束两个终结符之间的“中间内容”。
+当你在把清晰界定的终结符(数字、关键字、标点)组合成更大的结构时,规则是理想的工具。但它们不适合用来约束两个终结符“之间的东西”。
**保持终结符简单、有界且自包含**
-优先使用显式的字符类和有界的量词(`{0,10}`,而不是无界的 `*` )。如果需要“任意文本直到句号”,更推荐使用形如 `/[^.\n]{0,10}*\./` 的形式,而不是 `/.+\./` ,以避免失控增长。
+优先使用显式的字符类和有界量词(`{0,10}`,而非无界的 `*` )。如果你需要“任意文本直到句号”,更推荐类似 `/[^.\n]{0,10}*\./` 的形式,而不是 `/.+\./` ,以避免失控增长。
-**使用规则来组合 token,而不是操控正则表达式的内部行为**
+**使用规则来组合 token,而不是引导正则内部实现**
-正确的规则使用示例:
+好的规则使用示例:
```
start: expr
@@ -1963,18 +1966,18 @@ expr: term (("+"|"-") term)*
term: NUMBER
```
-**显式处理空白**
+**显式处理空白字符**
-不要依赖开放式 `%ignore` 指令。使用无界的 ignore 指令可能导致语法过于复杂,以及/或者可能导致模型超出训练分布。建议在允许出现空白的地方显式穿插终结符。
+不要依赖开放式的 `%ignore` 指令。使用无界的 ignore 指令可能导致语法过于复杂和/或导致模型超出分布。在允许出现空白的位置,请优先穿插显式的终结符。
### 故障排除
-- 如果 API 因为语法过于复杂而拒绝,请简化规则和终结符,并移除无界 `%ignore`的部分。
-- 如果自定义工具被传入了意外的 token,请确认终结符没有重叠,并检查贪心词法分析器。
-- 当模型出现“分布外”漂移时(表现为模型生成的输出过长或过度重复,虽然语法有效,但在语义上是错误的):
+- 如果 API 因语法过于复杂而拒绝,请简化规则和终结符,并移除无界的 `%ignore`部分。
+- 如果自定义工具调用时出现了意料之外的 token,请确认终结符没有重叠,并检查贪心词法分析器。
+- 当模型出现“分布外”漂移(表现为模型生成了过长或重复的输出,语法正确但语义有误)时:
- 收紧语法。
- - 迭代优化提示词(添加 few-shot 示例)以及工具描述(解释该语法并指示模型进行推理以遵循它)。
- - 尝试使用更高的推理力度(例如从 medium 提升到 high)。
+ - 迭代优化提示词(添加少样本示例)以及工具描述(解释语法并指示模型进行推理以符合该语法)。
+ - 尝试使用更高的推理力度(例如,从 medium 提升到 high)。
#### Regex CFG
@@ -2115,7 +2118,7 @@ puts(response.output)
```
-工具的输出随后应符合你所定义的 Regex CFG:
+该工具的输出随后应符合你所定义的 Regex CFG:
```json
[
@@ -2136,19 +2139,19 @@ puts(response.output)
]
```
-与 Lark 语法一样,regex 使用 [Rust regex crate 的语法](https://docs.rs/regex/latest/regex/#syntax),而不是 Python 的 `re` [模块](https://docs.python.org/3/library/re.html).
+与 Lark 语法一样,正则表达式使用 [Rust regex crate 语法](https://docs.rs/regex/latest/regex/#syntax),而不是 Python 的 `re` [re 模块](https://docs.python.org/3/library/re.html).
-Regex 的部分功能不受支持:
+Regex 的某些特性不受支持:
-- 环视
-- 惰性修饰符(`*?`, `+?`, `??`)
+- Lookarounds
+- Lazy modifiers (`*?`, `+?`, `??`)
-### 核心要点与最佳实践
+### 核心思路与最佳实践
-**模式必须写在同一行**
+**pattern 必须写在同一行**
-如果需要在输入中匹配换行符,请使用转义序列 `\n`。请勿使用 verbose/extended 模式,该模式允许模式跨多行。
+如果你需要在输入中匹配换行符,请使用转义序列 `\n`。请勿使用 verbose/extended 模式,该模式允许 pattern 跨多行。
-**将正则表达式作为纯模式字符串提供**
+**请将正则表达式作为普通的 pattern 字符串提供**
-不要将模式包裹在 `//`.
\ No newline at end of file
+不要将 pattern 用 `//`.
\ No newline at end of file
diff --git a/docs/zh/api/docs/guides/moderation.md b/docs/zh/api/docs/guides/moderation.md
index 12f0d75..c7b3bf1 100644
--- a/docs/zh/api/docs/guides/moderation.md
+++ b/docs/zh/api/docs/guides/moderation.md
@@ -1,25 +1,25 @@
# 内容审核
-> 完整文档索引请参阅 [llms.txt](/llms.txt)。可通过在页面 URL 末尾添加 `.md` 来获取文档页面的 Markdown 版本。
+> 完整文档索引请参阅 [llms.txt](/llms.txt)。如需获取文档页面的 Markdown 版本,可在页面 URL 末尾追加 `.md` 。
-使用 OpenAI 审核模型来检测文本和图像中的有害内容。你可以使用 [moderation 端点](https://developers.openai.com/api/reference/resources/moderations) 对独立输入进行分类,或在生成响应的同时请求审核评分。利用这些结果执行你的应用程序策略,例如过滤内容、将请求路由以供审核,或对提交被标记内容的账户进行干预。
+使用 OpenAI 审核模型来检测文本和图像中的有害内容。你可以使用以下方式对独立输入进行分类: [审核接口](https://developers.openai.com/api/reference/resources/moderations) ,或在生成回复的同时请求审核评分。使用这些结果来执行你的应用策略,例如过滤内容、将请求路由到审核流程,或对提交被标记内容的账户进行干预。
-该 `omni-moderation-latest` 模型接受文本和图像输入,不对音频进行分类。moderation 端点可免费使用,图像文件最大可达 20 MB。
+该 `omni-moderation-latest` 模型接受文本和图像输入,不对音频进行分类。审核接口可免费使用,图像文件最大为 20 MB。
## 选择审核工作流
-| 工作流 | 适用场景 |
+| 工作流 | 使用场景 |
| --------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ |
-| [审核生成的内容](#moderate-generated-content) | 你的应用使用Responses API 或 Chat Completions API 生成文本,并需要审核信号。 |
-| [对独立输入进行分类](#classify-standalone-inputs) | 你的应用需要在不生成模型响应的情况下对文本或图像进行分类。 |
+| [审核生成的内容](#moderate-generated-content) | 你的应用使用 Responses API 或 Chat Completions API 生成文本,并需要审核信号。 |
+| [对独立输入进行分类](#classify-standalone-inputs) | 你的应用需要对文本或图像进行分类,而不生成模型响应。 |
| [理解审核结果](#understand-moderation-results) | 你的应用需要解读标记、类别、分数或已应用的输入类型。 |
| [查看支持的类别](#review-supported-categories) | 你的应用需要了解哪些危害类别适用于文本、图像或两者。 |
-## 审核生成的内容
+## Moderate generated content
-当你的应用需要同时获取生成文本和审核分数时,请在生成请求中传入顶层 `moderation` 对象。API 会针对模型输入和生成输出返回审核分数,无需发起单独的审核请求。
+当你的应用需要同时获取生成文本和审核分数时,请在请求中传入顶层 `moderation` 对象。API 会在模型输入和生成输出上返回审核分数,无需额外发起审核请求。
-模型仍会正常生成。在将输出展示给用户或执行下游操作前,请先查看审核结果。
+模型仍会正常生成。在将输出展示给用户或执行下游操作之前,请先查看审核结果。
@@ -153,27 +153,31 @@ ResponseCreateParams params =
.build();
var response = client.responses().create(params);
-JsonValue moderation = response._additionalProperties().get("moderation");
-if (moderation == null) {
- throw new IllegalStateException("The response did not include moderation results");
-}
-Map, ?> results = moderation.convert(Map.class);
+var moderation =
+ response
+ .moderation()
+ .orElseThrow(
+ () -> new IllegalStateException("The response did not include moderation results"));
List flags = new ArrayList<>();
-for (String side : List.of("input", "output")) {
- if (!(results.get(side) instanceof Map, ?> result)) {
- throw new IllegalStateException("Missing " + side + " moderation result");
- }
- if ("error".equals(result.get("type"))) {
- throw new IllegalStateException(String.valueOf(result.get("message")));
- }
- if (!"moderation_result".equals(result.get("type"))) {
- throw new IllegalStateException("Unexpected " + side + " moderation result type");
- }
- if (!(result.get("flagged") instanceof Boolean flagged)) {
- throw new IllegalStateException("Missing " + side + " moderation flag");
- }
- flags.add(flagged);
+
+var input = moderation.input();
+if (input.isError()) {
+ throw new IllegalStateException(input.asError().message());
+}
+if (!input.isModerationResult()) {
+ throw new IllegalStateException("Missing input moderation flag");
}
+flags.add(input.asModerationResult().flagged());
+
+var output = moderation.output();
+if (output.isError()) {
+ throw new IllegalStateException(output.asError().message());
+}
+if (!output.isModerationResult()) {
+ throw new IllegalStateException("Missing output moderation flag");
+}
+flags.add(output.asModerationResult().flagged());
+
flags.forEach(System.out::println);
```
@@ -192,23 +196,23 @@ puts(response.moderation)
```
-Responses API 会返回一个输入 `moderation_result` 对象,位于 `response.moderation.input` ,以及一个输出 `moderation_result` 对象,位于 `response.moderation.output`.
+Responses API 会在响应中的 `moderation_result` 对象处返回一个 input `response.moderation.input` 对象,以及在 output `moderation_result` 对象处返回一个 input `response.moderation.output`.
-内联审核结果使用的类别字段与独立审核结果一致。首先使用 `flagged` 进行首轮判定,然后查看 `categories` 和 `category_scores` ,用于日志记录、路由、审计轨迹或人工审核队列。即使是拒绝回答或其他具有安全意识的响应,只要涉及有害内容,仍可能触发标记。请将审核分数视为应用策略的参考信号,而非自动阻止决策的依据。
+内联审核结果使用与独立审核结果相同的类别字段。先用 `flagged` 做第一轮判断,然后查看 `categories` 和 `category_scores` 用于日志记录、路由、审计追踪或人工审核队列。即使是拒绝或其他具有安全意识的响应,只要讨论了有害内容,仍然可能触发标记。请将审核分数视为应用策略的参考信号,而非自动阻止的决策依据。
-如果你的应用需要处理审核失败的情况,请在读取分数之前先检查审核结果的类型。如果某个审核步骤无法完成,对应的输入或输出审核字段可能返回错误,而不是审核分数。
+如果你的应用需要处理审核失败的情况,请先检查审核结果的类型再读取分数。如果某个审核步骤无法完成,对应的输入或输出审核字段可能包含错误而非审核分数。
-对于工具调用请求,当工具调用参数和工具输出出现在对话内容中时,审核会覆盖它们。审核不覆盖工具名称、工具描述、工具 schema 或响应格式 schema。
+对于工具调用请求,当工具调用参数和工具输出出现在对话内容中时,审核会覆盖这些内容。但它不覆盖工具名称、工具描述、工具 schema 或响应格式 schema。
-如果你以流式方式获取生成的响应,审核分数会在完整生成输出可用后才到达,而不会随部分输出的增量一起返回。
+如果你以流式方式获取生成的响应,审核分数会在完整生成输出可用后到达,不会随部分输出的增量一同返回。
-## 对独立输入进行分类
+## Classify standalone inputs
-使用 [moderation 端点](https://developers.openai.com/api/reference/resources/moderations) 对文本或图像输入进行分类,而无需生成模型响应。下方标签页展示了如何配合 [OpenAI libraries](https://developers.openai.com/api/docs/libraries) 以及 [`omni-moderation-latest` model](https://developers.openai.com/api/docs/models#moderation):
+使用 [审核接口](https://developers.openai.com/api/reference/resources/moderations) 对文本或图像输入进行分类,而无需生成模型响应。以下选项卡展示了如何使用 [OpenAI 库](https://developers.openai.com/api/docs/libraries) 和 [`omni-moderation-latest` 模型](https://developers.openai.com/api/docs/models#moderation):
@@ -520,7 +524,7 @@ curl https://api.openai.com/v1/moderations \
## 理解审核结果
-以下是来自一部战争电影单帧图像的完整示例输出。模型会识别图像中的暴力迹象,并给出 `violence` 大于 0.8 的类别分数。
+下面是一张战争电影单帧图像的完整示例输出。模型识别出图像中的暴力指标,其 `violence` 类别评分大于 0.8。
```json
{
@@ -579,7 +583,7 @@ curl https://api.openai.com/v1/moderations \
}
```
-JSON 响应包含描述输入中存在哪些类别以及模型对每个类别的置信度的字段。
+JSON 响应包含描述输入中存在哪些类别以及模型对每个类别置信度的字段。
@@ -619,18 +623,18 @@ JSON 响应包含描述输入中存在哪些类别以及模型对每个类别的
-我们计划持续升级审核端点所依赖的底层模型。
- 因此,依赖于 `category_scores` 的策略可能需要
- 随时间重新校准。
+我们计划持续升级审核端点的底层模型。
+ 因此,依赖于 `category_scores` 可能需要
+ 随时间进行重新校准。
## 查看支持的类别
-下表说明了审核接口能够检测的内容类别,以及每个类别支持的输入类型。
+下表描述了审核端点可以检测的内容类别,以及每个类别支持的输入类型。
-标记为“仅文本”的类别不支持图像输入。如果你只向
- 模型发送图像(不含伴随文本),它会针对这些不支持的类别返 `omni-moderation-latest` 回 0 分。图像文件大小有
- 限,不得超过 20 MB。
- (无对应正文)
+标记为“仅文本”的类别不支持图像输入。如果你仅向
+ 端点发送图像(不附带文本), `omni-moderation-latest` 模型将为这些
+ 不支持的类别返回 0 分。图像文件大小
+ 限制为 20 MB。
diff --git a/docs/zh/api/docs/guides/prompt-generation.md b/docs/zh/api/docs/guides/prompt-generation.md
index f63269c..78a6b45 100644
--- a/docs/zh/api/docs/guides/prompt-generation.md
+++ b/docs/zh/api/docs/guides/prompt-generation.md
@@ -1,23 +1,23 @@
-# Prompt 生成
+# Prompt generation
-> 完整文档索引请参阅 [llms.txt](/llms.txt)。在页面 URL 末尾添加 `.md` 即可获取文档页面的 Markdown 版本。
+> 如需完整文档索引,请参阅 [llms.txt](/llms.txt)。文档页面的 Markdown 版本可通过在页面 URL 末尾追加 `.md` 获取。
-该 **生成** 按钮在 [Playground](https://platform.openai.com/chat/edit) 让你仅根据任务描述就能生成提示词、 [函数](https://developers.openai.com/api/docs/guides/function-calling),以及 [架构](https://developers.openai.com/api/docs/guides/structured-outputs#supported-schemas) 。本指南将详细讲解它的工作原理。
+该 **生成** 按钮,位于 [Playground](https://platform.openai.com/chat/edit) 可让你根据任务描述生成提示、 [函数](https://developers.openai.com/api/docs/guides/function-calling),和 [架构](https://developers.openai.com/api/docs/guides/structured-outputs#supported-schemas) 。本指南将详细讲解其具体工作原理。
## 概述
-从头开始创建提示和模式可能非常耗时,因此生成它们可以帮助你快速上手。Generate 按钮主要采用两种方式:
+从零开始创建提示和模式可能很耗时,因此生成它们可以帮助你快速上手。Generate 按钮主要使用两种方法:
-1. **提示词:** 我们使用 **元提示** (meta-prompts),融入最佳实践,用于生成或改进提示词。
-1. **模式(Schema):** 我们使用 **元模式** (meta-schemas),用于生成合法的 JSON 和函数语法。
+1. **提示词:** 我们使用 **元提示词** ,结合最佳实践来生成或改进提示词。
+1. **模式:** 我们使用 **元模式** ,用于生成合法的 JSON 和函数语法。
-虽然我们目前使用元提示和架构,但未来可能会集成更先进的技术,例如 [DSPy](https://arxiv.org/abs/2310.03714) 和 ["Gradient Descent"](https://arxiv.org/abs/2305.03495).
+虽然我们目前使用元提示和模式,但未来可能会集成更先进的技术,例如 [DSPy](https://arxiv.org/abs/2310.03714) 和 ["梯度下降"](https://arxiv.org/abs/2305.03495).
## Prompts
-一个 **meta-prompt** 指示模型根据你的任务描述创建一个优质提示,或者改进现有提示。Playground 中的元提示借鉴自我们的 [提示工程](https://developers.openai.com/api/docs/guides/prompt-engineering) 最佳实践以及与用户交流积累的实战经验。
+一个 **meta-prompt** 指示模型根据你的任务描述创建一个好的提示,或改进现有的提示。Playground 中的 meta-prompt 源自我们的 [prompt engineering](https://developers.openai.com/api/docs/guides/prompt-engineering) 最佳实践以及与用户的实际经验。
-我们针对不同的输出类型(例如音频)使用特定的元提示,以确保生成的提示符合预期格式。
+我们针对不同的输出类型(如音频)使用特定的 meta-prompt,以确保生成的提示符合预期格式。
### Meta-prompts
@@ -232,6 +232,74 @@ client.chat().completions().create(params).choices().stream()
.forEach(System.out::println);
````
+````ruby
+require "openai"
+
+client = OpenAI::Client.new
+meta_prompt = <<~PROMPT
+ Given a task description or existing prompt, produce a detailed system prompt to guide a language model in completing the task effectively.
+
+ # Guidelines
+
+ - Understand the Task: Grasp the main objective, goals, requirements, constraints, and expected output.
+ - Minimal Changes: If an existing prompt is provided, improve it only if it's simple. For complex prompts, enhance clarity and add missing elements without altering the original structure.
+ - Reasoning Before Conclusions**: Encourage reasoning steps before any conclusions are reached. ATTENTION! If the user provides examples where the reasoning happens afterward, REVERSE the order! NEVER START EXAMPLES WITH CONCLUSIONS!
+ - Reasoning Order: Call out reasoning portions of the prompt and conclusion parts (specific fields by name). For each, determine the ORDER in which this is done, and whether it needs to be reversed.
+ - Conclusion, classifications, or results should ALWAYS appear last.
+ - Examples: Include high-quality examples if helpful, using placeholders [in brackets] for complex elements.
+ - What kinds of examples may need to be included, how many, and whether they are complex enough to benefit from placeholders.
+ - Clarity and Conciseness: Use clear, specific language. Avoid unnecessary instructions or bland statements.
+ - Formatting: Use markdown features for readability. DO NOT USE ``` CODE BLOCKS UNLESS SPECIFICALLY REQUESTED.
+ - Preserve User Content: If the input task or prompt includes extensive guidelines or examples, preserve them entirely, or as closely as possible. If they are vague, consider breaking down into sub-steps. Keep any details, guidelines, examples, variables, or placeholders provided by the user.
+ - Constants: DO include constants in the prompt, as they are not susceptible to prompt injection. Such as guides, rubrics, and examples.
+ - Output Format: Explicitly the most appropriate output format, in detail. This should include length and syntax (e.g. short sentence, paragraph, JSON, etc.)
+ - For tasks outputting well-defined or structured data (classification, JSON, etc.) bias toward outputting a JSON.
+ - JSON should never be wrapped in code blocks (```) unless explicitly requested.
+
+ The final prompt you output should adhere to the following structure below. Do not include any additional commentary, only output the completed system prompt. SPECIFICALLY, do not include any additional messages at the start or end of the prompt. (e.g. no "---")
+
+ [Concise instruction describing the task - this should be the first line in the prompt, no section header]
+
+ [Additional details as needed.]
+
+ [Optional sections with headings or bullet points for detailed steps.]
+
+ # Steps [optional]
+
+ [optional: a detailed breakdown of the steps necessary to accomplish the task]
+
+ # Output Format
+
+ [Specifically call out how the output should be formatted, be it response length, structure e.g. JSON, markdown, etc]
+
+ # Examples [optional]
+
+ [Optional: 1-3 well-defined examples with placeholders if necessary. Clearly mark where examples start and end, and what the input and output are. User placeholders as necessary.]
+ [If the examples are shorter than what a realistic example is expected to be, make a reference with () explaining how real examples should be longer / shorter / different. AND USE PLACEHOLDERS! ]
+
+ # Notes [optional]
+
+ [optional: edge cases, details, and an area to call or repeat out specific important considerations]
+PROMPT
+
+def generate_prompt(client, meta_prompt, task_or_prompt)
+ completion = client.chat.completions.create(
+ model: "gpt-5.6",
+ messages: [
+ {role: :system, content: meta_prompt},
+ {
+ role: :user,
+ content: "Task, Goal, or Current Prompt:\n#{task_or_prompt}"
+ }
+ ]
+ )
+
+ completion.choices.fetch(0).message.content
+end
+
+puts(generate_prompt(client, meta_prompt, "Write a concise product launch announcement."))
+````
+
@@ -420,11 +488,70 @@ client.chat().completions().create(params).choices().stream()
.forEach(System.out::println);
```
+```ruby
+require "openai"
+
+client = OpenAI::Client.new
+meta_prompt = <<~PROMPT
+ Given a task description or existing prompt, produce a detailed system prompt to guide a realtime audio output language model in completing the task effectively.
+
+ # Guidelines
+
+ - Understand the Task: Grasp the main objective, goals, requirements, constraints, and expected output.
+ - Tone: Make sure to specifically call out the tone. By default it should be emotive and friendly, and speak quickly to avoid keeping the user just waiting.
+ - Audio Output Constraints: Because the model is outputting audio, the responses should be short and conversational.
+ - Minimal Changes: If an existing prompt is provided, improve it only if it's simple. For complex prompts, enhance clarity and add missing elements without altering the original structure.
+ - Examples: Include high-quality examples if helpful, using placeholders [in brackets] for complex elements.
+ - What kinds of examples may need to be included, how many, and whether they are complex enough to benefit from placeholders.
+ - It is very important that any examples included reflect the short, conversational output responses of the model.
+ Keep the sentences very short by default. Instead of 3 sentences in a row by the assistant, it should be split up with a back and forth with the user instead.
+ - By default each sentence should be a few words only (5-20ish words). However, if the user specifically asks for "short" responses, then the examples should truly have 1-10 word responses max.
+ - Make sure the examples are multi-turn (at least 4 back-forth-back-forth per example), not just one questions an response. They should reflect an organic conversation.
+ - Clarity and Conciseness: Use clear, specific language. Avoid unnecessary instructions or bland statements.
+ - Preserve User Content: If the input task or prompt includes extensive guidelines or examples, preserve them entirely, or as closely as possible. If they are vague, consider breaking down into sub-steps. Keep any details, guidelines, examples, variables, or placeholders provided by the user.
+ - Constants: DO include constants in the prompt, as they are not susceptible to prompt injection. Such as guides, rubrics, and examples.
+
+ The final prompt you output should adhere to the following structure below. Do not include any additional commentary, only output the completed system prompt. SPECIFICALLY, do not include any additional messages at the start or end of the prompt. (e.g. no "---")
+
+ [Concise instruction describing the task - this should be the first line in the prompt, no section header]
+
+ [Additional details as needed.]
+
+ [Optional sections with headings or bullet points for detailed steps.]
+
+ # Examples [optional]
+
+ [Optional: 1-3 well-defined examples with placeholders if necessary. Clearly mark where examples start and end, and what the input and output are. User placeholders as necessary.]
+ [If the examples are shorter than what a realistic example is expected to be, make a reference with () explaining how real examples should be longer / shorter / different. AND USE PLACEHOLDERS! ]
+
+ # Notes [optional]
+
+ [optional: edge cases, details, and an area to call or repeat out specific important considerations]
+PROMPT
+
+def generate_prompt(client, meta_prompt, task_or_prompt)
+ completion = client.chat.completions.create(
+ model: "gpt-5.6",
+ messages: [
+ {role: :system, content: meta_prompt},
+ {
+ role: :user,
+ content: "Task, Goal, or Current Prompt:\n#{task_or_prompt}"
+ }
+ ]
+ )
+
+ completion.choices.fetch(0).message.content
+end
+
+puts(generate_prompt(client, meta_prompt, "Create a friendly voice assistant for a bike shop."))
+```
+
### 提示词编辑
-为了编辑提示词,我们使用了一个稍作修改的元提示词。虽然直接编辑比较容易应用,但对于更开放式的修改,识别必要的更改可能具有挑战性。为了解决这个问题,我们在响应开头加入了一个 **reasoning section** 。该部分通过评估现有提示词的清晰度、思维链顺序、整体结构和具体性等因素,帮助引导模型确定需要进行哪些更改。reasoning section 会提出改进建议,然后从最终响应中解析出来。
+为了编辑提示词,我们使用一个稍作修改的元提示词。虽然直接修改比较容易应用,但识别开放式修订所需的必要更改可能具有挑战性。为了解决这个问题,我们在响应开头包含一个 **推理部分** 。该部分通过评估现有提示词的清晰度、思维链顺序、整体结构和具体性等因素,引导模型确定需要做哪些修改。推理部分会提出改进建议,然后从最终响应中解析出来。
@@ -694,6 +821,93 @@ client.chat().completions().create(params).choices().stream()
.forEach(System.out::println);
````
+````ruby
+require "openai"
+
+client = OpenAI::Client.new
+meta_prompt = <<~PROMPT
+ Given a current prompt and a change description, produce a detailed system prompt to guide a language model in completing the task effectively.
+
+ Your final output will be the full corrected prompt verbatim. However, before that, at the very beginning of your response, use tags to analyze the prompt and determine the following, explicitly:
+
+ - Simple Change: (yes/no) Is the change description explicit and simple? (If so, skip the rest of these questions.)
+ - Reasoning: (yes/no) Does the current prompt use reasoning, analysis, or chain of thought?
+ - Identify: (max 10 words) if so, which section(s) utilize reasoning?
+ - Conclusion: (yes/no) is the chain of thought used to determine a conclusion?
+ - Ordering: (before/after) is the chain of though located before or after
+ - Structure: (yes/no) does the input prompt have a well defined structure
+ - Examples: (yes/no) does the input prompt have few-shot examples
+ - Representative: (1-5) if present, how representative are the examples?
+ - Complexity: (1-5) how complex is the input prompt?
+ - Task: (1-5) how complex is the implied task?
+ - Necessity: ()
+ - Specificity: (1-5) how detailed and specific is the prompt? (not to be confused with length)
+ - Prioritization: (list) what 1-3 categories are the MOST important to address.
+ - Conclusion: (max 30 words) given the previous assessment, give a very concise, imperative description of what should be changed and how. this does not have to adhere strictly to only the categories listed
+
+
+ # Guidelines
+
+ - Understand the Task: Grasp the main objective, goals, requirements, constraints, and expected output.
+ - Minimal Changes: If an existing prompt is provided, improve it only if it's simple. For complex prompts, enhance clarity and add missing elements without altering the original structure.
+ - Reasoning Before Conclusions**: Encourage reasoning steps before any conclusions are reached. ATTENTION! If the user provides examples where the reasoning happens afterward, REVERSE the order! NEVER START EXAMPLES WITH CONCLUSIONS!
+ - Reasoning Order: Call out reasoning portions of the prompt and conclusion parts (specific fields by name). For each, determine the ORDER in which this is done, and whether it needs to be reversed.
+ - Conclusion, classifications, or results should ALWAYS appear last.
+ - Examples: Include high-quality examples if helpful, using placeholders [in brackets] for complex elements.
+ - What kinds of examples may need to be included, how many, and whether they are complex enough to benefit from placeholders.
+ - Clarity and Conciseness: Use clear, specific language. Avoid unnecessary instructions or bland statements.
+ - Formatting: Use markdown features for readability. DO NOT USE ``` CODE BLOCKS UNLESS SPECIFICALLY REQUESTED.
+ - Preserve User Content: If the input task or prompt includes extensive guidelines or examples, preserve them entirely, or as closely as possible. If they are vague, consider breaking down into sub-steps. Keep any details, guidelines, examples, variables, or placeholders provided by the user.
+ - Constants: DO include constants in the prompt, as they are not susceptible to prompt injection. Such as guides, rubrics, and examples.
+ - Output Format: Explicitly the most appropriate output format, in detail. This should include length and syntax (e.g. short sentence, paragraph, JSON, etc.)
+ - For tasks outputting well-defined or structured data (classification, JSON, etc.) bias toward outputting a JSON.
+ - JSON should never be wrapped in code blocks (```) unless explicitly requested.
+
+ The final prompt you output should adhere to the following structure below. Do not include any additional commentary, only output the completed system prompt. SPECIFICALLY, do not include any additional messages at the start or end of the prompt. (e.g. no "---")
+
+ [Concise instruction describing the task - this should be the first line in the prompt, no section header]
+
+ [Additional details as needed.]
+
+ [Optional sections with headings or bullet points for detailed steps.]
+
+ # Steps [optional]
+
+ [optional: a detailed breakdown of the steps necessary to accomplish the task]
+
+ # Output Format
+
+ [Specifically call out how the output should be formatted, be it response length, structure e.g. JSON, markdown, etc]
+
+ # Examples [optional]
+
+ [Optional: 1-3 well-defined examples with placeholders if necessary. Clearly mark where examples start and end, and what the input and output are. User placeholders as necessary.]
+ [If the examples are shorter than what a realistic example is expected to be, make a reference with () explaining how real examples should be longer / shorter / different. AND USE PLACEHOLDERS! ]
+
+ # Notes [optional]
+
+ [optional: edge cases, details, and an area to call or repeat out specific important considerations]
+ [NOTE: you must start with a section. the immediate next token you produce should be ]
+PROMPT
+
+def generate_prompt(client, meta_prompt, task_or_prompt)
+ completion = client.chat.completions.create(
+ model: "gpt-5.6",
+ messages: [
+ {role: :system, content: meta_prompt},
+ {
+ role: :user,
+ content: "Task, Goal, or Current Prompt:\n#{task_or_prompt}"
+ }
+ ]
+ )
+
+ completion.choices.fetch(0).message.content
+end
+
+puts(generate_prompt(client, meta_prompt, "Make this support prompt more concise and empathetic."))
+````
+
@@ -940,59 +1154,137 @@ client.chat().completions().create(params).choices().stream()
.forEach(System.out::println);
```
+```ruby
+require "openai"
+
+client = OpenAI::Client.new
+meta_prompt = <<~PROMPT
+ Given a current prompt and a change description, produce a detailed system prompt to guide a realtime audio output language model in completing the task effectively.
+
+ Your final output will be the full corrected prompt verbatim. However, before that, at the very beginning of your response, use tags to analyze the prompt and determine the following, explicitly:
+
+ - Simple Change: (yes/no) Is the change description explicit and simple? (If so, skip the rest of these questions.)
+ - Reasoning: (yes/no) Does the current prompt use reasoning, analysis, or chain of thought?
+ - Identify: (max 10 words) if so, which section(s) utilize reasoning?
+ - Conclusion: (yes/no) is the chain of thought used to determine a conclusion?
+ - Ordering: (before/after) is the chain of though located before or after
+ - Structure: (yes/no) does the input prompt have a well defined structure
+ - Examples: (yes/no) does the input prompt have few-shot examples
+ - Representative: (1-5) if present, how representative are the examples?
+ - Complexity: (1-5) how complex is the input prompt?
+ - Task: (1-5) how complex is the implied task?
+ - Necessity: ()
+ - Specificity: (1-5) how detailed and specific is the prompt? (not to be confused with length)
+ - Prioritization: (list) what 1-3 categories are the MOST important to address.
+ - Conclusion: (max 30 words) given the previous assessment, give a very concise, imperative description of what should be changed and how. this does not have to adhere strictly to only the categories listed
+
+
+ # Guidelines
+
+ - Understand the Task: Grasp the main objective, goals, requirements, constraints, and expected output.
+ - Tone: Make sure to specifically call out the tone. By default it should be emotive and friendly, and speak quickly to avoid keeping the user just waiting.
+ - Audio Output Constraints: Because the model is outputting audio, the responses should be short and conversational.
+ - Minimal Changes: If an existing prompt is provided, improve it only if it's simple. For complex prompts, enhance clarity and add missing elements without altering the original structure.
+ - Examples: Include high-quality examples if helpful, using placeholders [in brackets] for complex elements.
+ - What kinds of examples may need to be included, how many, and whether they are complex enough to benefit from placeholders.
+ - It is very important that any examples included reflect the short, conversational output responses of the model.
+ Keep the sentences very short by default. Instead of 3 sentences in a row by the assistant, it should be split up with a back and forth with the user instead.
+ - By default each sentence should be a few words only (5-20ish words). However, if the user specifically asks for "short" responses, then the examples should truly have 1-10 word responses max.
+ - Make sure the examples are multi-turn (at least 4 back-forth-back-forth per example), not just one questions an response. They should reflect an organic conversation.
+ - Clarity and Conciseness: Use clear, specific language. Avoid unnecessary instructions or bland statements.
+ - Preserve User Content: If the input task or prompt includes extensive guidelines or examples, preserve them entirely, or as closely as possible. If they are vague, consider breaking down into sub-steps. Keep any details, guidelines, examples, variables, or placeholders provided by the user.
+ - Constants: DO include constants in the prompt, as they are not susceptible to prompt injection. Such as guides, rubrics, and examples.
+
+ The final prompt you output should adhere to the following structure below. Do not include any additional commentary, only output the completed system prompt. SPECIFICALLY, do not include any additional messages at the start or end of the prompt. (e.g. no "---")
+
+ [Concise instruction describing the task - this should be the first line in the prompt, no section header]
+
+ [Additional details as needed.]
+
+ [Optional sections with headings or bullet points for detailed steps.]
+
+ # Examples [optional]
+
+ [Optional: 1-3 well-defined examples with placeholders if necessary. Clearly mark where examples start and end, and what the input and output are. User placeholders as necessary.]
+ [If the examples are shorter than what a realistic example is expected to be, make a reference with () explaining how real examples should be longer / shorter / different. AND USE PLACEHOLDERS! ]
+
+ # Notes [optional]
+
+ [optional: edge cases, details, and an area to call or repeat out specific important considerations]
+ [NOTE: you must start with a section. the immediate next token you produce should be ]
+PROMPT
+
+def generate_prompt(client, meta_prompt, task_or_prompt)
+ completion = client.chat.completions.create(
+ model: "gpt-5.6",
+ messages: [
+ {role: :system, content: meta_prompt},
+ {
+ role: :user,
+ content: "Task, Goal, or Current Prompt:\n#{task_or_prompt}"
+ }
+ ]
+ )
+
+ completion.choices.fetch(0).message.content
+end
+
+puts(generate_prompt(client, meta_prompt, "Make this voice assistant prompt warmer and more direct."))
+```
+
## Schemas
-[结构化输出](https://developers.openai.com/api/docs/guides/structured-outputs) schemas 和函数模式本身就是 JSON 对象,因此我们借助结构化输出(Structured Outputs)来生成它们。
-这需要为期望的输出定义一个模式,而本例中的输出本身也是一个模式。为此,我们使用自描述模式——一个 **元模式**.
+[Structured Outputs](https://developers.openai.com/api/docs/guides/structured-outputs) schema 和 function schema 本身都是 JSON 对象,因此我们借助 Structured Outputs 来生成它们。
+这需要为期望的输出定义一个 schema,而这里期望的输出本身就是一个 schema。为此,我们使用一个自描述 schema —— 一个 **meta-schema**.
-由于函数模式中的 `parameters` 字段本身也是一个模式,我们使用同一个元模式来生成函数。
+由于 function schema 中的 `parameters` 字段本身也是一个 schema,我们使用同一个 meta-schema 来生成函数。
-### 定义受限的元模式
+### 定义受限的元架构
-[结构化输出](https://developers.openai.com/api/docs/guides/structured-outputs) 支持两种模式: `strict=true` 和 `strict=false`。两种模式都使用同一个经过训练的模型来遵循所提供的 schema,但只有 "strict mode" 通过受限采样保证完美遵循。
+[Structured Outputs](https://developers.openai.com/api/docs/guides/structured-outputs) 支持两种模式: `strict=true` 和 `strict=false`。两种模式都使用同一模型训练以遵循所提供的 schema,但只有“严格模式”能通过受约束采样保证完全遵循。
-我们的目标是使用 strict mode 本身为 strict mode 生成 schema。然而,由 [JSON Schema 规范](https://json-schema.org/specification#meta-schemas) 提供的官方 meta-schema 依赖 [strict mode 当前不支持](https://developers.openai.com/api/docs/guides/structured-outputs#some-type-specific-keywords-are-not-yet-supported) 的特性。这带来了同时影响输入和输出 schema 的挑战。
+我们的目标是使用严格模式本身来为严格模式生成 schema。然而, [JSON Schema 规范](https://json-schema.org/specification#meta-schemas) 官方提供的元 schema 依赖 [严格模式下暂不支持](https://developers.openai.com/api/docs/guides/structured-outputs#some-type-specific-keywords-are-not-yet-supported) 的特性,这对输入和输出 schema 都带来了挑战。
-1. **输入模式:** 我们无法使用 [unsupported features](https://developers.openai.com/api/docs/guides/structured-outputs#some-type-specific-keywords-are-not-yet-supported) 中的功能来描述输出模式。
-2. **输出模式:** 生成模式不得包含 [unsupported features](https://developers.openai.com/api/docs/guides/structured-outputs#some-type-specific-keywords-are-not-yet-supported).
+1. **输入架构:** 我们无法使用 [不受支持的功能](https://developers.openai.com/api/docs/guides/structured-outputs#some-type-specific-keywords-are-not-yet-supported) 来描述输入架构中的输出架构。
+2. **输出架构:** 生成的架构不得包含 [不受支持的功能](https://developers.openai.com/api/docs/guides/structured-outputs#some-type-specific-keywords-are-not-yet-supported).
-由于需要在输出 schema 中生成新的键,输入的元 schema 必须使用 `additionalProperties`。这意味着我们目前无法使用 strict 模式来生成 schema。不过,我们仍然希望生成的 schema 符合 strict 模式的约束。
+因为我们需要在输出 schema 中生成新的键,输入元 schema 必须使用 `additionalProperties`。这意味着我们目前无法使用 strict 模式来生成 schema。不过,我们仍然希望生成的 schema 能够符合 strict 模式的约束。
-为了克服这一限制,我们定义了一个 **pseudo-meta-schema** —— 一个元模式(meta-schema),它使用严格模式下不支持的特性,仅用于描述严格模式下所支持的特性。本质上,这种方式在元模式定义时跳出严格模式,同时仍确保所生成的模式遵循严格模式约束。
+为了克服这一限制,我们定义了一个 **伪元 schema** ——一种使用了 strict 模式不支持的特性、仅用来描述 strict 模式所支持特性的元 schema。本质上,这种方法在元 schema 定义中跳出了 strict 模式,同时仍然确保生成的 schema 遵循 strict 模式的约束。
-构建一个受限的元模式是一项具有挑战性的任务,因此我们借助了模型来协助完成。
+构建一个受限制的元 schema 是一项具有挑战性的任务,因此我们借助模型来帮忙。
-我们首先提供 `o1-preview` 和 `gpt-4o` 在 JSON 模式下,根据 Structured Outputs 文档描述我们的目标。
-经过几次迭代,我们开发出了第一个可用的元模式。
+我们首先让 `o1-preview` 和 `gpt-4o` 在 JSON 模式下根据 Structured Outputs 文档给出对我们目标的描述。
+经过几次迭代后,我们开发出了第一个可用的元 schema。
-然后我们使用了 `gpt-4o` 配合 Structured Outputs,并提供了 _那个初步的 schema_ 以及我们的任务说明和文档,以生成更好的候选方案。每一次迭代我们都使用更好的 schema 来生成下一个,直到最后我们仔细手工审核了它。
+然后我们使用 `gpt-4o` 配合 Structured Outputs,并向其提供 _那个初始 schema_ 以及我们的任务描述和文档,以生成更好的候选方案。每一次迭代,我们都使用一个更好的 schema 来生成下一个,直到最终仔细地进行人工审核。
-最后,在清理输出之后,我们针对一组针对 schema 和函数的评估对它们进行了验证。
+最后,在清理输出之后,我们根据一组针对 schema 和函数的评估对生成的 schema 进行了验证。
-### 输出清洗
+### 输出清理
-严格模式可确保完全符合架构。不过,我们无法在生成过程中使用它,因此需要在生成输出后对其进行验证和转换。
+严格模式可以保证完全遵循 schema。然而,由于我们在生成过程中无法使用它,因此需要在生成完成后对输出进行校验和转换。
-生成架构后,我们会执行以下步骤:
+生成 schema 后,我们会执行以下步骤:
1. **将 `additionalProperties` 设置为 `false`** ,适用于所有对象。
1. **将所有属性标记为必填**.
-1. **对于结构化输出架构**,请使用 [`json_schema`](https://developers.openai.com/api/docs/guides/structured-outputs?context=without_parse#how-to-use) 对象进行包装。
-1. **对于函数**,请使用 [`function`](https://developers.openai.com/api/docs/guides/function-calling#defining-functions) 对象进行包装。
+1. **对于结构化输出 schema**,请将它们包裹在 [`json_schema`](https://developers.openai.com/api/docs/guides/structured-outputs?context=without_parse#how-to-use) 对象中。
+1. **对于函数**,请将它们包裹在 [`function`](https://developers.openai.com/api/docs/guides/function-calling#defining-functions) 对象中。
Realtime API
[函数](https://developers.openai.com/api/docs/guides/realtime-conversations#function-calling) 对象
- 与 Chat Completions API 略有不同,但使用相同的架构。
+ 与 Chat Completions API 略有差异,但使用相同的架构。
-### Meta-schemas
+### 元模式
-每个元 schema 都对应一个提示,其中包含少量示例。借助 Structured Outputs 的可靠性——即使未使用严格模式——我们也能够生成 schema。
+每个元数据 schema 都附带一个包含少样本示例的提示词。结合 Structured Outputs 的可靠性 —— 即便不使用严格模式 —— 我们也能成功生成 schema。
diff --git a/docs/zh/api/docs/guides/rate-limits.md b/docs/zh/api/docs/guides/rate-limits.md
index 95edab4..548d8a8 100644
--- a/docs/zh/api/docs/guides/rate-limits.md
+++ b/docs/zh/api/docs/guides/rate-limits.md
@@ -1,77 +1,77 @@
-# 速率限制
+# Rate limits
-> 如需完整文档索引,请参阅 [llms.txt](/llms.txt)。文档页面的 Markdown 版本可通过在页面 URL 末尾追加 `.md` 获取。
+> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。文档页面的 Markdown 版本可通过在页面 URL 后追加 `.md` 获取。
-速率限制是我们对 API 所施加的限制,用于约束用户或客户端在特定时间段内可以
-访问我们服务的次数。
+速率限制是 API 对用户或客户端在指定时间内访问我们服务次数的限制。
+访问我们的服务次数施加的限制。
-## 为什么会有速率限制?
+## 为什么要设置速率限制?
-速率限制是 API 的常见做法,设置速率限制有以下几个原因:
+速率限制是 API 的常见做法,设置它们有几个不同的原因:
-- **它们有助于防止对 API 的滥用或误用。** 例如,恶意行为者可能向 API 发送大量请求,试图使其过载或造成服务中断。通过设置速率限制,OpenAI 可以阻止此类活动。
-- **速率限制有助于确保每个人都能公平地访问 API。** 如果某个人或组织发送过多请求,可能会拖慢 API,影响其他所有人。通过限制单个用户可发送的请求数量,OpenAI 能够确保尽可能多的人在不会遇到速度下降的情况下使用 API。
-- **速率限制可以帮助 OpenAI 管理其基础设施上的总体负载。** 如果对 API 的请求量大幅增加,可能会给服务器带来压力并引发性能问题。通过设置速率限制,OpenAI 可以帮助所有用户维持流畅且一致的体验。
+- **它们有助于防止滥用或误用 API。** 例如,恶意行为者可以向 API 发送大量请求,试图使其过载或导致服务中断。通过设置速率限制,OpenAI 可以防止这类活动。
+- **速率限制有助于确保每个人都能公平使用 API。** 如果个人或组织发出过多请求,就可能拖慢所有其他人使用 API 的速度。通过限制单个用户可发出的请求数量,OpenAI 确保尽可能多的人有机会使用 API,而不会遇到速度变慢的情况。
+- **速率限制可以帮助 OpenAI 管理其基础设施上的总体负载。** 如果发往 API 的请求量急剧增加,可能会给服务器造成压力并导致性能问题。通过设置速率限制,OpenAI 可以帮助所有用户保持流畅且一致的体验。
-请通读整篇文档,以便更好地了解
- OpenAI 的速率限制系统是如何运作的。我们提供了代码示例以及处理常见问题的
- 解决方案。我们还详细介绍了在使用层级(usage tiers)部分中,你的
- 速率限制是如何自动提升的。
+请完整阅读本文档,以便更好地了解
+ OpenAI 的速率限制系统是如何运作的。我们提供了代码示例和可能的
+ 解决方案以处理常见问题。我们还会详细介绍在下文的使用层级一节中,
+ 你的速率限制是如何被自动提升的。
## 这些速率限制是如何工作的?
-速率限制使用诸如 **RPM** (每分钟请求数)、 **RPD** (每天请求数)、 **TPM** (每分钟 token 数)、 **TPD** (每天 token 数)、 **IPM** (每分钟图像数)以及部分流式音频模型的每分钟音频分钟数等指标。速率限制可能在任意一项上达到上限,取决于哪个先触发。例如,你可能向 ChatCompletions 端点发送 20 个仅包含 100 token 的请求,即使你在这 20 个请求中并未发送 150k token(如果你的 TPM 上限是 150k),也会耗尽你的配额(如果你的 RPM 是 20)。
+速率限制使用以下指标: **RPM** (每分钟请求数), **RPD** (每天请求数), **TPM** (每分钟令牌数), **TPD** (每天令牌数), **IPM** (每分钟图像数),以及某些流式音频模型的每分钟音频分钟数。速率限制取决于哪个先达到,可能会在上述任意选项上触发。例如,你可能向 ChatCompletions 端点发送 20 个仅含 100 个令牌的请求,这就会耗尽你的限额(如果你的 RPM 为 20),即使在这 20 个请求中你并未发送 15 万个令牌(如果你的 TPM 限制为 15 万)。
-[批量 API](https://developers.openai.com/api/reference/resources/batches/methods/create) 队列限制是根据给定模型队列中输入 token 的总数计算的。待处理批量作业的 token 会计入你的队列限制。批量作业完成后,其 token 将不再计入该模型的限制。
+[Batch API](https://developers.openai.com/api/reference/resources/batches/methods/create) 队列限制是根据给定模型排队的输入令牌总数计算的。挂起中的批量作业中的令牌会计入你的队列限制。一旦批量作业完成,其令牌将不再计入该模型的限制。
其他值得注意的重要事项:
- 速率限制在 [组织层级](https://developers.openai.com/api/docs/guides/production-best-practices) 以及项目层级定义,而不是用户层级。
-- 速率限制因 [模型](https://developers.openai.com/api/docs/models) 而异。
-- 对于像 GPT-5.5 这样的长上下文模型,长上下文请求有单独的速率限制。你可以在 [开发者控制台](https://platform.openai.com/settings/organization/limits).
-- OpenAI 为每个组织设置一个已批准的每月使用上限。这与 [支出上限](https://developers.openai.com/api/docs/guides/spend-limits) 是分开的,你可以为组织或项目配置支出上限。
-- 一些模型系列共享速率限制。在你的 [组织限制页面](https://platform.openai.com/settings/organization/limits) 中列于同一“共享限制”下的任何模型共享该速率限制。例如,如果列出的共享 TPM 为 3.5M,则对该“共享限制”列表中任何模型的所有调用都将计入该 3.5M。
-- 向量存储的数据写入也按向量存储 ID 进行速率限制。 `/vector_stores/{vector_store_id}/files` 以及 `/vector_stores/{vector_store_id}/file_batches` 每个向量存储共享每分钟 300 次请求的限制。对于较大的数据写入,建议使用 `/vector_stores/{vector_store_id}/file_batches`.
+- 速率限制因所使用的 [模型](https://developers.openai.com/api/docs/models) 而异。
+- 对于 GPT-5.5 等长上下文模型,长上下文请求有单独的速率限制。你可以在 [开发者控制台](https://platform.openai.com/settings/organization/limits).
+- OpenAI 为每个组织设定一个已批准的月度用量上限。这与 [支出上限](https://developers.openai.com/api/docs/guides/spend-limits) 是分开的,你可以为组织或项目配置该支出上限。
+- 某些模型系列共享速率限制。在你的 [组织限制页面](https://platform.openai.com/settings/organization/limits) 中列于同一“共享限制”下的所有模型共享一个速率限制。例如,如果列出的共享 TPM 为 3.5M,则对该“共享限制”列表中任何模型的所有调用都将计入该 3.5M。
+- 向量存储的写入也按每个向量存储 ID 进行速率限制。 `/vector_stores/{vector_store_id}/files` 并且 `/vector_stores/{vector_store_id}/file_batches` 每个向量存储共享每分钟 300 次请求的限制。对于较大的写入任务,建议使用 `/vector_stores/{vector_store_id}/file_batches`.
## 使用层级
-你可以在账户设置中的 [限额](https://platform.openai.com/settings/organization/limits) 部分查看你所在组织的速率和使用上限。随着你在 API 上的支出增加,我们会自动将你升级到下一个使用层级。这通常会提高大多数模型的速率上限。
+你可以在账户设置的 [限制](https://platform.openai.com/settings/organization/limits) 部分查看你所在组织的速率和使用上限。随着你在我们 API 上的消费提升,我们会自动将你升级到下一使用层级,这通常会带来大多数模型速率限制的提高。
-| 层级 | 资格条件 | 使用限额 |
+| 层级 | 资格要求 | 使用限额 |
| ----------- | --------------------------------------------------------------------- | ---------------- |
| 免费 | 用户必须位于 [允许的地区](https://developers.openai.com/api/docs/supported-countries) | $100 / 月 |
-| 层级 1 | 已支付 $5 | $100 / 月 |
-| 层级 2 | 已支付 $50 | $500 / 月 |
-| 层级 3 | 已支付 $100 | $1,000 / 月 |
-| 层级 4 | 已支付 $250 | $5,000 / 月 |
-| 层级 5 | $1,000 paid | $200,000 / 月 |
+| 层级 1 | $5 充值 | $100 / 月 |
+| 层级 2 | $50 充值 | $500 / 月 |
+| 层级 3 | $100 充值 | $1,000 / 月 |
+| 层级 4 | $250 充值 | $5,000 / 月 |
+| 层级 5 | 1,000 美元(已支付) | 200,000 美元 / 月 |
-若需查看每个模型的速率限制概览,请访问 [models 页面](https://developers.openai.com/api/docs/models).
+若要查看每个模型的速率限制概览,请访问 [模型页面](https://developers.openai.com/api/docs/models).
### 响应头中的速率限制
-除了可以在你的 [账户页面](https://platform.openai.com/settings/organization/limits),中查看速率限制外,你还可以在 HTTP 响应的标头中查看有关速率限制的重要信息,例如剩余的请求数、令牌数以及其他元数据。
+除了在你的 [账户页面](https://platform.openai.com/settings/organization/limits),中查看速率限制外,你还可以在 HTTP 响应的请求头中查看有关速率限制的重要信息,例如剩余请求数、令牌数以及其他元数据。
-响应中可以包含以下标头字段:
+响应可以包含以下请求头字段:
| 字段 | 示例值 | 说明 |
| ------------------------------------ | ------------ | ------------------------------------------------------------------------------------------------- |
-| Retry-After | 56 | 临时速率限制错误重试前需等待的最短秒数(如有)。 |
-| x-ratelimit-limit-requests | 60 | 在耗尽速率限制之前允许的最大请求数。 |
-| x-ratelimit-limit-tokens | 150000 | 在耗尽速率限制之前允许的最大 token 数。 |
-| x-ratelimit-remaining-requests | 59 | 在耗尽速率限制之前允许的剩余请求数。 |
-| x-ratelimit-remaining-tokens | 149984 | 在耗尽速率限制之前允许的剩余 token 数。 |
-| x-ratelimit-reset-requests | 1s | 基于请求数的速率限制重置到初始状态所剩余的时间。 |
-| x-ratelimit-reset-tokens | 6m0s | 基于 token 数的速率限制重置到初始状态所剩余的时间。 |
-| x-ratelimit-limit-project-tokens | 60000 | 项目的 token 限制。 |
-| x-ratelimit-remaining-project-tokens | 57000 | 在耗尽项目范围的 token 速率限制之前,允许剩余的 token 数量。 |
-| x-ratelimit-reset-project-tokens | 3s | 项目范围的 token 速率限制重置到初始状态所剩余的时间。 |
-
-当存在项目级令牌限制时,响应中可能会出现 Project-token 头。 `Retry-After` 可能会出现在 `429` 因临时速率限制而引起的响应上。这并不表示配额、计费或其他需要用户操作的错误可以通过重试来解决。
+| Retry-After | 56 | 在出现临时限流错误时,重试前需等待的最短秒数(如果存在)。 |
+| x-ratelimit-limit-requests | 60 | 在耗尽限流额度之前所允许的最大请求数。 |
+| x-ratelimit-limit-tokens | 150000 | 在耗尽限流额度之前所允许的最大 token 数。 |
+| x-ratelimit-remaining-requests | 59 | 在耗尽限流额度之前所允许的剩余请求数。 |
+| x-ratelimit-remaining-tokens | 149984 | 在耗尽限流额度之前所允许的剩余 token 数。 |
+| x-ratelimit-reset-requests | 1s | 基于请求数的速率限制重置回初始状态前剩余的时间。 |
+| x-ratelimit-reset-tokens | 6m0s | 基于 token 数的速率限制重置回初始状态前剩余的时间。 |
+| x-ratelimit-limit-project-tokens | 60000 | 项目的 token 上限。 |
+| x-ratelimit-remaining-project-tokens | 57000 | 在项目级 token 速率限制耗尽之前允许使用的剩余 token 数。 |
+| x-ratelimit-reset-project-tokens | 3s | 项目级 token 速率限制重置回初始状态前剩余的时间。 |
+
+在项目级 token 限制适用时,可能出现项目 token 相关的响应头。 `Retry-After` 可能出现在 `429` 由临时速率限制引起的响应中。它并不意味着配额、计费或其他需要用户操作的错误可以通过重试解决。
### 微调速率限制
-你的组织的微调速率限制可在 [控制台中找到](https://platform.openai.com/settings/organization/limits),也可以通过 API 获取:
+你所在组织的微调速率限制可在 [控制台中查看](https://platform.openai.com/settings/organization/limits),也可以通过 API 获取:
```bash
curl https://api.openai.com/v1/fine_tuning/model_limits \
@@ -79,35 +79,52 @@ curl https://api.openai.com/v1/fine_tuning/model_limits \
```
-## 错误缓解
+## Error mitigation
+
+### 处理流量激增和模型过载
+
+API 可能会返回 `slow_down` 当你的请求速率增长过快时,或 `server_is_overloaded` 当所请求的模型暂时过载时。请检查 HTTP 状态码,并 `error.code` 以区分这两种情况:
+
+| HTTP 状态 | 错误类型 | 错误代码 | 含义说明 | 处理建议 |
+| ----------- | --------------------------- | ---------------------- | ---------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- |
+| `429` | `rate_limit_error` | `slow_down` | 请求速率增长过快。 | 遵循 `Retry-After` (如果存在)降低请求速率,然后再逐步提升。 |
+| `503` | `service_unavailable_error` | `server_is_overloaded` | 所请求的模型暂时过载。 | 遵循 `Retry-After` (如果存在)然后重试。如果错误仍然存在,请加大重试间隔。 |
+
+如果 `Retry-After` 错误缺失,请增加重试之间的间隔,并加入一个较小的随机延迟。
+
+一个 `slow_down` 错误即使在你的流量未超出每分钟请求数和每分钟 token 数限制时也可能发生。它反映的是流量增长的速度,而不是你是否已耗尽这些限制。
+
+作为经验法则,一旦你的流量达到每分钟 100 万输入 token(TPM),每 15 分钟的增长幅度不要超过 50%。斜率限制具体在何时生效,会因模型和流量状况而有所不同。
+
+按量付费流量经常触及斜率限制的企业客户可以考虑 [Scale Tier](https://openai.com/api-scale-tier/) ,以在符合条件的模型上获得更可预期的容量。对于 GPT-5.6 及更高版本的模型,请参阅 [Reserved Tier](https://openai.com/api-reserved-tier/)。容量层级不会改变你应该如何处理 `slow_down` 响应:遵循 `Retry-After` 中的说明(如果存在),降低流量,并逐步提升。
### 我可以采取哪些步骤来缓解此问题?
-OpenAI Cookbook 中有一个 [Python notebook](https://developers.openai.com/cookbook/examples/how_to_handle_rate_limits) 详细解释了如何避免速率限制错误,同时还提供了一个示例 [Python script](https://github.com/openai/openai-cookbook/blob/main/examples/api_request_parallel_processor.py) ,演示在批量处理 API 请求时如何保持在速率限制之内。
+OpenAI Cookbook 提供了一个 [Python notebook](https://developers.openai.com/cookbook/examples/how_to_handle_rate_limits) ,介绍如何避免速率限制错误,并附带一个示例 [Python 脚本](https://github.com/openai/openai-cookbook/blob/main/examples/api_request_parallel_processor.py) ,演示在批量处理 API 请求时如何保持在速率限制之内。
-在提供编程访问、批量处理功能以及自动化社交媒体发布功能时,你也应保持谨慎——建议仅向可信用户开放这些功能。
+在提供编程访问、批量处理功能以及自动社交媒体发布功能时,你也应保持谨慎——建议仅向可信的客户开放这些功能。
-为防止自动化的高频滥用,你应在指定的时间范围(每日、每周或每月)内为单个用户设置使用上限。对于超出限制的用户,可以考虑实施硬性上限或人工审核流程。
+为防范自动化的、高流量的滥用行为,应在指定时间范围(每日、每周或每月)内为单个用户设置用量限制。可考虑为超出限制的用户设置硬性上限或人工审核流程。
-#### 使用指数退避重试
+#### 使用指数退避进行重试
-当请求超过临时速率限制时,API 会返回 `429` 错误。响应可以包含一个 `Retry-After` 响应头,告诉你需要等待多少秒后再重试。请将此值视为最小值:至少等待这么久,并增加一个较小的随机延迟,以免多个客户端同时重试。
+当请求超出临时速率限制时,API 会返回 `429` 错误。响应中可以包含一个 `Retry-After` 响应头,用于告诉你重试前需要等待多少秒。请将该值视为最小值:至少等待这么长时间,并额外加上一个小的随机延时,防止多个客户端在同一时刻重试。
-每个 [官方 OpenAI SDK](https://developers.openai.com/api/docs/libraries#install-an-official-sdk) 会自动重试符合条件的速率限制错误,并在 `Retry-After` 存在时遵守其值。无需为标准的 API 调用解析该响应头或再添加重试循环。
+每个 [官方 OpenAI SDK](https://developers.openai.com/api/docs/libraries#install-an-official-sdk) 都会自动重试符合条件的速率限制错误,并遵循 `Retry-After` 的指示(当该头部存在时)。你无需解析该头部,也无需为标准的 API 调用额外添加重试循环。
-如果你使用自己的 HTTP 客户端,请在 `Retry-After` 响应头存在且包含有效值时遵循它。如果响应头缺失或无效,则回退到带有抖动的指数退避。同时限制重试次数和重试总耗时。如果添加了应用层重试,请将 SDK 已执行的重试计算在内。不要重试配额、计费或其他需要你采取操作的错误。
+如果使用自己的 HTTP 客户端,请在 `Retry-After` 存在且包含有效值时遵循该头部。如果缺失或无效,则回退到带抖动的指数退避策略。同时限制重试次数和重试总时长。如果你在应用层添加了重试逻辑,请将 SDK 已执行的重试计入其中。不要对配额、计费或其他需要你主动处理的错误进行重试。
-指数退避是指在一次失败的请求后短暂等待,然后在每次失败重试后增加延迟。该过程会一直持续,直到请求成功或达到配置的重试上限。
+指数退避指在请求失败后短暂等待,并在每次重试失败后逐步延长等待时间。这一过程会持续进行,直到请求成功或达到配置的重试上限。
-此方法有许多优点:
+这种做法有许多优点:
-- 自动重试意味着你可以在不发生崩溃或丢失数据的情况下,从限流错误中恢复
-- 指数退避意味着你可以较快地尝试最初几次重试,同时在前几次失败时仍能从较长的延迟中受益
-- 在延迟中加入随机抖动可以避免所有重试在同一时刻发生。
+- 自动重试意味着你可以在不发生崩溃或丢失数据的情况下从速率限制错误中恢复
+- 指数退避意味着你可以快速尝试最初几次重试,同时在前几次重试失败时仍能受益于更长的延迟
+- 在延迟中加入随机抖动有助于避免所有重试同时发生。
-请注意,未成功的请求会计入你的每分钟限额,因此持续重新发送请求是无效的。
+请注意,未成功的请求会计入你的每分钟限速,因此持续重发同一个请求是无效的。
-下面是几个示例方案 **针对 Python** 它们使用了指数退避。
+以下是几个示例解决方案 **(适用于 Python)** 使用了指数退避策略。
@@ -115,8 +132,8 @@ OpenAI Cookbook 中有一个 [Python notebook](https://developers.openai.com/coo
-Tenacity 是一个采用 Apache 2.0 许可的通用重试库,使用 Python 编写,旨在简化向几乎任意对象添加重试行为的任务。
-要为你的请求添加指数退避,可以使用 `tenacity.retry` 装饰器。下面的示例使用 `tenacity.wait_random_exponential` 函数为请求添加随机指数退避。
+Tenacity 是一个基于 Apache 2.0 许可的通用重试库,使用 Python 编写,旨在简化为几乎任何场景添加重试行为的工作。
+如果要为请求添加指数退避,可以使用 `tenacity.retry` 装饰器。下面的示例使用 `tenacity.wait_random_exponential` 函数为请求添加随机指数退避。
使用 Tenacity 库
@@ -143,8 +160,8 @@ completion_with_backoff(
```
-请注意,Tenacity 库是第三方工具,OpenAI 不对其
-可靠性或安全性作任何保证。
+请注意,Tenacity 库是第三方工具,OpenAI 对其不做任何
+可靠性或安全性方面的保证。
@@ -156,7 +173,7 @@ completion_with_backoff(
-另一个提供函数装饰器用于回退和重试的 Python 库是 [backoff](https://pypi.org/project/backoff/):
+另一个提供用于退避和重试的函数装饰器的 Python 库是 [backoff](https://pypi.org/project/backoff/):
使用 Tenacity 库
@@ -180,7 +197,7 @@ completions_with_backoff(
```
-与 Tenacity 一样,backoff 库是第三方工具,OpenAI 不对其可靠性或安全性作出任何保证。
+与 Tenacity 类似,backoff 库是一个第三方工具,OpenAI 不会对其可靠性或安全性做出任何保证。
@@ -188,10 +205,10 @@ completions_with_backoff(
-##### 示例 3:手动实现退避
+##### 示例 3:手动实现指数退避
-如果你不想使用第三方库,可以参考下面的示例自行实现退避逻辑:
+如果你不想使用第三方库,可以按照下面的示例自行实现退避逻辑:
使用手动退避实现
```python
@@ -256,22 +273,22 @@ def completions_with_backoff(**kwargs):
return client.completions.create(**kwargs)
```
-同样地,OpenAI 不对该方案的安全性或效率作任何保证,但它可以作为你自己方案的良好起点。
+同样,OpenAI 不对该方案的安全性或效率作出任何保证,但它可以作为你自己方案的良好起点。
-#### Reduce the `max_tokens` to match the size of your completions
+#### 减少 `max_tokens` 以匹配你的补全大小
-你的速率上限按以下两项中的较大值计算: `max_tokens` 以及根据请求字符数估算的 token 数。请尽量将 `max_tokens` 值设置得接近你预期的响应大小。
+你的速率限制按以下两者中的较大值计算: `max_tokens` 以及根据你的请求字符数估算的 token 数。请尽量将 `max_tokens` 值设定为接近你预期的响应大小。
-#### Batching requests
+#### 批量请求
-如果你的用例不需要立即获得响应,你可以使用 [批量 API](https://developers.openai.com/api/docs/guides/batch) 来更轻松地提交和执行大量请求,且不会影响你的同步请求速率限制。
+如果你的用例不需要立即获得响应,可以使用 [Batch API](https://developers.openai.com/api/docs/guides/batch) 更轻松地提交和执行大量请求,而不会影响你的同步请求速率限制。
-对于需要 _同步_ 响应的用例,OpenAI API 对以下指标有单独的速率限制: **每分钟请求数** 和 **每分钟 token 数**.
+对于那些 _需要_ 同步响应的用例,OpenAI API 对 **每分钟请求数** 和 **每分钟 token 数**.
-如果你遇到了每分钟请求数的限制,但每分钟 token 数仍有可用容量,你可以通过将多个任务打包到每个请求中来提高吞吐量。这样你就可以处理更多的每分钟 token,尤其是在使用我们较小的模型时。
+如果你达到了每分钟请求数的上限,但每分钟 token 数仍有可用容量,你可以通过将多个任务合并到每个请求中来提高吞吐量。这样可以让你每分钟处理更多的 token,尤其是在使用我们较小的模型时效果更明显。
-发送一批提示与普通的 API 调用完全相同,只是你需要向 prompt 参数传入一个字符串列表,而不是单个字符串。 [在 Batch API 指南中了解更多信息](https://developers.openai.com/api/docs/guides/batch).
\ No newline at end of file
+批量发送提示与普通的 API 调用完全相同,只是你需要向 prompt 参数传入一个字符串列表,而不是单个字符串。 [详细了解 Batch API 指南](https://developers.openai.com/api/docs/guides/batch).
\ No newline at end of file
diff --git a/docs/zh/api/docs/guides/structured-outputs.md b/docs/zh/api/docs/guides/structured-outputs.md
index 6826e11..1e4e929 100644
--- a/docs/zh/api/docs/guides/structured-outputs.md
+++ b/docs/zh/api/docs/guides/structured-outputs.md
@@ -1,18 +1,18 @@
# 结构化模型输出
-> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。在页面 URL 末尾附加 `.md` 即可获取该页面的 Markdown 版本。
+> 如需完整文档索引,请参阅 [llms.txt](/llms.txt)。在页面 URL 末尾追加 `.md` 即可获取该页面的 Markdown 版本。
-JSON 是全球应用之间交换数据时使用最广泛的格式之一。
+JSON 是全球应用程序间数据交换最广泛使用的格式之一。
-Structured Outputs 是一项功能,可确保模型始终生成符合你提供的 [JSON Schema](https://json-schema.org/overview/what-is-jsonschema),因此你无需担心模型遗漏必需字段或生成无效的枚举值。
+Structured Outputs 是一项功能,可确保模型始终生成遵循你提供的 [JSON Schema](https://json-schema.org/overview/what-is-jsonschema),的响应,因此你无需担心模型遗漏必需字段,或生成无效的枚举值。
Structured Outputs 的一些优势包括:
-1. **可靠的类型安全:** 无需对格式不正确的响应进行校验或重试
-1. **明确的拒绝:** 基于安全考虑由模型产生的拒绝现在可以以编程方式检测
-1. **更简洁的提示:** 无需使用措辞强硬的提示来获得一致的输出格式
+1. **可靠的类型安全:** 无需验证或重试格式错误的响应
+1. **显式拒绝:** 基于安全模型的拒绝现在可以通过编程检测
+1. **更简洁的提示:** 无需使用强硬的提示词即可实现一致的格式化
-除了在 REST API 中支持 JSON Schema 外,OpenAI SDK 还支持 [Python](https://github.com/openai/openai-python/blob/main/helpers.md#structured-outputs-parsing-helpers) 和 [JavaScript](https://github.com/openai/openai-node/blob/master/helpers.md#structured-outputs-parsing-helpers) 分别使用 [Pydantic](https://docs.pydantic.dev/latest/) 和 [Zod](https://zod.dev/) 以便轻松地在代码中定义对象模式。下面,你可以看到如何从符合代码中定义的模式的非结构化文本中提取信息。
+除了在 REST API 中支持 JSON Schema 外,OpenAI 的 SDK 也支持 [Python](https://github.com/openai/openai-python/blob/main/helpers.md#structured-outputs-parsing-helpers) 和 [JavaScript](https://github.com/openai/openai-node/blob/master/helpers.md#structured-outputs-parsing-helpers) 它们也可以方便地使用 [Pydantic](https://docs.pydantic.dev/latest/) 和 [Zod](https://zod.dev/) 来定义对象 schema。下面,你可以看到如何从符合代码中定义的 schema 的非结构化文本中提取信息。
@@ -271,63 +271,63 @@ puts(response.output_text)
-### Supported models
+### 支持的模型
-结构化输出已在我们的 [最新大语言模型](https://developers.openai.com/api/docs/models),中提供,从 GPT-4o 开始。新项目请从 [`gpt-5.6`](https://developers.openai.com/api/docs/models/gpt-5.6-sol)。开始。较早的模型如 `gpt-4-turbo` 及更早版本可改用 [JSON 模式](#json-mode) 。
+结构化输出在我们最新的 [最新的大语言模型](https://developers.openai.com/api/docs/models),中可用,从 GPT-4o 开始。对于新项目,请使用 [`gpt-5.6`](https://developers.openai.com/api/docs/models/gpt-5.6-sol)。像 `gpt-4-turbo` 及更早的模型可以使用 [JSON 模式](#json-mode) 。
-何时通过函数调用与通过
+何时通过函数调用使用结构化输出,何时通过
text.format
-使用结构化输出:结构化输出在 OpenAI API 中有两种形式:
+结构化输出在 OpenAI API 中有两种形式:
-1. 使用 [函数调用](https://developers.openai.com/api/docs/guides/function-calling)
-2. 使用 `json_schema` 响应格式
+1. 当使用 [函数调用](https://developers.openai.com/api/docs/guides/function-calling)
+2. 当使用 `json_schema` 响应格式
-当你构建的应用需要在模型和你应用的功能之间搭建桥梁时,函数调用会很有用。
+当你构建的应用需要在模型和应用自身的功能之间架起桥梁时,函数调用会非常有用。
-例如,你可以让模型访问查询数据库的函数,从而构建一个能帮助用户处理订单的 AI 助手;也可以让它访问能够与 UI 交互的函数。
+例如,你可以让模型调用一些查询数据库的函数,从而构建一个能帮助用户处理订单的 AI 助手;也可以让它调用能够与 UI 交互的函数。
-反过来,通过 `response_format` 使用结构化输出更适合在你希望为模型响应用户时指定一个结构化模式,而不是在模型调用工具时使用。
+与之相对,结构化输出(通过 `response_format` 实现)更适合在你希望为模型回复用户时指定一个结构化 schema 的场景,而不是在模型调用工具时使用。
-例如,如果你正在构建一个数学辅导应用,你可能希望助手按照特定的 JSON Schema 回复用户,这样你就能生成一个 UI,以不同方式展示模型输出的各个部分。
+例如,如果你正在构建一个数学辅导应用,你可能希望助手以特定的 JSON Schema 来回复用户,从而能够生成相应的 UI,以不同方式展示模型输出的各个部分。
-简而言之:
+简单来说:
- - 如果你正在将模型连接到系统中的工具、函数、数据等,
- 那么你应该使用函数调用 - 如果你想在模型响应用户
- 时对其输出进行结构化处理,那么你应该使用结构化
+ - 如果你要把模型连接到你的系统中的工具、函数、数据等,那么你应该使用 function calling - 如果你想在模型响应用户时
+ 系统,那么你应该使用 function calling - 如果你想在模型响应用户时对其输出进行结构化处理,那么你应该使用结构化
+ 输出结构化处理,那么你应该使用结构化输出
`text.format`
- 本指南的其余部分将重点介绍非函数调用的用例,
- 即在 Responses API 中的用法。若要了解如何将结构化输出与
+ 本指南的其余部分将重点介绍以下场景中的非函数调用用例:
+ Responses API。要了解如何将结构化输出与
函数调用结合使用,请参阅
- [函数调用](https://developers.openai.com/api/docs/guides/function-calling#strict-mode)
+ [Function Calling](https://developers.openai.com/api/docs/guides/function-calling#strict-mode)
指南。
-### Structured Outputs vs JSON mode
+### Structured Outputs 与 JSON 模式对比
-Structured Outputs 是 [JSON 模式](#json-mode)。的演进。两者虽然都确保生成有效的 JSON,但只有 Structured Outputs 能确保符合模式。Structured Outputs 和 JSON 模式都在 Responses API、Chat Completions API、Assistants API、微调 API 和 Batch API 中受支持。
+Structured Outputs 是 [JSON 模式](#json-mode)。的演进。两者都能确保生成有效的 JSON,但只有 Structured Outputs 能确保遵循架构。Structured Outputs 和 JSON 模式都受 Responses API、Chat Completions API、Assistants API、Fine-tuning API 以及 Batch API 支持。
我们建议在可能的情况下始终使用 Structured Outputs 而不是 JSON 模式。
-但是,将 Structured Outputs 与 `response_format: {type: "json_schema", ...}` 结合使用时,仅在 `gpt-4o-mini`, `gpt-4o-mini-2024-07-18`,及以后的模型快照中受支持。 `gpt-4o-2024-08-06` model snapshots and later.
+然而,使用 `response_format: {type: "json_schema", ...}` 的 Structured Outputs 仅受 `gpt-4o-mini`, `gpt-4o-mini-2024-07-18`,支持, `gpt-4o-2024-08-06` 模型快照及更高版本。
@@ -335,8 +335,8 @@ Structured Outputs 是 [JSON 模式](#json-mode)。的演进。两者虽然都
| | 结构化输出 | JSON 模式 |
|--------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------|
| **输出有效的 JSON** | 是 | 是 |
-| **遵循架构** | 是(参见 [支持的架构](#supported-schemas)) | 否 |
-| **兼容模型** | `gpt-4o-mini`, `gpt-4o-2024-08-06`,以及更高版本 | `gpt-3.5-turbo`, `gpt-4-*`, `gpt-4o-*`,以及兼容的 GPT-5 模型 |
+| **遵循架构** | 是(请参阅 [支持的架构](#supported-schemas)) | 否 |
+| **兼容模型** | `gpt-4o-mini`, `gpt-4o-2024-08-06`及更高版本 | `gpt-3.5-turbo`, `gpt-4-*`, `gpt-4o-*`及兼容的 GPT-5 模型 |
| **启用** | `text: { format: { type: "json_schema", "strict": true, "schema": ... } }` | `text: { format: { type: "json_object" } }` |
@@ -344,18 +344,18 @@ Structured Outputs 是 [JSON 模式](#json-mode)。的演进。两者虽然都
-思维链
+思路链
-### 思维链
+### Chain of thought
-你可以要求模型以结构化、循序渐进的方式输出答案,引导用户完成求解过程。
+你可以要求模型以结构化的、循序渐进的方式输出答案,引导用户完成解决方案。
- 面向链式思考数学辅导的结构化输出
+ 用于数学辅导思路链的结构化输出
```javascript
import OpenAI from "openai";
@@ -701,7 +701,7 @@ curl https://api.openai.com/v1/responses \
-#### 响应示例
+#### 示例响应
```json
{
@@ -743,7 +743,7 @@ curl https://api.openai.com/v1/responses \
### 结构化数据提取
-你可以定义结构化字段,从研究论文等非结构化输入数据中提取信息。
+你可以定义结构化字段,用于从非结构化输入数据(例如研究论文)中提取信息。
@@ -1091,7 +1091,7 @@ curl https://api.openai.com/v1/responses \
-#### 响应示例
+#### 示例响应
```json
{
@@ -1119,14 +1119,14 @@ UI 生成
-### UI 生成
+### UI Generation
-你可以通过将 HTML 表示为带约束的递归数据结构(如枚举)来生成合法的 HTML。
+你可以通过使用带约束的递归数据结构(例如枚举)来表示 HTML,从而生成合法的 HTML。
- 使用 Structured Outputs 生成 HTML
+ 使用结构化输出生成 HTML
```javascript
import OpenAI from "openai";
@@ -1541,7 +1541,7 @@ curl https://api.openai.com/v1/responses \
-#### 响应示例
+#### 示例响应
```json
{
@@ -1624,18 +1624,18 @@ curl https://api.openai.com/v1/responses \
-审核
+Moderation
-### 审核
+### Moderation
-你可以对输入进行多类别分类,这是一种常见的审核方式。
+你可以对输入按多个类别进行分类,这是常见的审核方式。
- 使用 Structured Outputs 进行审核
+ 使用结构化输出进行审核
```javascript
import OpenAI from "openai";
@@ -1972,7 +1972,7 @@ curl https://api.openai.com/v1/responses \
-#### 响应示例
+#### 示例响应
```json
{
@@ -1989,27 +1989,27 @@ curl https://api.openai.com/v1/responses \
-如何将 Structured Outputs 与
+如何将结构化输出与
text.format
-## 第 1 步:定义你的架构
+## 步骤 1:定义你的架构
-首先,你需要设计模型应当遵循的 JSON Schema。请参阅本指南开头的 [示例](https://developers.openai.com/api/docs/guides/structured-outputs#examples) 以供参考。
+首先,你需要设计模型应遵守的 JSON Schema。参见本文档开头的 [示例](https://developers.openai.com/api/docs/guides/structured-outputs#examples) 以供参考。
-虽然 Structured Outputs 支持大部分 JSON Schema,但由于性能或技术原因,某些功能不可用。详见 [此处](https://developers.openai.com/api/docs/guides/structured-outputs#supported-schemas) 以了解详细信息。
+虽然 Structured Outputs 支持大部分 JSON Schema,但由于性能或技术原因,某些功能不可用。详见 [此处](https://developers.openai.com/api/docs/guides/structured-outputs#supported-schemas) 了解详细信息。
-#### JSON Schema 使用技巧
+#### JSON Schema 使用提示
-为了最大化模型生成的质量,我们建议如下做法:
+为了最大化模型生成的质量,我们建议遵循以下做法:
-- 清晰、直观地命名键
+- 清晰且直观地命名键
- 为结构中的重要键创建清晰的标题和描述
-- 创建并使用 evals 来确定最适合你用例的结构
+- 创建并使用评估来确定最适合你用例的结构
@@ -2017,7 +2017,7 @@ text.format
-## 第 2 步:在 API 调用中提供你的 schema
+## 第 2 步:在 API 调用中提供你的架构
@@ -2394,7 +2394,7 @@ curl https://api.openai.com/v1/responses \
-**注意:** 你针对任何架构发出的首个请求会有额外的延迟,因为我们的API需要处理该架构,但使用相同架构的后续请求不会再有额外的延迟。
+**注意:** 你使用任何 schema 发出的首次请求都会产生额外的延迟,因为我们的 API 需要处理该 schema,但使用同一 schema 的后续请求不会再产生额外的延迟。
@@ -2402,15 +2402,15 @@ curl https://api.openai.com/v1/responses \
-## 步骤 3:处理边界情况
+## 第 3 步:处理边界情况
-在某些情况下,模型可能不会生成与你提供的 JSON 模式匹配的有效响应。
+在某些情况下,模型可能不会生成与所提供 JSON schema 匹配的有效响应。
-这种情况可能发生在模型因安全原因拒绝回答时,或者例如你达到了 max tokens 限制导致响应不完整时。
+这种情况可能发生在模型因安全原因拒绝回答时,或者例如你达到了 max tokens 上限导致响应不完整时。
@@ -2863,13 +2863,13 @@ end
-结构化输出中的拒绝
+结构化输出的拒绝情况
-当在用户生成的输入上使用结构化输出时,OpenAI 模型有时可能出于安全原因拒绝完成请求。由于拒绝响应不一定遵循你所提供的模式,因此 `response_format`,API 响应将包含一个名为 `refusal` 的字段,用于表明模型拒绝了该请求。
+当对用户生成的输入使用结构化输出时,OpenAI 模型有时可能因安全原因拒绝执行请求。由于拒绝不一定遵循你在 `response_format`,中提供的 schema,API 响应中将包含一个新字段 `refusal` ,用于表明模型拒绝执行请求。
-当 `refusal` 属性出现在你的输出对象中时,你可以在 UI 中展示该拒绝信息,或在使用该响应的代码中加入条件逻辑来处理请求被拒绝的情况。
+当 `refusal` 属性出现在你的输出对象中时,你可以在 UI 中展示该拒绝信息,或者在消费响应的代码中加入条件逻辑以处理请求被拒绝的情况。
@@ -3220,7 +3220,7 @@ end
-拒绝情况下的 API 响应大致如下所示:
+拒绝时 API 的响应大致如下:
@@ -3269,34 +3269,34 @@ end
-#### 处理用户生成的输入
+#### 处理用户输入
-如果你的应用使用的是用户生成的输入,请在提示中加入相关说明,告知当输入无法产生有效响应时该如何处理。
+如果你的应用使用了用户生成输入,请确保提示中包含相关说明,以处理输入无法产生有效响应的情况。
-模型会始终尝试遵循所提供的 schema,如果输入与 schema 完全无关,可能会产生幻觉。
+模型会始终尝试遵循所提供的 schema,如果输入与 schema 完全无关,可能会产生幻觉。
-你可以在提示中加入语言,明确说明当模型检测到输入与任务不兼容时,希望返回空参数或返回指定的句子。
+你可以在提示中加入相应措辞,指定当模型检测到输入与任务不兼容时,应返回空参数或返回某个特定句子。
#### 处理错误
-结构化输出仍可能包含错误。如果你发现了错误,可以尝试调整你的指令、在系统指令中提供示例,或将任务拆分为更简单的子任务。请参阅 [提示工程指南](https://developers.openai.com/api/docs/guides/prompt-engineering) ,获取更多关于如何调整输入的指导。
+结构化输出仍可能出现错误。如果你发现错误,可以尝试调整你的指令、在系统指令中提供示例,或将任务拆分为更简单的子任务。请参阅 [提示工程指南](https://developers.openai.com/api/docs/guides/prompt-engineering) 以获取有关如何调整输入的更多指导。
#### 避免 JSON schema 出现分歧
-为了防止你的 JSON Schema 与编程语言中对应的类型发生偏离,我们强烈建议使用原生的 Pydantic/zod sdk 支持。
+为了防止你的 JSON Schema 与编程语言中的对应类型出现分歧,我们强烈建议使用 Pydantic/zod 开发工具包 的原生支持。
-如果你倾向于直接指定 JSON schema,可以添加 CI 规则,在 JSON schema 或底层数据对象被修改时发出标记,或者添加一个 CI 步骤,从类型定义自动生成 JSON Schema(反之亦可)。
+如果你更倾向于直接指定 JSON schema,可以添加 CI 规则,在编辑 JSON schema 或底层数据对象时进行标记,或者添加一个 CI 步骤,从类型定义自动生成 JSON Schema(反之亦然)。
## 流式传输
-你可以使用流式输出来处理模型响应或函数调用参数,边生成边解析为结构化数据。
+你可以使用流式传输来处理模型响应或函数调用参数,在它们生成的同时将其解析为结构化数据。
-这样,你就不必等到整个响应完成后再进行处理。
-如果你希望逐个显示 JSON 字段,或在函数调用参数一可用时就立刻处理它们,这尤其有用。
+这样,你就不必等待整个响应完成后再进行处理。
+如果你希望逐个显示 JSON 字段,或在函数调用参数可用时立即处理它们,这一点尤其有用。
-我们建议依赖 SDK 来处理带结构化输出的流式输出。
+我们建议依赖 SDK 来处理结构化输出场景下的流式传输。
@@ -3470,13 +3470,60 @@ try (StreamResponse stream = client.responses().createStrea
}
```
+```ruby
+require "openai"
+
+client = OpenAI::Client.new
+entities_schema = {
+ type: :object,
+ properties: {
+ attributes: {type: :array, items: {type: :string}},
+ colors: {type: :array, items: {type: :string}},
+ animals: {type: :array, items: {type: :string}}
+ },
+ required: %w[attributes colors animals],
+ additionalProperties: false
+}
+
+stream = client.responses.stream(
+ model: "gpt-5.6",
+ input: [
+ {role: :system, content: "Extract entities from the input text."},
+ {
+ role: :user,
+ content: "The quick brown fox jumps over the lazy dog with piercing blue eyes."
+ }
+ ],
+ text: {
+ format: {
+ type: :json_schema,
+ name: "entities",
+ strict: true,
+ schema: entities_schema
+ }
+ }
+)
+
+stream.each do |event|
+ case event
+ when OpenAI::Models::Responses::ResponseRefusalDeltaEvent,
+ OpenAI::Models::Responses::ResponseTextDeltaEvent
+ print(event.delta)
+ when OpenAI::Models::Responses::ResponseErrorEvent
+ warn(event.message)
+ when OpenAI::Models::Responses::ResponseCompletedEvent
+ puts("\nCompleted")
+ end
+end
+```
+
-## 支持的架构
+## 支持的模式
-Structured Outputs 支持该语言的部分 [JSON Schema](https://json-schema.org/docs) 特性。
+Structured Outputs 支持以下语言的子集: [JSON Schema](https://json-schema.org/docs) 语言。
#### 支持的类型
@@ -3493,7 +3540,7 @@ Structured Outputs 支持以下类型:
#### 支持的属性
-除了指定属性的类型外,你还可以指定一系列额外的约束:
+除了指定属性的类型之外,你还可以指定一些额外的约束条件:
**支持的 `string` 属性:**
@@ -3511,18 +3558,18 @@ Structured Outputs 支持以下类型:
**支持的 `number` 属性:**
-- `multipleOf` — 该数字必须是此值的倍数。
-- `maximum` — 该数字必须小于或等于此值。
-- `exclusiveMaximum` — 该数字必须小于此值。
-- `minimum` — 该数字必须大于或等于此值。
-- `exclusiveMinimum` — 该数字必须大于此值。
+- `multipleOf` — 数字必须为此值的倍数。
+- `maximum` — 数字必须小于或等于此值。
+- `exclusiveMaximum` — 数字必须小于此值。
+- `minimum` — 数字必须大于或等于此值。
+- `exclusiveMinimum` — 数字必须大于此值。
**支持的 `array` 属性:**
-- `minItems` — 数组至少必须包含此数量的项。
-- `maxItems` — 数组最多只能包含此数量的项。
+- `minItems` — 数组必须至少包含这么多项。
+- `maxItems` — 数组最多只能包含这么多项。
-以下是一些有关如何使用这些类型限制的示例:
+以下是一些关于如何使用这些类型限制的示例:
@@ -3604,12 +3651,12 @@ Structured Outputs 支持以下类型:
-请注意,这些约束目前尚不支持 [微调的
+请注意,这些限制 [尚不支持微调
模型](#some-type-specific-keywords-are-not-yet-supported).
-#### 根对象不能是 `anyOf` ,并且必须是对象
+#### 根对象不能是 `anyOf` ,且必须是对象
-请注意,schema 的根级对象必须是一个对象,而不能使用 `anyOf`。Zod 中的一种模式(例如)是使用 discriminated union,这会生成一个 `anyOf` 作为顶层结构。因此类似下面的代码无法正常工作:
+请注意,schema 的根级对象必须是 object 类型,不能使用 `anyOf`。Zod 中存在这样一种模式(举例而言):使用 discriminated union,这会在顶层产生一个 `anyOf` 。因此类似下面的代码是无法使用的:
```javascript
import { z } from "zod";
@@ -3632,9 +3679,9 @@ const json = zodResponseFormat(finalSchema, "final_schema");
```
-#### 所有字段必须为 `required`
+#### 所有字段必须 `required`
-要使用结构化输出,所有字段或函数参数都必须指定为 `required`.
+要使用 Structured Outputs,所有字段或函数参数都必须指定为 `required`.
```json
{
@@ -3663,7 +3710,7 @@ const json = zodResponseFormat(finalSchema, "final_schema");
```
-虽然所有字段都必须是必需的(并且模型将为每个参数返回一个值),但可以通过使用联合类型并配合 `null`.
+虽然所有字段都必须是必需的(并且模型将为每个参数返回值),但可以通过使用联合类型来模拟可选参数, `null`.
```json
{
@@ -3696,21 +3743,21 @@ const json = zodResponseFormat(finalSchema, "final_schema");
#### 对象对嵌套深度和大小有限制
-一个 schema 最多可包含 5000 个对象属性,嵌套层级最多为 10 层。
+一个 schema 最多可以包含 5000 个对象属性,嵌套层级最多 10 层。
-#### 总字符串大小限制
+#### Limitations on total string size
-在 schema 中,所有属性名、定义名、枚举值和常量值的字符串总长度不能超过 120,000 个字符。
+在 schema 中,所有属性名、定义名、枚举值和 const 值的字符串总长度不得超过 120,000 个字符。
#### 枚举大小的限制
一个 schema 在所有枚举属性中最多可包含 1000 个枚举值。
-对于具有字符串值的单个枚举属性,当枚举值数量超过 250 个时,所有枚举值的字符串总长度不得超过 15000 个字符。
+对于具有字符串值的单个枚举属性,当枚举值超过 250 个时,所有枚举值的字符串总长度不能超过 15,000 个字符。
-#### `additionalProperties: false` 必须在对象中设置
+#### `additionalProperties: false` 必须在对象中始终设置
-`additionalProperties` 控制是否允许对象包含未在 JSON Schema 中定义的其他键 / 值。
+`additionalProperties` 控制对象是否可以包含 JSON Schema 中未定义的其他键 / 值。
Structured Outputs 仅支持生成指定的键 / 值,因此我们要求开发者设置 `additionalProperties: false` 以启用 Structured Outputs。
@@ -3743,26 +3790,26 @@ Structured Outputs 仅支持生成指定的键 / 值,因此我们要求开发
```
-#### 键排序
+#### 键的排序
-使用结构化输出时,输出将按照模式中键的顺序依次生成。
+在使用结构化输出时,输出会按照 schema 中键的顺序依次生成。
-#### 某些类型专属的关键字尚不受支持
+#### 部分特定类型的关键词暂不支持
- **组合:** `allOf`, `not`, `dependentRequired`, `dependentSchemas`, `if`, `then`, `else`
-对于微调模型,我们另外不支持以下内容:
+对于微调模型,我们同样不支持以下功能:
-- **对于字符串:** `minLength`, `maxLength`, `pattern`, `format`
-- **对于数字:** `minimum`, `maximum`, `multipleOf`
-- **对于对象:** `patternProperties`
-- **对于数组:** `minItems`, `maxItems`
+- **字符串:** `minLength`, `maxLength`, `pattern`, `format`
+- **数字:** `minimum`, `maximum`, `multipleOf`
+- **对象:** `patternProperties`
+- **数组:** `minItems`, `maxItems`
-如果通过提供 `strict: true` 并使用不受支持的 JSON Schema 调用 API,你将收到一个错误。
+如果你通过提供 `strict: true` 并使用不支持的 JSON Schema 调用 API,则会收到错误。
-#### 针对 `anyOf`,嵌套的 schema 必须各自符合该子集所规定的有效 JSON Schema
+#### 对于 `anyOf`,每个嵌套模式必须是符合此子集的合法 JSON Schema
-以下是一个受支持的 anyOf 模式示例:
+以下是一个受支持的 anyOf 架构示例:
```json
{
@@ -3826,7 +3873,7 @@ Structured Outputs 仅支持生成指定的键 / 值,因此我们要求开发
#### 支持定义
-你可以使用定义(definition)来定义 schema 中被各处引用的子 schema。以下是一个简单的示例。
+你可以使用 definitions 来定义在 schema 中被多次引用的子 schema。以下是一个简单的示例。
```json
{
@@ -3869,9 +3916,9 @@ Structured Outputs 仅支持生成指定的键 / 值,因此我们要求开发
```
-#### 支持递归 schema
+#### 支持递归架构
-使用以下方式表示的示例递归架构 `#` 以表示根级递归。
+使用以下结构的示例递归 schema `#` 以指示根级递归。
```json
{
@@ -3970,24 +4017,24 @@ Structured Outputs 仅支持生成指定的键 / 值,因此我们要求开发
## JSON mode
-JSON 模式是结构化输出功能的一个更基础版本。
- JSON 模式确保模型输出是合法的 JSON,而结构化输出则可靠地
- 将模型输出与你指定的模式进行匹配。我们建议你在
- 用例受支持的情况下使用结构化输出。
+JSON 模式是 Structured Outputs 功能的基础版本。虽然
+ JSON 模式可确保模型输出是合法 JSON,但 Structured Outputs 能可靠地
+ 将模型的输出与你指定的 schema 进行匹配。如果你的用例支持
+ Structured Outputs,建议你使用它。
-开启 JSON 模式后,模型的输出会被确保为合法的 JSON,但存在一些边界情况需要你自行检测并妥善处理。
+启用 JSON 模式后,模型的输出会被确保为合法 JSON,但某些边界情况除外,你需要自行检测并妥善处理。
-要使用 Responses API 开启 JSON 模式,你可以设置 `text.format` 为 `{ "type": "json_object" }`。如果你正在使用函数调用,JSON 模式会始终处于开启状态。
+要使用 Responses API 启用 JSON 模式,你可以设置 `text.format` 为 `{ "type": "json_object" }`。如果你使用的是函数调用功能,JSON 模式始终处于启用状态。
重要提示:
-- 使用 JSON 模式时,你必须始终通过对话中的某条消息(例如系统消息)指示模型输出 JSON。如果没有包含明确的 JSON 输出指令,模型可能会生成无止境的空白字符流,并且请求会一直运行,直到达到 token 上限。为帮助你避免遗漏,API 会在上下文中未出现字符串 "JSON" 时抛出错误。
-- JSON 模式不会保证输出匹配任何特定的 schema,只能保证它是有效的且解析时不报错。你应该使用结构化输出(Structured Outputs)来确保它匹配你的 schema;如果无法做到,则应使用校验库并结合必要的重试来确保输出符合预期的 schema。
-- 你的应用必须检测并处理模型输出不是完整 JSON 对象的边缘情况(见下文)。
+- 使用 JSON 模式时,你必须始终通过对话中的某条消息(例如系统消息)指示模型输出 JSON。如果不包含生成 JSON 的明确指令,模型可能会生成无止境的空白字符,请求会持续运行直至达到 token 上限。为了避免你忘记,API 会在上下文中任何位置都没有出现字符串 "JSON" 时抛出错误。
+- JSON 模式不会保证输出符合任何特定 schema,只会保证它是有效的并能无误地解析。你应该使用 Structured Outputs 来确保其符合你的 schema;如果无法做到,则应使用校验库并结合必要的重试来确保输出符合所需的 schema。
+- 你的应用必须检测并处理可能导致模型输出不是完整 JSON 对象的边界情况(见下文)。
@@ -4328,7 +4375,7 @@ end
## 资源
-要了解更多关于结构化输出的信息,我们推荐浏览以下资源:
+如需详细了解结构化输出,我们建议你浏览以下资源:
-- 查看我们的 [入门 Cookbook](https://developers.openai.com/cookbook/examples/structured_outputs_intro) ,了解结构化输出
-- 了解 [如何构建多智能体系统](https://developers.openai.com/cookbook/examples/structured_outputs_multi_agent) ,并结合结构化输出
\ No newline at end of file
+- 查看我们的 [结构化输出入门指南](https://developers.openai.com/cookbook/examples/structured_outputs_intro) 结构化输出入门指南
+- 了解 [如何使用结构化输出构建多智能体系统](https://developers.openai.com/cookbook/examples/structured_outputs_multi_agent) 使用结构化输出
\ No newline at end of file
diff --git a/docs/zh/api/docs/guides/workload-identity-federation/x509.md b/docs/zh/api/docs/guides/workload-identity-federation/x509.md
index 07cf7ed..c736c08 100644
--- a/docs/zh/api/docs/guides/workload-identity-federation/x509.md
+++ b/docs/zh/api/docs/guides/workload-identity-federation/x509.md
@@ -1,26 +1,26 @@
# 使用 X.509 证书配置工作负载身份联合
-> 完整文档索引请参阅 [llms.txt](/llms.txt)。在页面 URL 末尾附加 `.md` 即可获取该页面的 Markdown 版本。
+> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。如需获取 Markdown 版本的文档页面,可在页面 URL 末尾附加 `.md` 。
-X.509 工作负载身份联合让工作负载能够将 TLS 客户端证书中的身份交换为短期 OpenAI 访问令牌。然后,工作负载会同时携带该访问令牌和一份已接受的客户端证书调用 OpenAI API。此流程替代的是 API 密钥,而不是客户端证书。
+X.509 工作负载身份联合让工作负载可以将 TLS 客户端证书中的身份交换为短时效的 OpenAI 访问令牌。随后,工作负载会同时使用该访问令牌和已接受的客户端证书调用 OpenAI API。此流程替换的是 API 密钥,而非客户端证书。
-X.509 工作负载身份联合可用于 OpenAI API。Codex 不支持该功能。
- 对于 Codex,请改用 OIDC 令牌或 SPIFFE JWT-SVID,并参考
+X.509 工作负载身份联合可用于 OpenAI API。Codex 不
+ 支持该功能。对于 Codex,请使用 OIDC 令牌或 SPIFFE JWT-SVID,并参阅
[Codex 工作负载身份指南](https://developers.openai.com/codex/enterprise/workload-identity).
-如需了解令牌交换的请求和响应详情,请参阅 [工作负载身份令牌交换参考](https://developers.openai.com/api/reference/workload-identity-federation#exchange-an-x509-certificate)。关于 Mutual TLS 权限、证书要求、激活方式、mTLS 主机以及证书轮换,请参阅 [Mutual TLS 指南](https://developers.openai.com/api/docs/guides/mutual-tls).
+有关令牌交换请求和响应的详细信息,请参阅 [工作负载身份令牌交换参考](https://developers.openai.com/api/reference/workload-identity-federation#exchange-an-x509-certificate)。有关 Mutual TLS 权限、证书要求、激活、mTLS 主机和轮换的信息,请参阅 [Mutual TLS 指南](https://developers.openai.com/api/docs/guides/mutual-tls).
## 工作原理
X.509 工作负载身份交换包含五个部分:
-1. 你的组织在其现有的 Mutual TLS 设置中上传并激活一个受信根证书。
-2. X.509 工作负载身份提供方从已验证的客户端证书中派生 `openai.*` 属性。它必须派生出一个非空的 `openai.subject` 值。
-3. 服务账号映射会在一个项目中授予派生身份使用一个 OpenAI 服务账号的权限。
-4. 工作负载向 X.509 令牌端点出示其证书, `mtls.auth.openai.com` 并请求一个短期 bearer 令牌。证书来自 TLS 连接;请求体中不包含 `subject_token`.
-5. 工作负载将 bearer 令牌和客户端证书出示给 API 路由上的 `mtls.api.openai.com` 用于 API 授权。
+1. 你的组织在其现有的 Mutual TLS 设置中上传并激活一个受信任的根证书。
+2. X.509 工作负载身份提供方派生 `openai.*` 来自已验证客户端证书的属性。它必须派生出一个非空 `openai.subject` 值。
+3. 服务账号映射授权该派生身份在项目内使用一个 OpenAI 服务账号。
+4. 工作负载在 `mtls.auth.openai.com` 上的 X.509 令牌端点出示其证书并请求一个短时效的 bearer 令牌。该证书来自 TLS 连接;请求体不包含 `subject_token`.
+5. 工作负载在 API 路由上向 `mtls.api.openai.com` 出示 bearer 令牌和客户端证书以进行 API 授权。
-Bearer 令牌和证书会在 API 请求中独立进行授权。仅凭证书无法授权对 OpenAI API 的调用。
+Bearer 令牌和证书会在 API 请求中各自独立进行授权。仅凭证书无法授权对 OpenAI API 的调用。
## 准备工作
@@ -28,35 +28,35 @@ Bearer 令牌和证书会在 API 请求中独立进行授权。仅凭证书无
- 管理组织 Mutual TLS 证书和工作负载身份提供商的权限。
- 工作负载对应的项目和服务账号。
-- 客户端证书、其私钥,以及构建到受信根证书的证书链所需的任何中间证书。
-- 在组织或项目级别处于生效状态的受信根证书。
+- 客户端证书、私钥,以及构建到受信根证书路径所需的任何中间证书。
+- 在组织或项目级别处于有效状态的受信根证书。
-将私钥排除在源代码控制之外,并限制能访问这些私钥的工作负载的权限。不要记录私钥、证书内容或返回的访问令牌。
+将私钥排除在源代码管理之外,并仅限使用它们的工作负载访问。不要记录私钥、证书内容或返回的访问令牌。
## 配置 Mutual TLS 证书信任
-X.509 Workload Identity Providers 会复用你组织现有的 Mutual TLS 证书配置。它们不会上传证书,也不会维护单独的证书信任库。
+X.509 Workload Identity Providers 复用你组织现有的 Mutual TLS 证书配置。它们不上传证书,也不维护单独的证书信任库。
-请按照 [Mutual TLS 指南](https://developers.openai.com/api/docs/guides/mutual-tls) 查阅证书
-要求、mTLS 主机、证书激活行为、CEL 过滤器以及
+请按照 [Mutual TLS 指南](https://developers.openai.com/api/docs/guides/mutual-tls) 来查看证书
+要求、mTLS 主机、证书激活行为、CEL 过滤器,以及
客户端配置。然后打开 [Organization settings > Security > Mutual
-TLS](https://platform.openai.com/settings/organization/security/mtls),上传
-PEM 格式的可信证书,并为该组织或
-每个将使用 X.509 workload identity federation 的项目激活该证书。
+TLS](https://platform.openai.com/settings/organization/security/mtls),上传
+PEM 格式的可信证书,并针对组织或
+将使用 X.509 workload identity federation 的每个项目激活它。
-如果你的客户端证书通过中间证书进行链式信任,请配置稳定的信任锚点,并在 TLS 握手期间按顺序出示叶证书和当前的中间证书。OpenAI 使用请求中提供的中间证书,不会从证书 URL 中检索缺失的中间证书。
+如果你的客户端证书通过中间证书进行链式验证,请配置稳定的信任锚点,并在 TLS 握手期间依次提供叶证书和当前的中间证书。OpenAI 使用请求中提供的中间证书,不会从证书 URL 检索缺失的中间证书。
## 配置 X.509 提供方
-配置 X.509 提供程序的步骤如下:
+配置 X.509 提供方:
1. 打开 [Organization settings > Security > Workload Identity Provider](https://platform.openai.com/settings/organization/security/workload-identity-provider),然后选择 **Create identity provider**.
-2. 选择 **X.509** 作为 **Provider type**,然后输入名称和可选的描述。X.509 提供方不使用 OIDC 颁发者、受众、发现或 JWKS 设置。创建后无法更改提供方类型。
-3. 在 **Advanced**,下,可选择添加一个 **Attribute conditions** CEL 表达式,以在映射解析之前拒绝证书。
-4. 在 **Attribute transformations**,为所需的转换输入一个非空表达式。当你在 `openai.subject` 转换时选择 X.509,控制台会自动添加 `subject` 行,并显示和应用该 `openai.` 前缀。请选择一个用于标识工作负载的稳定证书事实。
-5. 可选择使用其他唯一 `openai.*` 名称,然后选择 **创建**.
+2. 选择 **X.509** 作为 **Provider type**,然后输入名称和可选的描述。X.509 提供程序不使用 OIDC issuer、audience、discovery 或 JWKS 设置。创建后无法更改提供程序类型。
+3. 在 **Advanced**,下,可选择添加一个 **Attribute conditions** CEL 表达式,以便在映射解析之前拒绝证书。
+4. 在 **Attribute transformations**,为所需的 `openai.subject` 转换输入一个非空表达式。当你在选择 X.509 时,控制台会添加 `subject` 行,并显示和应用 `openai.` 前缀。选择一个用于标识工作负载的稳定证书事实。
+5. 可选择使用其他唯一的 `openai.*` 名称,然后选择 **创建**.
-例如,以下配置将证书公用名用作规范主体,并将组织单位作为附加映射属性公开:
+例如,以下配置使用证书通用名作为规范主体,并将组织单位作为额外的映射属性公开:
```json
[
@@ -71,9 +71,9 @@ PEM 格式的可信证书,并为该组织或
]
```
-证书事实可在 `assertion.subject` 和 `assertion.subject_alt_names`。中找到。用于映射的转换结果必须是标量值。额外的转换必须具有唯一的 `openai.*` 名称。
+证书相关信息可在 `assertion.subject` 下找到 `assertion.subject_alt_names`。用于映射的转换结果必须是标量值。其他转换必须具有唯一的 `openai.*` 名称。
-例如,一个 **属性条件** 表达式可以将提供程序限制为生产证书:
+例如,使用 **属性条件** 表达式可以将该提供程序限制为生产环境证书:
```text
assertion.subject.organizational_unit == "Production"
@@ -81,24 +81,24 @@ assertion.subject.organizational_unit == "Production"
## 创建服务账号映射
-1. 在 X.509 提供方详情页中,选择 **创建映射**.
-2. 选择目标项目和API,并仅授予该工作负载所需的接口权限。
-3. 在 **Key** 和 **Value** 字段中,需要精确的 `openai.subject` 值。X.509 映射支持不使用断言(表示为空对象(`{}`),或使用键以 `openai.`.
+1. 在 X.509 提供方详情页面,选择 **Create mapping**.
+2. 选择目标项目和 service account,仅授予工作负载所需的API 权限。
+3. 在 **Key** 和 **Value** 字段中,要求精确的 `openai.subject` value。X.509 映射支持不包含任何断言,用空对象表示(`{}`),或者支持键以 `openai.`.
4. 选择 **创建**.
例如:
-| Key | Value |
+| 键 | 值 |
| ---------------- | ----------------------- |
| `openai.subject` | `payments-service-prod` |
-X.509 映射使用的是派生 `openai.*` 属性,它们不会匹配原始 JWT 声明,例如 `sub`, `iss`,或 `aud`.
+X.509 映射使用的是派生的 `openai.*` 属性。它们不会匹配原始 JWT 声明,例如 `sub`, `iss`,或 `aud`.
-提供商列表会显示提供商 ID,映射详情会显示所选的服务账号及其服务账号 ID。请同时记录这两个标识符,工作负载会在令牌交换时使用它们。
+提供方列表会显示提供方 ID,映射详情会显示所选服务账号及其服务账号 ID。请同时记录这两个标识符;工作负载在令牌交换时会一并发送。
-## 将证书兑换为访问令牌
+## 将 X.509 工作负载身份用于 SDK
-为证书链、私钥、提供方和服务账号设置环境变量:
+为证书链、私钥、提供方和服务账户设置环境变量:
```bash
export OPENAI_MTLS_CERT_CHAIN="/path/to/client-chain.pem"
@@ -107,7 +107,265 @@ export OPENAI_IDENTITY_PROVIDER_ID="idp_example"
export OPENAI_SERVICE_ACCOUNT_ID="svc_acct_example"
```
-证书链文件应先包含叶证书,后跟所有中间证书。不要在请求体中包含证书材料或 a `subject_token` 。
+证书链文件应首先包含叶子证书,然后是任何中间证书。不要在请求正文中包含证书材料或 a `subject_token` 。
+
+使用这些值配置 OpenAI SDK 客户端。该 SDK 在令牌交换和 API 请求期间出示客户端证书,将 API 请求路由到 mTLS 端点,并自动续期短期访问令牌。
+
+使用 X.509 客户端证书进行身份验证
+
+```javascript
+import { readFile } from "node:fs/promises";
+
+import OpenAI from "openai";
+import { workloadIdentity } from "openai/auth/x509-transport";
+
+const certificatePath = process.env.OPENAI_MTLS_CERT_CHAIN;
+const privateKeyPath = process.env.OPENAI_MTLS_KEY;
+const identityProviderId = process.env.OPENAI_IDENTITY_PROVIDER_ID;
+const serviceAccountId = process.env.OPENAI_SERVICE_ACCOUNT_ID;
+
+if (
+ !certificatePath ||
+ !privateKeyPath ||
+ !identityProviderId ||
+ !serviceAccountId
+) {
+ throw new Error(
+ "Set OPENAI_MTLS_CERT_CHAIN, OPENAI_MTLS_KEY, OPENAI_IDENTITY_PROVIDER_ID, and OPENAI_SERVICE_ACCOUNT_ID"
+ );
+}
+
+const credential = workloadIdentity.fromX509({
+ certificateChain: await readFile(certificatePath, "utf8"),
+ privateKey: await readFile(privateKeyPath, "utf8"),
+ identityProviderId,
+ serviceAccountId,
+});
+
+try {
+ const client = new OpenAI({ credential });
+ const response = await client.responses.create({
+ model: "gpt-5.6-terra",
+ input: "Say hello from X.509 workload identity federation.",
+ });
+
+ console.log(response.output_text);
+} finally {
+ await credential.close();
+}
+```
+
+```python
+import os
+import ssl
+
+from openai import DefaultHttpx2Client, OpenAI
+from openai.auth import x509_workload_identity
+
+tls_context = ssl.create_default_context()
+tls_context.load_cert_chain(
+ certfile=os.environ["OPENAI_MTLS_CERT_CHAIN"],
+ keyfile=os.environ["OPENAI_MTLS_KEY"],
+)
+
+with OpenAI(
+ base_url="https://mtls.api.openai.com/v1",
+ workload_identity=x509_workload_identity(
+ identity_provider_id=os.environ["OPENAI_IDENTITY_PROVIDER_ID"],
+ service_account_id=os.environ["OPENAI_SERVICE_ACCOUNT_ID"],
+ ),
+ http_client=DefaultHttpx2Client(verify=tls_context, follow_redirects=False),
+) as client:
+ response = client.responses.create(
+ model="gpt-5.6-terra",
+ input="Say hello from X.509 workload identity federation.",
+ )
+
+ print(response.output_text)
+```
+
+```go
+package main
+
+import (
+ "context"
+ "crypto/tls"
+ "fmt"
+ "log"
+ "net/http"
+ "os"
+
+ "github.com/openai/openai-go/v3"
+ "github.com/openai/openai-go/v3/auth"
+ "github.com/openai/openai-go/v3/option"
+ "github.com/openai/openai-go/v3/responses"
+)
+
+func main() {
+ certificate, err := tls.LoadX509KeyPair(
+ os.Getenv("OPENAI_MTLS_CERT_CHAIN"),
+ os.Getenv("OPENAI_MTLS_KEY"),
+ )
+ if err != nil {
+ log.Fatal(err)
+ }
+
+ transport, err := auth.NewX509Transport(&http.Transport{
+ TLSClientConfig: &tls.Config{
+ Certificates: []tls.Certificate{certificate},
+ MinVersion: tls.VersionTLS12,
+ },
+ })
+ if err != nil {
+ log.Fatal(err)
+ }
+ defer transport.Close()
+
+ client := openai.NewClient(
+ option.WithX509WorkloadIdentity(auth.X509WorkloadIdentity{
+ IdentityProviderID: os.Getenv("OPENAI_IDENTITY_PROVIDER_ID"),
+ ServiceAccountID: os.Getenv("OPENAI_SERVICE_ACCOUNT_ID"),
+ Transport: transport,
+ }),
+ )
+
+ response, err := client.Responses.New(context.Background(), responses.ResponseNewParams{
+ Model: "gpt-5.6-terra",
+ Input: responses.ResponseNewParamsInputUnion{
+ OfString: openai.String("Say hello from X.509 workload identity federation."),
+ },
+ })
+ if err != nil {
+ log.Fatal(err)
+ }
+
+ fmt.Println(response.OutputText())
+}
+```
+
+```java
+import com.openai.client.OpenAIClient;
+import com.openai.client.okhttp.OpenAIOkHttpClient;
+import com.openai.client.okhttp.X509Transport;
+import com.openai.client.okhttp.X509WorkloadIdentity;
+import com.openai.models.responses.ResponseCreateParams;
+import java.io.InputStream;
+import java.nio.file.Files;
+import java.nio.file.Paths;
+import java.security.KeyStore;
+import java.time.Duration;
+import java.util.Arrays;
+import javax.net.ssl.KeyManagerFactory;
+import javax.net.ssl.TrustManagerFactory;
+import javax.net.ssl.X509ExtendedKeyManager;
+import javax.net.ssl.X509TrustManager;
+
+char[] password = System.getenv("OPENAI_X509_KEYSTORE_PASSWORD").toCharArray();
+try {
+ KeyStore keyStore = KeyStore.getInstance("PKCS12");
+ try (InputStream input =
+ Files.newInputStream(Paths.get(System.getenv("OPENAI_X509_KEYSTORE_PATH")))) {
+ keyStore.load(input, password);
+ }
+
+ KeyManagerFactory keyManagers =
+ KeyManagerFactory.getInstance(KeyManagerFactory.getDefaultAlgorithm());
+ keyManagers.init(keyStore, password);
+ X509ExtendedKeyManager keyManager =
+ Arrays.stream(keyManagers.getKeyManagers())
+ .filter(X509ExtendedKeyManager.class::isInstance)
+ .map(X509ExtendedKeyManager.class::cast)
+ .findFirst()
+ .orElseThrow(() -> new IllegalStateException("No X.509 key manager available"));
+
+ TrustManagerFactory trustManagers =
+ TrustManagerFactory.getInstance(TrustManagerFactory.getDefaultAlgorithm());
+ trustManagers.init((KeyStore) null);
+ X509TrustManager trustManager =
+ Arrays.stream(trustManagers.getTrustManagers())
+ .filter(X509TrustManager.class::isInstance)
+ .map(X509TrustManager.class::cast)
+ .findFirst()
+ .orElseThrow(() -> new IllegalStateException("No X.509 trust manager available"));
+
+ X509Transport transport =
+ X509Transport.builder()
+ .keyManager(keyManager)
+ .certificateAlias(System.getenv("OPENAI_X509_CERTIFICATE_ALIAS"))
+ .trustManager(trustManager)
+ .build();
+ X509WorkloadIdentity identity =
+ X509WorkloadIdentity.builder()
+ .identityProviderId(System.getenv("OPENAI_IDENTITY_PROVIDER_ID"))
+ .serviceAccountId(System.getenv("OPENAI_SERVICE_ACCOUNT_ID"))
+ .transport(transport)
+ .refreshBuffer(Duration.ofMinutes(10))
+ .build();
+
+ OpenAIClient client = OpenAIOkHttpClient.builder().x509WorkloadIdentity(identity).build();
+ try {
+ ResponseCreateParams params =
+ ResponseCreateParams.builder()
+ .model("gpt-5.6-terra")
+ .input("Say hello from X.509 workload identity federation.")
+ .build();
+
+ client.responses().create(params).output().stream()
+ .flatMap(item -> item.message().stream())
+ .flatMap(message -> message.content().stream())
+ .flatMap(content -> content.outputText().stream())
+ .forEach(outputText -> System.out.println(outputText.text()));
+ } finally {
+ client.close();
+ }
+} finally {
+ Arrays.fill(password, '\0');
+}
+```
+
+```ruby
+require "openai"
+require "openssl"
+
+certificate_chain = OpenSSL::X509::Certificate.load(
+ File.binread(ENV.fetch("OPENAI_MTLS_CERT_CHAIN"))
+)
+certificate, *intermediates = certificate_chain
+private_key = OpenSSL::PKey.read(File.binread(ENV.fetch("OPENAI_MTLS_KEY")))
+
+http_client = OpenAI::NetHTTPClient.new do |connection|
+ connection.cert = certificate
+ connection.extra_chain_cert = intermediates
+ connection.key = private_key
+end
+
+workload_identity = OpenAI::Auth::X509WorkloadIdentity.new(
+ identity_provider_id: ENV.fetch("OPENAI_IDENTITY_PROVIDER_ID"),
+ service_account_id: ENV.fetch("OPENAI_SERVICE_ACCOUNT_ID"),
+ http_client: http_client
+)
+
+begin
+ client = OpenAI::Client.new(api_key: nil, workload_identity: workload_identity)
+ response = client.responses.create(
+ model: "gpt-5.6-terra",
+ input: "Say hello from X.509 workload identity federation."
+ )
+
+ puts(response.output_text)
+ensure
+ http_client.close
+end
+```
+
+
+这些示例需要支持此处所示 X.509 配置的 OpenAI SDK 版本:JavaScript 7.8.0 或更高版本,并安装 `undici` 对等依赖项;Python 3.6.0 或更高版本、Go 3.54.0 或更高版本、Java 4.55.0 或更高版本,以及 Ruby 0.83.0 或更高版本。
+
+Java 示例加载 PKCS12 密钥库以构造其 `X509ExtendedKeyManager` 并使用平台默认信任库来构造其 `X509TrustManager`。设置 `OPENAI_X509_KEYSTORE_PATH`, `OPENAI_X509_KEYSTORE_PASSWORD`,以及 `OPENAI_X509_CERTIFICATE_ALIAS` 用于本示例。你也可以向 SDK 提供基于 PEM 或基于硬件的管理器。
+
+## 手动交换证书
+
+若要直接检查或实现令牌交换协议,请向 X.509 令牌端点出示证书:
```bash
curl --cert "$OPENAI_MTLS_CERT_CHAIN" \
@@ -124,7 +382,7 @@ curl --cert "$OPENAI_MTLS_CERT_CHAIN" \
JSON
```
-成功交换后会返回一个普通的短期 bearer 令牌:
+成功交换后会返回一个普通的短时 bearer 令牌:
```json
{
@@ -136,15 +394,15 @@ JSON
}
```
-该 `scope` property 仅当匹配的服务账号映射具有相应权限时才会返回。
+该 `scope` 属性仅当匹配的服务账号映射具有相应权限时才会返回。
-该 `expires_in` 的 value 仅为示例值。当已验证的客户端证书更早到期时,返回的 lifetime 可能更短。 `3600` 仅为示意。当已验证的客户端证书更早到期时,返回的 lifetime 可能更短。
+该 `expires_in` 的值为 `3600` 仅为示例。当已验证的客户端证书更早过期时,返回的有效期可能会更短。
-将 successful response 中的 `access_token` 值读入应用的凭据存储或类似的环境变量中。 `OPENAI_WIF_ACCESS_TOKEN`。请将其视为密钥,不要打印、记录或提交它。
+请将 `access_token` 值从成功响应中读取出来,存入你的应用凭据存储或类似 `OPENAI_WIF_ACCESS_TOKEN`。的环境变量。请将其视为密钥,不要打印、记录或提交它。
-## 调用 OpenAI API
+## 手动调用 OpenAI API
-将模型设为 `OPENAI_MODEL` 为 `gpt-5.6`,即当前默认模型,或目标项目可用的其他模型。然后将持有者令牌和已接受的客户端证书发送到 API mTLS 端点:
+将 `OPENAI_MODEL` 设置为 `gpt-5.6`,即当前默认值,或目标项目可用的其他模型。然后将持有者令牌与一份已接受的客户端证书一起发送到 API mTLS 端点:
```bash
curl --request POST \
@@ -156,34 +414,34 @@ curl --request POST \
"https://mtls.api.openai.com/v1/responses"
```
-请使用持有者令牌而非 API 密钥,并在 API 请求中继续提供已接受的客户端证书。
+使用持有者令牌而不是 API 密钥,并继续在 API 请求中出示已接受的客户端证书。
-持有者令牌并未以加密方式绑定到证书。将交换证书复用于 API 请求是最直接的配置,但 API 请求可以使用另一张同样独立满足当前 API mTLS 策略的证书。
+持有者令牌并未以加密方式绑定到证书。将交换证书复用于 API 请求是最直接的配置方式,但 API 请求也可以使用另一份独立满足同一现行 API mTLS 策略的证书。
-## Token 生命周期与续期
+## 令牌生命周期与续期
-X.509 工作负载身份令牌最多在一小时后过期,并且永远不会超过已验证的客户端证书的有效期。该交换不返回刷新令牌。请重复证书交换以获取新的访问令牌。
+X.509 工作负载身份令牌最多在一小时后过期,且其有效期绝不会超过经验证的客户端证书。该交换不会返回刷新令牌。请重复证书交换以获取另一个访问令牌。
-轮换中间证书不需要更改已配置的根证书。在后续交换和 API 请求中提供新的完整证书链。
+轮换中间证书不需要更改所配置的根证书。请在后续的交换和 API 请求中提供新的完整链。
-## 排查令牌兑换问题
+## 排查令牌交换问题
-X.509 token 交换返回通用的 OAuth 错误,并且不会暴露证书、根、provider 或映射等详细信息。
+X.509 token exchange 返回通用的 OAuth 错误,并且不会暴露证书、根证书、提供方或映射相关的详细信息。
-| 结果 | 常见原因 |
+| 结果 | 典型原因 |
| ----------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
-| HTTP `403` | 请求使用了与精确不匹配的方法或路径 `POST /oauth/token` on `mtls.auth.openai.com`. |
-| `invalid_subject_token` | TLS 客户端证书缺失或无效、提供的证书链无法到达有效的根证书、证书已超出有效期,或被某条 Mutual TLS 证书准入规则拒绝。 |
-| `invalid_grant` | 提供方或映射无效或已被禁用,某个提供方 **属性条件** 表达式拒绝了该身份,没有适用的根处于有效状态,或没有匹配的映射。 |
-| 服务器错误 | OpenAI 返回了临时性服务器错误。请按照你既定的瞬态错误重试策略进行重试。 |
+| HTTP `403` | 请求使用了与 exact 不一致的方法或路径 `POST /oauth/token` on `mtls.auth.openai.com`. |
+| `invalid_subject_token` | TLS 客户端证书缺失或无效,所提供的证书链无法追溯到有效的根证书,证书已超出有效期,或被双向 TLS 证书准入规则拒绝。 |
+| `invalid_grant` | 提供商或映射无效或已禁用,提供商 **属性条件** 表达式拒绝了该身份,没有可用的有效根证书,或没有匹配的映射。 |
+| 服务器错误 | OpenAI 返回了临时服务器错误。请按照你常规的瞬态错误策略进行重试。 |
-X.509 交换绝不会回退为 OIDC 或普通的 OAuth 流程。
+X.509 交换永远不会回退到 OIDC 或普通 OAuth 流程。
## 限制
-- X.509 Workload Identity Providers 不维护单独的证书信任存储。
-- Bearer 令牌并未绑定证书,也不使用 DPoP 或 `cnf` 声明。
-- 证书交换并非仅通过证书进行 API 授权。API 请求仍然需要 bearer 令牌以及一个被接受的客户端证书。
+- X.509 Workload Identity Providers 不维护单独的证书信任库。
+- bearer 令牌未与证书绑定,也未使用 DPoP 或 `cnf` claim 绑定。
+- 证书交换不是仅限证书的 API 授权。API 请求仍需要 bearer 令牌和已接受的客户端证书。
- OpenAI 不会从 AIA URL 获取缺失的中间证书。请在 TLS 协商期间提供完整的证书链。
-- OpenAI 在此流程中不会执行证书吊销列表 (CRL) 或 OCSP 检查。请围绕 Mutual TLS 根证书、Provider 和映射控制以及所颁发令牌较短的生命周期来规划证书事件响应。
-- 此流程不增加对 SPIFFE X.509-SVID 的支持。 [SPIFFE 指南](https://developers.openai.com/api/docs/guides/workload-identity-federation/spiffe) 继续使用 JWT-SVID。
\ No newline at end of file
+- OpenAI 在此流程中不会执行证书吊销列表 (CRL) 或 OCSP 检查。请围绕 Mutual TLS 根、provider 与映射控制以及所颁发令牌较短的生存期来规划证书事件响应。
+- 此流程未新增对 SPIFFE X.509-SVID 的支持。 [SPIFFE 指南](https://developers.openai.com/api/docs/guides/workload-identity-federation/spiffe) 继续使用 JWT-SVID。
\ No newline at end of file
diff --git a/docs/zh/api/docs/libraries.md b/docs/zh/api/docs/libraries.md
index 8ca4512..13acd67 100644
--- a/docs/zh/api/docs/libraries.md
+++ b/docs/zh/api/docs/libraries.md
@@ -1,12 +1,12 @@
# SDK 和 CLI
-> 完整的文档索引请参阅 [llms.txt](/llms.txt)。通过在页面 URL 后追加 `.md` 即可获取该页面的 Markdown 版本。
+> 完整的文档索引请参见 [llms.txt](/llms.txt). 文档页面的 Markdown 版本可通过在页面 URL 后追加 `.md` 来获取。
-本页面介绍使用 [OpenAI API](https://developers.openai.com/api/reference/overview):进行开发的主要方式:用于应用程序代码的官方 SDK、用于 shell 原生工作流的 OpenAI CLI、用于编排的 Agents SDK,或你偏好的任意 HTTP 客户端。
+本页面介绍使用 [OpenAI API](https://developers.openai.com/api/reference/overview):进行开发的主要方式:用于应用代码的官方 SDK、用于 shell 原生工作流的 OpenAI CLI、用于编排的 Agents SDK,或你自己首选的 HTTP 客户端。
## 创建并导出 API 密钥
-开始之前, [在仪表板中创建一个 API 密钥](https://platform.openai.com/api-keys),你将用它来安全地 [访问 API](https://developers.openai.com/api/reference/overview)。请将此密钥保存在安全的位置,例如计算机上的一个 [`.zshrc` 文件](https://www.freecodecamp.org/news/how-do-zsh-configuration-files-work/) 或其他文本文件。生成 API 密钥后,请在终端中将其导出为 [环境变量](https://en.wikipedia.org/wiki/Environment_variable) 。
+在开始之前, [在控制台中创建一个 API 密钥](https://platform.openai.com/api-keys),你将使用该密钥安全地 [访问 API](https://developers.openai.com/api/reference/overview)。请将该密钥保存在安全的位置,例如计算机上的一个 [`.zshrc` 文件](https://www.freecodecamp.org/news/how-do-zsh-configuration-files-work/) 或其他文本文件。生成 API 密钥后,将其导出为终端中的 [环境变量](https://en.wikipedia.org/wiki/Environment_variable) 。
@@ -33,7 +33,7 @@ setx OPENAI_API_KEY "your_api_key_here"
-OpenAI SDK 被配置为自动从系统环境中读取你的 API 密钥。
+OpenAI SDK 已配置为自动从系统环境中读取你的 API 密钥。
## 安装官方 SDK
@@ -43,7 +43,7 @@ JavaScript
-要在 Node.js、Deno 或 Bun 等 服务端 JavaScript 环境中使用 OpenAI API,你可以使用官方的 [OpenAI SDK for TypeScript and JavaScript](https://github.com/openai/openai-node)。先使用 [npm](https://www.npmjs.com/) 或你常用的包管理器安装 SDK:
+要在 Node.js、Deno 或 Bun 等服务端 JavaScript 环境中使用 OpenAI API,你可以使用官方的 [OpenAI SDK for TypeScript and JavaScript](https://github.com/openai/openai-node)。首先使用 [npm](https://www.npmjs.com/) 或你常用的包管理器安装 SDK:
使用 npm 安装 OpenAI SDK
@@ -52,7 +52,7 @@ npm install openai
```
-安装好 OpenAI SDK 后,创建一个文件 `example.mjs` 并将示例代码复制进去:
+安装好 OpenAI SDK 后,新建一个名为 `example.mjs` 的文件,并将示例代码复制到该文件中:
测试一个基础的 API 请求
@@ -69,7 +69,7 @@ console.log(response.output_text);
```
-使用 `node example.mjs` (或 Deno、Bun 中等效的命令)执行代码。稍等片刻,你应当能看到 API 请求的输出。
+使用 `node example.mjs` (或 Deno、Bun 中对应的命令)执行该代码。稍等片刻,你应该就能看到 API 请求的输出结果。
[在 GitHub 上了解更多信息
@@ -87,7 +87,7 @@ Python
-要在 Python 中使用 OpenAI API,你可以使用官方的 [OpenAI SDK for Python](https://github.com/openai/openai-python)。先使用 [pip](https://pypi.org/project/pip/):
+要在 Python 中使用 OpenAI API,你可以使用官方的 [OpenAI SDK for Python](https://github.com/openai/openai-python)。首先使用 [pip](https://pypi.org/project/pip/):
使用 pip 安装 OpenAI SDK
@@ -96,7 +96,7 @@ pip install openai
```
-安装好 OpenAI SDK 后,创建一个文件 `example.py` 并将示例代码复制进去:
+安装好 OpenAI SDK 后,新建一个名为 `example.py` 的文件,并将示例代码复制到该文件中:
测试一个基础的 API 请求
@@ -114,7 +114,7 @@ print(response.output_text)
```
-使用 `python example.py`。稍等片刻,你应当能看到 API 请求的输出。
+使用 `python example.py`。稍等片刻,你应该就能看到 API 请求的输出结果。
[在 GitHub 上了解更多信息
@@ -132,13 +132,13 @@ print(response.output_text)
-OpenAI 与 Microsoft 合作,提供一个官方支持的 C# API 客户端。你可以使用 .NET CLI 从 [NuGet](https://www.nuget.org/).
+该公司 与 Microsoft 合作提供了一个官方支持的 C# OpenAIAPI 客户端。你可以使用 .NET CLI 通过以下方式安装它: [NuGet](https://www.nuget.org/).
```
dotnet add package OpenAI
```
-一个向 API 发出的简单请求,使用 [Responses API](https://developers.openai.com/api/reference/resources/responses) 示例如下:
+向 API 发出的简单请求如下所示,针对的是 [Responses API](https://developers.openai.com/api/reference/resources/responses) 看起来像这样:
测试一个基础的 API 请求
@@ -167,18 +167,18 @@ Java
-OpenAI 为 Java 语言提供了一个 API 帮助库,目前处于 beta 阶段。你可以使用以下配置加入 Maven 依赖:
+OpenAI 为 Java 编程语言提供了一个 API 辅助库,目前处于 beta 阶段。你可以使用以下配置添加 Maven 依赖:
```xml
com.openai
openai-java
- 4.55.0
+ 4.56.0
```
-一个向 API 发出的简单请求,使用 [Responses API](https://developers.openai.com/api/reference/resources/responses) 示例如下:
+向 API 发出的简单请求如下: [Responses API](https://developers.openai.com/api/reference/resources/responses) 看起来像这样:
测试一个基础的 API 请求
@@ -206,7 +206,7 @@ public class Main {
```
-要了解更多在 Java 中使用 OpenAI API 的信息,请查看下方链接的 GitHub 仓库!
+要了解如何在 Java 中使用 OpenAIAPI,请查看下方链接的 GitHub 仓库!
[在 GitHub 上了解更多信息
@@ -224,7 +224,7 @@ Go
-OpenAI 为 Go 语言提供了一个 API 帮助库,目前处于 beta 阶段。你可以使用下面的代码导入该库:
+OpenAI 为 Go 编程语言提供了一个 API 辅助库,目前处于 beta 阶段。你可以使用下面的代码导入该库:
```go
import (
@@ -233,7 +233,7 @@ import (
```
-向 API 发出的第一个请求,使用 [Responses API](https://developers.openai.com/api/reference/resources/responses) 示例如下:
+向 API 发出的第一个请求示例如下,针对的是 [Responses API](https://developers.openai.com/api/reference/resources/responses) 看起来像这样:
测试一个基础的 API 请求
@@ -264,7 +264,7 @@ func main() {
```
-要了解更多在 Go 中使用 OpenAI API 的信息,请查看下方链接的 GitHub 仓库!
+要了解如何在 Go 中使用 OpenAIAPI,请查看下方链接的 GitHub 仓库!
[在 GitHub 上了解更多信息
@@ -282,16 +282,16 @@ Ruby
-要在 Ruby 中使用 OpenAI API,你可以使用官方的 [OpenAI SDK for Ruby](https://github.com/openai/openai-ruby)。首先将 gem 添加到你的应用中:
+要在 Ruby 中使用 OpenAIAPI,你可以使用官方的 [OpenAI Ruby SDK](https://github.com/openai/openai-ruby)。首先将该 gem 添加到你的应用中:
-使用 Bundler 安装 OpenAI SDK
+使用 Bundler 安装 OpenAISDK
```ruby
gem "openai"
```
-安装好 OpenAI SDK 后,创建一个文件 `example.rb` 并将示例代码复制进去:
+安装好 OpenAI SDK 后,新建一个名为 `example.rb` 的文件,并将示例代码复制到该文件中:
测试一个基础的 API 请求
@@ -309,7 +309,7 @@ puts(response.output_text)
```
-使用 `ruby example.rb`。稍等片刻,你应当能看到 API 请求的输出。
+使用 `ruby example.rb`。稍等片刻,你应该就能看到 API 请求的输出结果。
[在 GitHub 上了解更多信息
@@ -327,7 +327,7 @@ CLI
-若要直接从终端调用 OpenAI API,请安装自动生成的 `openai` 命令行工具:
+若要从终端直接调用 OpenAIAPI,请安装生成的 `openai` 命令行工具:
使用 Homebrew 安装 OpenAI CLI
@@ -336,7 +336,7 @@ brew install openai/tools/openai
```
-然后在 shell 中运行一个基础的 API 请求:
+然后在命令行中发起一个基础 API 请求:
测试一个基础的 API 请求
@@ -349,7 +349,7 @@ openai responses create \
```
-将 CLI 用于可重复的终端工作流,例如从文件中提取结构化数据、生成图像、创建语音,以及使用以下 shell 工具组合 API 调用 `jq`.
+你可以将 CLI 用于可重复的终端工作流,例如从文件中提取结构化数据、生成图像、创建语音,以及结合 shell 工具编写 API 调用,例如 `jq`.
[OpenAI CLI 指南
@@ -361,12 +361,12 @@ openai responses create \
## 使用 Agents SDK
-直接 OpenAI 请求请使用上述官方 SDK API。当你的应用需要代码优先的编排时,请使用 Agents SDK
-来处理 智能体、工具、
-交接、护栏、追踪或沙箱执行。
+使用上述官方 OpenAI SDK 直接发出 API 请求。如果你的应用需要以代码优先的方式编排,请在需要时使用 Agents SDK
+为 智能体、工具、
+交接、护栏、追踪或沙箱执行提供代码优先的编排。
-如果你要在直接 API 请求和代码优先的编排之间做选择,
-请参阅 [Responses API 与 Agents SDK 的对比](https://developers.openai.com/api/docs/guides/agents#agents-sdk-vs-responses-api).
+如果你正在直接 API 请求与代码优先编排之间进行选择,
+请参阅 [Responses API 与 Agents SDK 的比较](https://developers.openai.com/api/docs/guides/agents#agents-sdk-vs-responses-api).
[Agents SDK 快速入门
@@ -379,7 +379,7 @@ openai responses create \
## Azure OpenAI 库
-Microsoft 的 Azure 团队维护着与 OpenAI API 和 Azure OpenAI 服务兼容的库。阅读下面的库文档,了解如何将它们与 OpenAI API 一起使用。
+Microsoft 的 Azure 团队维护与 OpenAI API 和 Azure OpenAI 服务兼容的库。请阅读下面的库文档,了解如何将它们与 OpenAI API 配合使用。
- [适用于 .NET 的 Azure OpenAI 客户端库](https://github.com/Azure/azure-sdk-for-net/tree/main/sdk/openai/Azure.AI.OpenAI)
- [适用于 JavaScript 的 Azure OpenAI 客户端库](https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/openai/openai)
@@ -390,9 +390,9 @@ Microsoft 的 Azure 团队维护着与 OpenAI API 和 Azure OpenAI 服务兼容
## 社区库
-以下库由更广泛的开发者社区构建和维护。你还可以 [在 GitHub 上关注我们的 OpenAPI 规范仓库](https://github.com/openai/openai-openapi) ,以便及时了解我们对 API 所做更改的更新。
+下面的库由更广泛的开发者社区构建和维护。你还可以 [在 GitHub 上关注我们的 OpenAPI 规范仓库](https://github.com/openai/openai-openapi) ,及时了解 API 的更新情况。
-请注意,OpenAI 不会验证这些项目的正确性或安全性。 **使用风险自负!**
+请注意,OpenAI 不会验证这些项目的正确性或安全性。 **使用时请自行承担风险!**
### Clojure
@@ -444,7 +444,7 @@ Microsoft 的 Azure 团队维护着与 OpenAI API 和 Azure OpenAI 服务兼容
## 其他 OpenAI 仓库
- [tiktoken](https://github.com/openai/tiktoken) - 统计 token 数
-- [simple-evals](https://github.com/openai/simple-evals) - 简易评估库
-- [mle-bench](https://github.com/openai/mle-bench) - 评估机器学习工程师的智能体库
+- [simple-evals](https://github.com/openai/simple-evals) - 简单评估库
+- [mle-bench](https://github.com/openai/mle-bench) - 用于评估机器学习工程师智能体的库
- [gym](https://github.com/openai/gym) - 强化学习库
-- [swarm](https://github.com/openai/swarm) - 教学用编排仓库
\ No newline at end of file
+- [swarm](https://github.com/openai/swarm) - 教学编排仓库
\ No newline at end of file
diff --git a/docs/zh/api/docs/quickstart.md b/docs/zh/api/docs/quickstart.md
index 0abbcd6..5202374 100644
--- a/docs/zh/api/docs/quickstart.md
+++ b/docs/zh/api/docs/quickstart.md
@@ -1,10 +1,10 @@
# 开发者快速入门
-> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。可通过在页面 URL 末尾附加 `.md` 来获取文档页面的 Markdown 版本。
+> 如需完整文档索引,请参阅 [llms.txt](/llms.txt)。可通过在页面 URL 后追加 `.md` 来获取文档页面的 Markdown 版本。
-OpenAI API 提供面向先进 AI 的统一接口 [模型](https://developers.openai.com/api/docs/models) ,可用于文本生成、自然语言处理、计算机视觉等任务。首先创建一个 API 密钥并运行你的首次 API 调用,快速入门。了解如何生成文本、分析图像、构建智能体等。
+OpenAI API 提供了一个统一的接口来访问业界领先的 AI [模型](https://developers.openai.com/api/docs/models) ,可用于文本生成、自然语言处理、计算机视觉等场景。你可以从创建 API 密钥并发起你的第一次 API 调用开始,了解如何生成文本、分析图像、构建 智能体 等。
-## 创建并导出API密钥
+## 创建并导出 API 密钥
@@ -17,13 +17,13 @@ StatsigClient.logEvent("quickstart_create_api_key_click", null, null)
-开始之前,请在控制台中创建一个 API 密钥,你将用它来
+在开始之前,先在仪表板中创建一个 API 密钥,后续你需要用它来
安全地 [访问 API](https://developers.openai.com/api/reference/overview)。请将该密钥
-存放在安全的位置,例如计算机上的一个 [`.zshrc`
-文件](https://www.freecodecamp.org/news/how-do-zsh-configuration-files-work/) 或
-另一个文本文件。生成 API 密钥后,请将其导出为
-环境变量 [环境变量](https://en.wikipedia.org/wiki/Environment_variable)
-在你的终端中。
+保存在安全的位置,例如计算机上的某个 [`.zshrc`
+文件](https://www.freecodecamp.org/news/how-do-zsh-configuration-files-work/) 或其他文本文件。生成 API 密钥后,将它导出
+生成 接口 密钥后,将它导出
+为 [环境变量](https://en.wikipedia.org/wiki/Environment_variable)
+在终端中。
@@ -50,9 +50,9 @@ setx OPENAI_API_KEY "your_api_key_here"
-每个 OpenAI SDK 都会自动从系统环境中读取你的 API 密钥。
+每个 OpenAI SDK 都会自动从系统环境变量中读取你的 API 密钥。
-## 安装 OpenAI SDK 并运行 API 调用
+## 安装 OpenAI SDK 并运行一次 API 调用
@@ -60,7 +60,7 @@ JavaScript
-要在 Node.js、Deno 或 Bun 等服务端 JavaScript 环境中使用 OpenAI API,你可以使用 [OpenAI TypeScript 和 JavaScript SDK](https://github.com/openai/openai-node)。先通过 [npm](https://www.npmjs.com/) 或你常用的包管理器安装 SDK:
+要在 Node.js、Deno 或 Bun 等 服务端 JavaScript 环境中使用 OpenAI API,你可以使用官方的 [TypeScript 和 JavaScript 版 OpenAI SDK](https://github.com/openai/openai-node)。首先使用 [npm](https://www.npmjs.com/) 或你常用的包管理器来安装 SDK:
使用 npm 安装 OpenAI SDK
@@ -69,7 +69,7 @@ npm install openai
```
-安装好 OpenAI SDK 后,新建一个文件 `example.mjs` ,并将下面的示例代码复制进去:
+安装好 OpenAI SDK 后,新建一个文件 `example.mjs` 并将下面的示例代码复制到该文件中:
测试一个基础的 API 请求
@@ -86,7 +86,7 @@ console.log(response.output_text);
```
-使用 `node example.mjs` (或 Deno、Bun 中等效的命令)执行代码。稍等片刻,你就能看到 API 请求的输出。
+使用 `node example.mjs` (执行该代码(如果你使用的是 Deno 或 Bun,请使用对应的命令)。稍等片刻,你应该就能看到本次 API 请求的输出。
[在 GitHub 上了解更多信息
@@ -104,7 +104,7 @@ Python
-要在 Python 中使用 OpenAI API,你可以使用官方的 [OpenAI Python SDK](https://github.com/openai/openai-python)。先通过 [pip](https://pypi.org/project/pip/):
+要在 Python 中使用 OpenAI API,你可以使用官方的 [Python 版 OpenAI SDK](https://github.com/openai/openai-python)。首先使用 [pip](https://pypi.org/project/pip/):
使用 pip 安装 OpenAI SDK
@@ -113,7 +113,7 @@ pip install openai
```
-安装好 OpenAI SDK 后,新建一个文件 `example.py` ,并将下面的示例代码复制进去:
+安装好 OpenAI SDK 后,新建一个文件 `example.py` 并将下面的示例代码复制到该文件中:
测试一个基础的 API 请求
@@ -131,7 +131,7 @@ print(response.output_text)
```
-使用 `python example.py`。稍等片刻,你就能看到 API 请求的输出。
+使用 `python example.py`。稍等片刻,你应该就能看到本次 API 请求的输出。
[在 GitHub 上了解更多信息
@@ -149,13 +149,13 @@ print(response.output_text)
-该公司 与 Microsoft 合作,提供一个官方支持的 C# OpenAI API 客户端。你可以使用 .NET CLI 从 [NuGet](https://www.nuget.org/).
+与 Microsoft 合作,OpenAI 为 C# 提供官方支持的 API 客户端。你可以使用 .NET CLI 从 [NuGet](https://www.nuget.org/).
```
dotnet add package OpenAI
```
-一个针对API 的简单请求到 [Responses API](https://developers.openai.com/api/reference/resources/responses) 看起来像这样:
+向 API 发起的简单请求到 [Responses API](https://developers.openai.com/api/reference/resources/responses) 如下所示:
测试一个基础的 API 请求
@@ -184,18 +184,18 @@ Java
-OpenAI 为 Java 编程语言提供了一个 API 帮助程序,目前处于 beta 阶段。你可以使用以下配置添加 Maven 依赖:
+OpenAI 为 Java 编程语言提供了一个 API 辅助库,目前仍处于 beta 阶段。你可以使用以下配置加入 Maven 依赖:
```xml
com.openai
openai-java
- 4.55.0
+ 4.56.0
```
-一个针对API 的简单请求到 [Responses API](https://developers.openai.com/api/reference/resources/responses) 看起来像这样:
+向 API 发起的简单请求到 [Responses API](https://developers.openai.com/api/reference/resources/responses) 如下所示:
测试一个基础的 API 请求
@@ -223,7 +223,7 @@ public class Main {
```
-要了解有关在 Java 中使用 OpenAI API 的更多信息,请查看下方链接的 GitHub 仓库!
+要了解更多在 Java 中使用 OpenAI API 的信息,请查看下方链接的 GitHub 仓库!
[在 GitHub 上了解更多信息
@@ -241,7 +241,7 @@ Go
-OpenAI 为 Go 编程语言提供了一个 API 帮助程序,目前处于 beta 阶段。你可以使用下面的代码导入该库:
+OpenAI 为 Go 编程语言提供了一个 API 辅助库,目前仍处于 beta 阶段。你可以使用下面的代码导入该库:
```go
import (
@@ -250,7 +250,7 @@ import (
```
-一个针对API 的首次请求到 [Responses API](https://developers.openai.com/api/reference/resources/responses) 看起来像这样:
+向 API 发起的首次请求到 [Responses API](https://developers.openai.com/api/reference/resources/responses) 如下所示:
测试一个基础的 API 请求
@@ -281,7 +281,7 @@ func main() {
```
-要了解有关在 Go 中使用 OpenAI API 的更多信息,请查看下方链接的 GitHub 仓库!
+要了解更多在 Go 中使用 OpenAI API 的信息,请查看下方链接的 GitHub 仓库!
[在 GitHub 上了解更多信息
@@ -299,7 +299,7 @@ Ruby
-要在 Ruby 中使用 OpenAI API,你可以使用官方的 [OpenAI Ruby SDK](https://github.com/openai/openai-ruby)。首先将 gem 添加到你的应用程序:
+要在 Ruby 中使用 OpenAI API,你可以使用官方的 [OpenAI SDK for Ruby](https://github.com/openai/openai-ruby)。首先将 gem 添加到你的应用中:
使用 Bundler 安装 OpenAI SDK
@@ -308,7 +308,7 @@ gem "openai"
```
-安装好 OpenAI SDK 后,新建一个文件 `example.rb` ,并将下面的示例代码复制进去:
+安装好 OpenAI SDK 后,新建一个文件 `example.rb` 并将下面的示例代码复制到该文件中:
测试一个基础的 API 请求
@@ -326,7 +326,7 @@ puts(response.output_text)
```
-使用 `ruby example.rb`。稍等片刻,你就能看到 API 请求的输出。
+使用 `ruby example.rb`。稍等片刻,你应该就能看到本次 API 请求的输出。
[在 GitHub 上了解更多信息
@@ -335,7 +335,7 @@ puts(response.output_text)
Discover more SDK capabilities and options on the library's GitHub README.](https://github.com/openai/openai-ruby)
-[Responses 入门应用
+[Responses 入门示例应用
@@ -354,17 +354,17 @@ puts(response.output_text)
StatsigClient.logEvent("quickstart_add_credits_billing_click", null, null)
}
>
- 前往结算
+ 前往账单
{/* prettier-ignore */}
-恭喜你成功运行了一次免费的测试 API 请求!开始构建具有更高限额的真实应用,使用 [我们的模型](https://developers.openai.com/api/docs/models) 生成文本、音频、图像、视频等内容。
+恭喜你成功运行了一次免费的 API 请求!现在可以开始使用更高的额度构建真实的应用,并使用 [我们的模型](https://developers.openai.com/api/docs/models) 来生成文本、音频、图像、视频等。
- 探索旨在帮助你更快交付的工具和文档:
+ 探索可帮助你更快交付的工具和文档:
[StatsigClient.logEvent(
@@ -374,7 +374,7 @@ StatsigClient.logEvent("quickstart_add_credits_billing_click", null, null)
)
}
>
- Chat Playground
+ 聊天 Playground
@@ -387,7 +387,7 @@ StatsigClient.logEvent("quickstart_add_credits_billing_click", null, null)
## 分析图像和文件
-将图片 URL、上传的文件或 PDF 文档直接发送给模型,以提取文本、对内容进行分类,或识别视觉元素。
+直接将图片 URL、上传的文件或 PDF 文档发送给模型,以提取文本、对内容进行分类或检测视觉元素。
@@ -1103,7 +1103,7 @@ curl "https://api.openai.com/v1/responses" \
## 使用工具扩展模型
-通过附加 [工具](https://developers.openai.com/api/docs/guides/tools)。为模型赋予对外部数据和函数的访问能力。使用 网页搜索 或 文件搜索 等内置工具,或自定义工具以调用 API、运行代码或与第三方系统集成。
+通过附加 [工具](https://developers.openai.com/api/docs/guides/tools),让模型能够访问外部数据和函数。使用 网页搜索 或 文件搜索 等内置工具,或自行定义工具以调用 API、运行代码或与第三方系统集成。
@@ -1998,9 +1998,9 @@ puts(response.output_text)
Learn to enable the model to call your own custom code.](https://developers.openai.com/api/docs/guides/function-calling)
-## 流式响应与构建实时应用
+## 流式响应并构建实时应用
-使用服务端发送 [流式事件](https://developers.openai.com/api/docs/guides/streaming-responses) 可在生成时展示结果,也可使用 [Realtime API](https://developers.openai.com/api/docs/guides/realtime) 来构建交互式语音应用,以及支持文本、音频和图像输入的应用。
+使用服务端发送的 [streaming events](https://developers.openai.com/api/docs/guides/streaming-responses) 可以在结果生成时即时展示,或使用 [Realtime API](https://developers.openai.com/api/docs/guides/realtime) 构建交互式语音应用,以及支持文本、音频和图像输入的应用。
从 API 流式接收服务端事件
@@ -2144,9 +2144,9 @@ end
## 构建智能体
-使用 OpenAI 平台来构建 [智能体](https://developers.openai.com/api/docs/guides/agents) ,让它们能够代表你的用户采取行动——例如 [控制计算机](https://developers.openai.com/api/docs/guides/tools-computer-use)。使用 Agents SDK [智能体开发工具包](https://developers.openai.com/api/docs/guides/agents) 在服务器上创建编排逻辑。
+使用 OpenAI 平台构建 [智能体](https://developers.openai.com/api/docs/guides/agents) 能够代表你的用户采取行动——例如 [控制计算机](https://developers.openai.com/api/docs/guides/tools-computer-use)。在你的服务器上使用 Agents SDK [智能体开发工具包](https://developers.openai.com/api/docs/guides/agents) 创建编排逻辑。
-构建一个语言分诊 智能体
+构建语言分诊 智能体
```javascript
import { Agent, run } from "@openai/agents";
diff --git a/docs/zh/api/reference/resources/beta/subresources/responses/streaming-events.md b/docs/zh/api/reference/resources/beta/subresources/responses/streaming-events.md
index e97df03..e8e9622 100644
--- a/docs/zh/api/reference/resources/beta/subresources/responses/streaming-events.md
+++ b/docs/zh/api/reference/resources/beta/subresources/responses/streaming-events.md
@@ -1,21 +1,21 @@
# Beta Responses 流式事件
-> 如需查看完整的文档索引,请参阅 [llms.txt](/llms.txt)。在页面 URL 末尾追加 `.md` 即可获得文档页面的 Markdown 版本。
+> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。文档页面的 Markdown 版本可通过在页面 URL 后追加 `.md` 来获取。
-当你 [创建 Response](https://developers.openai.com/docs/api-reference/responses/create) 时
-`stream` 设置为 `true`,服务器会向客户端发送服务端发送事件
-(server-sent events),在 Response 生成过程中推送。本节包含服务器
-所发送的事件。
+当你 [创建 Response](https://developers.openai.com/docs/api-reference/responses/create) 使用
+`stream` 设置为 `true`,时,服务端会向客户端发送服务端发送事件(server-sent events),
+在 Response 生成过程中持续推送。本节列出了服务端发出的
+事件类型。
-[了解有关流式响应的更多信息](https://developers.openai.com/docs/guides/streaming-responses?api-mode=responses).
+[了解更多关于流式 Response 的信息](https://developers.openai.com/docs/guides/streaming-responses?api-mode=responses).
## response.created
-在响应创建时发出的事件。
+在响应被创建时发出的事件。
### Schema
-Schema 名称: `BetaResponseCreatedEvent`
+Schema name: `BetaResponseCreatedEvent`
```json
{
@@ -2538,8 +2538,7 @@ Schema 名称: `BetaResponseCreatedEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) user": {
@@ -2902,6 +2901,10 @@ Schema 名称: `BetaResponseCreatedEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -2914,7 +2917,8 @@ Schema 名称: `BetaResponseCreatedEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) instructions > (variant) 0": {
@@ -8187,23 +8191,6 @@ Schema 名称: `BetaResponseCreatedEvent`
"schemaType": "integer",
"children": []
},
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/BetaResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) beta.responses > (model) beta_response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/BetaResponseUsage",
@@ -8226,9 +8213,6 @@ Schema 名称: `BetaResponseCreatedEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -8238,8 +8222,7 @@ Schema 名称: `BetaResponseCreatedEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response_error > (schema) > (property) code > (member) 0": {
@@ -8390,6 +8373,13 @@ Schema 名称: `BetaResponseCreatedEvent`
}
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -64237,11 +64227,11 @@ Schema 名称: `BetaResponseCreatedEvent`
## response.in_progress
-当响应正在进行时发出。
+在响应进行中时发出。
### Schema
-Schema 名称: `BetaResponseInProgressEvent`
+Schema name: `BetaResponseInProgressEvent`
```json
{
@@ -66764,8 +66754,7 @@ Schema 名称: `BetaResponseInProgressEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) user": {
@@ -67128,6 +67117,10 @@ Schema 名称: `BetaResponseInProgressEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -67140,7 +67133,8 @@ Schema 名称: `BetaResponseInProgressEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) instructions > (variant) 0": {
@@ -72413,23 +72407,6 @@ Schema 名称: `BetaResponseInProgressEvent`
"schemaType": "integer",
"children": []
},
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/BetaResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) beta.responses > (model) beta_response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/BetaResponseUsage",
@@ -72452,9 +72429,6 @@ Schema 名称: `BetaResponseInProgressEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -72464,8 +72438,7 @@ Schema 名称: `BetaResponseInProgressEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response_error > (schema) > (property) code > (member) 0": {
@@ -72616,6 +72589,13 @@ Schema 名称: `BetaResponseInProgressEvent`
}
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -128463,11 +128443,11 @@ Schema 名称: `BetaResponseInProgressEvent`
## response.completed
-在模型响应完成时发出。
+当模型响应完成时发出。
### Schema
-Schema 名称: `BetaResponseCompletedEvent`
+Schema name: `BetaResponseCompletedEvent`
```json
{
@@ -130990,8 +130970,7 @@ Schema 名称: `BetaResponseCompletedEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) user": {
@@ -131354,6 +131333,10 @@ Schema 名称: `BetaResponseCompletedEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -131366,7 +131349,8 @@ Schema 名称: `BetaResponseCompletedEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) instructions > (variant) 0": {
@@ -136639,23 +136623,6 @@ Schema 名称: `BetaResponseCompletedEvent`
"schemaType": "integer",
"children": []
},
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/BetaResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) beta.responses > (model) beta_response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/BetaResponseUsage",
@@ -136678,9 +136645,6 @@ Schema 名称: `BetaResponseCompletedEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -136690,8 +136654,7 @@ Schema 名称: `BetaResponseCompletedEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response_error > (schema) > (property) code > (member) 0": {
@@ -136842,6 +136805,13 @@ Schema 名称: `BetaResponseCompletedEvent`
}
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -192706,11 +192676,11 @@ Schema 名称: `BetaResponseCompletedEvent`
## response.failed
-在响应失败时发出的事件。
+当响应失败时发出的事件。
### Schema
-Schema 名称: `BetaResponseFailedEvent`
+Schema name: `BetaResponseFailedEvent`
```json
{
@@ -195233,8 +195203,7 @@ Schema 名称: `BetaResponseFailedEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) user": {
@@ -195597,6 +195566,10 @@ Schema 名称: `BetaResponseFailedEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -195609,7 +195582,8 @@ Schema 名称: `BetaResponseFailedEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) instructions > (variant) 0": {
@@ -200882,23 +200856,6 @@ Schema 名称: `BetaResponseFailedEvent`
"schemaType": "integer",
"children": []
},
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/BetaResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) beta.responses > (model) beta_response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/BetaResponseUsage",
@@ -200921,9 +200878,6 @@ Schema 名称: `BetaResponseFailedEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -200933,8 +200887,7 @@ Schema 名称: `BetaResponseFailedEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response_error > (schema) > (property) code > (member) 0": {
@@ -201085,6 +201038,13 @@ Schema 名称: `BetaResponseFailedEvent`
}
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -256930,11 +256890,11 @@ Schema 名称: `BetaResponseFailedEvent`
## response.incomplete
-当响应未完成时发出的事件。
+当响应以未完成状态结束时发出的事件。
### Schema
-Schema 名称: `BetaResponseIncompleteEvent`
+Schema name: `BetaResponseIncompleteEvent`
```json
{
@@ -259457,8 +259417,7 @@ Schema 名称: `BetaResponseIncompleteEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) user": {
@@ -259821,6 +259780,10 @@ Schema 名称: `BetaResponseIncompleteEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -259833,7 +259796,8 @@ Schema 名称: `BetaResponseIncompleteEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) instructions > (variant) 0": {
@@ -265106,23 +265070,6 @@ Schema 名称: `BetaResponseIncompleteEvent`
"schemaType": "integer",
"children": []
},
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/BetaResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) beta.responses > (model) beta_response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/BetaResponseUsage",
@@ -265145,9 +265092,6 @@ Schema 名称: `BetaResponseIncompleteEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -265157,8 +265101,7 @@ Schema 名称: `BetaResponseIncompleteEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response_error > (schema) > (property) code > (member) 0": {
@@ -265309,6 +265252,13 @@ Schema 名称: `BetaResponseIncompleteEvent`
}
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -321154,11 +321104,11 @@ Schema 名称: `BetaResponseIncompleteEvent`
## response.output_item.added
-添加新的输出项时触发。
+当添加新的输出项时发出。
### Schema
-Schema 名称: `BetaResponseOutputItemAddedEvent`
+Schema name: `BetaResponseOutputItemAddedEvent`
```json
{
@@ -348687,11 +348637,11 @@ Schema 名称: `BetaResponseOutputItemAddedEvent`
## response.output_item.done
-在某个输出项被标记为完成时触发。
+当某个输出项被标记为完成时触发。
### Schema
-Schema 名称: `BetaResponseOutputItemDoneEvent`
+Schema name: `BetaResponseOutputItemDoneEvent`
```json
{
@@ -376226,11 +376176,11 @@ Schema 名称: `BetaResponseOutputItemDoneEvent`
## response.content_part.added
-添加新的内容部分时发出。
+当新增一个内容部分时发出。
### Schema
-Schema 名称: `BetaResponseContentPartAddedEvent`
+Schema name: `BetaResponseContentPartAddedEvent`
```json
{
@@ -377415,11 +377365,11 @@ Schema 名称: `BetaResponseContentPartAddedEvent`
## response.content_part.done
-当内容部分完成时发出。
+当内容片段完成时发出。
### Schema
-Schema 名称: `BetaResponseContentPartDoneEvent`
+Schema name: `BetaResponseContentPartDoneEvent`
```json
{
@@ -378608,7 +378558,7 @@ Schema 名称: `BetaResponseContentPartDoneEvent`
### Schema
-Schema 名称: `BetaResponseTextDeltaEvent`
+Schema name: `BetaResponseTextDeltaEvent`
```json
{
@@ -378933,11 +378883,11 @@ Schema 名称: `BetaResponseTextDeltaEvent`
## response.output_text.done
-当文本内容最终确定时发出。
+在文本内容完成时发出。
### Schema
-Schema 名称: `BetaResponseTextDoneEvent`
+Schema name: `BetaResponseTextDoneEvent`
```json
{
@@ -379262,11 +379212,11 @@ Schema 名称: `BetaResponseTextDoneEvent`
## response.refusal.delta
-当存在部分拒绝文本时发出。
+存在部分拒绝文本时发出。
### Schema
-Schema 名称: `BetaResponseRefusalDeltaEvent`
+Schema name: `BetaResponseRefusalDeltaEvent`
```json
{
@@ -379467,11 +379417,11 @@ Schema 名称: `BetaResponseRefusalDeltaEvent`
## response.refusal.done
-当拒绝文本最终确定时发出。
+当拒绝文本最终确定时触发。
### Schema
-Schema 名称: `BetaResponseRefusalDoneEvent`
+Schema name: `BetaResponseRefusalDoneEvent`
```json
{
@@ -379676,7 +379626,7 @@ Schema 名称: `BetaResponseRefusalDoneEvent`
### Schema
-Schema 名称: `BetaResponseFunctionCallArgumentsDeltaEvent`
+Schema name: `BetaResponseFunctionCallArgumentsDeltaEvent`
```json
{
@@ -379858,11 +379808,11 @@ Schema 名称: `BetaResponseFunctionCallArgumentsDeltaEvent`
## response.function_call_arguments.done
-在函数调用参数最终确定时发出。
+在函数调用参数完成时发出。
### Schema
-Schema 名称: `BetaResponseFunctionCallArgumentsDoneEvent`
+Schema name: `BetaResponseFunctionCallArgumentsDoneEvent`
```json
{
@@ -380062,11 +380012,11 @@ Schema 名称: `BetaResponseFunctionCallArgumentsDoneEvent`
## response.file_search_call.in_progress
-在发起文件搜索调用时发出。
+在发起 文件搜索 调用时发出。
### Schema
-Schema 名称: `BetaResponseFileSearchCallInProgressEvent`
+Schema name: `BetaResponseFileSearchCallInProgressEvent`
```json
{
@@ -380229,11 +380179,11 @@ Schema 名称: `BetaResponseFileSearchCallInProgressEvent`
## response.file_search_call.searching
-在 文件搜索 当前正在执行搜索时发出。
+在当前进行文件搜索时发出。
### Schema
-Schema 名称: `BetaResponseFileSearchCallSearchingEvent`
+Schema name: `BetaResponseFileSearchCallSearchingEvent`
```json
{
@@ -380396,11 +380346,11 @@ Schema 名称: `BetaResponseFileSearchCallSearchingEvent`
## response.file_search_call.completed
-当一次文件搜索调用完成(已找到结果)时发出。
+在 文件搜索 调用完成时发出(已找到结果)。
### Schema
-Schema 名称: `BetaResponseFileSearchCallCompletedEvent`
+Schema name: `BetaResponseFileSearchCallCompletedEvent`
```json
{
@@ -380563,11 +380513,11 @@ Schema 名称: `BetaResponseFileSearchCallCompletedEvent`
## response.web_search_call.in_progress
-在发起网页搜索调用时发出。
+在发起 网页搜索 调用时发出。
### Schema
-Schema 名称: `BetaResponseWebSearchCallInProgressEvent`
+Schema name: `BetaResponseWebSearchCallInProgressEvent`
```json
{
@@ -380730,11 +380680,11 @@ Schema 名称: `BetaResponseWebSearchCallInProgressEvent`
## response.web_search_call.searching
-在执行网页搜索调用时发出。
+当 网页搜索 调用正在执行时发出。
### Schema
-Schema 名称: `BetaResponseWebSearchCallSearchingEvent`
+Schema name: `BetaResponseWebSearchCallSearchingEvent`
```json
{
@@ -380897,11 +380847,11 @@ Schema 名称: `BetaResponseWebSearchCallSearchingEvent`
## response.web_search_call.completed
-当 网页搜索 调用完成时发出。
+在 网页搜索 调用完成时发出。
### Schema
-Schema 名称: `BetaResponseWebSearchCallCompletedEvent`
+Schema name: `BetaResponseWebSearchCallCompletedEvent`
```json
{
@@ -381064,11 +381014,11 @@ Schema 名称: `BetaResponseWebSearchCallCompletedEvent`
## response.reasoning_summary_part.added
-当新增一个推理摘要片段时触发。
+当新增一段推理摘要内容时触发。
### Schema
-Schema 名称: `BetaResponseReasoningSummaryPartAddedEvent`
+Schema name: `BetaResponseReasoningSummaryPartAddedEvent`
```json
{
@@ -381329,11 +381279,11 @@ Schema 名称: `BetaResponseReasoningSummaryPartAddedEvent`
## response.reasoning_summary_part.done
-当推理摘要部分完成时发出。
+当推理摘要片段完成时触发。
### Schema
-Schema 名称: `BetaResponseReasoningSummaryPartDoneEvent`
+Schema name: `BetaResponseReasoningSummaryPartDoneEvent`
```json
{
@@ -381629,11 +381579,11 @@ Schema 名称: `BetaResponseReasoningSummaryPartDoneEvent`
## response.reasoning_summary_text.delta
-当向推理摘要文本添加增量时发出。
+当向推理摘要文本添加增量时触发。
### Schema
-Schema 名称: `BetaResponseReasoningSummaryTextDeltaEvent`
+Schema name: `BetaResponseReasoningSummaryTextDeltaEvent`
```json
{
@@ -381834,11 +381784,11 @@ Schema 名称: `BetaResponseReasoningSummaryTextDeltaEvent`
## response.reasoning_summary_text.done
-当推理摘要文本完成时发出。
+在推理摘要文本完成时触发。
### Schema
-Schema 名称: `BetaResponseReasoningSummaryTextDoneEvent`
+Schema name: `BetaResponseReasoningSummaryTextDoneEvent`
```json
{
@@ -382039,11 +381989,11 @@ Schema 名称: `BetaResponseReasoningSummaryTextDoneEvent`
## response.reasoning_text.delta
-在向推理文本添加增量时发出。
+当向推理文本添加增量时触发。
### Schema
-Schema 名称: `BetaResponseReasoningTextDeltaEvent`
+Schema name: `BetaResponseReasoningTextDeltaEvent`
```json
{
@@ -382244,11 +382194,11 @@ Schema 名称: `BetaResponseReasoningTextDeltaEvent`
## response.reasoning_text.done
-当一段推理文本完成时发出。
+在推理文本完成时发出。
### Schema
-Schema 名称: `BetaResponseReasoningTextDoneEvent`
+Schema name: `BetaResponseReasoningTextDoneEvent`
```json
{
@@ -382449,11 +382399,11 @@ Schema 名称: `BetaResponseReasoningTextDoneEvent`
## response.image_generation_call.completed
-当图片生成工具调用完成且最终图片可用时触发。
+当图像生成工具调用已完成且最终图像可用时触发。
### Schema
-Schema 名称: `BetaResponseImageGenCallCompletedEvent`
+Schema name: `BetaResponseImageGenCallCompletedEvent`
```json
{
@@ -382616,11 +382566,11 @@ Schema 名称: `BetaResponseImageGenCallCompletedEvent`
## response.image_generation_call.generating
-当图像生成工具调用正在主动生成图像时发出(中间状态)。
+当图像生成工具调用正在主动生成图像时触发(中间状态)。
### Schema
-Schema 名称: `BetaResponseImageGenCallGeneratingEvent`
+Schema name: `BetaResponseImageGenCallGeneratingEvent`
```json
{
@@ -382783,11 +382733,11 @@ Schema 名称: `BetaResponseImageGenCallGeneratingEvent`
## response.image_generation_call.in_progress
-当图像生成工具调用进行中时发出。
+在图像生成工具调用进行中时发出。
### Schema
-Schema 名称: `BetaResponseImageGenCallInProgressEvent`
+Schema name: `BetaResponseImageGenCallInProgressEvent`
```json
{
@@ -382950,11 +382900,11 @@ Schema 名称: `BetaResponseImageGenCallInProgressEvent`
## response.image_generation_call.partial_image
-在图像生成流式传输期间,当有部分图像可用时发出。
+在图像生成流式传输过程中,当有部分图像可用时发出。
### Schema
-Schema 名称: `BetaResponseImageGenCallPartialImageEvent`
+Schema name: `BetaResponseImageGenCallPartialImageEvent`
```json
{
@@ -383227,11 +383177,11 @@ Schema 名称: `BetaResponseImageGenCallPartialImageEvent`
## response.mcp_call_arguments.delta
-当 MCP 工具调用的参数出现增量(部分更新)时触发。
+当 MCP 工具调用的参数出现增量(部分更新)时发出。
### Schema
-Schema 名称: `BetaResponseMCPCallArgumentsDeltaEvent`
+Schema name: `BetaResponseMCPCallArgumentsDeltaEvent`
```json
{
@@ -383413,11 +383363,11 @@ Schema 名称: `BetaResponseMCPCallArgumentsDeltaEvent`
## response.mcp_call_arguments.done
-在 MCP 工具调用的参数最终确定时发出。
+当 MCP 工具调用的参数最终确定时发出。
### Schema
-Schema 名称: `BetaResponseMCPCallArgumentsDoneEvent`
+Schema name: `BetaResponseMCPCallArgumentsDoneEvent`
```json
{
@@ -383599,11 +383549,11 @@ Schema 名称: `BetaResponseMCPCallArgumentsDoneEvent`
## response.mcp_call.completed
-当 MCP 工具调用成功完成时发出。
+在 MCP 工具调用成功完成时发出。
### Schema
-Schema 名称: `BetaResponseMCPCallCompletedEvent`
+Schema name: `BetaResponseMCPCallCompletedEvent`
```json
{
@@ -383766,11 +383716,11 @@ Schema 名称: `BetaResponseMCPCallCompletedEvent`
## response.mcp_call.failed
-当 MCP 工具调用失败时发出。
+当某个 MCP 工具调用失败时触发。
### Schema
-Schema 名称: `BetaResponseMCPCallFailedEvent`
+Schema name: `BetaResponseMCPCallFailedEvent`
```json
{
@@ -383933,11 +383883,11 @@ Schema 名称: `BetaResponseMCPCallFailedEvent`
## response.mcp_call.in_progress
-当 MCP 工具调用进行时发出。
+当 MCP 工具调用进行中时发出。
### Schema
-Schema 名称: `BetaResponseMCPCallInProgressEvent`
+Schema name: `BetaResponseMCPCallInProgressEvent`
```json
{
@@ -384100,11 +384050,11 @@ Schema 名称: `BetaResponseMCPCallInProgressEvent`
## response.mcp_list_tools.completed
-在成功获取可用 MCP 工具列表时发出。
+当可用 MCP 工具列表已成功获取时触发。
### Schema
-Schema 名称: `BetaResponseMCPListToolsCompletedEvent`
+Schema name: `BetaResponseMCPListToolsCompletedEvent`
```json
{
@@ -384267,11 +384217,11 @@ Schema 名称: `BetaResponseMCPListToolsCompletedEvent`
## response.mcp_list_tools.failed
-在尝试列出可用的 MCP 工具失败时发出。
+当尝试列出可用的 MCP 工具失败时发出。
### Schema
-Schema 名称: `BetaResponseMCPListToolsFailedEvent`
+Schema name: `BetaResponseMCPListToolsFailedEvent`
```json
{
@@ -384434,11 +384384,11 @@ Schema 名称: `BetaResponseMCPListToolsFailedEvent`
## response.mcp_list_tools.in_progress
-当系统正在检索可用的 MCP 工具列表时发出。
+在系统正在检索可用的 MCP 工具列表时触发。
### Schema
-Schema 名称: `BetaResponseMCPListToolsInProgressEvent`
+Schema name: `BetaResponseMCPListToolsInProgressEvent`
```json
{
@@ -384601,11 +384551,11 @@ Schema 名称: `BetaResponseMCPListToolsInProgressEvent`
## response.code_interpreter_call.in_progress
-当代码解释器调用进行中时发出。
+在代码解释器调用进行中时发出。
### Schema
-Schema 名称: `BetaResponseCodeInterpreterCallInProgressEvent`
+Schema name: `BetaResponseCodeInterpreterCallInProgressEvent`
```json
{
@@ -384768,11 +384718,11 @@ Schema 名称: `BetaResponseCodeInterpreterCallInProgressEvent`
## response.code_interpreter_call.interpreting
-在代码解释器正在主动解释代码片段时发出。
+当代码解释器正在主动解释代码片段时触发。
### Schema
-Schema 名称: `BetaResponseCodeInterpreterCallInterpretingEvent`
+Schema name: `BetaResponseCodeInterpreterCallInterpretingEvent`
```json
{
@@ -384935,11 +384885,11 @@ Schema 名称: `BetaResponseCodeInterpreterCallInterpretingEvent`
## response.code_interpreter_call.completed
-当代码解释器调用完成时触发。
+在代码解释器调用完成时发出。
### Schema
-Schema 名称: `BetaResponseCodeInterpreterCallCompletedEvent`
+Schema name: `BetaResponseCodeInterpreterCallCompletedEvent`
```json
{
@@ -385102,11 +385052,11 @@ Schema 名称: `BetaResponseCodeInterpreterCallCompletedEvent`
## response.code_interpreter_call_code.delta
-当代码解释器流式传输部分代码片段时触发。
+当代码解释器流式传输部分代码片段时发出。
### Schema
-Schema 名称: `BetaResponseCodeInterpreterCallCodeDeltaEvent`
+Schema name: `BetaResponseCodeInterpreterCallCodeDeltaEvent`
```json
{
@@ -385288,11 +385238,11 @@ Schema 名称: `BetaResponseCodeInterpreterCallCodeDeltaEvent`
## response.code_interpreter_call_code.done
-当代码解释器完成代码片段时发出。
+当代码片段由代码解释器最终确定时触发。
### Schema
-Schema 名称: `BetaResponseCodeInterpreterCallCodeDoneEvent`
+Schema name: `BetaResponseCodeInterpreterCallCodeDoneEvent`
```json
{
@@ -385474,11 +385424,11 @@ Schema 名称: `BetaResponseCodeInterpreterCallCodeDoneEvent`
## response.output_text.annotation.added
-当有标注被添加到输出文本内容时发出。
+当向输出文本内容添加注解时发出。
### Schema
-Schema 名称: `BetaResponseOutputTextAnnotationAddedEvent`
+Schema name: `BetaResponseOutputTextAnnotationAddedEvent`
```json
{
@@ -386240,11 +386190,11 @@ Schema 名称: `BetaResponseOutputTextAnnotationAddedEvent`
## response.queued
-当响应被排队等待处理时触发。
+当 response(响应)被排入队列并等待处理时触发。
### Schema
-Schema 名称: `BetaResponseQueuedEvent`
+Schema name: `BetaResponseQueuedEvent`
```json
{
@@ -388767,8 +388717,7 @@ Schema 名称: `BetaResponseQueuedEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) user": {
@@ -389131,6 +389080,10 @@ Schema 名称: `BetaResponseQueuedEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -389143,7 +389096,8 @@ Schema 名称: `BetaResponseQueuedEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) instructions > (variant) 0": {
@@ -394416,23 +394370,6 @@ Schema 名称: `BetaResponseQueuedEvent`
"schemaType": "integer",
"children": []
},
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/BetaResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) beta.responses > (model) beta_response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/BetaResponseUsage",
@@ -394455,9 +394392,6 @@ Schema 名称: `BetaResponseQueuedEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -394467,8 +394401,7 @@ Schema 名称: `BetaResponseQueuedEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response_error > (schema) > (property) code > (member) 0": {
@@ -394619,6 +394552,13 @@ Schema 名称: `BetaResponseQueuedEvent`
}
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -450443,7 +450383,7 @@ Schema 名称: `BetaResponseQueuedEvent`
### Schema
-Schema 名称: `BetaResponseCustomToolCallInputDeltaEvent`
+Schema name: `BetaResponseCustomToolCallInputDeltaEvent`
```json
{
@@ -450628,7 +450568,7 @@ Schema 名称: `BetaResponseCustomToolCallInputDeltaEvent`
### Schema
-Schema 名称: `BetaResponseCustomToolCallInputDoneEvent`
+Schema name: `BetaResponseCustomToolCallInputDoneEvent`
```json
{
@@ -450809,11 +450749,11 @@ Schema 名称: `BetaResponseCustomToolCallInputDoneEvent`
## error
-在发生错误时发出。
+在发生错误时触发。
### Schema
-Schema 名称: `BetaResponseErrorEvent`
+Schema name: `BetaResponseErrorEvent`
```json
{
@@ -450999,7 +450939,7 @@ Schema 名称: `BetaResponseErrorEvent`
### Schema
-Schema 名称: `BetaResponseAudioDeltaEvent`
+Schema name: `BetaResponseAudioDeltaEvent`
```json
{
@@ -451144,11 +451084,11 @@ Schema 名称: `BetaResponseAudioDeltaEvent`
## response.audio.done
-当音频响应完成时发出。
+在音频响应完成时发出。
### Schema
-Schema 名称: `BetaResponseAudioDoneEvent`
+Schema name: `BetaResponseAudioDoneEvent`
```json
{
@@ -451274,11 +451214,11 @@ Schema 名称: `BetaResponseAudioDoneEvent`
## response.audio.transcript.delta
-当存在音频的部分转录时发出。
+当存在音频的部分转录文本时发出。
### Schema
-Schema 名称: `BetaResponseAudioTranscriptDeltaEvent`
+Schema name: `BetaResponseAudioTranscriptDeltaEvent`
```json
{
@@ -451423,11 +451363,11 @@ Schema 名称: `BetaResponseAudioTranscriptDeltaEvent`
## response.audio.transcript.done
-当完整音频转录完成时发出。
+当完整音频转写完成时触发。
### Schema
-Schema 名称: `BetaResponseAudioTranscriptDoneEvent`
+Schema name: `BetaResponseAudioTranscriptDoneEvent`
```json
{
@@ -451553,11 +451493,11 @@ Schema 名称: `BetaResponseAudioTranscriptDoneEvent`
## response.shell_call_command.added
-一个流式事件,用于指示已将 shell 命令添加到工具调用中。
+一个流式事件,表示一条 shell 命令已被添加到工具调用中。
### Schema
-Schema 名称: `BetaResponseShellCallCommandAddedStreamingEvent`
+Schema name: `BetaResponseShellCallCommandAddedStreamingEvent`
```json
{
@@ -451743,11 +451683,11 @@ Schema 名称: `BetaResponseShellCallCommandAddedStreamingEvent`
## response.shell_call_command.delta
-表示 shell 命令被增量更新的流式事件。
+一个流式事件,指示 shell 命令被增量更新。
### Schema
-Schema 名称: `BetaResponseShellCallCommandDeltaStreamingEvent`
+Schema name: `BetaResponseShellCallCommandDeltaStreamingEvent`
```json
{
@@ -451952,11 +451892,11 @@ Schema 名称: `BetaResponseShellCallCommandDeltaStreamingEvent`
## response.shell_call_command.done
-表示 shell 命令已完成的流式事件。
+指示 shell 命令已完成的流式事件。
### Schema
-Schema 名称: `BetaResponseShellCallCommandDoneStreamingEvent`
+Schema name: `BetaResponseShellCallCommandDoneStreamingEvent`
```json
{
@@ -452142,11 +452082,11 @@ Schema 名称: `BetaResponseShellCallCommandDoneStreamingEvent`
## response.shell_call_output_content.delta
-表示 shell 调用输出被增量添加的流式事件。
+一个流式事件,指示 shell 调用输出已增量添加。
### Schema
-Schema 名称: `BetaResponseShellCallOutputContentDeltaStreamingEvent`
+Schema name: `BetaResponseShellCallOutputContentDeltaStreamingEvent`
```json
{
@@ -452395,11 +452335,11 @@ Schema 名称: `BetaResponseShellCallOutputContentDeltaStreamingEvent`
## response.shell_call_output_content.done
-指示 shell 调用输出已完成的一个流事件。
+表示 shell 调用输出已完成的事件。
### Schema
-Schema 名称: `BetaResponseShellCallOutputContentDoneStreamingEvent`
+Schema name: `BetaResponseShellCallOutputContentDoneStreamingEvent`
```json
{
diff --git a/docs/zh/api/reference/resources/beta/subresources/responses/websocket-events.md b/docs/zh/api/reference/resources/beta/subresources/responses/websocket-events.md
index ca17735..f1dd8d9 100644
--- a/docs/zh/api/reference/resources/beta/subresources/responses/websocket-events.md
+++ b/docs/zh/api/reference/resources/beta/subresources/responses/websocket-events.md
@@ -1,8 +1,8 @@
-# WebSocket events
+# WebSocket 事件
-> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt). 文档页面的 Markdown 版本可通过在页面 URL 后追加 `.md` 获取。
+> 完整文档索引请参见 [llms.txt](/llms.txt)。文档页面的 Markdown 版本可通过在页面 URL 后追加 `.md` 获取。
-通过持久化的 Responses API WebSocket 连接发送客户端事件并接收服务端事件。 [详细了解 WebSocket 模式。](https://developers.openai.com/api/docs/guides/websocket-mode)
+通过持久的 Responses API WebSocket 连接发送客户端事件并接收服务端事件。 [了解有关 WebSocket 模式的更多信息。](https://developers.openai.com/api/docs/guides/websocket-mode)
## 客户端事件
@@ -10,18 +10,18 @@
### response.create
-用于通过持久 WebSocket 连接创建 response 的客户端事件。
-此负载使用与 `POST /v1/responses`,相同的顶层字段,外加
-仅限 WebSocket 的信封元数据。
+通过持久 WebSocket 连接创建响应的客户端事件。
+此负载使用与 `POST /v1/responses`,相同的顶级字段,
+以及 WebSocket 专属的包络元数据。
备注:
-- `stream` 在 WebSocket 上是隐式的,不应发送。
+- `stream` 在 WebSocket 上隐式存在,不应发送。
- `background` 在 WebSocket 上不支持。
-- `stream_id` 仅适用于 WebSocket,不属于 `POST /v1/responses`.
+- `stream_id` 是 WebSocket 专有的,不属于 `POST /v1/responses`.
#### Schema
-Schema 名称: `BetaResponsesClientEventResponseCreate`
+Schema name: `BetaResponsesClientEventResponseCreate`
```json
{
@@ -40057,12 +40057,12 @@ Schema 名称: `BetaResponsesClientEventResponseCreate`
### response.inject
通过 WebSocket 连接向正在进行的响应注入输入项。
-这些项会被原子性地校验并提交。目前,服务端
-接受客户端拥有的工具输出,以恢复正在等待的智能体。
+这些输入项会被原子地校验并提交。目前,服务端
+接受客户端拥有的工具输出,用于恢复一个正在等待的智能体。
#### Schema
-Schema 名称: `BetaResponseInjectEvent`
+Schema name: `BetaResponseInjectEvent`
```json
{
@@ -68624,7 +68624,7 @@ Schema 名称: `BetaResponseInjectEvent`
## 服务端事件(仅限 WebSocket)
-仅通过 Responses API WebSocket 连接发出的事件。
+事件仅通过 Responses API WebSocket 连接发出。
### error
@@ -68632,7 +68632,7 @@ Schema 名称: `BetaResponseInjectEvent`
#### Schema
-Schema 名称: `BetaResponseWsError`
+Schema name: `BetaResponseWsError`
```json
{
@@ -68923,12 +68923,12 @@ Schema 名称: `BetaResponseWsError`
### response.inject.created
-当所有注入的输入项都已通过校验并提交到
+在所有注入的输入项均已通过校验并提交到
当前响应时触发。
#### Schema
-Schema 名称: `BetaResponseInjectCreatedEvent`
+Schema name: `BetaResponseInjectCreatedEvent`
```json
{
@@ -69050,13 +69050,13 @@ Schema 名称: `BetaResponseInjectCreatedEvent`
### response.inject.failed
-当注入的输入无法提交到响应时触发。该事件
-返回未提交的原始输入,以便客户端在另一个
-响应中适时进行重试。
+当注入的输入无法被提交到响应时触发。该事件
+会返回未提交的原始输入,以便客户端在合适的另一个
+响应中重试该输入。
#### Schema
-Schema 名称: `BetaResponseInjectFailedEvent`
+Schema name: `BetaResponseInjectFailedEvent`
```json
{
@@ -97751,11 +97751,11 @@ Schema 名称: `BetaResponseInjectFailedEvent`
### response.created
-当响应被创建时发出的事件。
+在创建响应时发出的事件。
#### Schema
-Schema 名称: `BetaResponseCreatedEvent`
+Schema name: `BetaResponseCreatedEvent`
```json
{
@@ -100313,8 +100313,7 @@ Schema 名称: `BetaResponseCreatedEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) user": {
@@ -100677,6 +100676,10 @@ Schema 名称: `BetaResponseCreatedEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -100689,7 +100692,8 @@ Schema 名称: `BetaResponseCreatedEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) instructions > (variant) 0": {
@@ -105962,23 +105966,6 @@ Schema 名称: `BetaResponseCreatedEvent`
"schemaType": "integer",
"children": []
},
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/BetaResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) beta.responses > (model) beta_response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/BetaResponseUsage",
@@ -106001,9 +105988,6 @@ Schema 名称: `BetaResponseCreatedEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -106013,8 +105997,7 @@ Schema 名称: `BetaResponseCreatedEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response_error > (schema) > (property) code > (member) 0": {
@@ -106165,6 +106148,13 @@ Schema 名称: `BetaResponseCreatedEvent`
}
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -162016,7 +162006,7 @@ Schema 名称: `BetaResponseCreatedEvent`
#### Schema
-Schema 名称: `BetaResponseInProgressEvent`
+Schema name: `BetaResponseInProgressEvent`
```json
{
@@ -164574,8 +164564,7 @@ Schema 名称: `BetaResponseInProgressEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) user": {
@@ -164938,6 +164927,10 @@ Schema 名称: `BetaResponseInProgressEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -164950,7 +164943,8 @@ Schema 名称: `BetaResponseInProgressEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) instructions > (variant) 0": {
@@ -170223,23 +170217,6 @@ Schema 名称: `BetaResponseInProgressEvent`
"schemaType": "integer",
"children": []
},
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/BetaResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) beta.responses > (model) beta_response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/BetaResponseUsage",
@@ -170262,9 +170239,6 @@ Schema 名称: `BetaResponseInProgressEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -170274,8 +170248,7 @@ Schema 名称: `BetaResponseInProgressEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response_error > (schema) > (property) code > (member) 0": {
@@ -170426,6 +170399,13 @@ Schema 名称: `BetaResponseInProgressEvent`
}
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -226273,11 +226253,11 @@ Schema 名称: `BetaResponseInProgressEvent`
### response.completed
-在模型响应完成时发出。
+当模型响应完成时发出。
#### Schema
-Schema 名称: `BetaResponseCompletedEvent`
+Schema name: `BetaResponseCompletedEvent`
```json
{
@@ -228835,8 +228815,7 @@ Schema 名称: `BetaResponseCompletedEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) user": {
@@ -229199,6 +229178,10 @@ Schema 名称: `BetaResponseCompletedEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -229211,7 +229194,8 @@ Schema 名称: `BetaResponseCompletedEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) instructions > (variant) 0": {
@@ -234484,23 +234468,6 @@ Schema 名称: `BetaResponseCompletedEvent`
"schemaType": "integer",
"children": []
},
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/BetaResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) beta.responses > (model) beta_response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/BetaResponseUsage",
@@ -234523,9 +234490,6 @@ Schema 名称: `BetaResponseCompletedEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -234535,8 +234499,7 @@ Schema 名称: `BetaResponseCompletedEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response_error > (schema) > (property) code > (member) 0": {
@@ -234687,6 +234650,13 @@ Schema 名称: `BetaResponseCompletedEvent`
}
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -290551,11 +290521,11 @@ Schema 名称: `BetaResponseCompletedEvent`
### response.failed
-响应失败时发出的事件。
+当响应失败时发出的事件。
#### Schema
-Schema 名称: `BetaResponseFailedEvent`
+Schema name: `BetaResponseFailedEvent`
```json
{
@@ -293113,8 +293083,7 @@ Schema 名称: `BetaResponseFailedEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) user": {
@@ -293477,6 +293446,10 @@ Schema 名称: `BetaResponseFailedEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -293489,7 +293462,8 @@ Schema 名称: `BetaResponseFailedEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) instructions > (variant) 0": {
@@ -298762,23 +298736,6 @@ Schema 名称: `BetaResponseFailedEvent`
"schemaType": "integer",
"children": []
},
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/BetaResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) beta.responses > (model) beta_response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/BetaResponseUsage",
@@ -298801,9 +298758,6 @@ Schema 名称: `BetaResponseFailedEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -298813,8 +298767,7 @@ Schema 名称: `BetaResponseFailedEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response_error > (schema) > (property) code > (member) 0": {
@@ -298965,6 +298918,13 @@ Schema 名称: `BetaResponseFailedEvent`
}
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -354810,11 +354770,11 @@ Schema 名称: `BetaResponseFailedEvent`
### response.incomplete
-当响应以未完成状态结束时发出的事件。
+当响应未完成而结束时发出的事件。
#### Schema
-Schema 名称: `BetaResponseIncompleteEvent`
+Schema name: `BetaResponseIncompleteEvent`
```json
{
@@ -357372,8 +357332,7 @@ Schema 名称: `BetaResponseIncompleteEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) user": {
@@ -357736,6 +357695,10 @@ Schema 名称: `BetaResponseIncompleteEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -357748,7 +357711,8 @@ Schema 名称: `BetaResponseIncompleteEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) instructions > (variant) 0": {
@@ -363021,23 +362985,6 @@ Schema 名称: `BetaResponseIncompleteEvent`
"schemaType": "integer",
"children": []
},
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/BetaResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) beta.responses > (model) beta_response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/BetaResponseUsage",
@@ -363060,9 +363007,6 @@ Schema 名称: `BetaResponseIncompleteEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -363072,8 +363016,7 @@ Schema 名称: `BetaResponseIncompleteEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response_error > (schema) > (property) code > (member) 0": {
@@ -363224,6 +363167,13 @@ Schema 名称: `BetaResponseIncompleteEvent`
}
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -419069,11 +419019,11 @@ Schema 名称: `BetaResponseIncompleteEvent`
### response.output_item.added
-当新增输出项时发出。
+当新增一个输出项时发出。
#### Schema
-Schema 名称: `BetaResponseOutputItemAddedEvent`
+Schema name: `BetaResponseOutputItemAddedEvent`
```json
{
@@ -446637,11 +446587,11 @@ Schema 名称: `BetaResponseOutputItemAddedEvent`
### response.output_item.done
-当输出项被标记为完成时发出。
+当某个输出项被标记为完成时触发。
#### Schema
-Schema 名称: `BetaResponseOutputItemDoneEvent`
+Schema name: `BetaResponseOutputItemDoneEvent`
```json
{
@@ -474211,11 +474161,11 @@ Schema 名称: `BetaResponseOutputItemDoneEvent`
### response.content_part.added
-当新增内容片段时发出。
+当添加新的内容分块时发出。
#### Schema
-Schema 名称: `BetaResponseContentPartAddedEvent`
+Schema name: `BetaResponseContentPartAddedEvent`
```json
{
@@ -475435,11 +475385,11 @@ Schema 名称: `BetaResponseContentPartAddedEvent`
### response.content_part.done
-当内容部分完成时发出。
+当内容片段完成时发出。
#### Schema
-Schema 名称: `BetaResponseContentPartDoneEvent`
+Schema name: `BetaResponseContentPartDoneEvent`
```json
{
@@ -476659,11 +476609,11 @@ Schema 名称: `BetaResponseContentPartDoneEvent`
### response.output_text.delta
-当存在额外的文本增量时发出。
+当出现额外的文本增量时触发。
#### Schema
-Schema 名称: `BetaResponseTextDeltaEvent`
+Schema name: `BetaResponseTextDeltaEvent`
```json
{
@@ -477023,11 +476973,11 @@ Schema 名称: `BetaResponseTextDeltaEvent`
### response.output_text.done
-在文本内容最终确定时发出。
+当文本内容被最终确定时发出。
#### Schema
-Schema 名称: `BetaResponseTextDoneEvent`
+Schema name: `BetaResponseTextDoneEvent`
```json
{
@@ -477391,7 +477341,7 @@ Schema 名称: `BetaResponseTextDoneEvent`
#### Schema
-Schema 名称: `BetaResponseRefusalDeltaEvent`
+Schema name: `BetaResponseRefusalDeltaEvent`
```json
{
@@ -477627,11 +477577,11 @@ Schema 名称: `BetaResponseRefusalDeltaEvent`
### response.refusal.done
-在拒绝文本最终确定时发出。
+在拒绝文本确定后发出。
#### Schema
-Schema 名称: `BetaResponseRefusalDoneEvent`
+Schema name: `BetaResponseRefusalDoneEvent`
```json
{
@@ -477867,11 +477817,11 @@ Schema 名称: `BetaResponseRefusalDoneEvent`
### response.function_call_arguments.delta
-在出现部分函数调用参数增量时发出。
+当存在部分函数调用参数的增量时发出。
#### Schema
-Schema 名称: `BetaResponseFunctionCallArgumentsDeltaEvent`
+Schema name: `BetaResponseFunctionCallArgumentsDeltaEvent`
```json
{
@@ -478088,11 +478038,11 @@ Schema 名称: `BetaResponseFunctionCallArgumentsDeltaEvent`
### response.function_call_arguments.done
-在函数调用参数最终确定时发出。
+当函数调用参数最终确定时发出。
#### Schema
-Schema 名称: `BetaResponseFunctionCallArgumentsDoneEvent`
+Schema name: `BetaResponseFunctionCallArgumentsDoneEvent`
```json
{
@@ -478327,11 +478277,11 @@ Schema 名称: `BetaResponseFunctionCallArgumentsDoneEvent`
### response.file_search_call.in_progress
-在发起文件搜索调用时发出。
+在发起 文件搜索 调用时发出。
#### Schema
-Schema 名称: `BetaResponseFileSearchCallInProgressEvent`
+Schema name: `BetaResponseFileSearchCallInProgressEvent`
```json
{
@@ -478529,11 +478479,11 @@ Schema 名称: `BetaResponseFileSearchCallInProgressEvent`
### response.file_search_call.searching
-当 文件搜索 正在进行搜索时触发。
+在文件搜索正在进行搜索时发出。
#### Schema
-Schema 名称: `BetaResponseFileSearchCallSearchingEvent`
+Schema name: `BetaResponseFileSearchCallSearchingEvent`
```json
{
@@ -478731,11 +478681,11 @@ Schema 名称: `BetaResponseFileSearchCallSearchingEvent`
### response.file_search_call.completed
-在 文件搜索 调用完成时触发(已找到结果)。
+在 文件搜索 调用完成(已找到结果)时发出。
#### Schema
-Schema 名称: `BetaResponseFileSearchCallCompletedEvent`
+Schema name: `BetaResponseFileSearchCallCompletedEvent`
```json
{
@@ -478937,7 +478887,7 @@ Schema 名称: `BetaResponseFileSearchCallCompletedEvent`
#### Schema
-Schema 名称: `BetaResponseWebSearchCallInProgressEvent`
+Schema name: `BetaResponseWebSearchCallInProgressEvent`
```json
{
@@ -479135,11 +479085,11 @@ Schema 名称: `BetaResponseWebSearchCallInProgressEvent`
### response.web_search_call.searching
-当一次网页搜索调用正在执行时发出。
+在 网页搜索 调用执行时触发。
#### Schema
-Schema 名称: `BetaResponseWebSearchCallSearchingEvent`
+Schema name: `BetaResponseWebSearchCallSearchingEvent`
```json
{
@@ -479337,11 +479287,11 @@ Schema 名称: `BetaResponseWebSearchCallSearchingEvent`
### response.web_search_call.completed
-在一次网页搜索调用完成时发出。
+当一次网页搜索调用完成时发出。
#### Schema
-Schema 名称: `BetaResponseWebSearchCallCompletedEvent`
+Schema name: `BetaResponseWebSearchCallCompletedEvent`
```json
{
@@ -479539,11 +479489,11 @@ Schema 名称: `BetaResponseWebSearchCallCompletedEvent`
### response.reasoning_summary_part.added
-当新增一个推理摘要片段时发出。
+当新增一个推理摘要部分时触发。
#### Schema
-Schema 名称: `BetaResponseReasoningSummaryPartAddedEvent`
+Schema name: `BetaResponseReasoningSummaryPartAddedEvent`
```json
{
@@ -479839,11 +479789,11 @@ Schema 名称: `BetaResponseReasoningSummaryPartAddedEvent`
### response.reasoning_summary_part.done
-当某个推理摘要部分完成时发出。
+在推理摘要部分完成时发出。
#### Schema
-Schema 名称: `BetaResponseReasoningSummaryPartDoneEvent`
+Schema name: `BetaResponseReasoningSummaryPartDoneEvent`
```json
{
@@ -480174,11 +480124,11 @@ Schema 名称: `BetaResponseReasoningSummaryPartDoneEvent`
### response.reasoning_summary_text.delta
-当向推理摘要文本添加增量时发出。
+当向推理摘要文本添加增量时触发。
#### Schema
-Schema 名称: `BetaResponseReasoningSummaryTextDeltaEvent`
+Schema name: `BetaResponseReasoningSummaryTextDeltaEvent`
```json
{
@@ -480414,11 +480364,11 @@ Schema 名称: `BetaResponseReasoningSummaryTextDeltaEvent`
### response.reasoning_summary_text.done
-在推理摘要文本完成时触发。
+在推理摘要文本完成时发出。
#### Schema
-Schema 名称: `BetaResponseReasoningSummaryTextDoneEvent`
+Schema name: `BetaResponseReasoningSummaryTextDoneEvent`
```json
{
@@ -480654,11 +480604,11 @@ Schema 名称: `BetaResponseReasoningSummaryTextDoneEvent`
### response.reasoning_text.delta
-当向推理文本添加增量时发出。
+当向推理文本添加增量时触发。
#### Schema
-Schema 名称: `BetaResponseReasoningTextDeltaEvent`
+Schema name: `BetaResponseReasoningTextDeltaEvent`
```json
{
@@ -480898,7 +480848,7 @@ Schema 名称: `BetaResponseReasoningTextDeltaEvent`
#### Schema
-Schema 名称: `BetaResponseReasoningTextDoneEvent`
+Schema name: `BetaResponseReasoningTextDoneEvent`
```json
{
@@ -481134,11 +481084,11 @@ Schema 名称: `BetaResponseReasoningTextDoneEvent`
### response.image_generation_call.completed
-在图像生成工具调用已完成且最终图像可用时发出。
+当图像生成工具调用已完成且最终图像可用时发出。
#### Schema
-Schema 名称: `BetaResponseImageGenCallCompletedEvent`
+Schema name: `BetaResponseImageGenCallCompletedEvent`
```json
{
@@ -481336,11 +481286,11 @@ Schema 名称: `BetaResponseImageGenCallCompletedEvent`
### response.image_generation_call.generating
-当图像生成工具调用正在主动生成图像时发出(中间状态)。
+当图像生成工具调用正在主动生成图像(中间状态)时发出。
#### Schema
-Schema 名称: `BetaResponseImageGenCallGeneratingEvent`
+Schema name: `BetaResponseImageGenCallGeneratingEvent`
```json
{
@@ -481542,7 +481492,7 @@ Schema 名称: `BetaResponseImageGenCallGeneratingEvent`
#### Schema
-Schema 名称: `BetaResponseImageGenCallInProgressEvent`
+Schema name: `BetaResponseImageGenCallInProgressEvent`
```json
{
@@ -481744,7 +481694,7 @@ Schema 名称: `BetaResponseImageGenCallInProgressEvent`
#### Schema
-Schema 名称: `BetaResponseImageGenCallPartialImageEvent`
+Schema name: `BetaResponseImageGenCallPartialImageEvent`
```json
{
@@ -482056,7 +482006,7 @@ Schema 名称: `BetaResponseImageGenCallPartialImageEvent`
#### Schema
-Schema 名称: `BetaResponseMCPCallArgumentsDeltaEvent`
+Schema name: `BetaResponseMCPCallArgumentsDeltaEvent`
```json
{
@@ -482277,7 +482227,7 @@ Schema 名称: `BetaResponseMCPCallArgumentsDeltaEvent`
#### Schema
-Schema 名称: `BetaResponseMCPCallArgumentsDoneEvent`
+Schema name: `BetaResponseMCPCallArgumentsDoneEvent`
```json
{
@@ -482494,11 +482444,11 @@ Schema 名称: `BetaResponseMCPCallArgumentsDoneEvent`
### response.mcp_call.completed
-当 MCP 工具调用成功完成时发出。
+当 MCP 工具调用成功完成时发出。
#### Schema
-Schema 名称: `BetaResponseMCPCallCompletedEvent`
+Schema name: `BetaResponseMCPCallCompletedEvent`
```json
{
@@ -482696,11 +482646,11 @@ Schema 名称: `BetaResponseMCPCallCompletedEvent`
### response.mcp_call.failed
-当 MCP 工具调用失败时发出。
+当 MCP 工具调用失败时发出。
#### Schema
-Schema 名称: `BetaResponseMCPCallFailedEvent`
+Schema name: `BetaResponseMCPCallFailedEvent`
```json
{
@@ -482898,11 +482848,11 @@ Schema 名称: `BetaResponseMCPCallFailedEvent`
### response.mcp_call.in_progress
-当 MCP 工具调用进行中时发出。
+MCP 工具调用进行中时发出。
#### Schema
-Schema 名称: `BetaResponseMCPCallInProgressEvent`
+Schema name: `BetaResponseMCPCallInProgressEvent`
```json
{
@@ -483100,11 +483050,11 @@ Schema 名称: `BetaResponseMCPCallInProgressEvent`
### response.mcp_list_tools.completed
-在成功检索到可用的 MCP 工具列表时发出。
+在成功获取可用的 MCP 工具列表时发出。
#### Schema
-Schema 名称: `BetaResponseMCPListToolsCompletedEvent`
+Schema name: `BetaResponseMCPListToolsCompletedEvent`
```json
{
@@ -483306,7 +483256,7 @@ Schema 名称: `BetaResponseMCPListToolsCompletedEvent`
#### Schema
-Schema 名称: `BetaResponseMCPListToolsFailedEvent`
+Schema name: `BetaResponseMCPListToolsFailedEvent`
```json
{
@@ -483504,11 +483454,11 @@ Schema 名称: `BetaResponseMCPListToolsFailedEvent`
### response.mcp_list_tools.in_progress
-在系统正在检索可用的 MCP 工具列表时发出。
+在系统正在检索可用 MCP 工具列表时发出。
#### Schema
-Schema 名称: `BetaResponseMCPListToolsInProgressEvent`
+Schema name: `BetaResponseMCPListToolsInProgressEvent`
```json
{
@@ -483706,11 +483656,11 @@ Schema 名称: `BetaResponseMCPListToolsInProgressEvent`
### response.code_interpreter_call.in_progress
-在代码解释器调用进行中时发出。
+当代码解释器调用进行中时发出。
#### Schema
-Schema 名称: `BetaResponseCodeInterpreterCallInProgressEvent`
+Schema name: `BetaResponseCodeInterpreterCallInProgressEvent`
```json
{
@@ -483912,7 +483862,7 @@ Schema 名称: `BetaResponseCodeInterpreterCallInProgressEvent`
#### Schema
-Schema 名称: `BetaResponseCodeInterpreterCallInterpretingEvent`
+Schema name: `BetaResponseCodeInterpreterCallInterpretingEvent`
```json
{
@@ -484110,11 +484060,11 @@ Schema 名称: `BetaResponseCodeInterpreterCallInterpretingEvent`
### response.code_interpreter_call.completed
-在代码解释器调用完成时发出。
+当代码解释器调用完成时发出。
#### Schema
-Schema 名称: `BetaResponseCodeInterpreterCallCompletedEvent`
+Schema name: `BetaResponseCodeInterpreterCallCompletedEvent`
```json
{
@@ -484312,11 +484262,11 @@ Schema 名称: `BetaResponseCodeInterpreterCallCompletedEvent`
### response.code_interpreter_call_code.delta
-当代码解释器流式输出部分代码片段时触发。
+当代码解释器流式传输部分代码片段时发出。
#### Schema
-Schema 名称: `BetaResponseCodeInterpreterCallCodeDeltaEvent`
+Schema name: `BetaResponseCodeInterpreterCallCodeDeltaEvent`
```json
{
@@ -484533,11 +484483,11 @@ Schema 名称: `BetaResponseCodeInterpreterCallCodeDeltaEvent`
### response.code_interpreter_call_code.done
-当代码片段由代码解释器最终确定时发出。
+当代码片段被代码解释器最终确定时发出。
#### Schema
-Schema 名称: `BetaResponseCodeInterpreterCallCodeDoneEvent`
+Schema name: `BetaResponseCodeInterpreterCallCodeDoneEvent`
```json
{
@@ -484754,11 +484704,11 @@ Schema 名称: `BetaResponseCodeInterpreterCallCodeDoneEvent`
### response.output_text.annotation.added
-当注解被添加到输出文本内容时触发。
+当向输出文本内容添加注释时触发。
#### Schema
-Schema 名称: `BetaResponseOutputTextAnnotationAddedEvent`
+Schema name: `BetaResponseOutputTextAnnotationAddedEvent`
```json
{
@@ -485555,11 +485505,11 @@ Schema 名称: `BetaResponseOutputTextAnnotationAddedEvent`
### response.queued
-在响应已加入队列并等待处理时发出。
+当响应已排队并等待处理时发出。
#### Schema
-Schema 名称: `BetaResponseQueuedEvent`
+Schema name: `BetaResponseQueuedEvent`
```json
{
@@ -488117,8 +488067,7 @@ Schema 名称: `BetaResponseQueuedEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) user": {
@@ -488481,6 +488430,10 @@ Schema 名称: `BetaResponseQueuedEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -488493,7 +488446,8 @@ Schema 名称: `BetaResponseQueuedEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) instructions > (variant) 0": {
@@ -493766,23 +493720,6 @@ Schema 名称: `BetaResponseQueuedEvent`
"schemaType": "integer",
"children": []
},
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/BetaResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) beta.responses > (model) beta_response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/BetaResponseUsage",
@@ -493805,9 +493742,6 @@ Schema 名称: `BetaResponseQueuedEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -493817,8 +493751,7 @@ Schema 名称: `BetaResponseQueuedEvent`
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) input_tokens_details",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens",
"(resource) beta.responses > (model) beta_response_usage > (schema) > (property) output_tokens_details",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens",
- "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) compute_units"
+ "(resource) beta.responses > (model) beta_response_usage > (schema) > (property) total_tokens"
]
},
"(resource) beta.responses > (model) beta_response_error > (schema) > (property) code > (member) 0": {
@@ -493969,6 +493902,13 @@ Schema 名称: `BetaResponseQueuedEvent`
}
},
"(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) beta.responses > (model) beta_response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -549789,11 +549729,11 @@ Schema 名称: `BetaResponseQueuedEvent`
### response.custom_tool_call_input.delta
-表示对自定义工具调用输入的增量(部分更新)的事件。
+表示对自定义工具调用的输入进行增量(部分更新)的事件。
#### Schema
-Schema 名称: `BetaResponseCustomToolCallInputDeltaEvent`
+Schema name: `BetaResponseCustomToolCallInputDeltaEvent`
```json
{
@@ -550013,7 +549953,7 @@ Schema 名称: `BetaResponseCustomToolCallInputDeltaEvent`
#### Schema
-Schema 名称: `BetaResponseCustomToolCallInputDoneEvent`
+Schema name: `BetaResponseCustomToolCallInputDoneEvent`
```json
{
@@ -550233,7 +550173,7 @@ Schema 名称: `BetaResponseCustomToolCallInputDoneEvent`
#### Schema
-Schema 名称: `BetaResponseAudioDeltaEvent`
+Schema name: `BetaResponseAudioDeltaEvent`
```json
{
@@ -550417,7 +550357,7 @@ Schema 名称: `BetaResponseAudioDeltaEvent`
#### Schema
-Schema 名称: `BetaResponseAudioDoneEvent`
+Schema name: `BetaResponseAudioDoneEvent`
```json
{
@@ -550578,11 +550518,11 @@ Schema 名称: `BetaResponseAudioDoneEvent`
### response.audio.transcript.delta
-当存在音频的部分转录文本时发出。
+当存在音频的部分转写文本时发出。
#### Schema
-Schema 名称: `BetaResponseAudioTranscriptDeltaEvent`
+Schema name: `BetaResponseAudioTranscriptDeltaEvent`
```json
{
@@ -550762,11 +550702,11 @@ Schema 名称: `BetaResponseAudioTranscriptDeltaEvent`
### response.audio.transcript.done
-在完整音频转录完成时发出。
+当完整音频转录完成时发出。
#### Schema
-Schema 名称: `BetaResponseAudioTranscriptDoneEvent`
+Schema name: `BetaResponseAudioTranscriptDoneEvent`
```json
{
@@ -550927,11 +550867,11 @@ Schema 名称: `BetaResponseAudioTranscriptDoneEvent`
### response.shell_call_command.added
-一个流式事件,指示某个 shell 命令已添加到工具调用中。
+指示已向工具调用添加 shell 命令的流事件。
#### Schema
-Schema 名称: `BetaResponseShellCallCommandAddedStreamingEvent`
+Schema name: `BetaResponseShellCallCommandAddedStreamingEvent`
```json
{
@@ -551152,11 +551092,11 @@ Schema 名称: `BetaResponseShellCallCommandAddedStreamingEvent`
### response.shell_call_command.delta
-一个流式事件,表示某个 shell 命令被增量更新。
+指示 shell 命令被增量更新的流式事件。
#### Schema
-Schema 名称: `BetaResponseShellCallCommandDeltaStreamingEvent`
+Schema name: `BetaResponseShellCallCommandDeltaStreamingEvent`
```json
{
@@ -551394,13 +551334,13 @@ Schema 名称: `BetaResponseShellCallCommandDeltaStreamingEvent`
}
```
-### response.shell_call_command.done
+### response.shell_command.done
-指示 shell 命令已完成的流式事件。
+表示 shell 命令已完成的流式事件。
#### Schema
-Schema 名称: `BetaResponseShellCallCommandDoneStreamingEvent`
+Schema name: `BetaResponseShellCallCommandDoneStreamingEvent`
```json
{
@@ -551621,11 +551561,11 @@ Schema 名称: `BetaResponseShellCallCommandDoneStreamingEvent`
### response.shell_call_output_content.delta
-一个流式事件,用于表示 shell 调用输出正在被增量添加。
+一个流式事件,指示 shell 调用输出已增量添加。
#### Schema
-Schema 名称: `BetaResponseShellCallOutputContentDeltaStreamingEvent`
+Schema name: `BetaResponseShellCallOutputContentDeltaStreamingEvent`
```json
{
@@ -551909,11 +551849,11 @@ Schema 名称: `BetaResponseShellCallOutputContentDeltaStreamingEvent`
### response.shell_call_output_content.done
-指示 shell 调用输出已完成的事件。
+表示 shell 调用输出已完成的流式事件。
#### Schema
-Schema 名称: `BetaResponseShellCallOutputContentDoneStreamingEvent`
+Schema name: `BetaResponseShellCallOutputContentDoneStreamingEvent`
```json
{
diff --git a/docs/zh/api/reference/resources/chat.md b/docs/zh/api/reference/resources/chat.md
index f70e421..f26e110 100644
--- a/docs/zh/api/reference/resources/chat.md
+++ b/docs/zh/api/reference/resources/chat.md
@@ -1,58 +1,58 @@
# Chat
-> 完整文档索引请参见 [llms.txt](/llms.txt)。文档页面的 Markdown 版本可通过在页面 URL 末尾追加 `.md` 获取。
+> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。在页面 URL 末尾追加 `.md` 即可获取相应文档页面的 Markdown 版本。
# Completions
-## 创建聊天补全
+## Create chat completion
**post** `/chat/completions`
-**开始新项目?** 我们推荐尝试 [Responses](/docs/api-reference/responses)
-以充分利用 OpenAI 平台的最新特性。比较
+**开始一个新项目?** 我们推荐你试用 [Responses](/docs/api-reference/responses)
+以充分利用 OpenAI 平台的最新功能。比较
[Chat Completions 与 Responses](/docs/guides/responses-vs-chat-completions?api-mode=responses).
---
-为给定的聊天对话创建模型响应。更多内容请参阅
+为给定的聊天会话创建模型响应。详见
[文本生成](/docs/guides/text-generation), [视觉](/docs/guides/vision),
和 [音频](/docs/guides/audio) 指南。
-可支持的参数可能因用于生成
+参数支持可能因用于生成
响应的模型而异,尤其是较新的推理模型。仅
-支持推理模型的参数会在下方注明。有关推理模型中
+推理模型支持的参数将在下方注明。有关推理模型中
不受支持参数的当前情况,请,
[参阅推理指南](/docs/guides/reasoning).
-返回一个聊天补全对象,若请求以流式传输,则返回一系列聊天补全
-分块对象。
+返回一个聊天补全对象,如果请求以流式传输,则返回聊天补全
+分块对象的流式序列。
-### Body Parameters
+### 正文参数
- `messages: array of ChatCompletionMessageParam`
- 到目前为止组成对话的消息列表。根据所使用的
+ 包含到目前为止对话内容的消息列表。根据你使用的
[model](/docs/models) ,支持不同的消息类型(模态),例如
- 支持的,例如 [text](/docs/guides/text-generation),
- [images](/docs/guides/vision),以及 [audio](/docs/guides/audio).
+ 支持,诸如 [text](/docs/guides/text-generation),
+ [images](/docs/guides/vision)、和 [audio](/docs/guides/audio).
- `ChatCompletionDeveloperMessageParam object { content, role, name }`
- 开发者提供的指令,无论用户发送什么
- 消息,模型都应遵循。对于 o1 及更新的模型, `developer` messages
- 将取代先前的 `system` messages。
+ 开发者提供的指令,模型应当遵循这些指令,而无论用户发送了什么样的
+ 消息。在 o1 及更新模型上,developer, `developer` 消息取代了原先的
+ 消息中的 `system` messages。
- `content: string or array of ChatCompletionContentPartText`
- 开发者消息的内容。
+ developer 消息的内容。
- `TextContent = string`
- 开发者消息的内容。
+ developer 消息的内容。
- `ArrayOfContentParts = array of ChatCompletionContentPartText`
- 具有已定义类型的 content parts 数组。对于开发者消息,仅支持 type `text` 类型。
+ 具有指定类型的 content part 数组。对于 developer 消息,仅支持 type 为 input_text 的 `text` 内容。
- `text: string`
@@ -60,35 +60,35 @@
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `"text"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "developer"`
- 消息作者的角色,本例中为 `developer`.
+ 消息作者的角色,在本例中为 `developer`.
- `"developer"`
- `name: optional string`
- 参与者的可选名称。为模型提供信息,以便区分同一角色的不同参与者。
+ 参与者可选的名称。为模型提供信息,以区分同一角色的不同参与者。
- `ChatCompletionSystemMessageParam object { content, role, name }`
- 开发者提供的指令,无论用户发送什么
- 用户发送的消息。对于 o1 及更高版本的模型,请改用 `developer` messages
- 来实现此目的。
+ 开发者提供的指令,模型应当遵循这些指令,而无论用户发送了什么样的
+ 用户发送的消息。对于 o1 及更新模型,请使用 `developer` 消息取代了原先的
+ 来替代此用途。
- `content: string or array of ChatCompletionContentPartText`
@@ -100,7 +100,7 @@
- `ArrayOfContentParts = array of ChatCompletionContentPartText`
- 具有已定义类型的内容部分数组。对于系统消息,仅支持类型 `text` 类型。
+ 包含已定义类型的 content 部件数组。对于系统消息,仅支持 type `text` 内容。
- `text: string`
@@ -108,25 +108,25 @@
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `role: "system"`
- 消息作者的角色,本例中为 `system`.
+ 消息作者的角色,在本例中为 `system`.
- `"system"`
- `name: optional string`
- 参与者的可选名称。为模型提供信息,以便区分同一角色的不同参与者。
+ 参与者可选的名称。为模型提供信息,以区分同一角色的不同参与者。
- `ChatCompletionUserMessageParam object { content, role, name }`
- 由最终用户发送的消息,包含提示或额外的上下文
+ 由终端用户发送的消息,包含提示词或其他上下文
信息。
- `content: string or array of ChatCompletionContentPart`
@@ -139,7 +139,7 @@
- `ArrayOfContentParts = array of ChatCompletionContentPart`
- 具有已定义类型的内容部分数组。支持的具体选项因用于生成响应的 [model](/docs/models) 而异。可以包含文本、图像或音频输入。
+ 包含已定义类型的 content 部件数组。可选项取决于用于生成响应的 [model](/docs/models) 。可以包含文本、图像或音频输入。
- `ChatCompletionContentPartText object { text, type, prompt_cache_breakpoint }`
@@ -151,11 +151,11 @@
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `ChatCompletionContentPartImage object { image_url, type, prompt_cache_breakpoint }`
@@ -165,11 +165,11 @@
- `url: string`
- 图像的 URL 或 base64 编码的图像数据。
+ 图像的 URL 或 base64 编码后的图像数据。
- `detail: optional "auto" or "low" or "high"`
- 指定图像的细节级别。更多信息请参阅 [视觉指南](/docs/guides/vision#low-or-high-fidelity-image-understanding).
+ 指定图像的细节级别。详见 [视觉指南](/docs/guides/vision#low-or-high-fidelity-image-understanding).
- `"auto"`
@@ -179,17 +179,17 @@
- `type: "image_url"`
- 内容部分的类型。
+ content part 的类型。
- `"image_url"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -219,11 +219,11 @@
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -235,8 +235,8 @@
- `file_data: optional string`
- base64 编码的文件数据,在将文件传递给模型时使用
- 字符串。
+ Base64 编码的文件数据,在将文件传递给模型时使用
+ 字符串形式。
- `file_id: optional string`
@@ -244,8 +244,8 @@
- `filename: optional string`
- 文件的名称,在将文件以
- 字符串形式传递给模型时使用。
+ 文件的名称,在将文件作为以下形式传递给模型时使用
+ 字符串。
- `type: "file"`
@@ -255,23 +255,23 @@
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user"`
- 消息作者的角色,本例中为 `user`.
+ 消息作者的角色,在本例中为 `user`.
- `"user"`
- `name: optional string`
- 参与者的可选名称。为模型提供信息,以便区分同一角色的不同参与者。
+ 参与者可选的名称。为模型提供信息,以区分同一角色的不同参与者。
- `ChatCompletionAssistantMessageParam object { role, audio, content, 4 more }`
@@ -279,13 +279,13 @@
- `role: "assistant"`
- 消息作者的角色,本例中为 `assistant`.
+ 消息作者的角色,在本例中为 `assistant`.
- `"assistant"`
- `audio: optional object { id } or null`
- 模型先前音频响应的相关数据。
+ 关于模型先前音频响应的数据。
[了解更多](/docs/guides/audio).
- `id: string`
@@ -294,7 +294,7 @@
- `content: optional string or array of ChatCompletionContentPartText or ChatCompletionContentPartRefusal or null`
- 助手消息的内容。除非指定了 `tool_calls` 或 `function_call` ,否则此字段为必填。
+ 助手消息的内容。除非指定了 `tool_calls` 或 `function_call` ,否则此项为必填。
- `TextContent = string`
@@ -302,7 +302,7 @@
- `ArrayOfContentParts = array of ChatCompletionContentPartText or ChatCompletionContentPartRefusal`
- 具有已定义类型的内容片段数组。可以是以下类型的一个或多个 `text`,或以下类型的恰好一个 `refusal`.
+ 由已定义类型组成的内容部分数组。可以是一或多个以下类型 `text`,或恰好一个以下类型 `refusal`.
- `ChatCompletionContentPartText object { text, type, prompt_cache_breakpoint }`
@@ -312,33 +312,33 @@
- `refusal: string`
- 由模型生成的拒绝消息。
+ 模型生成的拒绝消息。
- `type: "refusal"`
- 内容部分的类型。
+ content part 的类型。
- `"refusal"`
- `function_call: optional object { arguments, name } or null`
- 已弃用,由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
+ 已弃用,已由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `name: optional string`
- 参与者的可选名称。为模型提供信息,以便区分同一角色的不同参与者。
+ 参与者可选的名称。为模型提供信息,以区分同一角色的不同参与者。
- `refusal: optional string or null`
- 助手生成的拒绝消息。
+ 助手返回的拒绝消息。
- `tool_calls: optional array of ChatCompletionMessageToolCall`
@@ -358,15 +358,15 @@
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `type: "function"`
- 工具的类型。目前,仅 `function` 类型。
+ 工具的类型。目前,仅支持 `function` 内容。
- `"function"`
@@ -408,7 +408,7 @@
- `ArrayOfContentParts = array of ChatCompletionContentPartText`
- 由已定义类型组成的内容分块数组。对于工具消息,仅支持类型 `text` 类型。
+ 具有已定义类型的内容片段数组。对于工具消息,仅类型 `text` 内容。
- `text: string`
@@ -416,15 +416,15 @@
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `role: "tool"`
- 消息作者的角色,本例中为 `tool`.
+ 消息作者的角色,在本例中为 `tool`.
- `"tool"`
@@ -440,28 +440,28 @@
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `role: "function"`
- 消息作者的角色,本例中为 `function`.
+ 消息作者的角色,在本例中为 `function`.
- `"function"`
- `model: string or "gpt-5.6-sol" or "gpt-5.6-terra" or "gpt-5.6-luna" or 80 more`
- 用于生成响应的模型 ID,例如 `gpt-5.6-sol` 或 `o3`。OpenAI
- 提供了大量能力、性能和价格各异的模型。请参阅
- 模型指南 [模型指南](/docs/models)
+ 用于生成响应的模型 ID,例如 `gpt-5.6-sol` 或 `o3`。 OpenAI
+ 提供多种具备不同能力、性能
+ 特征和价位的模型。请参阅 [模型指南](/docs/models)
以浏览和比较可用的模型。
- `string`
- `"gpt-5.6-sol" or "gpt-5.6-terra" or "gpt-5.6-luna" or 80 more`
- 用于生成响应的模型 ID,例如 `gpt-5.6-sol` 或 `o3`。OpenAI
- 提供了大量能力、性能和价格各异的模型。请参阅
- 模型指南 [模型指南](/docs/models)
+ 用于生成响应的模型 ID,例如 `gpt-5.6-sol` 或 `o3`。 OpenAI
+ 提供多种具备不同能力、性能
+ 特征和价位的模型。请参阅 [模型指南](/docs/models)
以浏览和比较可用的模型。
- `"gpt-5.6-sol"`
@@ -632,12 +632,12 @@
- `audio: optional ChatCompletionAudioParam or null`
- 音频输出的参数。当使用以下方式请求音频输出时为必填项
+ 音频输出的参数。在使用以下参数请求音频输出时必填:
`modalities: ["audio"]`. [了解更多](/docs/guides/audio).
- `format: "wav" or "aac" or "mp3" or 3 more`
- 指定输出音频格式。必须是以下之一 `wav`, `mp3`, `flac`,
+ 指定输出音频格式。必须是以下之一: `wav`, `mp3`, `flac`,
`opus`,或 `pcm16`.
- `"wav"`
@@ -654,10 +654,10 @@
- `voice: string or "alloy" or "ash" or "ballad" or 7 more or object { id }`
- 模型用于回复的声音。支持的内置声音包括
+ 模型用于响应的语音。支持的内置语音有
`alloy`, `ash`, `ballad`, `coral`, `echo`, `fable`, `nova`, `onyx`,
- `sage`, `shimmer`, `marin`,以及 `cedar`。你也可以提供带有
- 的自定义声音对象,使用 `id`,例如 `{ "id": "voice_1234" }`.
+ `sage`, `shimmer`, `marin`、和 `cedar`。你也可以提供带有
+ 的自定义语音对象, `id`,例如 `{ "id": "voice_1234" }`.
- `string`
@@ -685,39 +685,39 @@
- `ID object { id }`
- 自定义声音引用。
+ 自定义语音引用。
- `id: string`
- 自定义声音 ID,例如 `voice_1234`.
+ 自定义语音 ID,例如 `voice_1234`.
- `frequency_penalty: optional number or null`
- 介于 -2.0 和 2.0 之间的数字。正值会根据新 token 在
- 已有文本中的出现频率对其进行惩罚,从而降低模型原样
- 重复相同语句的可能性。
+ 介于 -2.0 和 2.0 之间的数字。正值会根据
+ 新 token 在已有文本中的出现频率对其进行惩罚,从而降低模型
+ 逐字重复相同内容的可能性。
- `function_call: optional "none" or "auto" or ChatCompletionFunctionCallOption`
已弃用,推荐使用 `tool_choice`.
- 控制模型调用哪个函数(如果有)。
+ 控制模型调用哪些函数(如果有的话)。
- `none` 表示模型不会调用函数,而是生成一条
+ `none` 意味着模型不会调用函数,而是生成一条
消息。
- `auto` 表示模型可以在生成消息和调用函数之间进行选择,
+ `auto` 意味着模型可以自行选择生成消息或调用
函数。
- 通过 `{"name": "my_function"}` 指定某个特定函数会强制
- 模型调用该函数。
+ 通过 `{"name": "my_function"}` 强制模型
+ 调用该函数。
- `none` 是当没有任何函数时的默认值。 `auto` 是默认值
- (当存在函数时)。
+ `none` 是在没有函数时的默认值。 `auto` 是存在函数
+ 时的默认值。
- `"none" or "auto"`
- `none` 表示模型不会调用函数,而是生成一条消息。 `auto` 表示模型可以在生成消息和调用函数之间进行选择。
+ `none` 意味着模型不会调用函数,而是生成一条消息。 `auto` 意味着模型可以自行选择生成消息或调用函数。
- `"none"`
@@ -729,7 +729,7 @@
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `functions: optional array of object { name, description, parameters }`
@@ -739,67 +739,67 @@
- `name: string`
- 要调用的函数名称。必须为 a-z、A-Z、0-9,或包含下划线和短横线,最大长度为 64。
+ 要调用的函数名称。只能包含 a-z、A-Z、0-9,或下划线和短横线,最大长度为 64。
- `description: optional string`
- 对函数作用的描述,模型据此选择何时以及如何调用该函数。
+ 对函数功能的描述,供模型用于选择何时以及如何调用该函数。
- `parameters: optional FunctionParameters`
- 函数接受的参数,以 JSON Schema 对象描述。参阅 [指南](/docs/guides/function-calling) 中的示例,以及 [JSON Schema 参考](https://json-schema.org/understanding-json-schema/) 获取有关该格式的文档。
+ 函数接受的参数,使用 JSON Schema 对象进行描述。详见 [指南](/docs/guides/function-calling) 中的示例,以及 [JSON Schema 参考](https://json-schema.org/understanding-json-schema/) 有关此格式的文档。
- 省略 `parameters` 用于定义一个参数列表为空的函数。
+ 省略 `parameters` 定义一个参数列表为空的函数。
- `logit_bias: optional map[number] or null`
- 修改指定标记在 completion 中出现的可能性。
+ 修改指定 token 在补全中出现的可能性。
- 接受一个 JSON 对象,该对象将标记(由分词器中的标记 ID 指定)映射到 -100 到 100 的关联偏差值。在数学上,
- 分词器中的标记 ID 指定)映射到 -100 到 100 的关联偏差值。在数学上,
- 该偏差会在采样之前添加到模型生成的 logits 上。
- 具体效果因模型而异,但介于 -1 到 1 之间的值应
- 会降低或提高被选中的可能性;像 -100 或 100 这样的值
- 应导致相应标记被禁止或被独占选中。
+ 接受一个 JSON 对象,将 token(在
+ 分词器中通过其 token ID 指定)映射到介于 -100 到 100 之间的关联偏差值。在数学上,
+ 该偏差会在采样之前被加到模型生成的 logits 上。
+ 具体效果因模型而异,但介于 -1 到 1 之间的值应该
+ 会降低或提高被选中的可能性;类似 -100 或 100 的值
+ 应导致相关 token 被禁止或被唯一选中。
- `logprobs: optional boolean or null`
- 是否返回输出标记的对数概率。如果为 true,
- 则返回所返回的每个输出标记的
- `content` 的 `message`.
+ 是否返回输出 token 的对数概率。如果为 true,
+ 返回每个输出 token 的对数概率,
+ `content` of `message`.
- `max_completion_tokens: optional number or null`
- 单次 completion 可生成标记数的上限,包括可见输出标记和 [推理标记](/docs/guides/reasoning).
+ 一次补全可生成的最大 token 数上限,包括可见的输出 token 和 [推理 token](/docs/guides/reasoning).
- `max_tokens: optional number or null`
- 可在 [聊天 completion](/tokenizer) 中生成的最大
- 标记数。该值可用于控制
+ 可生成的最大 [token](/tokenizer) 数(在
+ 聊天补全中生成。该值可用于控制
[成本](https://openai.com/api/pricing/) 用于通过 API 生成的文本。
- 此值现已弃用,推荐使用 `max_completion_tokens`,并且
- 与 [o 系列模型](/docs/guides/reasoning).
+ 此值现已弃用,改用 `max_completion_tokens`,并且
+ 不兼容于 [o 系列模型](/docs/guides/reasoning).
- `metadata: optional Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的其他信息,并通过 API 或控制台查询对象。
- 以结构化格式存储有关对象的其他信息,并通过 接口 或控制台查询对象。
+ 附加到对象的 16 个键值对集合。可用于以结构化
+ 格式存储关于对象的附加信息,并通过 API 或仪表板查询对象。
+ 格式存储关于对象的附加信息,并通过 接口 或仪表板查询对象。
- 键为字符串,最大长度为 64 个字符。值为字符串,
- 最大长度为 512 个字符。
+ 键为字符串,最长 64 个字符。值
+ 为字符串,最长 512 个字符。
- `modalities: optional array of "text" or "audio" or null`
你希望模型生成的输出类型。
- 大多数模型都能生成文本,这也是默认方式:
+ 大多数模型都能生成文本,这是默认方式:
`["text"]`
- 该 `gpt-4o-audio-preview` 模型还可以用于
- [生成音频](/docs/guides/audio).要让该模型生成
- 同时获取文本和音频响应,你可以使用:
+ 该 `gpt-4o-audio-preview` 模型还可用于
+ [generate audio](/docs/guides/audio)。若要让该模型生成
+ 同时包含文本和音频的响应,你可以使用:
`["text", "audio"]`
@@ -809,19 +809,19 @@
- `moderation: optional object { model, policy } or null`
- 对请求输入和生成输出运行审查的配置。
+ 对请求输入和生成输出运行审核的配置。
- `model: string`
- 用于审查补全的审查模型,例如 'omni-moderation-latest'。
+ 用于受审核补全的审核模型,例如 'omni-moderation-latest'。
- `policy: optional object { input, output } or null`
- 应用于审查响应输入和输出的策略。
+ 应用于受审核响应输入和输出的策略。
- `input: optional object { mode } or null`
- 响应输入的审核策略。
+ 响应输入的内容审核策略。
- `mode: "score" or "block"`
@@ -831,7 +831,7 @@
- `output: optional object { mode } or null`
- 响应输出的审核策略。
+ 响应输出的内容审核策略。
- `mode: "score" or "block"`
@@ -841,31 +841,31 @@
- `n: optional number or null`
- 为每个输入消息生成多少个聊天补全选项。请注意,你将根据所有选项中生成的 token 总数计费。请尽量将 n 保持为 1 `n` 以 `1` 降低成本。
+ 针对每条输入消息要生成的聊天补全选项数量。注意,将根据所有选项中生成的 token 总数向你收费。请将 `n` n `1` 设为 1,以最大限度降低成本。
- `parallel_tool_calls: optional boolean`
- 是否启用 [并行函数调用](/docs/guides/function-calling#configuring-parallel-function-calling) ,以便在工具使用期间调用。
+ 是否在工具使用期间启用 [并行函数调用](/docs/guides/function-calling#configuring-parallel-function-calling) 。
- `prediction: optional ChatCompletionPredictionContent or null`
- 静态预测输出内容,例如正在重新生成的文本文件的内容。
- 正在重新生成。
+ 静态预测输出内容,例如正在被重新生成的文本文件内容。
+ being regenerated.
- `content: string or array of ChatCompletionContentPartText`
生成模型响应时应匹配的内容。
如果生成的 token 与该内容匹配,则可以更快地返回整个模型响应。
- 可以更快地返回。
+ can be returned much more quickly.
- `TextContent = string`
- 用于预测输出的内容。这通常是
- 你正在重新生成且仅有少量改动的文件文本。
+ 用于 Predicted Output 的内容。这通常是
+ 你正在重新生成且仅有少量改动的文件的文本。
- `ArrayOfContentParts = array of ChatCompletionContentPartText`
- 具有已定义类型的内容部分数组。支持的具体选项因用于生成响应的 [model](/docs/models) 正在用于生成响应。可以包含文本输入。
+ 包含已定义类型的 content 部件数组。可选项取决于用于生成响应的 [model](/docs/models) 正在用于生成响应的输入消息。可以包含文本输入。
- `text: string`
@@ -873,24 +873,24 @@
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `type: "content"`
- 你希望提供的预测内容的类型。该类型
+ 你要提供的预测内容的类型。该类型
目前始终为 `content`.
- `"content"`
- `presence_penalty: optional number or null`
- 介于 -2.0 和 2.0 之间的数字。正值会根据新 token 在
- 无论它们是否已出现在迄今为止的文本中,都会提高模型讨论新主题的可能性
- 讨论新主题的可能性。
+ 介于 -2.0 和 2.0 之间的数字。正值会根据
+ 到目前为止是否出现在文本中会增加模型谈论新话题的可能性。
+ to talk about new topics.
- `prompt_cache_key: optional string or null`
@@ -898,11 +898,11 @@
- `prompt_cache_options: optional object { mode, ttl }`
- 提示缓存的选项。支持 `gpt-5.6` 及更高版本模型。默认情况下,OpenAI 会自动选择一个隐式缓存断点。你可以使用 `prompt_cache_breakpoint`。为内容块添加显式断点。每个请求最多可以写入四个断点。对于缓存匹配,OpenAI 会考虑对话中最近的 80 个断点,没有内容块回溯限制。设置 `mode` 为 `explicit` 以禁用隐式断点。 `ttl` 默认为 `30m`,这是当前唯一支持的值。请参阅 [提示缓存指南](/docs/guides/prompt-caching) 了解当前详情。
+ 提示缓存的选项。适用于 `gpt-5.6` 及更高版本模型。默认情况下,OpenAI 会自动选择一个隐式缓存断点。你可以使用 `prompt_cache_breakpoint`。为内容块添加显式断点。每个请求最多可写入四个断点。在缓存匹配时,OpenAI 会考虑对话中最多最近的 80 个断点,且没有内容块回溯限制。将 `mode` 设置为 `explicit` 可禁用隐式断点。 `ttl` 默认值为 `30m`,目前这是唯一支持的值。参阅 [提示缓存指南](/docs/guides/prompt-caching) 了解最新详情。
- `mode: optional "implicit" or "explicit"`
- 控制 OpenAI 是否自动创建隐式缓存断点。默认为 `implicit`。使用 `implicit`,时,OpenAI 会创建一个隐式断点,并在请求中写入最多最新的三个显式断点。使用 `explicit`,时,OpenAI 不会创建隐式断点,并写入最多最新的四个显式断点。如果没有显式断点,则该请求不使用提示缓存。
+ 控制 OpenAI 是否自动创建隐式缓存断点。默认值为 `implicit`。使用 `implicit`,时,OpenAI 会创建一个隐式断点,并在请求中写入最多最近的三个显式断点。使用 `explicit`,时,OpenAI 不会创建隐式断点,并写入最多最近的四个显式断点。如果不存在显式断点,则该请求不会使用提示缓存。
- `"implicit"`
@@ -910,7 +910,7 @@
- `ttl: optional "30m"`
- 应用于该请求写入的每个隐式和显式缓存断点的最短生命周期。默认为 `30m`,这是当前唯一支持的值。后端可能会将缓存条目保留更长时间。
+ 应用于请求所写入的每个隐式和显式缓存断点的最短生命周期。默认值为 `30m`,目前这是唯一支持的值。后端可能会保留缓存条目更长时间。
- `"30m"`
@@ -918,16 +918,16 @@
已弃用。请使用 `prompt_cache_options.ttl` 代替。
- 提示缓存的保留策略。设置为 `24h` 用于启用扩展的提示缓存,使缓存的前缀保持更长时间,最长可达 24 小时。 [了解更多](/docs/guides/prompt-caching#prompt-cache-retention).
+ 提示缓存的保留策略。设置为 `24h` 以启用扩展提示缓存,使缓存的前缀保持更长时间,最长可达 24 小时。 [了解更多](/docs/guides/prompt-caching#prompt-cache-retention).
该字段表示最大保留策略,而
- `prompt_cache_options.ttl` 表示最短缓存生命周期。两个
- 字段相互独立,不会相互影响。
- 对于 `gpt-5.5`, `gpt-5.5-pro`,及以后的模型,仅 `24h` 类型。
+ `prompt_cache_options.ttl` 表示最小缓存生命周期。两个
+ 字段相互独立,互不影响。
+ 对于 `gpt-5.5`, `gpt-5.5-pro`,及未来模型,仅 `24h` 内容。
- 对于同时支持两者的旧模型, `in_memory` 和 `24h`,的默认值取决于你所在组织的数据保留策略:
+ 对于同时支持 `in_memory` 和 `24h`,的较旧模型,默认值取决于你所在组织的数据保留策略:
- 未启用 ZDR 的组织默认为 `24h`.
- - 已启用 ZDR 的组织默认为 `in_memory` 当未指定 `prompt_cache_retention` 时。
+ - 启用了 ZDR 的组织默认使用 `in_memory` 当 `prompt_cache_retention` 未指定时。
- `"in_memory"`
@@ -935,13 +935,13 @@
- `reasoning_effort: optional ReasoningEffort or null`
- 限制推理模型在推理上的投入程度。当前支持的值
- 为 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,以及 `max`.
- 降低推理投入程度可以让响应更快,并减少在响应中用于推理的 token 数量。并非所有推理模型都支持每个
- 值。请参阅推理指南了解模型相关的支持情况。
+ 限制推理模型在推理上的投入程度。当前支持的
+ 值为 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`、和 `max`.
+ 降低推理投入程度可以加快响应速度并减少
+ 响应中用于推理的令牌数。并非所有推理模型都支持每个
值。请参阅
- [reasoning guide](https://platform.openai.com/docs/guides/reasoning)
- 了解模型相关的支持情况。
+ [推理指南](https://platform.openai.com/docs/guides/reasoning)
+ 了解特定模型的支持情况。
- `"none"`
@@ -959,20 +959,20 @@
- `response_format: optional ResponseFormatText or ResponseFormatJSONSchema or ResponseFormatJSONObject`
- 一个对象,用于指定模型必须输出的格式。
+ 用于指定模型必须输出的格式的对象。
- 设置为 `{ "type": "json_schema", "json_schema": {...} }` 启用
- 结构化输出,确保模型匹配你提供的 JSON
- schema。了解更多,请参阅 [Structured Outputs
+ 设置为 `{ "type": "json_schema", "json_schema": {...} }` 可启用
+ 结构化输出,确保模型输出与你提供的 JSON
+ 模式匹配。在 [结构化输出
指南](/docs/guides/structured-outputs).
- 设置为 `{ "type": "json_object" }` 启用旧的 JSON 模式,它
- 确保模型生成的消息是有效的 JSON。使用 `json_schema`
- 对于支持它的模型是首选。
+ 设置为 `{ "type": "json_object" }` 启用旧版的 JSON 模式,它
+ 可确保模型生成的消息是合法 JSON。对于支持 `json_schema`
+ 的模型,推荐使用。
- `ResponseFormatText object { type }`
- 默认响应格式。用于生成文本响应。
+ 默认的响应格式。用于生成文本响应。
- `type: "text"`
@@ -982,34 +982,34 @@
- `ResponseFormatJSONSchema object { json_schema, type }`
- JSON Schema 响应格式。用于生成结构化的 JSON 响应。
- 了解更多关于 [Structured Outputs](/docs/guides/structured-outputs).
+ JSON 模式响应格式。用于生成结构化的 JSON 响应。
+ 详细了解 [结构化输出](/docs/guides/structured-outputs).
- `json_schema: object { name, description, schema, strict }`
- 结构化输出配置选项,包括 JSON Schema。
+ 结构化输出的配置选项,包括 JSON 模式。
- `name: string`
- 响应格式的名称。必须为 a-z、A-Z、0-9,或包含
- 下划线和连字符,最大长度为 64。
+ 响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
+ 下划线和短横线,最大长度为 64 个字符。
- `description: optional string`
- 响应格式用途的描述,由模型用于
- 决定如何以该格式进行响应。
+ 关于该响应格式用途的描述,模型会根据它
+ 决定如何按该格式进行响应。
- `schema: optional map[unknown]`
- 响应格式的 schema,描述为一个 JSON Schema 对象。
- 了解如何构建 JSON schema [此处](https://json-schema.org/).
+ 响应格式的模式,以 JSON 模式对象描述。
+ 了解如何构建 JSON 模式 [此处](https://json-schema.org/).
- `strict: optional boolean or null`
是否在生成输出时启用严格的模式遵循。
- 若设置为 true,模型将始终遵循所定义的精确模式
- 字段中。仅支持 JSON Schema 的一个子集,当 `schema` 字段时。如需了解更多信息,请参阅
- `strict` 为 `true`。时。如需了解更多信息,请参阅 [Structured Outputs
+ 如果设置为 true,模型将始终遵循在
+ 字段中 `schema` 所定义的精确模式。当 strict
+ `strict` 为 `true`。时,仅支持 JSON Schema 的一个子集。要了解更多信息,请参阅 [结构化输出
指南](/docs/guides/structured-outputs).
- `type: "json_schema"`
@@ -1020,10 +1020,10 @@
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较旧的生成 JSON 响应的方法。
- 使用 `json_schema` 建议用于支持它的模型。请注意,
- 如果没有系统或用户消息指示模型生成 JSON,模型将不会生成 JSON。
- 以执行此操作。
+ JSON 对象响应格式。这是一种较旧的 JSON 响应生成方式。
+ 对于支持该格式的 `json_schema` 模型,推荐使用 json_schema。请注意,在没有系统或用户消息指示的情况下,
+ 模型不会生成 JSON
+ 输出。
- `type: "json_object"`
@@ -1034,25 +1034,25 @@
- `safety_identifier: optional string or null`
一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用策略的应用程序用户。
- 该 ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对其用户名或电子邮件地址进行哈希处理,以避免向我们发送任何识别信息。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
+ 这些 ID 应为字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对其用户名或电子邮件地址进行哈希处理,以避免向我们发送任何可识别信息。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
- `seed: optional number or null`
此功能处于测试阶段。
- 如果指定,我们的系统将尽最大努力进行确定性采样,以便使用相同 `seed` 和参数的重复请求应返回相同的结果。
+ 如果指定,我们的系统将尽力进行确定性采样,以便使用相同的 `seed` 和参数发起的重复请求应返回相同的结果。
不保证确定性,你应当参考 `system_fingerprint` 响应参数来监控后端的变化。
- `service_tier: optional "auto" or "default" or "flex" or 3 more or null`
- 指定用于处理请求的处理类型。
+ 指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则请求将使用 Project 设置中配置的服务层级进行处理。除非另行配置,否则该 Project 将使用 'default'。
+ - 如果设置为 'auto',则请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
- 如果设置为 'default',则请求将使用所选模型的标准定价和性能进行处理。
- - 如果设置为 '[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为'[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。
+ - 若要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中传入 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你在请求中是否指定 `service_tier=fast` 或 `priority` 。
- 未设置时,默认行为为 'auto'。
- 当设置了 `service_tier` 参数时,响应主体将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。该响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应主体将根据实际用于处理该请求的处理模式返回 `service_tier` 值。该响应值可能与参数中设置的值不同。
- `"auto"`
@@ -1068,10 +1068,10 @@
- `stop: optional string or array of string or null`
- 最新的推理模型不支持该参数 `o3` 和 `o4-mini`.
+ 最新的推理模型不支持此功能 `o3` 和 `o4-mini`.
- 最多 4 个序列,当出现这些序列时,API 将停止生成更多 token。返回的
- 文本不会包含该停止序列。
+ 最多 4 个序列,API 将在这些位置停止生成更多 token。
+ 返回的文本不会包含停止序列。
- `string`
@@ -1079,8 +1079,8 @@
- `store: optional boolean or null`
- 是否存储此次聊天补全请求的输出以用于
- 我们后续的 [model distillation](/docs/guides/distillation) 或
+ 是否存储本次聊天补全请求的输出以用于
+ 我们的 [模型蒸馏](/docs/guides/distillation) 或
[evals](/docs/guides/evals) 产品。
支持文本和图像输入。注意:超过 8MB 的图像输入将被丢弃。
@@ -1088,54 +1088,54 @@
- `stream: optional boolean or null`
如果设置为 true,模型响应数据将通过
- 边生成边使用 [服务端发送事件](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
- 请参阅下方的 [流式传输部分](/docs/api-reference/chat/streaming)
- 以获取更多信息,以及 [流式响应](/docs/guides/streaming-responses)
+ 生成时流式传输到客户端,使用 [服务端发送事件](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
+ 请参阅 [下面的流式传输部分](/docs/api-reference/chat/streaming)
+ 了解更多信息,以及 [流式响应](/docs/guides/streaming-responses)
指南,了解如何处理流式事件的更多信息。
- `stream_options: optional ChatCompletionStreamOptions or null`
- 流式响应的选项。仅在设置了 stream: true 时设置此参数。 `stream: true`.
+ 流式响应的选项。仅当你设置 `stream: true`.
- `include_obfuscation: optional boolean`
- 如果为 true,将启用流混淆。流混淆会向流式增量事件上的 obfuscation 字段添加
- 随机字符,以规范化负载大小,作为对某些侧信道攻击的缓解措施。这些混淆字段默认包含,但会增加少量数据流的开销。如果你信任客户端与 接口 之间的网络链路,可以将 include_obfuscation 设置为 `obfuscation` field on streaming delta events to
- normalize payload sizes as a mitigation to certain side-channel attacks.
- These obfuscation fields are included by default, but add a small amount
- of overhead to the data stream. You can set `include_obfuscation` 为
- false to optimize for bandwidth if you trust the network links between
- 你的应用与 OpenAI API 之间。
+ 当为 true 时,将启用流混淆。流混淆会向
+ 流式增量事件上的某个 `obfuscation` 字段添加随机字符,以
+ 规范化负载大小,作为对某些侧信道攻击的缓解措施。
+ 默认情况下会包含这些混淆字段,但会给数据流带来少量
+ 开销。如果你信任客户端与服务端之间的网络链路,可以将 `include_obfuscation` 设置为
+ 设置为 false 以优化带宽。
+ 你的应用与 OpenAI API 之间的。
- `include_usage: optional boolean`
- 如果设置了该参数,则会在 `data: [DONE]`
- 消息之前额外流式返回一个分块。该 `usage` 字段显示整个请求的 token 用量统计信息,
- 而该请求的 `choices` 字段将始终为空
+ 如果设置了该参数,会在 `data: [DONE]`
+ 之前流式传输一个额外的分块 `usage` message。该分块上的
+ 字段显示整个请求的 token 使用统计信息,而 `choices` 字段将始终为空
数组。
- 所有其他分块也会包含一个 `usage` 字段,但其值为
- null。 **注意:** 如果流被中断,你可能不会收到包含该请求
- 总 token 用量的最后一个 usage 分块。
+ 所有其他分块也会包含一个 `usage` 字段,但其值为 null
+ 。 **注意:** 如果流被中断,你可能无法收到
+ 包含该请求总 token 使用量的最后一个 usage 分块。
- `temperature: optional number or null`
- 使用的采样温度,介于 0 和 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加集中和确定。
- 我们通常建议修改该参数或 `top_p` ,但不要同时修改两者。
+ 使用的采样温度,介于 0 和 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加聚焦和确定。
+ 我们通常建议修改此项或 `top_p` ,但不要同时修改两者。
- `tool_choice: optional ChatCompletionToolChoiceOption`
- 控制模型调用哪些工具(如果有的话)。
- `none` 表示模型不会调用任何工具,而是生成一条消息。
- `auto` 表示模型可以在生成消息或调用一个或多个工具之间进行选择。
- `required` 表示模型必须调用一个或多个工具。
- 通过指定特定工具来 `{"type": "function", "function": {"name": "my_function"}}` 强制模型调用该工具。
+ 控制模型调用哪个工具(如果有的话)。
+ `none` 意味着模型不会调用任何工具,而是生成一条消息。
+ `auto` 意味着模型可以在生成消息和调用一个或多个工具之间进行选择。
+ `required` 意味着模型必须调用一个或多个工具。
+ 通过 `{"type": "function", "function": {"name": "my_function"}}` 强制模型调用该工具。
- `none` 是未提供任何工具时的默认行为。 `auto` 是提供了工具时的默认行为。
+ `none` 是没有工具时的默认值。 `auto` 是存在工具时的默认值。
- `ToolChoiceMode = "none" or "auto" or "required"`
- `none` 表示模型不会调用任何工具,而是生成一条消息。 `auto` 表示模型可以在生成消息或调用一个或多个工具之间进行选择。 `required` 表示模型必须调用一个或多个工具。
+ `none` 意味着模型不会调用任何工具,而是生成一条消息。 `auto` 意味着模型可以在生成消息和调用一个或多个工具之间进行选择。 `required` 意味着模型必须调用一个或多个工具。
- `"none"`
@@ -1145,17 +1145,17 @@
- `ChatCompletionAllowedToolChoice object { allowed_tools, type }`
- 将模型可使用的工具限制为预定义的集合。
+ 将模型可用的工具限制为预定义的集合。
- `allowed_tools: ChatCompletionAllowedTools`
- 将模型可使用的工具限制为预定义的集合。
+ 将模型可用的工具限制为预定义的集合。
- `mode: "auto" or "required"`
- 将模型可使用的工具限制为预定义的集合。
+ 将模型可用的工具限制为预定义的集合。
- `auto` 允许模型从允许的工具中选择并生成
+ `auto` 允许模型从允许的工具中选取并生成
消息。
`required` 要求模型调用一个或多个允许的工具。
@@ -1166,9 +1166,9 @@
- `tools: array of map[unknown]`
- 模型可调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
- 对于 Chat Completions API,工具定义列表可能如下:
+ 对于 Chat Completions API,工具定义列表可能如下所示:
```json
[
@@ -1185,13 +1185,13 @@
- `ChatCompletionNamedToolChoice object { function, type }`
- 指定模型应使用的工具。用于强制模型调用特定函数。
+ 指定模型应使用的工具。用于强制模型调用某个特定函数。
- `function: object { name }`
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `type: "function"`
@@ -1201,7 +1201,7 @@
- `ChatCompletionNamedToolChoiceCustom object { custom, type }`
- 指定模型应使用的工具。用于强制模型调用特定自定义工具。
+ 指定模型应使用的工具。用于强制模型调用某个特定的自定义工具。
- `custom: object { name }`
@@ -1229,25 +1229,25 @@
- `name: string`
- 要调用的函数名称。必须为 a-z、A-Z、0-9,或包含下划线和短横线,最大长度为 64。
+ 要调用的函数名称。只能包含 a-z、A-Z、0-9,或下划线和短横线,最大长度为 64。
- `description: optional string`
- 对函数作用的描述,模型据此选择何时以及如何调用该函数。
+ 对函数功能的描述,供模型用于选择何时以及如何调用该函数。
- `parameters: optional FunctionParameters`
- 函数接受的参数,以 JSON Schema 对象描述。参阅 [指南](/docs/guides/function-calling) 中的示例,以及 [JSON Schema 参考](https://json-schema.org/understanding-json-schema/) 获取有关该格式的文档。
+ 函数接受的参数,使用 JSON Schema 对象进行描述。详见 [指南](/docs/guides/function-calling) 中的示例,以及 [JSON Schema 参考](https://json-schema.org/understanding-json-schema/) 有关此格式的文档。
- 省略 `parameters` 用于定义一个参数列表为空的函数。
+ 省略 `parameters` 定义一个参数列表为空的函数。
- `strict: optional boolean or null`
- 在生成函数调用时是否启用严格模式遵循。如果设置为 true,模型将遵循 `parameters` 字段时。如需了解更多信息,请参阅 `strict` 为 `true`。中定义的确切模式。详细了解结构化输出,请参阅 [function calling guide](/docs/guides/function-calling).
+ 在生成函数调用时是否启用严格的 schema 遵循。如果设置为 true,模型将严格按照 `parameters` 所定义的精确模式。当 strict `strict` 为 `true`。中定义的 schema 执行。详细了解 Structured Outputs,请参阅 [function calling guide](/docs/guides/function-calling).
- `type: "function"`
- 工具的类型。目前,仅 `function` 类型。
+ 工具的类型。目前,仅支持 `function` 内容。
- `"function"`
@@ -1269,15 +1269,15 @@
- `format: optional object { type } or object { grammar, type }`
- 自定义工具的输入格式。默认为无约束文本。
+ 自定义工具的输入格式。默认情况下为不受约束的文本。
- `Text object { type }`
- 无约束的自由格式文本。
+ 不受约束的自由格式文本。
- `type: "text"`
- 无约束文本格式。始终为 `text`.
+ 不受约束的文本格式。始终为 `text`.
- `"text"`
@@ -1295,7 +1295,7 @@
- `syntax: "lark" or "regex"`
- 语法定义的语法格式,取值之一为 `lark` 或 `regex`.
+ 语法定义的语法。可选值为 `lark` 或 `regex`.
- `"lark"`
@@ -1315,32 +1315,32 @@
- `top_logprobs: optional number or null`
- 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的最可能
- token 的最大数量,每个 token 都有一个关联的对数
+ 一个介于 0 到 20 之间的整数,指定在每个 token 位置返回的最可能的
+ token 数量,每个 token 带有对应的对数
概率。在某些情况下,返回的 token 数量可能少于
请求的数量。
- `logprobs` 必须设置为 `true` 如果使用此参数。
+ `logprobs` 必须设置为 `true` 才能使用此参数。
- `top_p: optional number or null`
- 一种称为核心采样的温度采样替代方案,
+ 一种温度采样的替代方法,称为核采样,
模型只考虑概率累计达到 top_p 的标记结果
- 质量。因此 0.1 表示仅考虑构成前 10% 概率质量的标记
- 会被纳入考虑。
+ 质量。因此 0.1 表示只考虑构成前 10% 概率质量的标记
+ 被纳入考虑。
- 我们通常建议修改该参数或 `temperature` ,但不要同时修改两者。
+ 我们通常建议修改此项或 `temperature` ,但不要同时修改两者。
- `user: optional string`
- 此字段将被替换为 `safety_identifier` 和 `prompt_cache_key`。使用 `prompt_cache_key` 以保持缓存优化。
+ 此字段将被 `safety_identifier` 和 `prompt_cache_key`. 使用 `prompt_cache_key` 来维持缓存优化效果。
终端用户的稳定标识符。
- 用于通过更好地对相似请求进行分桶来提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
+ 通过更好地对相似请求进行分桶来提升缓存命中率,并帮助 OpenAI 检测和防止滥用。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
- `verbosity: optional "low" or "medium" or "high" or null`
- 约束模型回复的详细程度。较低的值会生成
- 更简洁的回复,而较高的值会生成更详尽的回复。
- 当前支持的值包括 `low`, `medium`,以及 `high`。默认值为
+ 限制模型响应的冗长度。较低的值会导致
+ 数值越低,回复越简洁;数值越高,回复越详细。
+ 当前支持的值包括 `low`, `medium`、和 `high`。默认值为
`medium`.
- `"low"`
@@ -1351,13 +1351,13 @@
- `web_search_options: optional object { search_context_size, user_location }`
- 该工具可在网络上搜索相关结果以用于回复中。
- 详细了解 [网页搜索工具](/docs/guides/tools-web-search?api-mode=chat).
+ 该工具会搜索网页以获取可在回复中使用的相关结果。
+ 详细了解网页搜索工具 [网页搜索 工具](/docs/guides/tools-web-search?api-mode=chat).
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间使用量的高层级指导。取值之一为
- 搜索的。取值之一为 `low`, `medium`,或 `high`. `medium` 是默认值。
+ 用于搜索的上下文窗口空间使用量的大致指导,取值为
+ 之一。 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -1379,8 +1379,8 @@
- `country: optional string`
- 两位字母的
- [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 所属国家,
+ 用户的两位字母
+ [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如,
例如。 `US`.
- `region: optional string`
@@ -1390,35 +1390,35 @@
- `timezone: optional string`
该 [IANA 时区](https://timeapi.io/documentation/iana-timezones)
- 用户的所在地区,例如。 `America/Los_Angeles`.
+ 的用户,例如。 `America/Los_Angeles`.
- `type: "approximate"`
- 位置近似的方式。始终 `approximate`.
+ 位置近似值的类型。始终为 `approximate`.
- `"approximate"`
-### 返回值
+### Returns
- `ChatCompletion object { id, choices, created, 7 more }`
- 表示模型根据提供的输入返回的聊天补全响应。
+ 表示模型根据提供的输入返回的聊天完成响应。
- `id: string`
- 聊天补全的唯一标识符。
+ 聊天完成的唯一标识符。
- `choices: array of object { finish_reason, index, logprobs, message }`
- 聊天补全选项的列表。如果 `n` 大于 1,则可能不止一个。
+ 聊天完成选项的列表。如果 `n` 大于 1,则可以包含多个。
- `finish_reason: "stop" or "length" or "tool_calls" or 2 more`
- 模型停止生成 token 的原因。如果模型遇到自然停止点或提供的停止序列,则为 `stop` ;如果达到请求中指定的最大 token 数,则为,
- `length` ;如果因我们的内容过滤器标记而被省略内容,则为,
- `content_filter` ;如果模型调用了工具,则为,
- `tool_calls` ;如果模型调用了函数,则为 `function_call` (已弃用)。
- 请参阅 [Model Spec](https://model-spec.openai.com/2025-12-18.html) 了解更多信息。
+ 模型停止生成 token 的原因。该字段为 `stop` ,表示模型到达了自然停止点或遇到了提供的停止序列,
+ `length` ,表示已达到请求中指定的最大 token 数,
+ `content_filter` ,表示内容因我们的内容过滤器的标记而被省略,
+ `tool_calls` ,表示模型调用了工具,或 `function_call` (已弃用),表示模型调用了函数。
+ 请阅读 [模型规范](https://model-spec.openai.com/2025-12-18.html) 了解更多信息。
- `"stop"`
@@ -1432,7 +1432,7 @@
- `index: number`
- 选项在选项列表中的索引。
+ 该选项在选项列表中的索引。
- `logprobs: object { content, refusal } or null`
@@ -1448,15 +1448,15 @@
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `top_logprobs: array of object { token, bytes, logprob }`
- 在该 token 位置上,最可能出现的 token 及其对数概率的列表。条目数量可能少于所请求的 `top_logprobs`.
+ 在该 token 位置处可能性最高的 token 列表及其对数概率。条目数量可能少于请求的 `top_logprobs`.
- `token: string`
@@ -1464,15 +1464,15 @@
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `refusal: array of ChatCompletionTokenLogprob or null`
- 包含对数概率信息的拒绝消息 token 列表。
+ 包含对数概率信息的消息拒绝 token 列表。
- `token: string`
@@ -1480,19 +1480,19 @@
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `top_logprobs: array of object { token, bytes, logprob }`
- 在该 token 位置上,最可能出现的 token 及其对数概率的列表。条目数量可能少于所请求的 `top_logprobs`.
+ 在该 token 位置处可能性最高的 token 列表及其对数概率。条目数量可能少于请求的 `top_logprobs`.
- `message: ChatCompletionMessage`
- 由模型生成的聊天完成消息。
+ 由模型生成的聊天补全消息。
- `content: string or null`
@@ -1500,7 +1500,7 @@
- `refusal: string or null`
- 由模型生成的拒绝消息。
+ 模型生成的拒绝消息。
- `role: "assistant"`
@@ -1510,8 +1510,8 @@
- `annotations: optional array of object { type, url_citation }`
- 消息的注释(如果适用),例如在使用
- [网页搜索工具](/docs/guides/tools-web-search?api-mode=chat).
+ 消息的注释(如适用),例如在使用
+ [网页搜索 工具](/docs/guides/tools-web-search?api-mode=chat).
- `type: "url_citation"`
@@ -1529,7 +1529,7 @@
- `start_index: number`
- 消息中 URL 引用的第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
@@ -1541,23 +1541,23 @@
- `audio: optional ChatCompletionAudio or null`
- 如果请求了音频输出模态,该对象包含来自模型的音频
- 响应的相关数据。 [了解更多](/docs/guides/audio).
+ 如果请求了音频输出模态,则此对象包含有关模型音频响应的数据
+ 关于模型的音频响应。 [了解更多](/docs/guides/audio).
- `id: string`
- 此音频响应的唯一标识符。
+ 该音频响应的唯一标识符。
- `data: string`
- 模型生成的 Base64 编码音频字节,格式为
+ 由模型生成的 Base64 编码音频字节,格式为
请求中指定的格式。
- `expires_at: number`
- 此音频响应在服务端上无法再被用于多轮
- 访问的 Unix 时间戳(秒)。
- 对话。
+ 该音频响应在服务端不再可用于多轮对话的 Unix 时间戳(秒)
+ 对话的 Unix 时间戳(以秒为单位)。
+ conversations.
- `transcript: string`
@@ -1565,15 +1565,15 @@
- `function_call: optional object { arguments, name }`
- 已弃用,由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
+ 已弃用,已由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `tool_calls: optional array of ChatCompletionMessageToolCall`
@@ -1593,15 +1593,15 @@
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `type: "function"`
- 工具的类型。目前,仅 `function` 类型。
+ 工具的类型。目前,仅支持 `function` 内容。
- `"function"`
@@ -1637,7 +1637,7 @@
- `model: string`
- 用于该聊天补全的模型。
+ 用于聊天补全的模型。
- `object: "chat.completion"`
@@ -1647,21 +1647,21 @@
- `metadata: optional Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的其他信息,并通过 API 或控制台查询对象。
- 以结构化格式存储有关对象的其他信息,并通过 接口 或控制台查询对象。
+ 附加到对象的 16 个键值对集合。可用于以结构化
+ 格式存储关于对象的附加信息,并通过 API 或仪表板查询对象。
+ 格式存储关于对象的附加信息,并通过 接口 或仪表板查询对象。
- 键为字符串,最大长度为 64 个字符。值为字符串,
- 最大长度为 512 个字符。
+ 键为字符串,最长 64 个字符。值
+ 为字符串,最长 512 个字符。
- `moderation: optional object { input, output } or null`
- 请求输入和生成输出的审核结果(如果请求了
- 补全审核)。
+ 请求输入和生成输出的审核结果(如果请求了审核补全)
+ 补全。
- `input: object { model, results, type } or object { code, message, type }`
- 对请求输入的审核。
+ 请求输入的审核结果。
- `ModerationResults object { model, results, type }`
@@ -1677,11 +1677,11 @@
- `categories: map[boolean]`
- 一个从审核类别到布尔值的字典,若输入在该类别下被标记则为 True。
+ 从审核类别到布尔值的字典,如果输入在该类别下被标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所反映的输入模态。
+ 每个类别的分数反映了哪些输入模态。
- `"text"`
@@ -1689,11 +1689,11 @@
- `category_scores: map[number]`
- 一个从审核类别到分数的字典。
+ 从审核类别到分数的字典。
- `flagged: boolean`
- 一个布尔值,指示内容是否被任何类别标记。
+ 指示内容是否被任何类别标记的布尔值。
- `model: string`
@@ -1701,7 +1701,7 @@
- `type: "moderation_result"`
- 对象类型,在成功的审核结果中始终为 `moderation_result` 。
+ 对象类型,过去始终为 `moderation_result` (针对成功的审核结果)。
- `"moderation_result"`
@@ -1731,7 +1731,7 @@
- `output: object { model, results, type } or object { code, message, type }`
- 生成输出的审核。
+ 对生成内容的审核。
- `ModerationResults object { model, results, type }`
@@ -1747,11 +1747,11 @@
- `categories: map[boolean]`
- 一个从审核类别到布尔值的字典,若输入在该类别下被标记则为 True。
+ 从审核类别到布尔值的字典,如果输入在该类别下被标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所反映的输入模态。
+ 每个类别的分数反映了哪些输入模态。
- `"text"`
@@ -1759,11 +1759,11 @@
- `category_scores: map[number]`
- 一个从审核类别到分数的字典。
+ 从审核类别到分数的字典。
- `flagged: boolean`
- 一个布尔值,指示内容是否被任何类别标记。
+ 指示内容是否被任何类别标记的布尔值。
- `model: string`
@@ -1771,7 +1771,7 @@
- `type: "moderation_result"`
- 对象类型,在成功的审核结果中始终为 `moderation_result` 。
+ 对象类型,过去始终为 `moderation_result` (针对成功的审核结果)。
- `"moderation_result"`
@@ -1801,15 +1801,15 @@
- `service_tier: optional "auto" or "default" or "flex" or 3 more or null`
- 指定用于处理请求的处理类型。
+ 指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则请求将使用 Project 设置中配置的服务层级进行处理。除非另行配置,否则该 Project 将使用 'default'。
+ - 如果设置为 'auto',则请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
- 如果设置为 'default',则请求将使用所选模型的标准定价和性能进行处理。
- - 如果设置为 '[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为'[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。
+ - 若要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中传入 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你在请求中是否指定 `service_tier=fast` 或 `priority` 。
- 未设置时,默认行为为 'auto'。
- 当设置了 `service_tier` 参数时,响应主体将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。该响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应主体将根据实际用于处理该请求的处理模式返回 `service_tier` 值。该响应值可能与参数中设置的值不同。
- `"auto"`
@@ -1825,13 +1825,13 @@
- `system_fingerprint: optional string`
- 此指纹表示模型运行所使用的后端配置。
+ 该指纹表示模型运行所使用到的服务端配置。
- 可与 `seed` 请求参数结合使用,以了解何时进行了可能影响确定性的后端变更。
+ 可与以下 `seed` 请求参数配合使用,以了解何时进行了可能影响确定性的后端更改。
- `usage: optional CompletionUsage`
- 补全请求的使用情况统计信息。
+ 补全请求的使用统计信息。
- `completion_tokens: number`
@@ -1839,11 +1839,11 @@
- `prompt_tokens: number`
- 提示中的 token 数。
+ 提示词中的 token 数。
- `total_tokens: number`
- 请求中使用的总 token 数(提示 + 补全)。
+ 请求中使用的总 token 数(提示词 + 补全)。
- `completion_tokens_details: optional object { accepted_prediction_tokens, audio_tokens, reasoning_tokens, 2 more }`
@@ -1856,51 +1856,47 @@
- `audio_tokens: optional number`
- 模型生成的音频输入 token。
+ 模型生成的音频输入 token 数。
- `reasoning_tokens: optional number`
- 模型为推理生成的 token。
+ 模型生成的用于推理的 token 数。
- `rejected_prediction_tokens: optional number`
使用 Predicted Outputs 时,
- 未在补全中出现的预测 token。但是,与
- 推理 token 一样,这些 token 仍会计入
- 用于计费、输出和上下文窗口限制的
- 总补全 token 数中。
+ 未出现在补全中的预测 token。但与
+ 推理 token 类似,这些 token 仍会计入用于计费、
+ 输出以及上下文窗口限制的总补全 token 数中。
+ 限制。
- `text_tokens: optional number`
- 模型生成的文本输出 token。
-
- - `compute_units: optional number or null`
-
- 请求的计算单元。目前可用时为 null。
+ 模型生成的文本输出 token 数。
- `prompt_tokens_details: optional object { audio_tokens, cache_write_tokens, cached_tokens, 2 more }`
- 提示词中所使用 token 的明细。
+ 提示词中使用的 token 明细。
- `audio_tokens: optional number`
- 提示词中存在的音频输入 token。
+ 提示中存在的音频输入 token。
- `cache_write_tokens: optional number`
- 写入缓存的提示词 token 未调整数量。
+ 写入缓存的未调整提示 token 数量。
- `cached_tokens: optional number`
- 提示词中存在的已缓存 token。
+ 提示中存在的已缓存 token。
- `image_tokens: optional number`
- 提示词中存在的图像输入 token。
+ 提示中存在的图像输入 token。
- `text_tokens: optional number`
- 提示词中存在的文本输入 token。
+ 提示中存在的文本输入 token。
### 示例
@@ -2075,7 +2071,6 @@ curl https://api.openai.com/v1/chat/completions \
"rejected_prediction_tokens": 0,
"text_tokens": 0
},
- "compute_units": 0,
"prompt_tokens_details": {
"audio_tokens": 0,
"cache_write_tokens": 0,
@@ -2552,14 +2547,14 @@ curl https://api.openai.com/v1/chat/completions \
**delete** `/chat/completions/{completion_id}`
-删除已存储的聊天补全。仅可删除使用
-参数设为 `store` 创建的 Chat Completions `true` 。
+删除已存储的 Chat Completions。仅当 Chat Completions 是通过设置
+参数创建的 `store` 参数时才能被删除。 `true` 才能被删除。
### 路径参数
- `completion_id: string`
-### 返回值
+### Returns
- `ChatCompletionDeleted object { id, deleted, object }`
@@ -2573,7 +2568,7 @@ curl https://api.openai.com/v1/chat/completions \
- `object: "chat.completion.deleted"`
- 被删除对象的类型。
+ 正在删除的对象的类型。
- `"chat.completion.deleted"`
@@ -2613,62 +2608,62 @@ curl -X DELETE https://api.openai.com/v1/chat/completions/chat_abc123 \
}
```
-## 聊天补全列表
+## List Chat Completions
**get** `/chat/completions`
-列出已存储的 Chat Completions。仅返回通过 store 参数设置为存储的 Chat Completions。
-with the `store` 创建的 Chat Completions `true` 将不会被返回。
+列出已存储的 Chat Completions。仅返回使用
+存储的 `store` 参数时才能被删除。 `true` 将被返回。
### 查询参数
- `after: optional string`
- 上一个分页请求所返回的最后一次 chat completion 的标识符。
+ 上一次分页请求中最后一条聊天补全的标识符。
- `limit: optional number`
- 要检索的 Chat Completions 数量。
+ 要检索的聊天补全数量。
- `metadata: optional Metadata or null`
- 用于筛选 Chat Completions 的元数据键列表。示例:
+ 用于按元数据键筛选聊天补全的列表。例如:
`metadata[key1]=value1&metadata[key2]=value2`
- `model: optional string`
- 用于生成这些 Chat Completions 的模型。
+ 用于生成聊天补全的模型。
- `order: optional "asc" or "desc"`
- 按时间戳排序 Chat Completions 的顺序。使用 `asc` 表示升序,或使用 `desc` 表示降序。默认为 `asc`.
+ 按时间戳排序聊天补全的顺序。使用 `asc` 表示升序,或 `desc` 表示降序。默认为 `asc`.
- `"asc"`
- `"desc"`
-### 返回值
+### Returns
- `data: array of ChatCompletion`
- chat completion 对象数组。
+ 一个由聊天补全对象组成的数组。
- `id: string`
- 聊天补全的唯一标识符。
+ 聊天完成的唯一标识符。
- `choices: array of object { finish_reason, index, logprobs, message }`
- 聊天补全选项的列表。如果 `n` 大于 1,则可能不止一个。
+ 聊天完成选项的列表。如果 `n` 大于 1,则可以包含多个。
- `finish_reason: "stop" or "length" or "tool_calls" or 2 more`
- 模型停止生成 token 的原因。如果模型遇到自然停止点或提供的停止序列,则为 `stop` ;如果达到请求中指定的最大 token 数,则为,
- `length` ;如果因我们的内容过滤器标记而被省略内容,则为,
- `content_filter` ;如果模型调用了工具,则为,
- `tool_calls` ;如果模型调用了函数,则为 `function_call` (已弃用)。
- 请参阅 [Model Spec](https://model-spec.openai.com/2025-12-18.html) 了解更多信息。
+ 模型停止生成 token 的原因。该字段为 `stop` ,表示模型到达了自然停止点或遇到了提供的停止序列,
+ `length` ,表示已达到请求中指定的最大 token 数,
+ `content_filter` ,表示内容因我们的内容过滤器的标记而被省略,
+ `tool_calls` ,表示模型调用了工具,或 `function_call` (已弃用),表示模型调用了函数。
+ 请阅读 [模型规范](https://model-spec.openai.com/2025-12-18.html) 了解更多信息。
- `"stop"`
@@ -2682,7 +2677,7 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `index: number`
- 选项在选项列表中的索引。
+ 该选项在选项列表中的索引。
- `logprobs: object { content, refusal } or null`
@@ -2698,15 +2693,15 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `top_logprobs: array of object { token, bytes, logprob }`
- 在该 token 位置上,最可能出现的 token 及其对数概率的列表。条目数量可能少于所请求的 `top_logprobs`.
+ 在该 token 位置处可能性最高的 token 列表及其对数概率。条目数量可能少于请求的 `top_logprobs`.
- `token: string`
@@ -2714,15 +2709,15 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `refusal: array of ChatCompletionTokenLogprob or null`
- 包含对数概率信息的拒绝消息 token 列表。
+ 包含对数概率信息的消息拒绝 token 列表。
- `token: string`
@@ -2730,19 +2725,19 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `top_logprobs: array of object { token, bytes, logprob }`
- 在该 token 位置上,最可能出现的 token 及其对数概率的列表。条目数量可能少于所请求的 `top_logprobs`.
+ 在该 token 位置处可能性最高的 token 列表及其对数概率。条目数量可能少于请求的 `top_logprobs`.
- `message: ChatCompletionMessage`
- 由模型生成的聊天完成消息。
+ 由模型生成的聊天补全消息。
- `content: string or null`
@@ -2750,7 +2745,7 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `refusal: string or null`
- 由模型生成的拒绝消息。
+ 模型生成的拒绝消息。
- `role: "assistant"`
@@ -2760,8 +2755,8 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `annotations: optional array of object { type, url_citation }`
- 消息的注释(如果适用),例如在使用
- [网页搜索工具](/docs/guides/tools-web-search?api-mode=chat).
+ 消息的注释(如适用),例如在使用
+ [网页搜索 工具](/docs/guides/tools-web-search?api-mode=chat).
- `type: "url_citation"`
@@ -2779,7 +2774,7 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `start_index: number`
- 消息中 URL 引用的第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
@@ -2791,23 +2786,23 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `audio: optional ChatCompletionAudio or null`
- 如果请求了音频输出模态,该对象包含来自模型的音频
- 响应的相关数据。 [了解更多](/docs/guides/audio).
+ 如果请求了音频输出模态,则此对象包含有关模型音频响应的数据
+ 关于模型的音频响应。 [了解更多](/docs/guides/audio).
- `id: string`
- 此音频响应的唯一标识符。
+ 该音频响应的唯一标识符。
- `data: string`
- 模型生成的 Base64 编码音频字节,格式为
+ 由模型生成的 Base64 编码音频字节,格式为
请求中指定的格式。
- `expires_at: number`
- 此音频响应在服务端上无法再被用于多轮
- 访问的 Unix 时间戳(秒)。
- 对话。
+ 该音频响应在服务端不再可用于多轮对话的 Unix 时间戳(秒)
+ 对话的 Unix 时间戳(以秒为单位)。
+ conversations.
- `transcript: string`
@@ -2815,15 +2810,15 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `function_call: optional object { arguments, name }`
- 已弃用,由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
+ 已弃用,已由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `tool_calls: optional array of ChatCompletionMessageToolCall`
@@ -2843,15 +2838,15 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `type: "function"`
- 工具的类型。目前,仅 `function` 类型。
+ 工具的类型。目前,仅支持 `function` 内容。
- `"function"`
@@ -2887,7 +2882,7 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `model: string`
- 用于该聊天补全的模型。
+ 用于聊天补全的模型。
- `object: "chat.completion"`
@@ -2897,21 +2892,21 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `metadata: optional Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的其他信息,并通过 API 或控制台查询对象。
- 以结构化格式存储有关对象的其他信息,并通过 接口 或控制台查询对象。
+ 附加到对象的 16 个键值对集合。可用于以结构化
+ 格式存储关于对象的附加信息,并通过 API 或仪表板查询对象。
+ 格式存储关于对象的附加信息,并通过 接口 或仪表板查询对象。
- 键为字符串,最大长度为 64 个字符。值为字符串,
- 最大长度为 512 个字符。
+ 键为字符串,最长 64 个字符。值
+ 为字符串,最长 512 个字符。
- `moderation: optional object { input, output } or null`
- 请求输入和生成输出的审核结果(如果请求了
- 补全审核)。
+ 请求输入和生成输出的审核结果(如果请求了审核补全)
+ 补全。
- `input: object { model, results, type } or object { code, message, type }`
- 对请求输入的审核。
+ 请求输入的审核结果。
- `ModerationResults object { model, results, type }`
@@ -2927,11 +2922,11 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `categories: map[boolean]`
- 一个从审核类别到布尔值的字典,若输入在该类别下被标记则为 True。
+ 从审核类别到布尔值的字典,如果输入在该类别下被标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所反映的输入模态。
+ 每个类别的分数反映了哪些输入模态。
- `"text"`
@@ -2939,11 +2934,11 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `category_scores: map[number]`
- 一个从审核类别到分数的字典。
+ 从审核类别到分数的字典。
- `flagged: boolean`
- 一个布尔值,指示内容是否被任何类别标记。
+ 指示内容是否被任何类别标记的布尔值。
- `model: string`
@@ -2951,7 +2946,7 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `type: "moderation_result"`
- 对象类型,在成功的审核结果中始终为 `moderation_result` 。
+ 对象类型,过去始终为 `moderation_result` (针对成功的审核结果)。
- `"moderation_result"`
@@ -2981,7 +2976,7 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `output: object { model, results, type } or object { code, message, type }`
- 生成输出的审核。
+ 对生成内容的审核。
- `ModerationResults object { model, results, type }`
@@ -2997,11 +2992,11 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `categories: map[boolean]`
- 一个从审核类别到布尔值的字典,若输入在该类别下被标记则为 True。
+ 从审核类别到布尔值的字典,如果输入在该类别下被标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所反映的输入模态。
+ 每个类别的分数反映了哪些输入模态。
- `"text"`
@@ -3009,11 +3004,11 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `category_scores: map[number]`
- 一个从审核类别到分数的字典。
+ 从审核类别到分数的字典。
- `flagged: boolean`
- 一个布尔值,指示内容是否被任何类别标记。
+ 指示内容是否被任何类别标记的布尔值。
- `model: string`
@@ -3021,7 +3016,7 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `type: "moderation_result"`
- 对象类型,在成功的审核结果中始终为 `moderation_result` 。
+ 对象类型,过去始终为 `moderation_result` (针对成功的审核结果)。
- `"moderation_result"`
@@ -3051,15 +3046,15 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `service_tier: optional "auto" or "default" or "flex" or 3 more or null`
- 指定用于处理请求的处理类型。
+ 指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则请求将使用 Project 设置中配置的服务层级进行处理。除非另行配置,否则该 Project 将使用 'default'。
+ - 如果设置为 'auto',则请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
- 如果设置为 'default',则请求将使用所选模型的标准定价和性能进行处理。
- - 如果设置为 '[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为'[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。
+ - 若要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中传入 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你在请求中是否指定 `service_tier=fast` 或 `priority` 。
- 未设置时,默认行为为 'auto'。
- 当设置了 `service_tier` 参数时,响应主体将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。该响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应主体将根据实际用于处理该请求的处理模式返回 `service_tier` 值。该响应值可能与参数中设置的值不同。
- `"auto"`
@@ -3075,13 +3070,13 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `system_fingerprint: optional string`
- 此指纹表示模型运行所使用的后端配置。
+ 该指纹表示模型运行所使用到的服务端配置。
- 可与 `seed` 请求参数结合使用,以了解何时进行了可能影响确定性的后端变更。
+ 可与以下 `seed` 请求参数配合使用,以了解何时进行了可能影响确定性的后端更改。
- `usage: optional CompletionUsage`
- 补全请求的使用情况统计信息。
+ 补全请求的使用统计信息。
- `completion_tokens: number`
@@ -3089,11 +3084,11 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `prompt_tokens: number`
- 提示中的 token 数。
+ 提示词中的 token 数。
- `total_tokens: number`
- 请求中使用的总 token 数(提示 + 补全)。
+ 请求中使用的总 token 数(提示词 + 补全)。
- `completion_tokens_details: optional object { accepted_prediction_tokens, audio_tokens, reasoning_tokens, 2 more }`
@@ -3106,63 +3101,59 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `audio_tokens: optional number`
- 模型生成的音频输入 token。
+ 模型生成的音频输入 token 数。
- `reasoning_tokens: optional number`
- 模型为推理生成的 token。
+ 模型生成的用于推理的 token 数。
- `rejected_prediction_tokens: optional number`
使用 Predicted Outputs 时,
- 未在补全中出现的预测 token。但是,与
- 推理 token 一样,这些 token 仍会计入
- 用于计费、输出和上下文窗口限制的
- 总补全 token 数中。
+ 未出现在补全中的预测 token。但与
+ 推理 token 类似,这些 token 仍会计入用于计费、
+ 输出以及上下文窗口限制的总补全 token 数中。
+ 限制。
- `text_tokens: optional number`
- 模型生成的文本输出 token。
-
- - `compute_units: optional number or null`
-
- 请求的计算单元。目前可用时为 null。
+ 模型生成的文本输出 token 数。
- `prompt_tokens_details: optional object { audio_tokens, cache_write_tokens, cached_tokens, 2 more }`
- 提示词中所使用 token 的明细。
+ 提示词中使用的 token 明细。
- `audio_tokens: optional number`
- 提示词中存在的音频输入 token。
+ 提示中存在的音频输入 token。
- `cache_write_tokens: optional number`
- 写入缓存的提示词 token 未调整数量。
+ 写入缓存的未调整提示 token 数量。
- `cached_tokens: optional number`
- 提示词中存在的已缓存 token。
+ 提示中存在的已缓存 token。
- `image_tokens: optional number`
- 提示词中存在的图像输入 token。
+ 提示中存在的图像输入 token。
- `text_tokens: optional number`
- 提示词中存在的文本输入 token。
+ 提示中存在的文本输入 token。
- `first_id: string`
- data 数组中第一个 chat completion 的标识符。
+ 数据数组中第一条聊天补全的标识符。
- `has_more: boolean`
- 指示是否还有更多 Chat Completions 可供检索。
+ 指示是否还有更多可用的聊天补全。
- `last_id: string`
- data 数组中最后一个 chat completion 的标识符。
+ 数据数组中最后一条聊天补全的标识符。
- `object: "list"`
@@ -3329,7 +3320,6 @@ curl https://api.openai.com/v1/chat/completions \
"rejected_prediction_tokens": 0,
"text_tokens": 0
},
- "compute_units": 0,
"prompt_tokens_details": {
"audio_tokens": 0,
"cache_write_tokens": 0,
@@ -3409,34 +3399,34 @@ curl https://api.openai.com/v1/chat/completions \
**get** `/chat/completions/{completion_id}`
-获取已存储的对话补全。仅限已创建的 Chat Completions
-with the `store` 创建的 Chat Completions `true` 将不会被返回。
+获取已存储的聊天补全。仅限已创建的 Chat Completions
+存储的 `store` 参数时才能被删除。 `true` 将被返回。
### 路径参数
- `completion_id: string`
-### 返回值
+### Returns
- `ChatCompletion object { id, choices, created, 7 more }`
- 表示模型根据提供的输入返回的聊天补全响应。
+ 表示模型根据提供的输入返回的聊天完成响应。
- `id: string`
- 聊天补全的唯一标识符。
+ 聊天完成的唯一标识符。
- `choices: array of object { finish_reason, index, logprobs, message }`
- 聊天补全选项的列表。如果 `n` 大于 1,则可能不止一个。
+ 聊天完成选项的列表。如果 `n` 大于 1,则可以包含多个。
- `finish_reason: "stop" or "length" or "tool_calls" or 2 more`
- 模型停止生成 token 的原因。如果模型遇到自然停止点或提供的停止序列,则为 `stop` ;如果达到请求中指定的最大 token 数,则为,
- `length` ;如果因我们的内容过滤器标记而被省略内容,则为,
- `content_filter` ;如果模型调用了工具,则为,
- `tool_calls` ;如果模型调用了函数,则为 `function_call` (已弃用)。
- 请参阅 [Model Spec](https://model-spec.openai.com/2025-12-18.html) 了解更多信息。
+ 模型停止生成 token 的原因。该字段为 `stop` ,表示模型到达了自然停止点或遇到了提供的停止序列,
+ `length` ,表示已达到请求中指定的最大 token 数,
+ `content_filter` ,表示内容因我们的内容过滤器的标记而被省略,
+ `tool_calls` ,表示模型调用了工具,或 `function_call` (已弃用),表示模型调用了函数。
+ 请阅读 [模型规范](https://model-spec.openai.com/2025-12-18.html) 了解更多信息。
- `"stop"`
@@ -3450,7 +3440,7 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `index: number`
- 选项在选项列表中的索引。
+ 该选项在选项列表中的索引。
- `logprobs: object { content, refusal } or null`
@@ -3466,15 +3456,15 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `top_logprobs: array of object { token, bytes, logprob }`
- 在该 token 位置上,最可能出现的 token 及其对数概率的列表。条目数量可能少于所请求的 `top_logprobs`.
+ 在该 token 位置处可能性最高的 token 列表及其对数概率。条目数量可能少于请求的 `top_logprobs`.
- `token: string`
@@ -3482,15 +3472,15 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `refusal: array of ChatCompletionTokenLogprob or null`
- 包含对数概率信息的拒绝消息 token 列表。
+ 包含对数概率信息的消息拒绝 token 列表。
- `token: string`
@@ -3498,19 +3488,19 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `top_logprobs: array of object { token, bytes, logprob }`
- 在该 token 位置上,最可能出现的 token 及其对数概率的列表。条目数量可能少于所请求的 `top_logprobs`.
+ 在该 token 位置处可能性最高的 token 列表及其对数概率。条目数量可能少于请求的 `top_logprobs`.
- `message: ChatCompletionMessage`
- 由模型生成的聊天完成消息。
+ 由模型生成的聊天补全消息。
- `content: string or null`
@@ -3518,7 +3508,7 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `refusal: string or null`
- 由模型生成的拒绝消息。
+ 模型生成的拒绝消息。
- `role: "assistant"`
@@ -3528,8 +3518,8 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `annotations: optional array of object { type, url_citation }`
- 消息的注释(如果适用),例如在使用
- [网页搜索工具](/docs/guides/tools-web-search?api-mode=chat).
+ 消息的注释(如适用),例如在使用
+ [网页搜索 工具](/docs/guides/tools-web-search?api-mode=chat).
- `type: "url_citation"`
@@ -3547,7 +3537,7 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `start_index: number`
- 消息中 URL 引用的第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
@@ -3559,23 +3549,23 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `audio: optional ChatCompletionAudio or null`
- 如果请求了音频输出模态,该对象包含来自模型的音频
- 响应的相关数据。 [了解更多](/docs/guides/audio).
+ 如果请求了音频输出模态,则此对象包含有关模型音频响应的数据
+ 关于模型的音频响应。 [了解更多](/docs/guides/audio).
- `id: string`
- 此音频响应的唯一标识符。
+ 该音频响应的唯一标识符。
- `data: string`
- 模型生成的 Base64 编码音频字节,格式为
+ 由模型生成的 Base64 编码音频字节,格式为
请求中指定的格式。
- `expires_at: number`
- 此音频响应在服务端上无法再被用于多轮
- 访问的 Unix 时间戳(秒)。
- 对话。
+ 该音频响应在服务端不再可用于多轮对话的 Unix 时间戳(秒)
+ 对话的 Unix 时间戳(以秒为单位)。
+ conversations.
- `transcript: string`
@@ -3583,15 +3573,15 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `function_call: optional object { arguments, name }`
- 已弃用,由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
+ 已弃用,已由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `tool_calls: optional array of ChatCompletionMessageToolCall`
@@ -3611,15 +3601,15 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `type: "function"`
- 工具的类型。目前,仅 `function` 类型。
+ 工具的类型。目前,仅支持 `function` 内容。
- `"function"`
@@ -3655,7 +3645,7 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `model: string`
- 用于该聊天补全的模型。
+ 用于聊天补全的模型。
- `object: "chat.completion"`
@@ -3665,21 +3655,21 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `metadata: optional Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的其他信息,并通过 API 或控制台查询对象。
- 以结构化格式存储有关对象的其他信息,并通过 接口 或控制台查询对象。
+ 附加到对象的 16 个键值对集合。可用于以结构化
+ 格式存储关于对象的附加信息,并通过 API 或仪表板查询对象。
+ 格式存储关于对象的附加信息,并通过 接口 或仪表板查询对象。
- 键为字符串,最大长度为 64 个字符。值为字符串,
- 最大长度为 512 个字符。
+ 键为字符串,最长 64 个字符。值
+ 为字符串,最长 512 个字符。
- `moderation: optional object { input, output } or null`
- 请求输入和生成输出的审核结果(如果请求了
- 补全审核)。
+ 请求输入和生成输出的审核结果(如果请求了审核补全)
+ 补全。
- `input: object { model, results, type } or object { code, message, type }`
- 对请求输入的审核。
+ 请求输入的审核结果。
- `ModerationResults object { model, results, type }`
@@ -3695,11 +3685,11 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `categories: map[boolean]`
- 一个从审核类别到布尔值的字典,若输入在该类别下被标记则为 True。
+ 从审核类别到布尔值的字典,如果输入在该类别下被标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所反映的输入模态。
+ 每个类别的分数反映了哪些输入模态。
- `"text"`
@@ -3707,11 +3697,11 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `category_scores: map[number]`
- 一个从审核类别到分数的字典。
+ 从审核类别到分数的字典。
- `flagged: boolean`
- 一个布尔值,指示内容是否被任何类别标记。
+ 指示内容是否被任何类别标记的布尔值。
- `model: string`
@@ -3719,7 +3709,7 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `type: "moderation_result"`
- 对象类型,在成功的审核结果中始终为 `moderation_result` 。
+ 对象类型,过去始终为 `moderation_result` (针对成功的审核结果)。
- `"moderation_result"`
@@ -3749,7 +3739,7 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `output: object { model, results, type } or object { code, message, type }`
- 生成输出的审核。
+ 对生成内容的审核。
- `ModerationResults object { model, results, type }`
@@ -3765,11 +3755,11 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `categories: map[boolean]`
- 一个从审核类别到布尔值的字典,若输入在该类别下被标记则为 True。
+ 从审核类别到布尔值的字典,如果输入在该类别下被标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所反映的输入模态。
+ 每个类别的分数反映了哪些输入模态。
- `"text"`
@@ -3777,11 +3767,11 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `category_scores: map[number]`
- 一个从审核类别到分数的字典。
+ 从审核类别到分数的字典。
- `flagged: boolean`
- 一个布尔值,指示内容是否被任何类别标记。
+ 指示内容是否被任何类别标记的布尔值。
- `model: string`
@@ -3789,7 +3779,7 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `type: "moderation_result"`
- 对象类型,在成功的审核结果中始终为 `moderation_result` 。
+ 对象类型,过去始终为 `moderation_result` (针对成功的审核结果)。
- `"moderation_result"`
@@ -3819,15 +3809,15 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `service_tier: optional "auto" or "default" or "flex" or 3 more or null`
- 指定用于处理请求的处理类型。
+ 指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则请求将使用 Project 设置中配置的服务层级进行处理。除非另行配置,否则该 Project 将使用 'default'。
+ - 如果设置为 'auto',则请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
- 如果设置为 'default',则请求将使用所选模型的标准定价和性能进行处理。
- - 如果设置为 '[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为'[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。
+ - 若要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中传入 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你在请求中是否指定 `service_tier=fast` 或 `priority` 。
- 未设置时,默认行为为 'auto'。
- 当设置了 `service_tier` 参数时,响应主体将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。该响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应主体将根据实际用于处理该请求的处理模式返回 `service_tier` 值。该响应值可能与参数中设置的值不同。
- `"auto"`
@@ -3843,13 +3833,13 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `system_fingerprint: optional string`
- 此指纹表示模型运行所使用的后端配置。
+ 该指纹表示模型运行所使用到的服务端配置。
- 可与 `seed` 请求参数结合使用,以了解何时进行了可能影响确定性的后端变更。
+ 可与以下 `seed` 请求参数配合使用,以了解何时进行了可能影响确定性的后端更改。
- `usage: optional CompletionUsage`
- 补全请求的使用情况统计信息。
+ 补全请求的使用统计信息。
- `completion_tokens: number`
@@ -3857,11 +3847,11 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `prompt_tokens: number`
- 提示中的 token 数。
+ 提示词中的 token 数。
- `total_tokens: number`
- 请求中使用的总 token 数(提示 + 补全)。
+ 请求中使用的总 token 数(提示词 + 补全)。
- `completion_tokens_details: optional object { accepted_prediction_tokens, audio_tokens, reasoning_tokens, 2 more }`
@@ -3874,51 +3864,47 @@ with the `store` 创建的 Chat Completions `true` 将不会被返回。
- `audio_tokens: optional number`
- 模型生成的音频输入 token。
+ 模型生成的音频输入 token 数。
- `reasoning_tokens: optional number`
- 模型为推理生成的 token。
+ 模型生成的用于推理的 token 数。
- `rejected_prediction_tokens: optional number`
使用 Predicted Outputs 时,
- 未在补全中出现的预测 token。但是,与
- 推理 token 一样,这些 token 仍会计入
- 用于计费、输出和上下文窗口限制的
- 总补全 token 数中。
+ 未出现在补全中的预测 token。但与
+ 推理 token 类似,这些 token 仍会计入用于计费、
+ 输出以及上下文窗口限制的总补全 token 数中。
+ 限制。
- `text_tokens: optional number`
- 模型生成的文本输出 token。
-
- - `compute_units: optional number or null`
-
- 请求的计算单元。目前可用时为 null。
+ 模型生成的文本输出 token 数。
- `prompt_tokens_details: optional object { audio_tokens, cache_write_tokens, cached_tokens, 2 more }`
- 提示词中所使用 token 的明细。
+ 提示词中使用的 token 明细。
- `audio_tokens: optional number`
- 提示词中存在的音频输入 token。
+ 提示中存在的音频输入 token。
- `cache_write_tokens: optional number`
- 写入缓存的提示词 token 未调整数量。
+ 写入缓存的未调整提示 token 数量。
- `cached_tokens: optional number`
- 提示词中存在的已缓存 token。
+ 提示中存在的已缓存 token。
- `image_tokens: optional number`
- 提示词中存在的图像输入 token。
+ 提示中存在的图像输入 token。
- `text_tokens: optional number`
- 提示词中存在的文本输入 token。
+ 提示中存在的文本输入 token。
### 示例
@@ -4077,7 +4063,6 @@ curl https://api.openai.com/v1/chat/completions/$COMPLETION_ID \
"rejected_prediction_tokens": 0,
"text_tokens": 0
},
- "compute_units": 0,
"prompt_tokens_details": {
"audio_tokens": 0,
"cache_write_tokens": 0,
@@ -4139,50 +4124,50 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
}
```
-## Update chat completion
+## 更新聊天补全
**post** `/chat/completions/{completion_id}`
-修改已存储的聊天补全。仅限已被修改的 Chat Completions
-参数设为 `store` 创建的 Chat Completions `true` 可被修改。目前,
+修改已存储的 Chat Completions。只能修改
+参数创建的 `store` 参数时才能被删除。 `true` 的 Chat Completion。当前,
唯一支持的修改是更新 `metadata` 字段。
### 路径参数
- `completion_id: string`
-### Body Parameters
+### 正文参数
- `metadata: Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的其他信息,并通过 API 或控制台查询对象。
- 以结构化格式存储有关对象的其他信息,并通过 接口 或控制台查询对象。
+ 附加到对象的 16 个键值对集合。可用于以结构化
+ 格式存储关于对象的附加信息,并通过 API 或仪表板查询对象。
+ 格式存储关于对象的附加信息,并通过 接口 或仪表板查询对象。
- 键为字符串,最大长度为 64 个字符。值为字符串,
- 最大长度为 512 个字符。
+ 键为字符串,最长 64 个字符。值
+ 为字符串,最长 512 个字符。
-### 返回值
+### Returns
- `ChatCompletion object { id, choices, created, 7 more }`
- 表示模型根据提供的输入返回的聊天补全响应。
+ 表示模型根据提供的输入返回的聊天完成响应。
- `id: string`
- 聊天补全的唯一标识符。
+ 聊天完成的唯一标识符。
- `choices: array of object { finish_reason, index, logprobs, message }`
- 聊天补全选项的列表。如果 `n` 大于 1,则可能不止一个。
+ 聊天完成选项的列表。如果 `n` 大于 1,则可以包含多个。
- `finish_reason: "stop" or "length" or "tool_calls" or 2 more`
- 模型停止生成 token 的原因。如果模型遇到自然停止点或提供的停止序列,则为 `stop` ;如果达到请求中指定的最大 token 数,则为,
- `length` ;如果因我们的内容过滤器标记而被省略内容,则为,
- `content_filter` ;如果模型调用了工具,则为,
- `tool_calls` ;如果模型调用了函数,则为 `function_call` (已弃用)。
- 请参阅 [Model Spec](https://model-spec.openai.com/2025-12-18.html) 了解更多信息。
+ 模型停止生成 token 的原因。该字段为 `stop` ,表示模型到达了自然停止点或遇到了提供的停止序列,
+ `length` ,表示已达到请求中指定的最大 token 数,
+ `content_filter` ,表示内容因我们的内容过滤器的标记而被省略,
+ `tool_calls` ,表示模型调用了工具,或 `function_call` (已弃用),表示模型调用了函数。
+ 请阅读 [模型规范](https://model-spec.openai.com/2025-12-18.html) 了解更多信息。
- `"stop"`
@@ -4196,7 +4181,7 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `index: number`
- 选项在选项列表中的索引。
+ 该选项在选项列表中的索引。
- `logprobs: object { content, refusal } or null`
@@ -4212,15 +4197,15 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `top_logprobs: array of object { token, bytes, logprob }`
- 在该 token 位置上,最可能出现的 token 及其对数概率的列表。条目数量可能少于所请求的 `top_logprobs`.
+ 在该 token 位置处可能性最高的 token 列表及其对数概率。条目数量可能少于请求的 `top_logprobs`.
- `token: string`
@@ -4228,15 +4213,15 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `refusal: array of ChatCompletionTokenLogprob or null`
- 包含对数概率信息的拒绝消息 token 列表。
+ 包含对数概率信息的消息拒绝 token 列表。
- `token: string`
@@ -4244,19 +4229,19 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `top_logprobs: array of object { token, bytes, logprob }`
- 在该 token 位置上,最可能出现的 token 及其对数概率的列表。条目数量可能少于所请求的 `top_logprobs`.
+ 在该 token 位置处可能性最高的 token 列表及其对数概率。条目数量可能少于请求的 `top_logprobs`.
- `message: ChatCompletionMessage`
- 由模型生成的聊天完成消息。
+ 由模型生成的聊天补全消息。
- `content: string or null`
@@ -4264,7 +4249,7 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `refusal: string or null`
- 由模型生成的拒绝消息。
+ 模型生成的拒绝消息。
- `role: "assistant"`
@@ -4274,8 +4259,8 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `annotations: optional array of object { type, url_citation }`
- 消息的注释(如果适用),例如在使用
- [网页搜索工具](/docs/guides/tools-web-search?api-mode=chat).
+ 消息的注释(如适用),例如在使用
+ [网页搜索 工具](/docs/guides/tools-web-search?api-mode=chat).
- `type: "url_citation"`
@@ -4293,7 +4278,7 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `start_index: number`
- 消息中 URL 引用的第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
@@ -4305,23 +4290,23 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `audio: optional ChatCompletionAudio or null`
- 如果请求了音频输出模态,该对象包含来自模型的音频
- 响应的相关数据。 [了解更多](/docs/guides/audio).
+ 如果请求了音频输出模态,则此对象包含有关模型音频响应的数据
+ 关于模型的音频响应。 [了解更多](/docs/guides/audio).
- `id: string`
- 此音频响应的唯一标识符。
+ 该音频响应的唯一标识符。
- `data: string`
- 模型生成的 Base64 编码音频字节,格式为
+ 由模型生成的 Base64 编码音频字节,格式为
请求中指定的格式。
- `expires_at: number`
- 此音频响应在服务端上无法再被用于多轮
- 访问的 Unix 时间戳(秒)。
- 对话。
+ 该音频响应在服务端不再可用于多轮对话的 Unix 时间戳(秒)
+ 对话的 Unix 时间戳(以秒为单位)。
+ conversations.
- `transcript: string`
@@ -4329,15 +4314,15 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `function_call: optional object { arguments, name }`
- 已弃用,由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
+ 已弃用,已由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `tool_calls: optional array of ChatCompletionMessageToolCall`
@@ -4357,15 +4342,15 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `type: "function"`
- 工具的类型。目前,仅 `function` 类型。
+ 工具的类型。目前,仅支持 `function` 内容。
- `"function"`
@@ -4401,7 +4386,7 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `model: string`
- 用于该聊天补全的模型。
+ 用于聊天补全的模型。
- `object: "chat.completion"`
@@ -4411,21 +4396,21 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `metadata: optional Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的其他信息,并通过 API 或控制台查询对象。
- 以结构化格式存储有关对象的其他信息,并通过 接口 或控制台查询对象。
+ 附加到对象的 16 个键值对集合。可用于以结构化
+ 格式存储关于对象的附加信息,并通过 API 或仪表板查询对象。
+ 格式存储关于对象的附加信息,并通过 接口 或仪表板查询对象。
- 键为字符串,最大长度为 64 个字符。值为字符串,
- 最大长度为 512 个字符。
+ 键为字符串,最长 64 个字符。值
+ 为字符串,最长 512 个字符。
- `moderation: optional object { input, output } or null`
- 请求输入和生成输出的审核结果(如果请求了
- 补全审核)。
+ 请求输入和生成输出的审核结果(如果请求了审核补全)
+ 补全。
- `input: object { model, results, type } or object { code, message, type }`
- 对请求输入的审核。
+ 请求输入的审核结果。
- `ModerationResults object { model, results, type }`
@@ -4441,11 +4426,11 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `categories: map[boolean]`
- 一个从审核类别到布尔值的字典,若输入在该类别下被标记则为 True。
+ 从审核类别到布尔值的字典,如果输入在该类别下被标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所反映的输入模态。
+ 每个类别的分数反映了哪些输入模态。
- `"text"`
@@ -4453,11 +4438,11 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `category_scores: map[number]`
- 一个从审核类别到分数的字典。
+ 从审核类别到分数的字典。
- `flagged: boolean`
- 一个布尔值,指示内容是否被任何类别标记。
+ 指示内容是否被任何类别标记的布尔值。
- `model: string`
@@ -4465,7 +4450,7 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `type: "moderation_result"`
- 对象类型,在成功的审核结果中始终为 `moderation_result` 。
+ 对象类型,过去始终为 `moderation_result` (针对成功的审核结果)。
- `"moderation_result"`
@@ -4495,7 +4480,7 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `output: object { model, results, type } or object { code, message, type }`
- 生成输出的审核。
+ 对生成内容的审核。
- `ModerationResults object { model, results, type }`
@@ -4511,11 +4496,11 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `categories: map[boolean]`
- 一个从审核类别到布尔值的字典,若输入在该类别下被标记则为 True。
+ 从审核类别到布尔值的字典,如果输入在该类别下被标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所反映的输入模态。
+ 每个类别的分数反映了哪些输入模态。
- `"text"`
@@ -4523,11 +4508,11 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `category_scores: map[number]`
- 一个从审核类别到分数的字典。
+ 从审核类别到分数的字典。
- `flagged: boolean`
- 一个布尔值,指示内容是否被任何类别标记。
+ 指示内容是否被任何类别标记的布尔值。
- `model: string`
@@ -4535,7 +4520,7 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `type: "moderation_result"`
- 对象类型,在成功的审核结果中始终为 `moderation_result` 。
+ 对象类型,过去始终为 `moderation_result` (针对成功的审核结果)。
- `"moderation_result"`
@@ -4565,15 +4550,15 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `service_tier: optional "auto" or "default" or "flex" or 3 more or null`
- 指定用于处理请求的处理类型。
+ 指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则请求将使用 Project 设置中配置的服务层级进行处理。除非另行配置,否则该 Project 将使用 'default'。
+ - 如果设置为 'auto',则请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
- 如果设置为 'default',则请求将使用所选模型的标准定价和性能进行处理。
- - 如果设置为 '[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为'[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。
+ - 若要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中传入 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你在请求中是否指定 `service_tier=fast` 或 `priority` 。
- 未设置时,默认行为为 'auto'。
- 当设置了 `service_tier` 参数时,响应主体将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。该响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应主体将根据实际用于处理该请求的处理模式返回 `service_tier` 值。该响应值可能与参数中设置的值不同。
- `"auto"`
@@ -4589,13 +4574,13 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `system_fingerprint: optional string`
- 此指纹表示模型运行所使用的后端配置。
+ 该指纹表示模型运行所使用到的服务端配置。
- 可与 `seed` 请求参数结合使用,以了解何时进行了可能影响确定性的后端变更。
+ 可与以下 `seed` 请求参数配合使用,以了解何时进行了可能影响确定性的后端更改。
- `usage: optional CompletionUsage`
- 补全请求的使用情况统计信息。
+ 补全请求的使用统计信息。
- `completion_tokens: number`
@@ -4603,11 +4588,11 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `prompt_tokens: number`
- 提示中的 token 数。
+ 提示词中的 token 数。
- `total_tokens: number`
- 请求中使用的总 token 数(提示 + 补全)。
+ 请求中使用的总 token 数(提示词 + 补全)。
- `completion_tokens_details: optional object { accepted_prediction_tokens, audio_tokens, reasoning_tokens, 2 more }`
@@ -4620,51 +4605,47 @@ curl https://api.openai.com/v1/chat/completions/chatcmpl-abc123 \
- `audio_tokens: optional number`
- 模型生成的音频输入 token。
+ 模型生成的音频输入 token 数。
- `reasoning_tokens: optional number`
- 模型为推理生成的 token。
+ 模型生成的用于推理的 token 数。
- `rejected_prediction_tokens: optional number`
使用 Predicted Outputs 时,
- 未在补全中出现的预测 token。但是,与
- 推理 token 一样,这些 token 仍会计入
- 用于计费、输出和上下文窗口限制的
- 总补全 token 数中。
+ 未出现在补全中的预测 token。但与
+ 推理 token 类似,这些 token 仍会计入用于计费、
+ 输出以及上下文窗口限制的总补全 token 数中。
+ 限制。
- `text_tokens: optional number`
- 模型生成的文本输出 token。
-
- - `compute_units: optional number or null`
-
- 请求的计算单元。目前可用时为 null。
+ 模型生成的文本输出 token 数。
- `prompt_tokens_details: optional object { audio_tokens, cache_write_tokens, cached_tokens, 2 more }`
- 提示词中所使用 token 的明细。
+ 提示词中使用的 token 明细。
- `audio_tokens: optional number`
- 提示词中存在的音频输入 token。
+ 提示中存在的音频输入 token。
- `cache_write_tokens: optional number`
- 写入缓存的提示词 token 未调整数量。
+ 写入缓存的未调整提示 token 数量。
- `cached_tokens: optional number`
- 提示词中存在的已缓存 token。
+ 提示中存在的已缓存 token。
- `image_tokens: optional number`
- 提示词中存在的图像输入 token。
+ 提示中存在的图像输入 token。
- `text_tokens: optional number`
- 提示词中存在的文本输入 token。
+ 提示中存在的文本输入 token。
### 示例
@@ -4829,7 +4810,6 @@ curl https://api.openai.com/v1/chat/completions/$COMPLETION_ID \
"rejected_prediction_tokens": 0,
"text_tokens": 0
},
- "compute_units": 0,
"prompt_tokens_details": {
"audio_tokens": 0,
"cache_write_tokens": 0,
@@ -4900,13 +4880,13 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ChatCompletionAllowedTools object { mode, tools }`
- 将模型可使用的工具限制为预定义的集合。
+ 将模型可用的工具限制为预定义的集合。
- `mode: "auto" or "required"`
- 将模型可使用的工具限制为预定义的集合。
+ 将模型可用的工具限制为预定义的集合。
- `auto` 允许模型从允许的工具中选择并生成
+ `auto` 允许模型从允许的工具中选取并生成
消息。
`required` 要求模型调用一个或多个允许的工具。
@@ -4917,9 +4897,9 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `tools: array of map[unknown]`
- 模型可调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
- 对于 Chat Completions API,工具定义列表可能如下:
+ 对于 Chat Completions API,工具定义列表可能如下所示:
```json
[
@@ -4932,23 +4912,23 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ChatCompletion object { id, choices, created, 7 more }`
- 表示模型根据提供的输入返回的聊天补全响应。
+ 表示模型根据提供的输入返回的聊天完成响应。
- `id: string`
- 聊天补全的唯一标识符。
+ 聊天完成的唯一标识符。
- `choices: array of object { finish_reason, index, logprobs, message }`
- 聊天补全选项的列表。如果 `n` 大于 1,则可能不止一个。
+ 聊天完成选项的列表。如果 `n` 大于 1,则可以包含多个。
- `finish_reason: "stop" or "length" or "tool_calls" or 2 more`
- 模型停止生成 token 的原因。如果模型遇到自然停止点或提供的停止序列,则为 `stop` ;如果达到请求中指定的最大 token 数,则为,
- `length` ;如果因我们的内容过滤器标记而被省略内容,则为,
- `content_filter` ;如果模型调用了工具,则为,
- `tool_calls` ;如果模型调用了函数,则为 `function_call` (已弃用)。
- 请参阅 [Model Spec](https://model-spec.openai.com/2025-12-18.html) 了解更多信息。
+ 模型停止生成 token 的原因。该字段为 `stop` ,表示模型到达了自然停止点或遇到了提供的停止序列,
+ `length` ,表示已达到请求中指定的最大 token 数,
+ `content_filter` ,表示内容因我们的内容过滤器的标记而被省略,
+ `tool_calls` ,表示模型调用了工具,或 `function_call` (已弃用),表示模型调用了函数。
+ 请阅读 [模型规范](https://model-spec.openai.com/2025-12-18.html) 了解更多信息。
- `"stop"`
@@ -4962,7 +4942,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `index: number`
- 选项在选项列表中的索引。
+ 该选项在选项列表中的索引。
- `logprobs: object { content, refusal } or null`
@@ -4978,15 +4958,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `top_logprobs: array of object { token, bytes, logprob }`
- 在该 token 位置上,最可能出现的 token 及其对数概率的列表。条目数量可能少于所请求的 `top_logprobs`.
+ 在该 token 位置处可能性最高的 token 列表及其对数概率。条目数量可能少于请求的 `top_logprobs`.
- `token: string`
@@ -4994,15 +4974,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `refusal: array of ChatCompletionTokenLogprob or null`
- 包含对数概率信息的拒绝消息 token 列表。
+ 包含对数概率信息的消息拒绝 token 列表。
- `token: string`
@@ -5010,19 +4990,19 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `top_logprobs: array of object { token, bytes, logprob }`
- 在该 token 位置上,最可能出现的 token 及其对数概率的列表。条目数量可能少于所请求的 `top_logprobs`.
+ 在该 token 位置处可能性最高的 token 列表及其对数概率。条目数量可能少于请求的 `top_logprobs`.
- `message: ChatCompletionMessage`
- 由模型生成的聊天完成消息。
+ 由模型生成的聊天补全消息。
- `content: string or null`
@@ -5030,7 +5010,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `refusal: string or null`
- 由模型生成的拒绝消息。
+ 模型生成的拒绝消息。
- `role: "assistant"`
@@ -5040,8 +5020,8 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `annotations: optional array of object { type, url_citation }`
- 消息的注释(如果适用),例如在使用
- [网页搜索工具](/docs/guides/tools-web-search?api-mode=chat).
+ 消息的注释(如适用),例如在使用
+ [网页搜索 工具](/docs/guides/tools-web-search?api-mode=chat).
- `type: "url_citation"`
@@ -5059,7 +5039,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `start_index: number`
- 消息中 URL 引用的第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
@@ -5071,23 +5051,23 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `audio: optional ChatCompletionAudio or null`
- 如果请求了音频输出模态,该对象包含来自模型的音频
- 响应的相关数据。 [了解更多](/docs/guides/audio).
+ 如果请求了音频输出模态,则此对象包含有关模型音频响应的数据
+ 关于模型的音频响应。 [了解更多](/docs/guides/audio).
- `id: string`
- 此音频响应的唯一标识符。
+ 该音频响应的唯一标识符。
- `data: string`
- 模型生成的 Base64 编码音频字节,格式为
+ 由模型生成的 Base64 编码音频字节,格式为
请求中指定的格式。
- `expires_at: number`
- 此音频响应在服务端上无法再被用于多轮
- 访问的 Unix 时间戳(秒)。
- 对话。
+ 该音频响应在服务端不再可用于多轮对话的 Unix 时间戳(秒)
+ 对话的 Unix 时间戳(以秒为单位)。
+ conversations.
- `transcript: string`
@@ -5095,15 +5075,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `function_call: optional object { arguments, name }`
- 已弃用,由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
+ 已弃用,已由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `tool_calls: optional array of ChatCompletionMessageToolCall`
@@ -5123,15 +5103,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `type: "function"`
- 工具的类型。目前,仅 `function` 类型。
+ 工具的类型。目前,仅支持 `function` 内容。
- `"function"`
@@ -5167,7 +5147,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `model: string`
- 用于该聊天补全的模型。
+ 用于聊天补全的模型。
- `object: "chat.completion"`
@@ -5177,21 +5157,21 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `metadata: optional Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的其他信息,并通过 API 或控制台查询对象。
- 以结构化格式存储有关对象的其他信息,并通过 接口 或控制台查询对象。
+ 附加到对象的 16 个键值对集合。可用于以结构化
+ 格式存储关于对象的附加信息,并通过 API 或仪表板查询对象。
+ 格式存储关于对象的附加信息,并通过 接口 或仪表板查询对象。
- 键为字符串,最大长度为 64 个字符。值为字符串,
- 最大长度为 512 个字符。
+ 键为字符串,最长 64 个字符。值
+ 为字符串,最长 512 个字符。
- `moderation: optional object { input, output } or null`
- 请求输入和生成输出的审核结果(如果请求了
- 补全审核)。
+ 请求输入和生成输出的审核结果(如果请求了审核补全)
+ 补全。
- `input: object { model, results, type } or object { code, message, type }`
- 对请求输入的审核。
+ 请求输入的审核结果。
- `ModerationResults object { model, results, type }`
@@ -5207,11 +5187,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `categories: map[boolean]`
- 一个从审核类别到布尔值的字典,若输入在该类别下被标记则为 True。
+ 从审核类别到布尔值的字典,如果输入在该类别下被标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所反映的输入模态。
+ 每个类别的分数反映了哪些输入模态。
- `"text"`
@@ -5219,11 +5199,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `category_scores: map[number]`
- 一个从审核类别到分数的字典。
+ 从审核类别到分数的字典。
- `flagged: boolean`
- 一个布尔值,指示内容是否被任何类别标记。
+ 指示内容是否被任何类别标记的布尔值。
- `model: string`
@@ -5231,7 +5211,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "moderation_result"`
- 对象类型,在成功的审核结果中始终为 `moderation_result` 。
+ 对象类型,过去始终为 `moderation_result` (针对成功的审核结果)。
- `"moderation_result"`
@@ -5261,7 +5241,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `output: object { model, results, type } or object { code, message, type }`
- 生成输出的审核。
+ 对生成内容的审核。
- `ModerationResults object { model, results, type }`
@@ -5277,11 +5257,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `categories: map[boolean]`
- 一个从审核类别到布尔值的字典,若输入在该类别下被标记则为 True。
+ 从审核类别到布尔值的字典,如果输入在该类别下被标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所反映的输入模态。
+ 每个类别的分数反映了哪些输入模态。
- `"text"`
@@ -5289,11 +5269,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `category_scores: map[number]`
- 一个从审核类别到分数的字典。
+ 从审核类别到分数的字典。
- `flagged: boolean`
- 一个布尔值,指示内容是否被任何类别标记。
+ 指示内容是否被任何类别标记的布尔值。
- `model: string`
@@ -5301,7 +5281,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "moderation_result"`
- 对象类型,在成功的审核结果中始终为 `moderation_result` 。
+ 对象类型,过去始终为 `moderation_result` (针对成功的审核结果)。
- `"moderation_result"`
@@ -5331,15 +5311,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `service_tier: optional "auto" or "default" or "flex" or 3 more or null`
- 指定用于处理请求的处理类型。
+ 指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则请求将使用 Project 设置中配置的服务层级进行处理。除非另行配置,否则该 Project 将使用 'default'。
+ - 如果设置为 'auto',则请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
- 如果设置为 'default',则请求将使用所选模型的标准定价和性能进行处理。
- - 如果设置为 '[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为'[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。
+ - 若要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中传入 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你在请求中是否指定 `service_tier=fast` 或 `priority` 。
- 未设置时,默认行为为 'auto'。
- 当设置了 `service_tier` 参数时,响应主体将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。该响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应主体将根据实际用于处理该请求的处理模式返回 `service_tier` 值。该响应值可能与参数中设置的值不同。
- `"auto"`
@@ -5355,13 +5335,13 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `system_fingerprint: optional string`
- 此指纹表示模型运行所使用的后端配置。
+ 该指纹表示模型运行所使用到的服务端配置。
- 可与 `seed` 请求参数结合使用,以了解何时进行了可能影响确定性的后端变更。
+ 可与以下 `seed` 请求参数配合使用,以了解何时进行了可能影响确定性的后端更改。
- `usage: optional CompletionUsage`
- 补全请求的使用情况统计信息。
+ 补全请求的使用统计信息。
- `completion_tokens: number`
@@ -5369,11 +5349,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `prompt_tokens: number`
- 提示中的 token 数。
+ 提示词中的 token 数。
- `total_tokens: number`
- 请求中使用的总 token 数(提示 + 补全)。
+ 请求中使用的总 token 数(提示词 + 补全)。
- `completion_tokens_details: optional object { accepted_prediction_tokens, audio_tokens, reasoning_tokens, 2 more }`
@@ -5386,67 +5366,63 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `audio_tokens: optional number`
- 模型生成的音频输入 token。
+ 模型生成的音频输入 token 数。
- `reasoning_tokens: optional number`
- 模型为推理生成的 token。
+ 模型生成的用于推理的 token 数。
- `rejected_prediction_tokens: optional number`
使用 Predicted Outputs 时,
- 未在补全中出现的预测 token。但是,与
- 推理 token 一样,这些 token 仍会计入
- 用于计费、输出和上下文窗口限制的
- 总补全 token 数中。
+ 未出现在补全中的预测 token。但与
+ 推理 token 类似,这些 token 仍会计入用于计费、
+ 输出以及上下文窗口限制的总补全 token 数中。
+ 限制。
- `text_tokens: optional number`
- 模型生成的文本输出 token。
-
- - `compute_units: optional number or null`
-
- 请求的计算单元。目前可用时为 null。
+ 模型生成的文本输出 token 数。
- `prompt_tokens_details: optional object { audio_tokens, cache_write_tokens, cached_tokens, 2 more }`
- 提示词中所使用 token 的明细。
+ 提示词中使用的 token 明细。
- `audio_tokens: optional number`
- 提示词中存在的音频输入 token。
+ 提示中存在的音频输入 token。
- `cache_write_tokens: optional number`
- 写入缓存的提示词 token 未调整数量。
+ 写入缓存的未调整提示 token 数量。
- `cached_tokens: optional number`
- 提示词中存在的已缓存 token。
+ 提示中存在的已缓存 token。
- `image_tokens: optional number`
- 提示词中存在的图像输入 token。
+ 提示中存在的图像输入 token。
- `text_tokens: optional number`
- 提示词中存在的文本输入 token。
+ 提示中存在的文本输入 token。
### Chat Completion Allowed Tool Choice
- `ChatCompletionAllowedToolChoice object { allowed_tools, type }`
- 将模型可使用的工具限制为预定义的集合。
+ 将模型可用的工具限制为预定义的集合。
- `allowed_tools: ChatCompletionAllowedTools`
- 将模型可使用的工具限制为预定义的集合。
+ 将模型可用的工具限制为预定义的集合。
- `mode: "auto" or "required"`
- 将模型可使用的工具限制为预定义的集合。
+ 将模型可用的工具限制为预定义的集合。
- `auto` 允许模型从允许的工具中选择并生成
+ `auto` 允许模型从允许的工具中选取并生成
消息。
`required` 要求模型调用一个或多个允许的工具。
@@ -5457,9 +5433,9 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `tools: array of map[unknown]`
- 模型可调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
- 对于 Chat Completions API,工具定义列表可能如下:
+ 对于 Chat Completions API,工具定义列表可能如下所示:
```json
[
@@ -5482,13 +5458,13 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `role: "assistant"`
- 消息作者的角色,本例中为 `assistant`.
+ 消息作者的角色,在本例中为 `assistant`.
- `"assistant"`
- `audio: optional object { id } or null`
- 模型先前音频响应的相关数据。
+ 关于模型先前音频响应的数据。
[了解更多](/docs/guides/audio).
- `id: string`
@@ -5497,7 +5473,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `content: optional string or array of ChatCompletionContentPartText or ChatCompletionContentPartRefusal or null`
- 助手消息的内容。除非指定了 `tool_calls` 或 `function_call` ,否则此字段为必填。
+ 助手消息的内容。除非指定了 `tool_calls` 或 `function_call` ,否则此项为必填。
- `TextContent = string`
@@ -5505,7 +5481,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ArrayOfContentParts = array of ChatCompletionContentPartText or ChatCompletionContentPartRefusal`
- 具有已定义类型的内容片段数组。可以是以下类型的一个或多个 `text`,或以下类型的恰好一个 `refusal`.
+ 由已定义类型组成的内容部分数组。可以是一或多个以下类型 `text`,或恰好一个以下类型 `refusal`.
- `ChatCompletionContentPartText object { text, type, prompt_cache_breakpoint }`
@@ -5517,17 +5493,17 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `"text"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -5535,33 +5511,33 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `refusal: string`
- 由模型生成的拒绝消息。
+ 模型生成的拒绝消息。
- `type: "refusal"`
- 内容部分的类型。
+ content part 的类型。
- `"refusal"`
- `function_call: optional object { arguments, name } or null`
- 已弃用,由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
+ 已弃用,已由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `name: optional string`
- 参与者的可选名称。为模型提供信息,以便区分同一角色的不同参与者。
+ 参与者可选的名称。为模型提供信息,以区分同一角色的不同参与者。
- `refusal: optional string or null`
- 助手生成的拒绝消息。
+ 助手返回的拒绝消息。
- `tool_calls: optional array of ChatCompletionMessageToolCall`
@@ -5581,15 +5557,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `type: "function"`
- 工具的类型。目前,仅 `function` 类型。
+ 工具的类型。目前,仅支持 `function` 内容。
- `"function"`
@@ -5623,23 +5599,23 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ChatCompletionAudio object { id, data, expires_at, transcript }`
- 如果请求了音频输出模态,该对象包含来自模型的音频
- 响应的相关数据。 [了解更多](/docs/guides/audio).
+ 如果请求了音频输出模态,则此对象包含有关模型音频响应的数据
+ 关于模型的音频响应。 [了解更多](/docs/guides/audio).
- `id: string`
- 此音频响应的唯一标识符。
+ 该音频响应的唯一标识符。
- `data: string`
- 模型生成的 Base64 编码音频字节,格式为
+ 由模型生成的 Base64 编码音频字节,格式为
请求中指定的格式。
- `expires_at: number`
- 此音频响应在服务端上无法再被用于多轮
- 访问的 Unix 时间戳(秒)。
- 对话。
+ 该音频响应在服务端不再可用于多轮对话的 Unix 时间戳(秒)
+ 对话的 Unix 时间戳(以秒为单位)。
+ conversations.
- `transcript: string`
@@ -5649,12 +5625,12 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ChatCompletionAudioParam object { format, voice }`
- 音频输出的参数。当使用以下方式请求音频输出时为必填项
+ 音频输出的参数。在使用以下参数请求音频输出时必填:
`modalities: ["audio"]`. [了解更多](/docs/guides/audio).
- `format: "wav" or "aac" or "mp3" or 3 more`
- 指定输出音频格式。必须是以下之一 `wav`, `mp3`, `flac`,
+ 指定输出音频格式。必须是以下之一: `wav`, `mp3`, `flac`,
`opus`,或 `pcm16`.
- `"wav"`
@@ -5671,10 +5647,10 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `voice: string or "alloy" or "ash" or "ballad" or 7 more or object { id }`
- 模型用于回复的声音。支持的内置声音包括
+ 模型用于响应的语音。支持的内置语音有
`alloy`, `ash`, `ballad`, `coral`, `echo`, `fable`, `nova`, `onyx`,
- `sage`, `shimmer`, `marin`,以及 `cedar`。你也可以提供带有
- 的自定义声音对象,使用 `id`,例如 `{ "id": "voice_1234" }`.
+ `sage`, `shimmer`, `marin`、和 `cedar`。你也可以提供带有
+ 的自定义语音对象, `id`,例如 `{ "id": "voice_1234" }`.
- `string`
@@ -5702,32 +5678,32 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ID object { id }`
- 自定义声音引用。
+ 自定义语音引用。
- `id: string`
- 自定义声音 ID,例如 `voice_1234`.
+ 自定义语音 ID,例如 `voice_1234`.
### Chat Completion Chunk
- `ChatCompletionChunk object { id, choices, created, 7 more }`
- 表示模型基于提供的输入返回的聊天完成响应的流式分块。
- 由模型根据提供的输入返回。
+ 表示模型根据所提供的输入返回的聊天补全响应的流式分块
+ 。
[了解更多](/docs/guides/streaming-responses).
- `id: string`
- 聊天完成的唯一标识符。每个分块具有相同的 ID。
+ 聊天补全的唯一标识符。每个分块具有相同的 ID。
- `choices: array of object { delta, finish_reason, index, logprobs }`
- 聊天完成选项的列表。如果大于 1,可以包含多个元素。如果设置了 `n` ,则可以包含多个元素。对于
- 最后一个分块也可以为空,当你设置了 `stream_options: {"include_usage": true}`.
+ 聊天补全选项的列表。如果 `n` 大于 1,则可以包含多个元素。如果在
+ 最后一个分块中你设置了 `stream_options: {"include_usage": true}`.
- `delta: object { content, function_call, refusal, 2 more }`
- 由流式模型响应生成的聊天完成增量。
+ 由流式模型响应生成的聊天补全增量。
- `content: optional string or null`
@@ -5735,19 +5711,19 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `function_call: optional object { arguments, name }`
- 已弃用,由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
+ 已弃用,已由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
- `arguments: optional string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: optional string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `refusal: optional string or null`
- 由模型生成的拒绝消息。
+ 模型生成的拒绝消息。
- `role: optional "developer" or "system" or "user" or 2 more`
@@ -5775,24 +5751,24 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `arguments: optional string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: optional string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `type: optional "function"`
- 工具的类型。目前,仅 `function` 类型。
+ 工具的类型。目前,仅支持 `function` 内容。
- `"function"`
- `finish_reason: "stop" or "length" or "tool_calls" or 2 more or null`
- 模型停止生成 token 的原因。如果模型遇到自然停止点或提供的停止序列,则为 `stop` ;如果达到请求中指定的最大 token 数,则为,
- `length` ;如果因我们的内容过滤器标记而被省略内容,则为,
- `content_filter` ;如果模型调用了工具,则为,
- `tool_calls` ;如果模型调用了函数,则为 `function_call` (已弃用)。
+ 模型停止生成 token 的原因。该字段为 `stop` ,表示模型到达了自然停止点或遇到了提供的停止序列,
+ `length` ,表示已达到请求中指定的最大 token 数,
+ `content_filter` ,表示内容因我们的内容过滤器的标记而被省略,
+ `tool_calls` ,表示模型调用了工具,或 `function_call` (已弃用),表示模型调用了函数。
- `"stop"`
@@ -5806,7 +5782,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `index: number`
- 选项在选项列表中的索引。
+ 该选项在选项列表中的索引。
- `logprobs: optional object { content, refusal } or null`
@@ -5822,15 +5798,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `top_logprobs: array of object { token, bytes, logprob }`
- 在该 token 位置上,最可能出现的 token 及其对数概率的列表。条目数量可能少于所请求的 `top_logprobs`.
+ 在该 token 位置处可能性最高的 token 列表及其对数概率。条目数量可能少于请求的 `top_logprobs`.
- `token: string`
@@ -5838,15 +5814,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `refusal: array of ChatCompletionTokenLogprob or null`
- 包含对数概率信息的拒绝消息 token 列表。
+ 包含对数概率信息的消息拒绝 token 列表。
- `token: string`
@@ -5854,23 +5830,23 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `top_logprobs: array of object { token, bytes, logprob }`
- 在该 token 位置上,最可能出现的 token 及其对数概率的列表。条目数量可能少于所请求的 `top_logprobs`.
+ 在该 token 位置处可能性最高的 token 列表及其对数概率。条目数量可能少于请求的 `top_logprobs`.
- `created: number`
- 聊天完成创建时的 Unix 时间戳(以秒为单位)。每个分块具有相同的时间戳。
+ 聊天补全创建时的 Unix 时间戳(以秒为单位)。每个分块具有相同的时间戳。
- `model: string`
- 用于生成完成的模型。
+ 用于生成补全的模型。
- `object: "chat.completion.chunk"`
@@ -5880,12 +5856,12 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `moderation: optional object { input, output } or null`
- 请求输入和生成输出的审核结果。当请求经过审核的完成时,
- 该字段会出现在审核分块上。
+ 针对请求输入和生成输出的审核结果。当请求经过审核的补全时,
+ 该字段会出现在审核分块中。
- `input: object { model, results, type } or object { code, message, type }`
- 对请求输入的审核。
+ 请求输入的审核结果。
- `ModerationResults object { model, results, type }`
@@ -5901,11 +5877,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `categories: map[boolean]`
- 一个从审核类别到布尔值的字典,若输入在该类别下被标记则为 True。
+ 从审核类别到布尔值的字典,如果输入在该类别下被标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所反映的输入模态。
+ 每个类别的分数反映了哪些输入模态。
- `"text"`
@@ -5913,11 +5889,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `category_scores: map[number]`
- 一个从审核类别到分数的字典。
+ 从审核类别到分数的字典。
- `flagged: boolean`
- 一个布尔值,指示内容是否被任何类别标记。
+ 指示内容是否被任何类别标记的布尔值。
- `model: string`
@@ -5925,7 +5901,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "moderation_result"`
- 对象类型,在成功的审核结果中始终为 `moderation_result` 。
+ 对象类型,过去始终为 `moderation_result` (针对成功的审核结果)。
- `"moderation_result"`
@@ -5955,7 +5931,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `output: object { model, results, type } or object { code, message, type }`
- 生成输出的审核。
+ 对生成内容的审核。
- `ModerationResults object { model, results, type }`
@@ -5971,11 +5947,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `categories: map[boolean]`
- 一个从审核类别到布尔值的字典,若输入在该类别下被标记则为 True。
+ 从审核类别到布尔值的字典,如果输入在该类别下被标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所反映的输入模态。
+ 每个类别的分数反映了哪些输入模态。
- `"text"`
@@ -5983,11 +5959,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `category_scores: map[number]`
- 一个从审核类别到分数的字典。
+ 从审核类别到分数的字典。
- `flagged: boolean`
- 一个布尔值,指示内容是否被任何类别标记。
+ 指示内容是否被任何类别标记的布尔值。
- `model: string`
@@ -5995,7 +5971,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "moderation_result"`
- 对象类型,在成功的审核结果中始终为 `moderation_result` 。
+ 对象类型,过去始终为 `moderation_result` (针对成功的审核结果)。
- `"moderation_result"`
@@ -6025,21 +6001,21 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `obfuscation: optional string`
- 添加的混淆字符串,用于将流式分块的大小标准化,
- 作为对某些侧信道攻击的缓解措施。该字段默认包含,
- 当 `stream_options.include_obfuscation` 为 `false`.
+ 添加的混淆字符串,用于将流式分块的大小标准化,作为
+ 对某些侧信道攻击的缓解措施。该字段默认包含,并在
+ 时被省略 `stream_options.include_obfuscation` 为 `false`.
- `service_tier: optional "auto" or "default" or "flex" or 3 more or null`
- 指定用于处理请求的处理类型。
+ 指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则请求将使用 Project 设置中配置的服务层级进行处理。除非另行配置,否则该 Project 将使用 'default'。
+ - 如果设置为 'auto',则请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
- 如果设置为 'default',则请求将使用所选模型的标准定价和性能进行处理。
- - 如果设置为 '[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为'[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。
+ - 若要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中传入 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你在请求中是否指定 `service_tier=fast` 或 `priority` 。
- 未设置时,默认行为为 'auto'。
- 当设置了 `service_tier` 参数时,响应主体将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。该响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应主体将根据实际用于处理该请求的处理模式返回 `service_tier` 值。该响应值可能与参数中设置的值不同。
- `"auto"`
@@ -6055,19 +6031,19 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `system_fingerprint: optional string`
- 此指纹表示模型运行所使用的后端配置。
- 可与 `seed` 请求参数结合使用,以了解何时进行了可能影响确定性的后端变更。
+ 此指纹表示模型运行所使用后端配置。
+ 可与以下 `seed` 请求参数配合使用,以了解何时进行了可能影响确定性的后端更改。
- `usage: optional CompletionUsage or null`
- 一个可选字段,仅当你在请求中设置了
- `stream_options: {"include_usage": true}` 时才会出现。当出现时,它
- 包含一个 null 值 **,最后一个分块除外** 其中包含整个请求的
- token 使用统计信息。
+ 仅当你在请求中设置
+ `stream_options: {"include_usage": true}` 时才会出现的可选字段。当存在时,它
+ 包含一个 null 值 **,但最后一个分块除外** 其中包含
+ 整个请求的 token 使用统计信息。
**注意:** 如果流被中断或取消,你可能不会
- 收到包含整个请求总 token 使用量的最终 usage 分块,
- 即请求的 usage 信息。
+ 接收到包含本次请求总 token 用量的
+ 最后一个 usage 数据块。
- `completion_tokens: number`
@@ -6075,11 +6051,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `prompt_tokens: number`
- 提示中的 token 数。
+ 提示词中的 token 数。
- `total_tokens: number`
- 请求中使用的总 token 数(提示 + 补全)。
+ 请求中使用的总 token 数(提示词 + 补全)。
- `completion_tokens_details: optional object { accepted_prediction_tokens, audio_tokens, reasoning_tokens, 2 more }`
@@ -6092,53 +6068,49 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `audio_tokens: optional number`
- 模型生成的音频输入 token。
+ 模型生成的音频输入 token 数。
- `reasoning_tokens: optional number`
- 模型为推理生成的 token。
+ 模型生成的用于推理的 token 数。
- `rejected_prediction_tokens: optional number`
使用 Predicted Outputs 时,
- 未在补全中出现的预测 token。但是,与
- 推理 token 一样,这些 token 仍会计入
- 用于计费、输出和上下文窗口限制的
- 总补全 token 数中。
+ 未出现在补全中的预测 token。但与
+ 推理 token 类似,这些 token 仍会计入用于计费、
+ 输出以及上下文窗口限制的总补全 token 数中。
+ 限制。
- `text_tokens: optional number`
- 模型生成的文本输出 token。
-
- - `compute_units: optional number or null`
-
- 请求的计算单元。目前可用时为 null。
+ 模型生成的文本输出 token 数。
- `prompt_tokens_details: optional object { audio_tokens, cache_write_tokens, cached_tokens, 2 more }`
- 提示词中所使用 token 的明细。
+ 提示词中使用的 token 明细。
- `audio_tokens: optional number`
- 提示词中存在的音频输入 token。
+ 提示中存在的音频输入 token。
- `cache_write_tokens: optional number`
- 写入缓存的提示词 token 未调整数量。
+ 写入缓存的未调整提示 token 数量。
- `cached_tokens: optional number`
- 提示词中存在的已缓存 token。
+ 提示中存在的已缓存 token。
- `image_tokens: optional number`
- 提示词中存在的图像输入 token。
+ 提示中存在的图像输入 token。
- `text_tokens: optional number`
- 提示词中存在的文本输入 token。
+ 提示中存在的文本输入 token。
-### Chat Completion 内容分块
+### Chat Completion Content Part
- `ChatCompletionContentPart = ChatCompletionContentPartText or ChatCompletionContentPartImage or ChatCompletionContentPartInputAudio or object { file, type, prompt_cache_breakpoint }`
@@ -6154,17 +6126,17 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `"text"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -6176,11 +6148,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `url: string`
- 图像的 URL 或 base64 编码的图像数据。
+ 图像的 URL 或 base64 编码后的图像数据。
- `detail: optional "auto" or "low" or "high"`
- 指定图像的细节级别。更多信息请参阅 [视觉指南](/docs/guides/vision#low-or-high-fidelity-image-understanding).
+ 指定图像的细节级别。详见 [视觉指南](/docs/guides/vision#low-or-high-fidelity-image-understanding).
- `"auto"`
@@ -6190,17 +6162,17 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "image_url"`
- 内容部分的类型。
+ content part 的类型。
- `"image_url"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -6230,11 +6202,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -6246,8 +6218,8 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `file_data: optional string`
- base64 编码的文件数据,在将文件传递给模型时使用
- 字符串。
+ Base64 编码的文件数据,在将文件传递给模型时使用
+ 字符串形式。
- `file_id: optional string`
@@ -6255,8 +6227,8 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `filename: optional string`
- 文件的名称,在将文件以
- 字符串形式传递给模型时使用。
+ 文件的名称,在将文件作为以下形式传递给模型时使用
+ 字符串。
- `type: "file"`
@@ -6266,15 +6238,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
-### Chat Completion 内容分块图像
+### Chat Completion Content Part Image
- `ChatCompletionContentPartImage object { image_url, type, prompt_cache_breakpoint }`
@@ -6284,11 +6256,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `url: string`
- 图像的 URL 或 base64 编码的图像数据。
+ 图像的 URL 或 base64 编码后的图像数据。
- `detail: optional "auto" or "low" or "high"`
- 指定图像的细节级别。更多信息请参阅 [视觉指南](/docs/guides/vision#low-or-high-fidelity-image-understanding).
+ 指定图像的细节级别。详见 [视觉指南](/docs/guides/vision#low-or-high-fidelity-image-understanding).
- `"auto"`
@@ -6298,21 +6270,21 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "image_url"`
- 内容部分的类型。
+ content part 的类型。
- `"image_url"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
-### Chat Completion 内容分块输入音频
+### Chat Completion Content Part Input Audio
- `ChatCompletionContentPartInputAudio object { input_audio, type, prompt_cache_breakpoint }`
@@ -6340,29 +6312,29 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
-### Chat Completion 内容分块拒绝
+### Chat Completion Content Part Refusal
- `ChatCompletionContentPartRefusal object { refusal, type }`
- `refusal: string`
- 由模型生成的拒绝消息。
+ 模型生成的拒绝消息。
- `type: "refusal"`
- 内容部分的类型。
+ content part 的类型。
- `"refusal"`
-### Chat Completion 内容分块文本
+### Chat Completion Content Part Text
- `ChatCompletionContentPartText object { text, type, prompt_cache_breakpoint }`
@@ -6374,21 +6346,21 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `"text"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
-### Chat Completion 自定义工具
+### Chat Completion Custom Tool
- `ChatCompletionCustomTool object { custom, type }`
@@ -6408,15 +6380,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `format: optional object { type } or object { grammar, type }`
- 自定义工具的输入格式。默认为无约束文本。
+ 自定义工具的输入格式。默认情况下为不受约束的文本。
- `Text object { type }`
- 无约束的自由格式文本。
+ 不受约束的自由格式文本。
- `type: "text"`
- 无约束文本格式。始终为 `text`.
+ 不受约束的文本格式。始终为 `text`.
- `"text"`
@@ -6434,7 +6406,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `syntax: "lark" or "regex"`
- 语法定义的语法格式,取值之一为 `lark` 或 `regex`.
+ 语法定义的语法。可选值为 `lark` 或 `regex`.
- `"lark"`
@@ -6452,7 +6424,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `"custom"`
-### Chat Completion 已删除
+### Chat Completion Deleted
- `ChatCompletionDeleted object { id, deleted, object }`
@@ -6466,29 +6438,29 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `object: "chat.completion.deleted"`
- 被删除对象的类型。
+ 正在删除的对象的类型。
- `"chat.completion.deleted"`
-### Chat Completion 开发者消息参数
+### Chat Completion Developer Message Param
- `ChatCompletionDeveloperMessageParam object { content, role, name }`
- 开发者提供的指令,无论用户发送什么
- 消息,模型都应遵循。对于 o1 及更新的模型, `developer` messages
- 将取代先前的 `system` messages。
+ 开发者提供的指令,模型应当遵循这些指令,而无论用户发送了什么样的
+ 消息。在 o1 及更新模型上,developer, `developer` 消息取代了原先的
+ 消息中的 `system` messages。
- `content: string or array of ChatCompletionContentPartText`
- 开发者消息的内容。
+ developer 消息的内容。
- `TextContent = string`
- 开发者消息的内容。
+ developer 消息的内容。
- `ArrayOfContentParts = array of ChatCompletionContentPartText`
- 具有已定义类型的 content parts 数组。对于开发者消息,仅支持 type `text` 类型。
+ 具有指定类型的 content part 数组。对于 developer 消息,仅支持 type 为 input_text 的 `text` 内容。
- `text: string`
@@ -6496,31 +6468,31 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `"text"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "developer"`
- 消息作者的角色,本例中为 `developer`.
+ 消息作者的角色,在本例中为 `developer`.
- `"developer"`
- `name: optional string`
- 参与者的可选名称。为模型提供信息,以便区分同一角色的不同参与者。
+ 参与者可选的名称。为模型提供信息,以区分同一角色的不同参与者。
-### Chat Completion 函数调用选项
+### Chat Completion Function Call Option
- `ChatCompletionFunctionCallOption object { name }`
@@ -6528,9 +6500,9 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
-### Chat Completion 函数消息参数
+### Chat Completion Function Message Param
- `ChatCompletionFunctionMessageParam object { content, name, role }`
@@ -6540,15 +6512,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `role: "function"`
- 消息作者的角色,本例中为 `function`.
+ 消息作者的角色,在本例中为 `function`.
- `"function"`
-### Chat Completion 函数工具
+### Chat Completion Function Tool
- `ChatCompletionFunctionTool object { function, type }`
@@ -6558,33 +6530,33 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `name: string`
- 要调用的函数名称。必须为 a-z、A-Z、0-9,或包含下划线和短横线,最大长度为 64。
+ 要调用的函数名称。只能包含 a-z、A-Z、0-9,或下划线和短横线,最大长度为 64。
- `description: optional string`
- 对函数作用的描述,模型据此选择何时以及如何调用该函数。
+ 对函数功能的描述,供模型用于选择何时以及如何调用该函数。
- `parameters: optional FunctionParameters`
- 函数接受的参数,以 JSON Schema 对象描述。参阅 [指南](/docs/guides/function-calling) 中的示例,以及 [JSON Schema 参考](https://json-schema.org/understanding-json-schema/) 获取有关该格式的文档。
+ 函数接受的参数,使用 JSON Schema 对象进行描述。详见 [指南](/docs/guides/function-calling) 中的示例,以及 [JSON Schema 参考](https://json-schema.org/understanding-json-schema/) 有关此格式的文档。
- 省略 `parameters` 用于定义一个参数列表为空的函数。
+ 省略 `parameters` 定义一个参数列表为空的函数。
- `strict: optional boolean or null`
- 在生成函数调用时是否启用严格模式遵循。如果设置为 true,模型将遵循 `parameters` 字段时。如需了解更多信息,请参阅 `strict` 为 `true`。中定义的确切模式。详细了解结构化输出,请参阅 [function calling guide](/docs/guides/function-calling).
+ 在生成函数调用时是否启用严格的 schema 遵循。如果设置为 true,模型将严格按照 `parameters` 所定义的精确模式。当 strict `strict` 为 `true`。中定义的 schema 执行。详细了解 Structured Outputs,请参阅 [function calling guide](/docs/guides/function-calling).
- `type: "function"`
- 工具的类型。目前,仅 `function` 类型。
+ 工具的类型。目前,仅支持 `function` 内容。
- `"function"`
-### Chat Completion 消息
+### Chat Completion Message
- `ChatCompletionMessage object { content, refusal, role, 4 more }`
- 由模型生成的聊天完成消息。
+ 由模型生成的聊天补全消息。
- `content: string or null`
@@ -6592,7 +6564,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `refusal: string or null`
- 由模型生成的拒绝消息。
+ 模型生成的拒绝消息。
- `role: "assistant"`
@@ -6602,8 +6574,8 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `annotations: optional array of object { type, url_citation }`
- 消息的注释(如果适用),例如在使用
- [网页搜索工具](/docs/guides/tools-web-search?api-mode=chat).
+ 消息的注释(如适用),例如在使用
+ [网页搜索 工具](/docs/guides/tools-web-search?api-mode=chat).
- `type: "url_citation"`
@@ -6621,7 +6593,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `start_index: number`
- 消息中 URL 引用的第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
@@ -6633,23 +6605,23 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `audio: optional ChatCompletionAudio or null`
- 如果请求了音频输出模态,该对象包含来自模型的音频
- 响应的相关数据。 [了解更多](/docs/guides/audio).
+ 如果请求了音频输出模态,则此对象包含有关模型音频响应的数据
+ 关于模型的音频响应。 [了解更多](/docs/guides/audio).
- `id: string`
- 此音频响应的唯一标识符。
+ 该音频响应的唯一标识符。
- `data: string`
- 模型生成的 Base64 编码音频字节,格式为
+ 由模型生成的 Base64 编码音频字节,格式为
请求中指定的格式。
- `expires_at: number`
- 此音频响应在服务端上无法再被用于多轮
- 访问的 Unix 时间戳(秒)。
- 对话。
+ 该音频响应在服务端不再可用于多轮对话的 Unix 时间戳(秒)
+ 对话的 Unix 时间戳(以秒为单位)。
+ conversations.
- `transcript: string`
@@ -6657,15 +6629,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `function_call: optional object { arguments, name }`
- 已弃用,由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
+ 已弃用,已由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `tool_calls: optional array of ChatCompletionMessageToolCall`
@@ -6685,15 +6657,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `type: "function"`
- 工具的类型。目前,仅 `function` 类型。
+ 工具的类型。目前,仅支持 `function` 内容。
- `"function"`
@@ -6723,7 +6695,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `"custom"`
-### Chat Completion 消息自定义工具调用
+### Chat Completion Message Custom Tool Call
- `ChatCompletionMessageCustomToolCall object { id, custom, type }`
@@ -6751,7 +6723,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `"custom"`
-### Chat Completion 消息函数工具调用
+### Chat Completion Message Function Tool Call
- `ChatCompletionMessageFunctionToolCall object { id, function, type }`
@@ -6767,43 +6739,43 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `type: "function"`
- 工具的类型。目前,仅 `function` 类型。
+ 工具的类型。目前,仅支持 `function` 内容。
- `"function"`
-### Chat Completion 消息参数
+### Chat Completion Message Param
- `ChatCompletionMessageParam = ChatCompletionDeveloperMessageParam or ChatCompletionSystemMessageParam or ChatCompletionUserMessageParam or 3 more`
- 开发者提供的指令,无论用户发送什么
- 消息,模型都应遵循。对于 o1 及更新的模型, `developer` messages
- 将取代先前的 `system` messages。
+ 开发者提供的指令,模型应当遵循这些指令,而无论用户发送了什么样的
+ 消息。在 o1 及更新模型上,developer, `developer` 消息取代了原先的
+ 消息中的 `system` messages。
- `ChatCompletionDeveloperMessageParam object { content, role, name }`
- 开发者提供的指令,无论用户发送什么
- 消息,模型都应遵循。对于 o1 及更新的模型, `developer` messages
- 将取代先前的 `system` messages。
+ 开发者提供的指令,模型应当遵循这些指令,而无论用户发送了什么样的
+ 消息。在 o1 及更新模型上,developer, `developer` 消息取代了原先的
+ 消息中的 `system` messages。
- `content: string or array of ChatCompletionContentPartText`
- 开发者消息的内容。
+ developer 消息的内容。
- `TextContent = string`
- 开发者消息的内容。
+ developer 消息的内容。
- `ArrayOfContentParts = array of ChatCompletionContentPartText`
- 具有已定义类型的 content parts 数组。对于开发者消息,仅支持 type `text` 类型。
+ 具有指定类型的 content part 数组。对于 developer 消息,仅支持 type 为 input_text 的 `text` 内容。
- `text: string`
@@ -6811,35 +6783,35 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `"text"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "developer"`
- 消息作者的角色,本例中为 `developer`.
+ 消息作者的角色,在本例中为 `developer`.
- `"developer"`
- `name: optional string`
- 参与者的可选名称。为模型提供信息,以便区分同一角色的不同参与者。
+ 参与者可选的名称。为模型提供信息,以区分同一角色的不同参与者。
- `ChatCompletionSystemMessageParam object { content, role, name }`
- 开发者提供的指令,无论用户发送什么
- 用户发送的消息。对于 o1 及更高版本的模型,请改用 `developer` messages
- 来实现此目的。
+ 开发者提供的指令,模型应当遵循这些指令,而无论用户发送了什么样的
+ 用户发送的消息。对于 o1 及更新模型,请使用 `developer` 消息取代了原先的
+ 来替代此用途。
- `content: string or array of ChatCompletionContentPartText`
@@ -6851,7 +6823,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ArrayOfContentParts = array of ChatCompletionContentPartText`
- 具有已定义类型的内容部分数组。对于系统消息,仅支持类型 `text` 类型。
+ 包含已定义类型的 content 部件数组。对于系统消息,仅支持 type `text` 内容。
- `text: string`
@@ -6859,25 +6831,25 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `role: "system"`
- 消息作者的角色,本例中为 `system`.
+ 消息作者的角色,在本例中为 `system`.
- `"system"`
- `name: optional string`
- 参与者的可选名称。为模型提供信息,以便区分同一角色的不同参与者。
+ 参与者可选的名称。为模型提供信息,以区分同一角色的不同参与者。
- `ChatCompletionUserMessageParam object { content, role, name }`
- 由最终用户发送的消息,包含提示或额外的上下文
+ 由终端用户发送的消息,包含提示词或其他上下文
信息。
- `content: string or array of ChatCompletionContentPart`
@@ -6890,7 +6862,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ArrayOfContentParts = array of ChatCompletionContentPart`
- 具有已定义类型的内容部分数组。支持的具体选项因用于生成响应的 [model](/docs/models) 而异。可以包含文本、图像或音频输入。
+ 包含已定义类型的 content 部件数组。可选项取决于用于生成响应的 [model](/docs/models) 。可以包含文本、图像或音频输入。
- `ChatCompletionContentPartText object { text, type, prompt_cache_breakpoint }`
@@ -6902,11 +6874,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `ChatCompletionContentPartImage object { image_url, type, prompt_cache_breakpoint }`
@@ -6916,11 +6888,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `url: string`
- 图像的 URL 或 base64 编码的图像数据。
+ 图像的 URL 或 base64 编码后的图像数据。
- `detail: optional "auto" or "low" or "high"`
- 指定图像的细节级别。更多信息请参阅 [视觉指南](/docs/guides/vision#low-or-high-fidelity-image-understanding).
+ 指定图像的细节级别。详见 [视觉指南](/docs/guides/vision#low-or-high-fidelity-image-understanding).
- `"auto"`
@@ -6930,17 +6902,17 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "image_url"`
- 内容部分的类型。
+ content part 的类型。
- `"image_url"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -6970,11 +6942,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -6986,8 +6958,8 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `file_data: optional string`
- base64 编码的文件数据,在将文件传递给模型时使用
- 字符串。
+ Base64 编码的文件数据,在将文件传递给模型时使用
+ 字符串形式。
- `file_id: optional string`
@@ -6995,8 +6967,8 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `filename: optional string`
- 文件的名称,在将文件以
- 字符串形式传递给模型时使用。
+ 文件的名称,在将文件作为以下形式传递给模型时使用
+ 字符串。
- `type: "file"`
@@ -7006,23 +6978,23 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user"`
- 消息作者的角色,本例中为 `user`.
+ 消息作者的角色,在本例中为 `user`.
- `"user"`
- `name: optional string`
- 参与者的可选名称。为模型提供信息,以便区分同一角色的不同参与者。
+ 参与者可选的名称。为模型提供信息,以区分同一角色的不同参与者。
- `ChatCompletionAssistantMessageParam object { role, audio, content, 4 more }`
@@ -7030,13 +7002,13 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `role: "assistant"`
- 消息作者的角色,本例中为 `assistant`.
+ 消息作者的角色,在本例中为 `assistant`.
- `"assistant"`
- `audio: optional object { id } or null`
- 模型先前音频响应的相关数据。
+ 关于模型先前音频响应的数据。
[了解更多](/docs/guides/audio).
- `id: string`
@@ -7045,7 +7017,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `content: optional string or array of ChatCompletionContentPartText or ChatCompletionContentPartRefusal or null`
- 助手消息的内容。除非指定了 `tool_calls` 或 `function_call` ,否则此字段为必填。
+ 助手消息的内容。除非指定了 `tool_calls` 或 `function_call` ,否则此项为必填。
- `TextContent = string`
@@ -7053,7 +7025,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ArrayOfContentParts = array of ChatCompletionContentPartText or ChatCompletionContentPartRefusal`
- 具有已定义类型的内容片段数组。可以是以下类型的一个或多个 `text`,或以下类型的恰好一个 `refusal`.
+ 由已定义类型组成的内容部分数组。可以是一或多个以下类型 `text`,或恰好一个以下类型 `refusal`.
- `ChatCompletionContentPartText object { text, type, prompt_cache_breakpoint }`
@@ -7063,33 +7035,33 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `refusal: string`
- 由模型生成的拒绝消息。
+ 模型生成的拒绝消息。
- `type: "refusal"`
- 内容部分的类型。
+ content part 的类型。
- `"refusal"`
- `function_call: optional object { arguments, name } or null`
- 已弃用,由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
+ 已弃用,已由 `tool_calls`。替代。应调用的函数的名称和参数,由模型生成。
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `name: optional string`
- 参与者的可选名称。为模型提供信息,以便区分同一角色的不同参与者。
+ 参与者可选的名称。为模型提供信息,以区分同一角色的不同参与者。
- `refusal: optional string or null`
- 助手生成的拒绝消息。
+ 助手返回的拒绝消息。
- `tool_calls: optional array of ChatCompletionMessageToolCall`
@@ -7109,15 +7081,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `type: "function"`
- 工具的类型。目前,仅 `function` 类型。
+ 工具的类型。目前,仅支持 `function` 内容。
- `"function"`
@@ -7159,7 +7131,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ArrayOfContentParts = array of ChatCompletionContentPartText`
- 由已定义类型组成的内容分块数组。对于工具消息,仅支持类型 `text` 类型。
+ 具有已定义类型的内容片段数组。对于工具消息,仅类型 `text` 内容。
- `text: string`
@@ -7167,15 +7139,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `role: "tool"`
- 消息作者的角色,本例中为 `tool`.
+ 消息作者的角色,在本例中为 `tool`.
- `"tool"`
@@ -7191,15 +7163,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `role: "function"`
- 消息作者的角色,本例中为 `function`.
+ 消息作者的角色,在本例中为 `function`.
- `"function"`
-### Chat Completion 消息工具调用
+### Chat Completion Message Tool Call
- `ChatCompletionMessageToolCall = ChatCompletionMessageFunctionToolCall or ChatCompletionMessageCustomToolCall`
@@ -7219,15 +7191,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `arguments: string`
- 调用函数时使用的参数,以 JSON 格式由模型生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你的函数 schema 中未定义的参数。在调用函数之前,请在代码中校验这些参数。
+ 调用函数时使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构函数 schema 中未定义的参数。在调用函数之前,请先在代码中校验这些参数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `type: "function"`
- 工具的类型。目前,仅 `function` 类型。
+ 工具的类型。目前,仅支持 `function` 内容。
- `"function"`
@@ -7257,7 +7229,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `"custom"`
-### Chat Completion 模态
+### Chat Completion Modality
- `ChatCompletionModality = "text" or "audio"`
@@ -7265,17 +7237,17 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `"audio"`
-### Chat Completion 命名工具选择
+### Chat Completion Named Tool Choice
- `ChatCompletionNamedToolChoice object { function, type }`
- 指定模型应使用的工具。用于强制模型调用特定函数。
+ 指定模型应使用的工具。用于强制模型调用某个特定函数。
- `function: object { name }`
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `type: "function"`
@@ -7283,11 +7255,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `"function"`
-### Chat Completion 命名工具选择自定义
+### Chat Completion Named Tool Choice Custom
- `ChatCompletionNamedToolChoiceCustom object { custom, type }`
- 指定模型应使用的工具。用于强制模型调用特定自定义工具。
+ 指定模型应使用的工具。用于强制模型调用某个特定的自定义工具。
- `custom: object { name }`
@@ -7301,27 +7273,27 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `"custom"`
-### Chat Completion 预测内容
+### Chat Completion Prediction Content
- `ChatCompletionPredictionContent object { content, type }`
- 静态预测输出内容,例如正在重新生成的文本文件的内容。
- 正在重新生成。
+ 静态预测输出内容,例如正在被重新生成的文本文件内容。
+ being regenerated.
- `content: string or array of ChatCompletionContentPartText`
生成模型响应时应匹配的内容。
如果生成的 token 与该内容匹配,则可以更快地返回整个模型响应。
- 可以更快地返回。
+ can be returned much more quickly.
- `TextContent = string`
- 用于预测输出的内容。这通常是
- 你正在重新生成且仅有少量改动的文件文本。
+ 用于 Predicted Output 的内容。这通常是
+ 你正在重新生成且仅有少量改动的文件的文本。
- `ArrayOfContentParts = array of ChatCompletionContentPartText`
- 具有已定义类型的内容部分数组。支持的具体选项因用于生成响应的 [model](/docs/models) 正在用于生成响应。可以包含文本输入。
+ 包含已定义类型的 content 部件数组。可选项取决于用于生成响应的 [model](/docs/models) 正在用于生成响应的输入消息。可以包含文本输入。
- `text: string`
@@ -7329,28 +7301,28 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `"text"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `type: "content"`
- 你希望提供的预测内容的类型。该类型
+ 你要提供的预测内容的类型。该类型
目前始终为 `content`.
- `"content"`
-### Chat Completion Role
+### Chat Completion 角色
- `ChatCompletionRole = "developer" or "system" or "user" or 3 more`
@@ -7372,7 +7344,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ChatCompletionStoreMessage = ChatCompletionMessage`
- 由模型生成的聊天完成消息。
+ 由模型生成的聊天补全消息。
- `id: string`
@@ -7380,7 +7352,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `content_parts: optional array of ChatCompletionContentPartText or ChatCompletionContentPartImage or null`
- 如果提供了内容部分数组,则这是一个由 `text` 和 `image_url` 部分组成的数组。
+ 如果提供了 content parts 数组,则该字段为一个数组,元素为 `text` 和 `image_url` parts。
否则为 null。
- `ChatCompletionContentPartText object { text, type, prompt_cache_breakpoint }`
@@ -7393,17 +7365,17 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `"text"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -7415,11 +7387,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `url: string`
- 图像的 URL 或 base64 编码的图像数据。
+ 图像的 URL 或 base64 编码后的图像数据。
- `detail: optional "auto" or "low" or "high"`
- 指定图像的细节级别。更多信息请参阅 [视觉指南](/docs/guides/vision#low-or-high-fidelity-image-understanding).
+ 指定图像的细节级别。详见 [视觉指南](/docs/guides/vision#low-or-high-fidelity-image-understanding).
- `"auto"`
@@ -7429,17 +7401,17 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "image_url"`
- 内容部分的类型。
+ content part 的类型。
- `"image_url"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -7447,36 +7419,36 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ChatCompletionStreamOptions object { include_obfuscation, include_usage }`
- 流式响应的选项。仅在设置了 stream: true 时设置此参数。 `stream: true`.
+ 流式响应的选项。仅当你设置 `stream: true`.
- `include_obfuscation: optional boolean`
- 如果为 true,将启用流混淆。流混淆会向流式增量事件上的 obfuscation 字段添加
- 随机字符,以规范化负载大小,作为对某些侧信道攻击的缓解措施。这些混淆字段默认包含,但会增加少量数据流的开销。如果你信任客户端与 接口 之间的网络链路,可以将 include_obfuscation 设置为 `obfuscation` field on streaming delta events to
- normalize payload sizes as a mitigation to certain side-channel attacks.
- These obfuscation fields are included by default, but add a small amount
- of overhead to the data stream. You can set `include_obfuscation` 为
- false to optimize for bandwidth if you trust the network links between
- 你的应用与 OpenAI API 之间。
+ 当为 true 时,将启用流混淆。流混淆会向
+ 流式增量事件上的某个 `obfuscation` 字段添加随机字符,以
+ 规范化负载大小,作为对某些侧信道攻击的缓解措施。
+ 默认情况下会包含这些混淆字段,但会给数据流带来少量
+ 开销。如果你信任客户端与服务端之间的网络链路,可以将 `include_obfuscation` 设置为
+ 设置为 false 以优化带宽。
+ 你的应用与 OpenAI API 之间的。
- `include_usage: optional boolean`
- 如果设置了该参数,则会在 `data: [DONE]`
- 消息之前额外流式返回一个分块。该 `usage` 字段显示整个请求的 token 用量统计信息,
- 而该请求的 `choices` 字段将始终为空
+ 如果设置了该参数,会在 `data: [DONE]`
+ 之前流式传输一个额外的分块 `usage` message。该分块上的
+ 字段显示整个请求的 token 使用统计信息,而 `choices` 字段将始终为空
数组。
- 所有其他分块也会包含一个 `usage` 字段,但其值为
- null。 **注意:** 如果流被中断,你可能不会收到包含该请求
- 总 token 用量的最后一个 usage 分块。
+ 所有其他分块也会包含一个 `usage` 字段,但其值为 null
+ 。 **注意:** 如果流被中断,你可能无法收到
+ 包含该请求总 token 使用量的最后一个 usage 分块。
### Chat Completion 系统消息参数
- `ChatCompletionSystemMessageParam object { content, role, name }`
- 开发者提供的指令,无论用户发送什么
- 用户发送的消息。对于 o1 及更高版本的模型,请改用 `developer` messages
- 来实现此目的。
+ 开发者提供的指令,模型应当遵循这些指令,而无论用户发送了什么样的
+ 用户发送的消息。对于 o1 及更新模型,请使用 `developer` 消息取代了原先的
+ 来替代此用途。
- `content: string or array of ChatCompletionContentPartText`
@@ -7488,7 +7460,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ArrayOfContentParts = array of ChatCompletionContentPartText`
- 具有已定义类型的内容部分数组。对于系统消息,仅支持类型 `text` 类型。
+ 包含已定义类型的 content 部件数组。对于系统消息,仅支持 type `text` 内容。
- `text: string`
@@ -7496,31 +7468,31 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `"text"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "system"`
- 消息作者的角色,本例中为 `system`.
+ 消息作者的角色,在本例中为 `system`.
- `"system"`
- `name: optional string`
- 参与者的可选名称。为模型提供信息,以便区分同一角色的不同参与者。
+ 参与者可选的名称。为模型提供信息,以区分同一角色的不同参与者。
-### Chat Completion Token Logprob
+### Chat Completion Token 概率
- `ChatCompletionTokenLogprob object { token, bytes, logprob, top_logprobs }`
@@ -7530,15 +7502,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `top_logprobs: array of object { token, bytes, logprob }`
- 在该 token 位置上,最可能出现的 token 及其对数概率的列表。条目数量可能少于所请求的 `top_logprobs`.
+ 在该 token 位置处可能性最高的 token 列表及其对数概率。条目数量可能少于请求的 `top_logprobs`.
- `token: string`
@@ -7546,11 +7518,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `bytes: array of number or null`
- 表示该 token UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示时非常有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的场景下非常有用。可以为 `null` ,表示该 token 没有字节表示。
- `logprob: number`
- 该 token 的对数概率(如果它位于概率最高的 20 个 token 之内)。否则,值为 `-9999.0` 表示该 token 极不可能出现。
+ 该 token 的对数概率(若它处于概率最高的前 20 个 token 之列)。否则,值 `-9999.0` 用于表示该 token 出现的可能性极低。
### Chat Completion 工具
@@ -7566,25 +7538,25 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `name: string`
- 要调用的函数名称。必须为 a-z、A-Z、0-9,或包含下划线和短横线,最大长度为 64。
+ 要调用的函数名称。只能包含 a-z、A-Z、0-9,或下划线和短横线,最大长度为 64。
- `description: optional string`
- 对函数作用的描述,模型据此选择何时以及如何调用该函数。
+ 对函数功能的描述,供模型用于选择何时以及如何调用该函数。
- `parameters: optional FunctionParameters`
- 函数接受的参数,以 JSON Schema 对象描述。参阅 [指南](/docs/guides/function-calling) 中的示例,以及 [JSON Schema 参考](https://json-schema.org/understanding-json-schema/) 获取有关该格式的文档。
+ 函数接受的参数,使用 JSON Schema 对象进行描述。详见 [指南](/docs/guides/function-calling) 中的示例,以及 [JSON Schema 参考](https://json-schema.org/understanding-json-schema/) 有关此格式的文档。
- 省略 `parameters` 用于定义一个参数列表为空的函数。
+ 省略 `parameters` 定义一个参数列表为空的函数。
- `strict: optional boolean or null`
- 在生成函数调用时是否启用严格模式遵循。如果设置为 true,模型将遵循 `parameters` 字段时。如需了解更多信息,请参阅 `strict` 为 `true`。中定义的确切模式。详细了解结构化输出,请参阅 [function calling guide](/docs/guides/function-calling).
+ 在生成函数调用时是否启用严格的 schema 遵循。如果设置为 true,模型将严格按照 `parameters` 所定义的精确模式。当 strict `strict` 为 `true`。中定义的 schema 执行。详细了解 Structured Outputs,请参阅 [function calling guide](/docs/guides/function-calling).
- `type: "function"`
- 工具的类型。目前,仅 `function` 类型。
+ 工具的类型。目前,仅支持 `function` 内容。
- `"function"`
@@ -7606,15 +7578,15 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `format: optional object { type } or object { grammar, type }`
- 自定义工具的输入格式。默认为无约束文本。
+ 自定义工具的输入格式。默认情况下为不受约束的文本。
- `Text object { type }`
- 无约束的自由格式文本。
+ 不受约束的自由格式文本。
- `type: "text"`
- 无约束文本格式。始终为 `text`.
+ 不受约束的文本格式。始终为 `text`.
- `"text"`
@@ -7632,7 +7604,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `syntax: "lark" or "regex"`
- 语法定义的语法格式,取值之一为 `lark` 或 `regex`.
+ 语法定义的语法。可选值为 `lark` 或 `regex`.
- `"lark"`
@@ -7654,17 +7626,17 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ChatCompletionToolChoiceOption = "none" or "auto" or "required" or ChatCompletionAllowedToolChoice or ChatCompletionNamedToolChoice or ChatCompletionNamedToolChoiceCustom`
- 控制模型调用哪些工具(如果有的话)。
- `none` 表示模型不会调用任何工具,而是生成一条消息。
- `auto` 表示模型可以在生成消息或调用一个或多个工具之间进行选择。
- `required` 表示模型必须调用一个或多个工具。
- 通过指定特定工具来 `{"type": "function", "function": {"name": "my_function"}}` 强制模型调用该工具。
+ 控制模型调用哪个工具(如果有的话)。
+ `none` 意味着模型不会调用任何工具,而是生成一条消息。
+ `auto` 意味着模型可以在生成消息和调用一个或多个工具之间进行选择。
+ `required` 意味着模型必须调用一个或多个工具。
+ 通过 `{"type": "function", "function": {"name": "my_function"}}` 强制模型调用该工具。
- `none` 是未提供任何工具时的默认行为。 `auto` 是提供了工具时的默认行为。
+ `none` 是没有工具时的默认值。 `auto` 是存在工具时的默认值。
- `ToolChoiceMode = "none" or "auto" or "required"`
- `none` 表示模型不会调用任何工具,而是生成一条消息。 `auto` 表示模型可以在生成消息或调用一个或多个工具之间进行选择。 `required` 表示模型必须调用一个或多个工具。
+ `none` 意味着模型不会调用任何工具,而是生成一条消息。 `auto` 意味着模型可以在生成消息和调用一个或多个工具之间进行选择。 `required` 意味着模型必须调用一个或多个工具。
- `"none"`
@@ -7674,17 +7646,17 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ChatCompletionAllowedToolChoice object { allowed_tools, type }`
- 将模型可使用的工具限制为预定义的集合。
+ 将模型可用的工具限制为预定义的集合。
- `allowed_tools: ChatCompletionAllowedTools`
- 将模型可使用的工具限制为预定义的集合。
+ 将模型可用的工具限制为预定义的集合。
- `mode: "auto" or "required"`
- 将模型可使用的工具限制为预定义的集合。
+ 将模型可用的工具限制为预定义的集合。
- `auto` 允许模型从允许的工具中选择并生成
+ `auto` 允许模型从允许的工具中选取并生成
消息。
`required` 要求模型调用一个或多个允许的工具。
@@ -7695,9 +7667,9 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `tools: array of map[unknown]`
- 模型可调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
- 对于 Chat Completions API,工具定义列表可能如下:
+ 对于 Chat Completions API,工具定义列表可能如下所示:
```json
[
@@ -7714,13 +7686,13 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ChatCompletionNamedToolChoice object { function, type }`
- 指定模型应使用的工具。用于强制模型调用特定函数。
+ 指定模型应使用的工具。用于强制模型调用某个特定函数。
- `function: object { name }`
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `type: "function"`
@@ -7730,7 +7702,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ChatCompletionNamedToolChoiceCustom object { custom, type }`
- 指定模型应使用的工具。用于强制模型调用特定自定义工具。
+ 指定模型应使用的工具。用于强制模型调用某个特定的自定义工具。
- `custom: object { name }`
@@ -7758,7 +7730,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ArrayOfContentParts = array of ChatCompletionContentPartText`
- 由已定义类型组成的内容分块数组。对于工具消息,仅支持类型 `text` 类型。
+ 具有已定义类型的内容片段数组。对于工具消息,仅类型 `text` 内容。
- `text: string`
@@ -7766,23 +7738,23 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `"text"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "tool"`
- 消息作者的角色,本例中为 `tool`.
+ 消息作者的角色,在本例中为 `tool`.
- `"tool"`
@@ -7794,7 +7766,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ChatCompletionUserMessageParam object { content, role, name }`
- 由最终用户发送的消息,包含提示或额外的上下文
+ 由终端用户发送的消息,包含提示词或其他上下文
信息。
- `content: string or array of ChatCompletionContentPart`
@@ -7807,7 +7779,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `ArrayOfContentParts = array of ChatCompletionContentPart`
- 具有已定义类型的内容部分数组。支持的具体选项因用于生成响应的 [model](/docs/models) 而异。可以包含文本、图像或音频输入。
+ 包含已定义类型的 content 部件数组。可选项取决于用于生成响应的 [model](/docs/models) 。可以包含文本、图像或音频输入。
- `ChatCompletionContentPartText object { text, type, prompt_cache_breakpoint }`
@@ -7819,17 +7791,17 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `"text"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -7841,11 +7813,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `url: string`
- 图像的 URL 或 base64 编码的图像数据。
+ 图像的 URL 或 base64 编码后的图像数据。
- `detail: optional "auto" or "low" or "high"`
- 指定图像的细节级别。更多信息请参阅 [视觉指南](/docs/guides/vision#low-or-high-fidelity-image-understanding).
+ 指定图像的细节级别。详见 [视觉指南](/docs/guides/vision#low-or-high-fidelity-image-understanding).
- `"auto"`
@@ -7855,17 +7827,17 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "image_url"`
- 内容部分的类型。
+ content part 的类型。
- `"image_url"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -7895,11 +7867,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -7911,8 +7883,8 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `file_data: optional string`
- base64 编码的文件数据,在将文件传递给模型时使用
- 字符串。
+ Base64 编码的文件数据,在将文件传递给模型时使用
+ 字符串形式。
- `file_id: optional string`
@@ -7920,8 +7892,8 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `filename: optional string`
- 文件的名称,在将文件以
- 字符串形式传递给模型时使用。
+ 文件的名称,在将文件作为以下形式传递给模型时使用
+ 字符串。
- `type: "file"`
@@ -7931,23 +7903,23 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user"`
- 消息作者的角色,本例中为 `user`.
+ 消息作者的角色,在本例中为 `user`.
- `"user"`
- `name: optional string`
- 参与者的可选名称。为模型提供信息,以便区分同一角色的不同参与者。
+ 参与者可选的名称。为模型提供信息,以区分同一角色的不同参与者。
# 消息
@@ -7956,7 +7928,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
**get** `/chat/completions/{completion_id}/messages`
获取存储的聊天补全中的消息。仅返回使用
-创建的 Chat Completions `store` 创建的 Chat Completions `true` 将被
+以下参数创建的 Chat Completions `store` 参数时才能被删除。 `true` 会被
返回。
### 路径参数
@@ -7967,25 +7939,25 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `after: optional string`
- 上一页分页请求中最后一条消息的标识符。
+ 上一次分页请求中最后一条消息的标识符。
- `limit: optional number`
- 要获取的消息数量。
+ 要检索的消息数量。
- `order: optional "asc" or "desc"`
- 按时间戳排序消息的顺序。使用 `asc` 表示升序,或使用 `desc` 表示降序。默认为 `asc`.
+ 按时间戳排序消息的顺序。使用 `asc` 表示升序,或 `desc` 表示降序。默认为 `asc`.
- `"asc"`
- `"desc"`
-### 返回值
+### Returns
- `data: array of ChatCompletionStoreMessage`
- 聊天补全消息对象组成的数组。
+ 聊天补全消息对象的数组。
- `id: string`
@@ -7993,7 +7965,7 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `content_parts: optional array of ChatCompletionContentPartText or ChatCompletionContentPartImage or null`
- 如果提供了内容部分数组,则这是一个由 `text` 和 `image_url` 部分组成的数组。
+ 如果提供了 content parts 数组,则该字段为一个数组,元素为 `text` 和 `image_url` parts。
否则为 null。
- `ChatCompletionContentPartText object { text, type, prompt_cache_breakpoint }`
@@ -8006,17 +7978,17 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "text"`
- 内容部分的类型。
+ content part 的类型。
- `"text"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -8028,11 +8000,11 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `url: string`
- 图像的 URL 或 base64 编码的图像数据。
+ 图像的 URL 或 base64 编码后的图像数据。
- `detail: optional "auto" or "low" or "high"`
- 指定图像的细节级别。更多信息请参阅 [视觉指南](/docs/guides/vision#low-or-high-fidelity-image-understanding).
+ 指定图像的细节级别。详见 [视觉指南](/docs/guides/vision#low-or-high-fidelity-image-understanding).
- `"auto"`
@@ -8042,17 +8014,17 @@ curl -X POST https://api.openai.com/v1/chat/completions/chat_abc123 \
- `type: "image_url"`
- 内容部分的类型。
+ content part 的类型。
- `"image_url"`
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的确切结束位置。该断点继承自请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用 prompt 前缀的精确结束位置。该断点会沿用请求的 prompt_cache_key `prompt_cache_options.ttl`;所对应的 TTL;边界不会取整到 token 块。
- `mode: "explicit"`
- 断点模式。始终 `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
diff --git a/docs/zh/api/reference/resources/chat/subresources/completions/methods/retrieve.md b/docs/zh/api/reference/resources/chat/subresources/completions/methods/retrieve.md
index 3362324..79f94dd 100644
--- a/docs/zh/api/reference/resources/chat/subresources/completions/methods/retrieve.md
+++ b/docs/zh/api/reference/resources/chat/subresources/completions/methods/retrieve.md
@@ -1,21 +1,21 @@
-> 如需完整文档索引,请参阅 [llms.txt](/llms.txt)。在页面 URL 后面追加 `.md` 即可获取该页面的 Markdown 版本。
+> 完整文档索引请参阅 [llms.txt](/llms.txt). 可通过在页面 URL 末尾追加 `.md` 来获取文档页面的 Markdown 版本。
## 获取聊天补全
**get** `/chat/completions/{completion_id}`
-获取已存储的 Chat Completions。仅返回已使用
-参数创建的 `store` 参数设置为 `true` 的 Chat Completions。
+获取已存储的聊天补全。仅返回已使用
+参数 `store` 设置为 `true` 创建的 Chat Completions。
### 路径参数
- `completion_id: string`
-### 返回
+### 返回值
- `ChatCompletion object { id, choices, created, 7 more }`
- 表示由模型根据所提供的输入返回的聊天补全响应。
+ 表示模型根据所提供输入返回的聊天补全响应。
- `id: string`
@@ -23,15 +23,15 @@
- `choices: array of object { finish_reason, index, logprobs, message }`
- 聊天补全选项的列表。如果 `n` 大于 1,则可能包含多个。
+ 聊天补全选项列表。如果 `n` 大于 1,则可以包含多个选项。
- `finish_reason: "stop" or "length" or "tool_calls" or 2 more`
- 模型停止生成 token 的原因。该值将为 `stop` (如果模型遇到自然停止点或提供了停止序列),
- `length` (如果达到了请求中指定的最大 token 数),
- `content_filter` (如果由于内容过滤器的标记而省略了内容),
- `tool_calls` (如果模型调用了工具),或 `function_call` (已废弃,如果模型调用了函数)。
- 请参阅 [模型规范](https://model-spec.openai.com/2025-12-18.html) 以了解更多信息。
+ 模型停止生成 token 的原因。如果模型遇到自然停止点或提供了停止序列,则该原因将 `stop` ;如果请求中指定的最大 token 数已达到,则,
+ `length` ;如果由于我们的内容过滤器的标记而省略了内容,则,
+ `content_filter` ;如果模型调用了工具,则,
+ `tool_calls` ;或者如果模型调用了函数,则 `function_call` (已弃用)。
+ 请参阅 [模型规范](https://model-spec.openai.com/2025-12-18.html) 了解更多信息。
- `"stop"`
@@ -45,7 +45,7 @@
- `index: number`
- 该选项在选项列表中的索引。
+ 选项在选项列表中的索引。
- `logprobs: object { content, refusal } or null`
@@ -53,7 +53,7 @@
- `content: array of ChatCompletionTokenLogprob or null`
- 带有对数概率信息的消息内容 token 列表。
+ 包含对数概率信息的消息内容 token 列表。
- `token: string`
@@ -61,15 +61,15 @@
- `bytes: array of number or null`
- 一个整数列表,表示该 token 的 UTF-8 字节表示。在字符由多个 token 表示且必须组合其字节表示以生成正确文本表示的场景中很有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的情况下非常有用。如果该 token 没有字节表示,则可以为 `null` 。
- `logprob: number`
- 此 token 的对数概率(如果它位于最可能的 20 个 token 之内)。否则,值 `-9999.0` 用于表示该令牌极不可能出现。
+ 该 token 的对数概率(如果它位于概率最高的前 20 个 token 之内)。否则,该值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `top_logprobs: array of object { token, bytes, logprob }`
- 该令牌位置最可能的令牌及其对数概率列表。条目的数量可能少于请求的 `top_logprobs`.
+ 在该 token 位置处最可能的 token 列表及其对数概率。条目数可能少于所请求的 `top_logprobs`.
- `token: string`
@@ -77,15 +77,15 @@
- `bytes: array of number or null`
- 一个整数列表,表示该 token 的 UTF-8 字节表示。在字符由多个 token 表示且必须组合其字节表示以生成正确文本表示的场景中很有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的情况下非常有用。如果该 token 没有字节表示,则可以为 `null` 。
- `logprob: number`
- 此 token 的对数概率(如果它位于最可能的 20 个 token 之内)。否则,值 `-9999.0` 用于表示该令牌极不可能出现。
+ 该 token 的对数概率(如果它位于概率最高的前 20 个 token 之内)。否则,该值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `refusal: array of ChatCompletionTokenLogprob or null`
- 包含对数概率信息的消息拒绝令牌列表。
+ 包含消息拒绝 token 及其对数概率信息的列表。
- `token: string`
@@ -93,19 +93,19 @@
- `bytes: array of number or null`
- 一个整数列表,表示该 token 的 UTF-8 字节表示。在字符由多个 token 表示且必须组合其字节表示以生成正确文本表示的场景中很有用。如果该 token 没有字节表示,则可以为 `null` 。
+ 表示该 token 的 UTF-8 字节表示的整数列表。在字符由多个 token 表示且必须组合其字节表示才能生成正确文本表示的情况下非常有用。如果该 token 没有字节表示,则可以为 `null` 。
- `logprob: number`
- 此 token 的对数概率(如果它位于最可能的 20 个 token 之内)。否则,值 `-9999.0` 用于表示该令牌极不可能出现。
+ 该 token 的对数概率(如果它位于概率最高的前 20 个 token 之内)。否则,该值 `-9999.0` 用于表示该 token 出现的可能性极低。
- `top_logprobs: array of object { token, bytes, logprob }`
- 该令牌位置最可能的令牌及其对数概率列表。条目的数量可能少于请求的 `top_logprobs`.
+ 在该 token 位置处最可能的 token 列表及其对数概率。条目数可能少于所请求的 `top_logprobs`.
- `message: ChatCompletionMessage`
- 模型生成的一次聊天补全消息。
+ 由模型生成的聊天补全消息。
- `content: string or null`
@@ -123,7 +123,7 @@
- `annotations: optional array of object { type, url_citation }`
- 适用于消息的注释,例如使用
+ 消息的注解(如适用),例如使用
[网页搜索工具](/docs/guides/tools-web-search?api-mode=chat).
- `type: "url_citation"`
@@ -134,15 +134,15 @@
- `url_citation: object { end_index, start_index, title, url }`
- 使用网页搜索时的 URL 引用。
+ 使用 网页搜索 时的 URL 引用。
- `end_index: number`
- 消息中 URL 引用最后一个字符的索引。
+ 消息中 URL 引用末尾字符的索引。
- `start_index: number`
- 消息中 URL 引用第一个字符的索引。
+ 消息中 URL 引用起始字符的索引。
- `title: string`
@@ -154,8 +154,8 @@
- `audio: optional ChatCompletionAudio or null`
- 如果请求音频输出模态,则此对象包含
- 模型音频响应的相关数据。 [了解详情](/docs/guides/audio).
+ 如果请求了音频输出模态,此对象包含来自模型的音频
+ 响应的相关数据。 [了解更多](/docs/guides/audio).
- `id: string`
@@ -163,14 +163,14 @@
- `data: string`
- 模型生成的 Base64 编码音频字节,格式为
- 请求中指定。
+ 由模型生成的 Base64 编码音频字节,格式为
+ 在请求中指定。
- `expires_at: number`
- Unix 时间戳(以秒为单位),表示该音频响应在多轮对话中将
- 无法再从服务端访问的时间点。
- 不再可访问的时间。
+ 此音频响应的 Unix 时间戳(单位:秒),表示该音频将在何时
+ 在服务端不再可用于多轮
+ 对话。
- `transcript: string`
@@ -178,11 +178,11 @@
- `function_call: optional object { arguments, name }`
- 已弃用,并被替换为 `tool_calls`。模型生成的应被调用的函数的名称和参数。
+ 已弃用并替换为 `tool_calls`。应调用的函数的名称和参数,由模型生成。
- `arguments: string`
- 调用函数所使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,也可能会编造你函数 schema 中未定义的参数。在调用函数之前,请务必在代码中校验这些参数。
+ 用于调用函数的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你函数 schema 中未定义的参数。在调用函数之前,请验证代码中的参数。
- `name: string`
@@ -194,7 +194,7 @@
- `ChatCompletionMessageFunctionToolCall object { id, function, type }`
- 模型创建的函数工具调用。
+ 对模型创建的函数工具的调用。
- `id: string`
@@ -206,7 +206,7 @@
- `arguments: string`
- 调用函数所使用的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,也可能会编造你函数 schema 中未定义的参数。在调用函数之前,请务必在代码中校验这些参数。
+ 用于调用函数的参数,由模型以 JSON 格式生成。请注意,模型并不总是生成有效的 JSON,并且可能会虚构你函数 schema 中未定义的参数。在调用函数之前,请验证代码中的参数。
- `name: string`
@@ -220,7 +220,7 @@
- `ChatCompletionMessageCustomToolCall object { id, custom, type }`
- 模型创建的自定义工具调用。
+ 对模型创建的自定义工具的调用。
- `id: string`
@@ -250,7 +250,7 @@
- `model: string`
- 用于聊天补全的模型。
+ 用于该聊天补全的模型。
- `object: "chat.completion"`
@@ -261,8 +261,8 @@
- `metadata: optional Metadata or null`
可附加到对象的 16 个键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过
- API 或仪表板查询对象。
+ 以结构化格式存储对象的附加信息,并通过 API 或仪表板
+ 查询对象。
键为字符串,最长 64 个字符。值为字符串,
最长 512 个字符。
@@ -270,11 +270,11 @@
- `moderation: optional object { input, output } or null`
请求输入和生成输出的审核结果(如果请求了
- 审核补全)。
+ 经审核的补全)。
- `input: object { model, results, type } or object { code, message, type }`
- 针对请求输入的审核。
+ 请求输入的审核结果。
- `ModerationResults object { model, results, type }`
@@ -290,11 +290,11 @@
- `categories: map[boolean]`
- 审核类别到布尔值的字典,如果输入在该类别下被标记则为 True。
+ 从审核类别到布尔值的字典,如果输入在该类别下被标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的分数反映了哪些输入模态。
- `"text"`
@@ -302,11 +302,11 @@
- `category_scores: map[number]`
- 审核类别到分数的字典。
+ 从审核类别到分数的字典。
- `flagged: boolean`
- 一个布尔值,指示内容是否被任何类别标记。
+ 指示内容是否被任何类别标记的布尔值。
- `model: string`
@@ -314,7 +314,7 @@
- `type: "moderation_result"`
- 对象类型,始终为 `moderation_result` 表示成功的内容审核结果。
+ 对象类型,过去始终为 `moderation_result` 用于成功的审核结果。
- `"moderation_result"`
@@ -326,7 +326,7 @@
- `Error object { code, message, type }`
- 尝试内容审核时产生的错误。
+ 尝试审核时产生的错误。
- `code: string`
@@ -344,7 +344,7 @@
- `output: object { model, results, type } or object { code, message, type }`
- 对生成输出的内容审核。
+ 对生成输出的审核。
- `ModerationResults object { model, results, type }`
@@ -360,11 +360,11 @@
- `categories: map[boolean]`
- 审核类别到布尔值的字典,如果输入在该类别下被标记则为 True。
+ 从审核类别到布尔值的字典,如果输入在该类别下被标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的分数反映了哪些输入模态。
- `"text"`
@@ -372,11 +372,11 @@
- `category_scores: map[number]`
- 审核类别到分数的字典。
+ 从审核类别到分数的字典。
- `flagged: boolean`
- 一个布尔值,指示内容是否被任何类别标记。
+ 指示内容是否被任何类别标记的布尔值。
- `model: string`
@@ -384,7 +384,7 @@
- `type: "moderation_result"`
- 对象类型,始终为 `moderation_result` 表示成功的内容审核结果。
+ 对象类型,过去始终为 `moderation_result` 用于成功的审核结果。
- `"moderation_result"`
@@ -396,7 +396,7 @@
- `Error object { code, message, type }`
- 尝试内容审核时产生的错误。
+ 尝试审核时产生的错误。
- `code: string`
@@ -416,13 +416,13 @@
指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则将使用项目设置中配置的服务层级来处理请求。除非另行配置,项目将使用 'default'。
- - 如果设置为 'default',则将使用所选模型的标准定价和性能来处理请求。
- - 如果设置为 '[flex](/docs/guides/flex-processing)',则将使用 Flex Processing 服务层级来处理请求。
- - 若要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中传入 `service_tier=fast` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=priority` 。 `service_tier=fast` 参数。响应中将显示 `priority` 。
- - 当未设置时,默认行为为 'auto'。
+ - 如果设置为 'auto',则请求将使用项目设置中配置的服务层级进行处理。除非另行配置,项目将使用 'default'。
+ - 如果设置为 'default',则请求将使用所选模型的标准定价和性能进行处理。
+ - 如果设置为 '[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。
+ - 若要在请求级别启用 [快速模式](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 请求中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 未设置时,默认行为为 'auto'。
- 当 `service_tier` 参数已设置时,响应体将包含根据实际用于处理该请求的处理模式得出的 `service_tier` 值。此响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数已设置时,响应体将包含基于实际用于处理该请求的处理模式的 `service_tier` 值。该响应值可能与该参数中设置的值不同。
- `"auto"`
@@ -438,25 +438,25 @@
- `system_fingerprint: optional string`
- 此指纹表示模型运行所使用后端配置。
+ 该指纹表示模型运行所使用的前端配置。
- 可与 `seed` 请求参数结合使用,以了解何时发生了可能影响确定性的后端变更。
+ 可与 `seed` 请求参数结合使用,以了解何时发生了可能影响确定性的后端更改。
- `usage: optional CompletionUsage`
- 补全请求的使用情况统计。
+ 补全请求的使用统计信息。
- `completion_tokens: number`
- 生成的补全内容中的 token 数。
+ 生成的补全中的 token 数量。
- `prompt_tokens: number`
- 提示中的 token 数。
+ 提示中的 token 数量。
- `total_tokens: number`
- 该请求使用的总 token 数(提示 + 补全)。
+ 请求中使用的 token 总数(提示 + 补全)。
- `completion_tokens_details: optional object { accepted_prediction_tokens, audio_tokens, reasoning_tokens, 2 more }`
@@ -465,7 +465,7 @@
- `accepted_prediction_tokens: optional number`
使用 Predicted Outputs 时,
- 预测中出现在补全内容中的 token 数。
+ 中出现在补全里的预测部分的 token 数量。
- `audio_tokens: optional number`
@@ -478,42 +478,38 @@
- `rejected_prediction_tokens: optional number`
使用 Predicted Outputs 时,
- 预测中未出现在补全内容中的 token 数。但是,与
- 推理 token 一样,这些 token 仍计入计费、输出和上下文窗口的
- 总补全 token 数中,用于
+ 中未出现在补全里的预测部分的 token 数量。但是,与
+ 推理 token 一样,这些 token 仍会计入用于计费、输出和上下文窗口的
+ 总补全 token 中,包括
限制。
- `text_tokens: optional number`
模型生成的文本输出 token。
- - `compute_units: optional number or null`
-
- 该请求的计算单元。目前可用时为 null。
-
- `prompt_tokens_details: optional object { audio_tokens, cache_write_tokens, cached_tokens, 2 more }`
- 提示词中使用的 token 明细。
+ 提示中使用的 token 明细。
- `audio_tokens: optional number`
- 提示词中存在的音频输入 token。
+ 提示中存在的音频输入 token。
- `cache_write_tokens: optional number`
- 写入缓存的未调整提示词 token 数。
+ 写入缓存的未调整提示 token 数。
- `cached_tokens: optional number`
- 提示词中存在的缓存 token。
+ 提示中存在的已缓存 token。
- `image_tokens: optional number`
- 提示词中存在的图像输入 token。
+ 提示中存在的图片输入 token。
- `text_tokens: optional number`
- 提示词中存在的文本输入 token。
+ 提示中存在的文本输入 token。
### 示例
@@ -672,7 +668,6 @@ curl https://api.openai.com/v1/chat/completions/$COMPLETION_ID \
"rejected_prediction_tokens": 0,
"text_tokens": 0
},
- "compute_units": 0,
"prompt_tokens_details": {
"audio_tokens": 0,
"cache_write_tokens": 0,
diff --git a/docs/zh/api/reference/resources/chat/subresources/completions/streaming-events.md b/docs/zh/api/reference/resources/chat/subresources/completions/streaming-events.md
index 8f38733..f02a2a1 100644
--- a/docs/zh/api/reference/resources/chat/subresources/completions/streaming-events.md
+++ b/docs/zh/api/reference/resources/chat/subresources/completions/streaming-events.md
@@ -1,16 +1,16 @@
# Chat Completions 流式事件
-> 完整文档索引请参阅 [llms.txt](/llms.txt).可通过在页面 URL 末尾追加 `.md` 获取文档页面的 Markdown 版本。
+> 完整文档索引请参阅 [llms.txt](/llms.txt)。文档页面的 Markdown 版本可通过在页面 URL 末尾添加 `.md` 来获取。
-实时流式传输 Chat Completions。使用服务端发送事件接收模型返回的补全分块
+实时流式输出 Chat Completions。以服务端发送事件的形式接收模型返回的补全分块
。
-[了解详情](https://developers.openai.com/docs/guides/streaming-responses?api-mode=chat).
+[了解更多](https://developers.openai.com/docs/guides/streaming-responses?api-mode=chat).
## chat.completion.chunk
-表示模型基于所提供的输入返回的聊天补全响应的流式分块
+表示模型基于所提供的输入流式返回的聊天补全响应分块
。
-[了解详情](https://developers.openai.com/docs/guides/streaming-responses).
+[了解更多](https://developers.openai.com/docs/guides/streaming-responses).
### Schema
@@ -305,7 +305,6 @@ Schema name: `CreateChatCompletionStreamResponse`
"(resource) completions > (model) completion_usage > (schema) > (property) prompt_tokens",
"(resource) completions > (model) completion_usage > (schema) > (property) total_tokens",
"(resource) completions > (model) completion_usage > (schema) > (property) completion_tokens_details",
- "(resource) completions > (model) completion_usage > (schema) > (property) compute_units",
"(resource) completions > (model) completion_usage > (schema) > (property) prompt_tokens_details"
]
},
@@ -661,23 +660,6 @@ Schema name: `CreateChatCompletionStreamResponse`
"(resource) completions > (model) completion_usage > (schema) > (property) completion_tokens_details > (property) text_tokens"
]
},
- "(resource) completions > (model) completion_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/CompletionUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) completions > (model) completion_usage > (schema) > (property) prompt_tokens_details": {
"kind": "HttpDeclProperty",
"oasRef": "#/components/schemas/CompletionUsage/properties/prompt_tokens_details",
@@ -736,9 +718,6 @@ Schema name: `CreateChatCompletionStreamResponse`
{
"ident": "completion_tokens_details"
},
- {
- "ident": "compute_units"
- },
{
"ident": "prompt_tokens_details"
}
@@ -750,7 +729,6 @@ Schema name: `CreateChatCompletionStreamResponse`
"(resource) completions > (model) completion_usage > (schema) > (property) prompt_tokens",
"(resource) completions > (model) completion_usage > (schema) > (property) total_tokens",
"(resource) completions > (model) completion_usage > (schema) > (property) completion_tokens_details",
- "(resource) completions > (model) completion_usage > (schema) > (property) compute_units",
"(resource) completions > (model) completion_usage > (schema) > (property) prompt_tokens_details"
]
},
@@ -2189,7 +2167,7 @@ Schema name: `CreateChatCompletionStreamResponse`
}
```
-### 示例
+### Example
```json
{"id":"chatcmpl-123","object":"chat.completion.chunk","created":1694268190,"model":"gpt-5.6-sol", "system_fingerprint": "fp_44709d6fcb", "choices":[{"index":0,"delta":{"role":"assistant","content":""},"logprobs":null,"finish_reason":null}],"obfuscation":"r4N7vQ2m"}
diff --git a/docs/zh/api/reference/resources/completions.md b/docs/zh/api/reference/resources/completions.md
index 91f4b2d..721d60a 100644
--- a/docs/zh/api/reference/resources/completions.md
+++ b/docs/zh/api/reference/resources/completions.md
@@ -1,6 +1,6 @@
# Completions
-> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。在页面 URL 末尾追加 `.md` 即可获取文档页面的 Markdown 版本。
+> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。可通过在页面 URL 后追加 `.md` 来获取文档页面的 Markdown 版本。
## 创建补全
@@ -8,19 +8,19 @@
根据提供的提示和参数创建补全。
-返回一个补全对象,如果请求是流式的,则返回一系列补全对象。
+返回一个补全对象,如果请求为流式传输,则返回一个补全对象序列。
### 请求体参数
- `model: string or "gpt-3.5-turbo-instruct" or "davinci-002" or "babbage-002"`
- 要使用的模型 ID。你可以使用 [列出模型](/docs/api-reference/models/list) API 查看所有可用模型,或参阅我们的 [模型概述](/docs/models) 了解相关描述。
+ 要使用的模型 ID。你可以前往 [模型列表](/docs/api-reference/models/list) API 查看所有可用模型,也可以参阅 [模型概述](/docs/models) 了解相关描述。
- `string`
- `"gpt-3.5-turbo-instruct" or "davinci-002" or "babbage-002"`
- 要使用的模型 ID。你可以使用 [列出模型](/docs/api-reference/models/list) API 查看所有可用模型,或参阅我们的 [模型概述](/docs/models) 了解相关描述。
+ 要使用的模型 ID。你可以前往 [模型列表](/docs/api-reference/models/list) API 查看所有可用模型,也可以参阅 [模型概述](/docs/models) 了解相关描述。
- `"gpt-3.5-turbo-instruct"`
@@ -30,9 +30,9 @@
- `prompt: string or array of string or array of number or array of array of number or null`
- 用于生成补全的提示(prompt),可以编码为字符串、字符串数组、token 数组或 token 数组的数组。
+ 用于生成补全的提示,可以编码为字符串、字符串数组、token 数组或 token 数组的数组。
- 注意,是模型在训练期间看到的文档分隔符,因此如果未指定提示,模型将如同从一篇新文档的开头开始生成。
+ 注意 <|endoftext|> 是模型在训练过程中看到的文档分隔符,因此如果未指定提示,模型将像从一篇新文档的开头一样继续生成。
- `string`
@@ -44,66 +44,66 @@
- `best_of: optional number or null`
- 服务端 `best_of` 生成补全并返回“最佳”结果(即每个 token 具有最高对数概率的那一个)。结果无法以流式方式返回。服务端。
+ 在服务端生成 `best_of` 多个补全,并返回“最佳”的那一个(即每个 token 具有最高对数概率的那个)。结果无法以流式方式返回。
- 与 `n`, `best_of` 配合使用时,它控制候选补全的数量,而 `n` 指定要返回多少个 – `best_of` 必须大于 `n`.
+ 当与 `n`, `best_of` 配合使用时,用于控制候选补全的数量,而 `n` 用于指定返回多少个—— `best_of` 必须大于 `n`.
- **注意:** 由于此参数会生成大量补全,可能会迅速消耗你的 token 配额。请谨慎使用,并确保你对 `max_tokens` 和 `stop`.
+ **注意:** 由于该参数会生成大量补全,因此可能会迅速消耗你的 token 配额。请谨慎使用,并确保为 `max_tokens` 和 `stop`.
- `echo: optional boolean or null`
- 除了补全内容外,将提示一同回显
+ 除了补全内容外,回显输入的提示
- `frequency_penalty: optional number or null`
- 介于 -2.0 到 2.0 之间的数值。正值会根据新 token 在已有文本中出现的频率对其进行惩罚,从而降低模型逐字重复相同内容的可能性。
+ 介于 -2.0 到 2.0 之间的数值。正值会根据新 token 在文本中已出现的频率对其进行惩罚,从而降低模型逐字重复相同内容的可能性。
- [查看关于频率和存在惩罚的更多信息。](/docs/guides/text-generation)
+ [查看有关频率和存在惩罚的更多信息。](/docs/guides/text-generation)
- `logit_bias: optional map[number] or null`
- 修改指定 token 在补全中出现的可能性。
+ 修改指定 token 出现在补全中的可能性。
- 接受一个 JSON 对象,将 token(通过 GPT 分词器中的 token ID 指定)映射到 -100 到 100 之间的关联偏差值。可以使用此 [分词器工具](/tokenizer?view=bpe) 将文本转换为 token ID。数学上,偏差会在采样之前被加到模型生成的 logits 上。具体影响会因模型而异,但介于 -1 到 1 之间的值会降低或增加被选中的可能性;像 -100 或 100 这样的值会导致禁用或独占选择相应的 token。
+ 接受一个 JSON 对象,将 token(按其在 GPT 分词器中的 token ID 指定)映射到 -100 到 100 之间的关联偏置值。你可以使用该 [分词器工具](/tokenizer?view=bpe) 将文本转换为 token ID。从数学上讲,该偏置会在模型采样前加到模型生成的 logits 上。确切效果会因模型而异,但 -1 到 1 之间的值会降低或提高被选中的可能性;像 -100 或 100 这样的值则会导致相关 token 被禁止或被唯一选中。
- 例如,可以传入 `{"50256": -100}` 来阻止生成 token。
+ 例如,你可以传入 `{"50256": -100}` 来阻止生成该 token。
- `logprobs: optional number or null`
- 在以下输出中包含对数概率: `logprobs` 最可能的输出 token,以及所选 token。例如,如果 `logprobs` 为 5,API 将返回 5 个最可能 token 的列表。API 将始终返回所采样 token 的 `logprob` ,因此响应中最多可以有 `logprobs+1` 个元素。
+ 在 `logprobs` 最可能的输出 token 上包含对数概率,以及所选 token 的对数概率。例如,如果 `logprobs` 为 5,API 将返回最可能的 5 个 token 的列表。API 将始终返回所采样 token 的 `logprob` ,因此响应中最多可有 `logprobs+1` 个元素。
的最大值为 `logprobs` 5。
- `max_tokens: optional number or null`
- 可在补全中生成的最大 [token 数](/tokenizer) 。
+ 可在补全中生成的最大 [token](/tokenizer) 数。
- 你的 prompt 的 token 数加上 `max_tokens` 不能超过模型的上下文长度。 [用于计算 token 的示例 Python 代码](https://cookbook.openai.com/examples/how_to_count_tokens_with_tiktoken) 。
+ 你的提示的 token 数加上 `max_tokens` 不能超过模型的上下文长度。 [用于统计 token 的 Python 示例代码](https://cookbook.openai.com/examples/how_to_count_tokens_with_tiktoken) 。
- `n: optional number or null`
- 每个 prompt 要生成的补全数。
+ 每个提示要生成多少个补全。
- **注意:** 由于此参数会生成大量补全,可能会迅速消耗你的 token 配额。请谨慎使用,并确保你对 `max_tokens` 和 `stop`.
+ **注意:** 由于该参数会生成大量补全,因此可能会迅速消耗你的 token 配额。请谨慎使用,并确保为 `max_tokens` 和 `stop`.
- `presence_penalty: optional number or null`
- 介于 -2.0 到 2.0 之间的数值。正值会根据新 token 是否已在文本中出现对其进行惩罚,从而提高模型谈论新主题的可能性。
+ 介于 -2.0 和 2.0 之间的数字。正值会根据新词元是否已出现在文本中对其进行惩罚,从而增加模型谈论新主题的可能性。
- [查看关于频率和存在惩罚的更多信息。](/docs/guides/text-generation)
+ [查看有关频率和存在惩罚的更多信息。](/docs/guides/text-generation)
- `seed: optional number or null`
- 如果指定,我们的系统将尽最大努力进行确定性采样,使得在相同 `seed` 和参数下重复请求应返回相同的结果。
+ 如果指定,我们的系统将尽最大努力进行确定性采样,使得使用相同的 `seed` 和参数的重复请求返回相同的结果。
- 无法保证完全确定性,你可以查阅 `system_fingerprint` 响应参数以监控后端的变化。
+ 确定性无法保证,你可以参考 `system_fingerprint` response 参数以监控后端的变化。
- `stop: optional string or array of string or null`
- 最新的推理模型不支持该参数 `o3` 和 `o4-mini`.
+ 最新的推理模型不支持此功能 `o3` 和 `o4-mini`.
- 最多 4 个序列,当遇到这些序列时 API 将停止生成更多 token。返回的
- 文本将不包含停止序列。
+ 最多 4 个 API 将停止生成更多词元的序列。
+ 返回的文本不会包含停止序列。
- `string`
@@ -111,54 +111,54 @@
- `stream: optional boolean or null`
- 是否流式返回部分进度。如果启用,token 将以纯数据的形式作为 [服务端发送事件](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format) 随着数据变得可用而发送,流以一个 `data: [DONE]` 消息结束。 [用于计算 token 的示例 Python 代码](https://cookbook.openai.com/examples/how_to_stream_completions).
+ 是否流式返回部分进度。如果设置,词元将以仅含数据的 [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format) 的形式在可用时发送,流由一个 `data: [DONE]` message 终止。 [用于统计 token 的 Python 示例代码](https://cookbook.openai.com/examples/how_to_stream_completions).
- `stream_options: optional ChatCompletionStreamOptions or null`
- 流式响应的选项。仅当你设置 `stream: true`.
+ 流式响应的选项。仅当你在设置 `stream: true`.
- `include_obfuscation: optional boolean`
- 如果为 true,将启用流混淆。流混淆会向流式 delta 事件的
- 字段添加随机字符, `obfuscation` 以规范化负载大小,作为针对某些侧信道攻击的缓解措施。
- 这些混淆字段默认包含,但会增加少量。
- 到数据流的开销。你可以将
- 设置为 `include_obfuscation` 为
- false 时可在信任你的应用与
- OpenAI API 之间网络链路的情况下优化带宽。
+ 为 true 时才设置此参数。开启后,流混淆将启用。流混淆会向
+ 流式增量事件上的某个字段添加 `obfuscation` 随机字符,以规范化
+ 负载大小,作为对某些侧信道攻击的缓解措施。
+ 默认会包含这些混淆字段,但会给数据流带来少量
+ 开销。你可以将 `include_obfuscation` 设置为
+ 如果信任应用程序之间的网络链路,可将其设为 false 以优化带宽
+ 应用程序与 OpenAI API 之间。
- `include_usage: optional boolean`
- 若设置,则在 `data: [DONE]`
- 消息之前还会流式传出一个额外的数据块。该 `usage` 字段显示整个请求的 token 使用统计信息,
- 字段对应整个请求, `choices` 字段始终为空
+ 如果设置此项,将会在消息之前流式传输一个额外的分块 `data: [DONE]`
+ 。该 `usage` 字段会显示令牌使用情况统计信息
+ ,涵盖整个请求,而 `choices` 字段将始终为空
数组。
- 所有其他数据块也会包含一个 `usage` 字段,但其值为
- null。 **注意:** 如果流被中断,你可能无法收到
- 包含整个请求总 token 使用量的最终使用情况数据块。
+ 所有其他分块也会包含一个 `usage` 字段,但该字段为 null
+ 值。 **注意:** 如果流式传输中断,你可能无法收到包含整个请求令牌使用总量的
+ 最终使用情况分块。
- `suffix: optional string or null`
- 插入文本补全之后的后缀。
+ 插入文本完成后出现的后缀。
- 该参数仅支持 `gpt-3.5-turbo-instruct`.
+ 此参数仅支持 `gpt-3.5-turbo-instruct`.
- `temperature: optional number or null`
- 使用的采样温度,介于 0 和 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加聚焦和确定。
+ 要使用的采样温度,介于 0 和 2 之间。较高的值(如 0.8)会使输出更随机,而较低的值(如 0.2)会使输出更集中、更确定。
- 我们通常建议修改此参数或 `top_p` ,但不要同时修改两者。
+ 通常建议修改此项或 `top_p` ,但不要同时修改两者。
- `top_p: optional number or null`
- 一种采用温度采样的替代方案,称为核采样(nucleus sampling),即模型考虑具有 top_p 概率质量的 token 结果。所以 0.1 表示仅考虑构成前 10% 概率质量的 token。
+ 一种称为核采样的温度采样替代方法,模型会考虑概率质量排名前 top_p 的令牌结果。因此,0.1 表示仅考虑组成概率质量前 10% 的令牌。
- 我们通常建议修改此参数或 `temperature` ,但不要同时修改两者。
+ 通常建议修改此项或 `temperature` ,但不要同时修改两者。
- `user: optional string`
- 用于标识你最终用户的唯一 ID,可以帮助 OpenAI 监控和检测滥用行为。 [了解更多](/docs/guides/safety-best-practices#end-user-ids).
+ 用于表示你最终用户的唯一标识符,可帮助 OpenAI 监控并检测滥用行为。 [了解更多](/docs/guides/safety-best-practices#end-user-ids).
### Returns
@@ -176,9 +176,9 @@
- `finish_reason: "stop" or "length" or "content_filter"`
- 模型停止生成 token 的原因。该值为 `stop` ,如果模型遇到了自然停止点或提供的停止序列;
- `length` ,如果达到了请求中指定的最大 token 数;
- 或 `content_filter` ,如果由于我们的内容过滤器标记而省略了内容。
+ 模型停止生成 token 的原因。该值将是 `stop` 如果模型遇到了自然停止点或提供的停止序列,
+ `length` 如果达到了请求中指定的最大 token 数,
+ 或者 `content_filter` 如果由于我们内容过滤器的标记导致内容被省略。
- `"stop"`
@@ -216,9 +216,9 @@
- `system_fingerprint: optional string`
- 此指纹表示模型运行时的后端配置。
+ 此指纹表示模型运行所用的后端配置。
- 可与 `seed` 请求参数结合使用,以了解可能影响确定性的后端更改。
+ 可与 `seed` 请求参数结合使用,以了解何时发生了可能影响确定性的后端更改。
- `usage: optional CompletionUsage`
@@ -238,36 +238,32 @@
- `completion_tokens_details: optional object { accepted_prediction_tokens, audio_tokens, reasoning_tokens, 2 more }`
- 补全中使用的 token 细分。
+ 补全中使用的 token 明细。
- `accepted_prediction_tokens: optional number`
使用 Predicted Outputs 时,
- 出现在补全结果中的预测 token。
+ 出现在补全中的预测。
- `audio_tokens: optional number`
- 由模型生成的音频输入 token。
+ 模型生成的音频输入 token。
- `reasoning_tokens: optional number`
- 由模型生成的用于推理的 token。
+ 模型为推理生成的 token。
- `rejected_prediction_tokens: optional number`
使用 Predicted Outputs 时,
- 未出现在补全结果中的预测 token。但是,与推理 token 类似,
- 这些 token 仍会计入用于计费、输出和上下文窗口的总
- 补全 token 中,用于计费、输出和上下文窗口
+ 未出现在补全中的预测。但是,与
+ 推理 token 一样,这些 token 仍然计入用于
+ 计费、输出和上下文窗口的总补全 token 数中
限制。
- `text_tokens: optional number`
- 由模型生成的文本输出 token。
-
- - `compute_units: optional number or null`
-
- 请求所用的计算单元。目前可用时为 null。
+ 模型生成的文本输出 token。
- `prompt_tokens_details: optional object { audio_tokens, cache_write_tokens, cached_tokens, 2 more }`
@@ -275,7 +271,7 @@
- `audio_tokens: optional number`
- 提示中存在的音频输入 token。
+ 提示中出现的音频输入 token。
- `cache_write_tokens: optional number`
@@ -283,15 +279,15 @@
- `cached_tokens: optional number`
- 提示中存在的已缓存 token。
+ 提示中出现的已缓存 token。
- `image_tokens: optional number`
- 提示中存在的图像输入 token。
+ 提示中出现的图像输入 token。
- `text_tokens: optional number`
- 提示中存在的文本输入 token。
+ 提示中出现的文本输入 token。
### 示例
@@ -311,7 +307,7 @@ curl https://api.openai.com/v1/completions \
}'
```
-#### Response
+#### 响应
```json
{
@@ -354,7 +350,6 @@ curl https://api.openai.com/v1/completions \
"rejected_prediction_tokens": 0,
"text_tokens": 0
},
- "compute_units": 0,
"prompt_tokens_details": {
"audio_tokens": 0,
"cache_write_tokens": 0,
@@ -366,7 +361,7 @@ curl https://api.openai.com/v1/completions \
}
```
-### 无流式输出
+### 无流式
```http
curl https://api.openai.com/v1/completions \
@@ -380,7 +375,7 @@ curl https://api.openai.com/v1/completions \
}'
```
-#### Response
+#### 响应
```json
{
@@ -405,7 +400,7 @@ curl https://api.openai.com/v1/completions \
}
```
-### 流式输出
+### 流式
```http
curl https://api.openai.com/v1/completions \
@@ -420,7 +415,7 @@ curl https://api.openai.com/v1/completions \
}'
```
-#### Response
+#### 响应
```json
{
@@ -440,7 +435,7 @@ curl https://api.openai.com/v1/completions \
}
```
-## Domain Types
+## 域类型
### Completion
@@ -458,9 +453,9 @@ curl https://api.openai.com/v1/completions \
- `finish_reason: "stop" or "length" or "content_filter"`
- 模型停止生成 token 的原因。该值为 `stop` ,如果模型遇到了自然停止点或提供的停止序列;
- `length` ,如果达到了请求中指定的最大 token 数;
- 或 `content_filter` ,如果由于我们的内容过滤器标记而省略了内容。
+ 模型停止生成 token 的原因。该值将是 `stop` 如果模型遇到了自然停止点或提供的停止序列,
+ `length` 如果达到了请求中指定的最大 token 数,
+ 或者 `content_filter` 如果由于我们内容过滤器的标记导致内容被省略。
- `"stop"`
@@ -498,9 +493,9 @@ curl https://api.openai.com/v1/completions \
- `system_fingerprint: optional string`
- 此指纹表示模型运行时的后端配置。
+ 此指纹表示模型运行所用的后端配置。
- 可与 `seed` 请求参数结合使用,以了解可能影响确定性的后端更改。
+ 可与 `seed` 请求参数结合使用,以了解何时发生了可能影响确定性的后端更改。
- `usage: optional CompletionUsage`
@@ -520,36 +515,32 @@ curl https://api.openai.com/v1/completions \
- `completion_tokens_details: optional object { accepted_prediction_tokens, audio_tokens, reasoning_tokens, 2 more }`
- 补全中使用的 token 细分。
+ 补全中使用的 token 明细。
- `accepted_prediction_tokens: optional number`
使用 Predicted Outputs 时,
- 出现在补全结果中的预测 token。
+ 出现在补全中的预测。
- `audio_tokens: optional number`
- 由模型生成的音频输入 token。
+ 模型生成的音频输入 token。
- `reasoning_tokens: optional number`
- 由模型生成的用于推理的 token。
+ 模型为推理生成的 token。
- `rejected_prediction_tokens: optional number`
使用 Predicted Outputs 时,
- 未出现在补全结果中的预测 token。但是,与推理 token 类似,
- 这些 token 仍会计入用于计费、输出和上下文窗口的总
- 补全 token 中,用于计费、输出和上下文窗口
+ 未出现在补全中的预测。但是,与
+ 推理 token 一样,这些 token 仍然计入用于
+ 计费、输出和上下文窗口的总补全 token 数中
限制。
- `text_tokens: optional number`
- 由模型生成的文本输出 token。
-
- - `compute_units: optional number or null`
-
- 请求所用的计算单元。目前可用时为 null。
+ 模型生成的文本输出 token。
- `prompt_tokens_details: optional object { audio_tokens, cache_write_tokens, cached_tokens, 2 more }`
@@ -557,7 +548,7 @@ curl https://api.openai.com/v1/completions \
- `audio_tokens: optional number`
- 提示中存在的音频输入 token。
+ 提示中出现的音频输入 token。
- `cache_write_tokens: optional number`
@@ -565,15 +556,15 @@ curl https://api.openai.com/v1/completions \
- `cached_tokens: optional number`
- 提示中存在的已缓存 token。
+ 提示中出现的已缓存 token。
- `image_tokens: optional number`
- 提示中存在的图像输入 token。
+ 提示中出现的图像输入 token。
- `text_tokens: optional number`
- 提示中存在的文本输入 token。
+ 提示中出现的文本输入 token。
### Completion Choice
@@ -581,9 +572,9 @@ curl https://api.openai.com/v1/completions \
- `finish_reason: "stop" or "length" or "content_filter"`
- 模型停止生成 token 的原因。该值为 `stop` ,如果模型遇到了自然停止点或提供的停止序列;
- `length` ,如果达到了请求中指定的最大 token 数;
- 或 `content_filter` ,如果由于我们的内容过滤器标记而省略了内容。
+ 模型停止生成 token 的原因。该值将是 `stop` 如果模型遇到了自然停止点或提供的停止序列,
+ `length` 如果达到了请求中指定的最大 token 数,
+ 或者 `content_filter` 如果由于我们内容过滤器的标记导致内容被省略。
- `"stop"`
@@ -607,7 +598,7 @@ curl https://api.openai.com/v1/completions \
### Completion Usage
-- `CompletionUsage object { completion_tokens, prompt_tokens, total_tokens, 3 more }`
+- `CompletionUsage object { completion_tokens, prompt_tokens, total_tokens, 2 more }`
补全请求的使用统计信息。
@@ -625,36 +616,32 @@ curl https://api.openai.com/v1/completions \
- `completion_tokens_details: optional object { accepted_prediction_tokens, audio_tokens, reasoning_tokens, 2 more }`
- 补全中使用的 token 细分。
+ 补全中使用的 token 明细。
- `accepted_prediction_tokens: optional number`
使用 Predicted Outputs 时,
- 出现在补全结果中的预测 token。
+ 出现在补全中的预测。
- `audio_tokens: optional number`
- 由模型生成的音频输入 token。
+ 模型生成的音频输入 token。
- `reasoning_tokens: optional number`
- 由模型生成的用于推理的 token。
+ 模型为推理生成的 token。
- `rejected_prediction_tokens: optional number`
使用 Predicted Outputs 时,
- 未出现在补全结果中的预测 token。但是,与推理 token 类似,
- 这些 token 仍会计入用于计费、输出和上下文窗口的总
- 补全 token 中,用于计费、输出和上下文窗口
+ 未出现在补全中的预测。但是,与
+ 推理 token 一样,这些 token 仍然计入用于
+ 计费、输出和上下文窗口的总补全 token 数中
限制。
- `text_tokens: optional number`
- 由模型生成的文本输出 token。
-
- - `compute_units: optional number or null`
-
- 请求所用的计算单元。目前可用时为 null。
+ 模型生成的文本输出 token。
- `prompt_tokens_details: optional object { audio_tokens, cache_write_tokens, cached_tokens, 2 more }`
@@ -662,7 +649,7 @@ curl https://api.openai.com/v1/completions \
- `audio_tokens: optional number`
- 提示中存在的音频输入 token。
+ 提示中出现的音频输入 token。
- `cache_write_tokens: optional number`
@@ -670,12 +657,12 @@ curl https://api.openai.com/v1/completions \
- `cached_tokens: optional number`
- 提示中存在的已缓存 token。
+ 提示中出现的已缓存 token。
- `image_tokens: optional number`
- 提示中存在的图像输入 token。
+ 提示中出现的图像输入 token。
- `text_tokens: optional number`
- 提示中存在的文本输入 token。
+ 提示中出现的文本输入 token。
diff --git a/docs/zh/api/reference/resources/completions/methods/create.md b/docs/zh/api/reference/resources/completions/methods/create.md
index ef2f36d..f87cc58 100644
--- a/docs/zh/api/reference/resources/completions/methods/create.md
+++ b/docs/zh/api/reference/resources/completions/methods/create.md
@@ -1,24 +1,24 @@
-> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。可通过在页面 URL 末尾添加 `.md` 来获取文档页面的 Markdown 版本。
+> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。可通过在页面 URL 后追加 `.md` 获取文档页面的 Markdown 版本。
-## 创建补全
+## Create completion
**post** `/completions`
-根据提供的提示和参数创建一个补全。
+根据提供的提示和参数创建补全。
-返回一个补全对象,如果请求是流式的,则返回一个补全对象序列。
+返回一个补全对象,如果请求以流式传输,则返回一组补全对象。
### 正文参数
- `model: string or "gpt-3.5-turbo-instruct" or "davinci-002" or "babbage-002"`
- 要使用的模型 ID。你可以使用 [列出模型](/docs/api-reference/models/list) API 查看所有可用的模型,或参阅我们的 [模型概述](/docs/models) 了解它们的说明。
+ 要使用的模型 ID。你可以使用 [列出模型](/docs/api-reference/models/list) API 来查看所有可用模型,或参阅我们的 [模型概述](/docs/models) 了解相关说明。
- `string`
- `"gpt-3.5-turbo-instruct" or "davinci-002" or "babbage-002"`
- 要使用的模型 ID。你可以使用 [列出模型](/docs/api-reference/models/list) API 查看所有可用的模型,或参阅我们的 [模型概述](/docs/models) 了解它们的说明。
+ 要使用的模型 ID。你可以使用 [列出模型](/docs/api-reference/models/list) API 来查看所有可用模型,或参阅我们的 [模型概述](/docs/models) 了解相关说明。
- `"gpt-3.5-turbo-instruct"`
@@ -28,9 +28,9 @@
- `prompt: string or array of string or array of number or array of array of number or null`
- 用于生成补全的提示,可以编码为字符串、字符串数组、token 数组或 token 数组的数组。
+ 用于生成补全的提示,可编码为字符串、字符串数组、token 数组或 token 数组的数组。
- 注意 <|endoftext|> 是模型在训练期间看到的文档分隔符,因此如果未指定提示,模型将如同从新文档开头开始一样进行生成。
+ 注意, 是模型在训练时见到的文档分隔符,因此如果未指定提示,模型将如同从新文档的开头开始生成。
- `string`
@@ -42,66 +42,66 @@
- `best_of: optional number or null`
- 在 `best_of` 端服务端生成补全,并返回“最佳”的一个(每个 token 具有最高对数概率的那个)。结果无法以流式返回。
+ 在 `best_of` 端服务端生成补全,并返回“最佳”结果(每个 token 对数概率最高的那一个)。结果无法以流式方式返回。
- 与 `n`, `best_of` 一起使用时,用于控制候选补全的数量,而 `n` 指定要返回的数量 —— `best_of` 必须大于 `n`.
+ 与以下参数配合使用时, `n`, `best_of` 控制候选补全的数量, `n` 指定要返回的数量 —— `best_of` 必须大于 `n`.
- **注意:** 由于此参数会生成大量补全,可能会迅速消耗你的 token 配额。请谨慎使用,并确保你对 `max_tokens` 和 `stop`.
+ **注意:** 由于该参数会生成大量补全,可能会迅速消耗你的 token 配额。请谨慎使用,并确保为 `max_tokens` 和 `stop`.
- `echo: optional boolean or null`
- 除补全外,还回显提示
+ 除补全内容外,回显输入的提示
- `frequency_penalty: optional number or null`
- 介于 -2.0 和 2.0 之间的数值。正值会根据新 token 截至目前在文本中已出现的频率对其进行惩罚,从而降低模型逐字重复相同内容的可能性。
+ 介于 -2.0 到 2.0 之间的数值。正值会根据新 token 在已有文本中的出现频率对其进行惩罚,从而降低模型逐字重复相同内容的可能性。
- [查看有关频率和存在惩罚的更多信息。](/docs/guides/text-generation)
+ [查看有关频率惩罚和存在惩罚的更多信息。](/docs/guides/text-generation)
- `logit_bias: optional map[number] or null`
- 修改指定 token 出现在补全中的可能性。
+ 修改指定 token 在补全中出现的可能性。
- 接受一个 JSON 对象,用于将词元(通过其在 GPT 分词器中的词元 ID 指定)映射到 -100 到 100 之间的关联偏置值。你可以使用这个 [分词器工具](/tokenizer?view=bpe) 将文本转换为词元 ID。从数学上讲,该偏置会在采样之前添加到模型生成的 logits 上。不同模型的具体效果会有所不同,但 -1 到 1 之间的值应会降低或提高被选中的可能性;像 -100 或 100 这样的值应会导致相应词元被禁止或被唯一选中。
+ 接受一个 JSON 对象,将分词器中的 token(以 GPT 分词器中的 token ID 指定)映射到 -100 到 100 之间的关联偏置值。你可以使用此 [分词器工具](/tokenizer?view=bpe) 将文本转换为 token ID。从数学上讲,该偏置会在采样之前添加到模型生成的 logits 上。确切效果因模型而异,但介于 -1 到 1 之间的值应会降低或增加被选中的可能性;类似 -100 或 100 的值应会导致禁止或独占选择相应的 token。
- 例如,你可以传入 `{"50256": -100}` 以防止 词元被生成。
+ 例如,你可以传入 `{"50256": -100}` 以防止生成 token。
- `logprobs: optional number or null`
- 在 `logprobs` 最可能的输出词元以及所选词元上包含对数概率。例如,如果 `logprobs` 为 5,API 将返回一个包含 5 个最可能词元的列表。API 将始终返回所采样词元的 `logprob` ,因此响应中最多可能有 `logprobs+1` 个元素。
+ 在以下位置包含 log 概率: `logprobs` 最可能的输出 token,以及所选 token。例如,如果 `logprobs` 为 5,API 将返回 5 个最可能 token 的列表。API 将始终返回 `logprob` 采样 token 的 ,因此响应中最多可能有 `logprobs+1` 个元素。
的最大值为 `logprobs` 5。
- `max_tokens: optional number or null`
- 可在完成中生成的最大 [词元](/tokenizer) 数。
+ 可在补全中生成的最大 [token 数](/tokenizer) 。
- 你的提示的词元数加上 `max_tokens` 不能超过模型的上下文长度。 [用于计算词元的 Python 示例代码](https://cookbook.openai.com/examples/how_to_count_tokens_with_tiktoken) 。
+ 你的提示词的 token 数加上 `max_tokens` 不能超过模型的上下文长度。 [用于统计 token 的 Python 代码示例](https://cookbook.openai.com/examples/how_to_count_tokens_with_tiktoken) 。
- `n: optional number or null`
- 为每个提示生成的完成数。
+ 为每个提示词生成多少条补全。
- **注意:** 由于此参数会生成大量补全,可能会迅速消耗你的 token 配额。请谨慎使用,并确保你对 `max_tokens` 和 `stop`.
+ **注意:** 由于该参数会生成大量补全,可能会迅速消耗你的 token 配额。请谨慎使用,并确保为 `max_tokens` 和 `stop`.
- `presence_penalty: optional number or null`
- 介于 -2.0 和 2.0 之间的数值。正值会根据新 token 是否已在迄今为止的文本中出现来对其进行惩罚,从而提高模型谈论新主题的可能性。
+ 介于 -2.0 和 2.0 之间的数字。正值会根据新 token 是否已出现在文本中来对其进行惩罚,从而增加模型谈论新话题的可能性。
- [查看有关频率和存在惩罚的更多信息。](/docs/guides/text-generation)
+ [查看有关频率惩罚和存在惩罚的更多信息。](/docs/guides/text-generation)
- `seed: optional number or null`
- 如果指定,我们的系统将尽最大努力进行确定性采样,使得在相同参数下重复发起的请求 `seed` 应返回相同的结果。
+ 如果指定,我们的系统将尽最大努力进行确定性采样,以便在相同 `seed` 和参数下重复请求时返回相同的结果。
- 无法保证完全确定性,你可以参考 `system_fingerprint` 响应参数来监测后端的变化。
+ 确定性无法保证,你可以参考 `system_fingerprint` 响应参数来监控后端的变化。
- `stop: optional string or array of string or null`
- 最新的推理模型不支持该参数 `o3` 和 `o4-mini`.
+ 最新的推理模型不支持此参数 `o3` 和 `o4-mini`.
- 最多 4 个序列,当出现这些序列时,API 将停止生成更多 token。
- 返回的文本不会包含停止序列。
+ 最多 4 个序列,当 API 遇到这些序列时将停止生成更多 token。返回
+ 的文本不会包含停止序列。
- `string`
@@ -109,60 +109,60 @@
- `stream: optional boolean or null`
- 是否流式返回部分进度。如果启用,token 将以仅含数据的 [服务端发送事件](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format) 在数据可用时,流以一条 `data: [DONE]` 消息结束。 [用于计算词元的 Python 示例代码](https://cookbook.openai.com/examples/how_to_stream_completions).
+ 是否流式返回部分进度。如果设置,token 将以仅数据 [服务端发送事件](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format) 的形式在可用时发送,流以一条 `data: [DONE]` 消息终止。 [用于统计 token 的 Python 代码示例](https://cookbook.openai.com/examples/how_to_stream_completions).
- `stream_options: optional ChatCompletionStreamOptions or null`
- 流式响应的选项。仅在你设置 `stream: true`.
+ 流式响应的选项。仅当你设置 `stream: true`.
- `include_obfuscation: optional boolean`
- 为 true 时,将启用流混淆。流混淆会向流式增量事件上的
- 字段添加随机字符,以 `obfuscation` 规整负载大小,作为针对某些侧信道攻击的缓解措施。
- 这些混淆字段默认包含在内,但会给数据流带来少量。
- 开销。你可以将
- 设置为 `include_obfuscation` 以
- 如果信任你的应用与 OpenAI API 之间的网络链路,则可设为 false 以优化带宽。
- 你的应用与 该公司 接口 之间的。
+ 时启用。启用后,将向流式 delta 事件的
+ 字段添加 `obfuscation` 随机字符,以
+ 规整负载大小,作为对某些侧信道攻击的缓解措施。
+ 这些混淆字段默认包含,但会给数据流带来少量
+ 开销。你可以将 `include_obfuscation` 设置为
+ 在信任你的应用与
+ OpenAI API 之间的网络链路时,设为 false 以优化带宽。
- `include_usage: optional boolean`
- 如果设置,则会在之前流式传输一个额外的分块 `data: [DONE]`
- 消息。该分块的 `usage` 字段会显示整个请求的 token 使用统计信息,
- 整个请求的 token 使用情况,并且该 `choices` 字段将始终为空
+ 如果设置,将在 `data: [DONE]`
+ 消息之前流式传输一个额外的数据块。该 `usage` 字段表示整个请求的 token 用量统计,
+ 而该 `choices` 字段将始终为空
数组。
- 所有其他分块也会包含一个 `usage` 字段,但其值为 null
- 值。 **注意:** 如果流被中断,你可能无法收到包含该请求总 token 用量的
- 最后一个用量数据块。
+ 所有其他数据块也会包含一个 `usage` 字段,但值为 null
+ 。 **注意:** 如果流被中断,你可能无法收到
+ 包含该请求总 token 用量的最终用量数据块。
- `suffix: optional string or null`
插入文本补全之后的后缀。
- 此参数仅受支持于 `gpt-3.5-turbo-instruct`.
+ 该参数仅在以下模型中支持: `gpt-3.5-turbo-instruct`.
- `temperature: optional number or null`
- 使用的采样温度,介于 0 和 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加集中和确定。
+ 使用的采样温度,介于 0 和 2 之间。较高的值(如 0.8)会使输出更随机,而较低的值(如 0.2)会使输出更聚焦、更确定。
- 我们通常建议更改此参数或 `top_p` ,但不要同时更改两者。
+ 我们通常建议修改此参数或 `top_p` ,但不要同时修改两者。
- `top_p: optional number or null`
- 一种替代的温度采样方法,称为核采样,其中模型会考虑具有 top_p 概率质量的 token 的结果。因此 0.1 表示仅考虑构成前 10% 概率质量的 token。
+ 一种替代温度采样的方法,称为核采样(nucleus sampling),模型只考虑具有 top_p 概率质量的 token 的结果。因此 0.1 表示仅考虑构成前 10% 概率质量的 token。
- 我们通常建议更改此参数或 `temperature` ,但不要同时更改两者。
+ 我们通常建议修改此参数或 `temperature` ,但不要同时修改两者。
- `user: optional string`
- 用于表示你终端用户的唯一标识符,可以帮助 OpenAI 监控和检测滥用行为。 [了解更多](/docs/guides/safety-best-practices#end-user-ids).
+ 一个用于标识你最终用户的唯一标识符,可帮助 OpenAI 监控并检测滥用行为。 [了解更多](/docs/guides/safety-best-practices#end-user-ids).
### Returns
- `Completion object { id, choices, created, 4 more }`
- 表示来自 API 的补全响应。注意:流式和非流式响应对象共享相同的结构(与 chat 端点不同)。
+ 表示来自 API 的补全响应。注意:流式和非流式响应对象共享相同的结构(与对话端点不同)。
- `id: string`
@@ -170,13 +170,13 @@
- `choices: array of CompletionChoice`
- 模型针对输入提示所生成的补全选项列表。
+ 模型为输入提示生成的补全选项列表。
- `finish_reason: "stop" or "length" or "content_filter"`
- 模型停止生成 token 的原因。该值将 `stop` 如果模型遇到了自然停止点或提供了停止序列,
- `length` 如果达到了请求中指定的最大 token 数,
- 或者 `content_filter` 如果由于我们内容过滤器的标记而省略了内容。
+ 模型停止生成令牌的原因。该值为 `stop` 表示模型到达自然停止点或命中提供的停止序列,
+ `length` 表示已达到请求中指定的最大 token 数,
+ 或 `content_filter` 表示由于我们的内容过滤器标记而省略了内容。
- `"stop"`
@@ -200,7 +200,7 @@
- `created: number`
- 创建补全时的 Unix 时间戳(以秒为单位)。
+ 补全创建时的 Unix 时间戳(以秒为单位)。
- `model: string`
@@ -214,82 +214,78 @@
- `system_fingerprint: optional string`
- 此指纹表示模型运行所使用后端配置。
+ 此指纹表示模型运行所使用的后端配置。
- 可与以下请求参数结合使用, `seed` 以了解何时进行了可能影响确定性的后端更改。
+ 可与 `seed` 请求参数结合使用,以了解后端何时发生可能影响确定性的更改。
- `usage: optional CompletionUsage`
- 补全请求的使用统计信息。
+ 补全请求的使用情况统计信息。
- `completion_tokens: number`
- 生成的补全中的 token 数。
+ 生成补全中的令牌数量。
- `prompt_tokens: number`
- 提示中的 token 数。
+ 提示中的令牌数量。
- `total_tokens: number`
- 请求中使用的总 token 数(提示 + 补全)。
+ 请求中使用的令牌总数(提示 + 补全)。
- `completion_tokens_details: optional object { accepted_prediction_tokens, audio_tokens, reasoning_tokens, 2 more }`
- 补全中使用的 token 明细。
+ 补全中使用的令牌细分。
- `accepted_prediction_tokens: optional number`
- 使用 Predicted Outputs 时,下面的 token 数
- completion 中出现的预测 token。
+ 使用 Predicted Outputs 时,以下内容中的令牌数量:
+ 出现在补全中的预测 token。
- `audio_tokens: optional number`
- 模型生成的音频输入 token。
+ 由模型生成的音频输入 token。
- `reasoning_tokens: optional number`
- 模型用于推理生成的 token。
+ 模型为推理生成的 token。
- `rejected_prediction_tokens: optional number`
- 使用 Predicted Outputs 时,下面的 token 数
- 未在 completion 中出现的预测 token。然而,与
- 推理 token 一样,这些 token 仍会计入用于计费、输出和上下文窗口
- 的 total completion tokens 中。
- 限制。
+ 使用 Predicted Outputs 时,以下内容中的令牌数量:
+ 未出现在补全中的预测 token。但是,与
+ 推理 token 一样,这些 token 仍会计入用于计费、
+ 输出和上下文窗口限制的补全 token 总数中
+ 的限制。
- `text_tokens: optional number`
- 模型生成的文本输出 token。
-
- - `compute_units: optional number or null`
-
- 请求的计算单元。当前可用时为 null。
+ 由模型生成的文本输出 token。
- `prompt_tokens_details: optional object { audio_tokens, cache_write_tokens, cached_tokens, 2 more }`
- 提示中使用的 token 明细。
+ 提示词中使用的 token 明细。
- `audio_tokens: optional number`
- 提示中存在的音频输入 token。
+ 提示词中出现的音频输入 token。
- `cache_write_tokens: optional number`
- 写入缓存的未调整提示 token 数。
+ 写入缓存的未调整提示词 token 数。
- `cached_tokens: optional number`
- 提示中存在的已缓存 token。
+ 提示词中出现的已缓存 token。
- `image_tokens: optional number`
- 提示中存在的图像输入 token。
+ 提示词中出现的图像输入 token。
- `text_tokens: optional number`
- 提示中存在的文本输入 token。
+ 提示词中出现的文本输入 token。
### 示例
@@ -352,7 +348,6 @@ curl https://api.openai.com/v1/completions \
"rejected_prediction_tokens": 0,
"text_tokens": 0
},
- "compute_units": 0,
"prompt_tokens_details": {
"audio_tokens": 0,
"cache_write_tokens": 0,
diff --git a/docs/zh/api/reference/resources/responses.md b/docs/zh/api/reference/resources/responses.md
index bbae6c6..6aa60e0 100644
--- a/docs/zh/api/reference/resources/responses.md
+++ b/docs/zh/api/reference/resources/responses.md
@@ -1,20 +1,20 @@
# Responses
-> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。如需获取文档页面的 Markdown 版本,可在页面 URL 后追加 `.md` 。
+> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。可通过在页面 URL 末尾附加 `.md` 来获取文档页面的 Markdown 版本。
## 取消响应
**post** `/responses/{response_id}/cancel`
-取消具有给定 ID 的模型响应。仅可取消使用
-该 `background` 参数设置为 `true` 创建的响应。
+取消具有指定 ID 的模型响应。仅当使用
+该 `background` 参数设置为 `true` 时,响应才可以被取消。
[了解更多](/docs/guides/background).
### 路径参数
- `response_id: string`
-### 返回
+### 返回值
- `Response object { id, created_at, error, 32 more }`
@@ -24,7 +24,7 @@
- `created_at: number`
- 创建此 Response 时的 Unix 时间戳(以秒为单位)。
+ 此 Response 创建时的 Unix 时间戳(以秒为单位)。
- `error: ResponseError or null`
@@ -80,87 +80,89 @@
- `incomplete_details: object { reason } or null`
- 有关响应未完成原因的详细信息。
+ 有关响应不完整的详细原因。
- - `reason: optional "max_output_tokens" or "content_filter"`
+ - `reason: optional "max_output_tokens" or "max_messages" or "content_filter"`
- 响应未完成的原因。
+ 响应不完整的原因。
- `"max_output_tokens"`
+ - `"max_messages"`
+
- `"content_filter"`
- `instructions: string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more or null`
插入到模型上下文中的系统(或开发者)消息。
- 当与 `previous_response_id`,配合使用时,前一次
- 响应的指令不会延续到下一次响应。这便于在新响应中
- 替换系统(或开发者)消息。
+ 当与 `previous_response_id`,配合使用时,上一个
+ response 中的 instructions 不会延续到下一个 response。这样可以轻松地
+ 在新的 response 中替换系统(或开发者)消息。
- `string`
- 发送给模型的文本输入,相当于使用
+ 发送给模型的文本输入,等同于
`developer` 角色的文本输入。
- `InputItemList = array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 发送给模型的一个或多个输入项的列表,包含
+ 发送给模型的一个或多个输入项列表,包含
不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` role. Messages with the
- `assistant` role are presumed to have been generated by the model in previous
- interactions.
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色给出的指令。带有
+ `assistant` 角色的消息被视为模型在之前的
+ 交互中生成。
- `content: string or ResponseInputMessageContentList`
- Text, image, or audio input to the model, used to generate a response.
- Can also contain previous assistant responses.
+ 发送给模型的文本、图像或音频输入,用于生成响应。
+ 也可以包含之前的助手响应。
- `TextInput = string`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputMessageContentList = array of ResponseInputContent`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -172,25 +174,25 @@
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -200,13 +202,13 @@
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -216,33 +218,33 @@
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `assistant`, `system`, or
+ 消息输入的角色。其一为 接口 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -255,9 +257,9 @@
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -265,24 +267,24 @@
- `type: optional "message"`
- 消息输入的类型。始终为 `message`.
+ 消息输入的类型。始终为 接口 `message`.
- `"message"`
- `Message object { content, role, status, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` 角色的文本输入。
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色的文本输入。
- `content: ResponseInputMessageContentList`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `system`, or `developer`.
+ 消息输入的角色。其一为 接口 `user`, `system`,或 `developer`.
- `"user"`
@@ -292,8 +294,8 @@
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -313,7 +315,7 @@
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -321,15 +323,15 @@
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -345,7 +347,7 @@
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -355,25 +357,25 @@
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -385,7 +387,7 @@
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -393,11 +395,11 @@
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -451,15 +453,15 @@
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -471,8 +473,8 @@
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -488,9 +490,9 @@
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -498,8 +500,8 @@
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -511,7 +513,7 @@
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -536,11 +538,11 @@
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -558,7 +560,7 @@
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -567,7 +569,7 @@
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -579,7 +581,7 @@
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -595,8 +597,8 @@
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -620,7 +622,7 @@
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -634,7 +636,7 @@
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -660,7 +662,7 @@
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -678,7 +680,7 @@
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -697,7 +699,7 @@
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -707,11 +709,11 @@
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -731,15 +733,15 @@
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -771,19 +773,19 @@
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -807,8 +809,8 @@
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -824,7 +826,7 @@
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -840,7 +842,7 @@
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -848,44 +850,44 @@
- `ComputerCallOutput object { call_id, output, type, 3 more }`
- 一次 computer 工具调用的输出。
+ 计算机工具调用的输出。
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `id: optional string or null`
- computer 工具调用输出的 ID。
+ 计算机工具调用输出的 ID。
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 已被开发者确认的 API 所报告的安全检查结果。
+ 开发者已确认的 API 所报告的安全检查。
- `id: string`
@@ -901,7 +903,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值为 `in_progress`, `completed`, or `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -912,7 +914,7 @@
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -920,12 +922,12 @@
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -935,11 +937,11 @@
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -957,7 +959,7 @@
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -971,7 +973,7 @@
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -989,7 +991,7 @@
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -1001,14 +1003,14 @@
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -1058,8 +1060,8 @@
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -1073,7 +1075,7 @@
- `output: string or array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的文本、图片或文件输出。
+ 函数工具调用的文本、图像或文件输出。
- `string`
@@ -1081,61 +1083,61 @@
- `array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的内容输出(文本、图片、文件)数组。
+ 函数工具调用的内容输出(文本、图像、文件)数组。
- `ResponseInputTextContent object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision)
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `detail: optional ImageDetail or null`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -1145,13 +1147,13 @@
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -1165,23 +1167,23 @@
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -1193,7 +1195,7 @@
- `id: optional string or null`
- 函数工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
+ 函数工具调用输出的唯一 ID。当此项通过 API 返回时填充。
- `call_id: optional string or null`
@@ -1233,7 +1235,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -1249,7 +1251,7 @@
- `type: "tool_search_call"`
- 条目类型。始终为 `tool_search_call`.
+ 项的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
@@ -1317,37 +1319,37 @@
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -1360,11 +1362,11 @@
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -1384,7 +1386,7 @@
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -1400,15 +1402,15 @@
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -1422,7 +1424,7 @@
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -1430,7 +1432,7 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -1442,7 +1444,7 @@
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -1450,21 +1452,21 @@
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -1490,18 +1492,18 @@
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -1509,22 +1511,22 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -1534,23 +1536,23 @@
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -1561,11 +1563,11 @@
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -1583,21 +1585,21 @@
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -1605,14 +1607,14 @@
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -1644,32 +1646,32 @@
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -1677,13 +1679,13 @@
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -1691,9 +1693,9 @@
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -1705,22 +1707,22 @@
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -1729,7 +1731,7 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -1739,7 +1741,7 @@
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -1769,29 +1771,29 @@
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -1827,7 +1829,7 @@
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -1837,11 +1839,11 @@
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -1851,7 +1853,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -1859,7 +1861,7 @@
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -1868,13 +1870,13 @@
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -1883,7 +1885,7 @@
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -1910,7 +1912,7 @@
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -1921,7 +1923,7 @@
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -1938,13 +1940,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -1960,7 +1962,7 @@
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -1970,7 +1972,7 @@
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -1994,7 +1996,7 @@
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -2018,13 +2020,13 @@
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -2048,7 +2050,7 @@
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -2056,13 +2058,13 @@
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -2082,7 +2084,7 @@
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -2094,13 +2096,13 @@
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -2114,11 +2116,11 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -2144,7 +2146,7 @@
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -2162,7 +2164,7 @@
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -2176,19 +2178,19 @@
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -2208,19 +2210,19 @@
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -2228,11 +2230,11 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -2278,7 +2280,7 @@
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -2290,11 +2292,11 @@
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -2308,7 +2310,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -2318,7 +2320,7 @@
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -2328,23 +2330,23 @@
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -2362,13 +2364,13 @@
- `type: "tool_search_output"`
- 条目类型。始终为 `tool_search_output`.
+ 项的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `id: optional string or null`
- 此工具搜索输出的唯一 ID。
+ 该工具搜索输出的唯一 ID。
- `call_id: optional string or null`
@@ -2396,13 +2398,13 @@
- `role: "developer"`
- 提供其他工具的角色。仅 `developer` 受支持。
+ 提供这些额外工具的角色。仅支持 `developer` 。
- `"developer"`
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 此项目提供的其他工具列表。
+ 在该条目中提供的额外工具列表。
- `Function object { name, parameters, strict, 5 more }`
@@ -2436,45 +2438,45 @@
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -2482,7 +2484,7 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -2494,7 +2496,7 @@
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -2502,21 +2504,21 @@
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -2542,18 +2544,18 @@
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -2561,22 +2563,22 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -2586,23 +2588,23 @@
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -2613,11 +2615,11 @@
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -2635,21 +2637,21 @@
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -2657,14 +2659,14 @@
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -2696,32 +2698,32 @@
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -2729,13 +2731,13 @@
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -2743,9 +2745,9 @@
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -2757,22 +2759,22 @@
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -2781,7 +2783,7 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -2791,7 +2793,7 @@
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -2847,7 +2849,7 @@
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -2857,11 +2859,11 @@
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -2871,7 +2873,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -2879,7 +2881,7 @@
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -2888,13 +2890,13 @@
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -2903,7 +2905,7 @@
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -2930,7 +2932,7 @@
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -2941,7 +2943,7 @@
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -2958,13 +2960,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -2980,7 +2982,7 @@
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -2990,7 +2992,7 @@
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -3016,11 +3018,11 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -3046,19 +3048,19 @@
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -3078,19 +3080,19 @@
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -3098,11 +3100,11 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -3148,7 +3150,7 @@
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -3160,11 +3162,11 @@
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -3178,7 +3180,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -3188,7 +3190,7 @@
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -3198,23 +3200,23 @@
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -3232,19 +3234,19 @@
- `type: "additional_tools"`
- 条目类型。始终为 `additional_tools`.
+ 项的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `id: optional string or null`
- 此其他工具项目的唯一 ID。
+ 该额外工具条目的唯一 ID。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -3257,7 +3259,7 @@
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -3277,7 +3279,7 @@
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -3287,20 +3289,20 @@
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -3310,7 +3312,7 @@
- `Compaction object { encrypted_content, type, id }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -3318,17 +3320,17 @@
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `id: optional string or null`
- 压缩条目的 ID。
+ 压缩项的 ID。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -3352,7 +3354,7 @@
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -3375,7 +3377,7 @@
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -3387,23 +3389,23 @@
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -3421,13 +3423,13 @@
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -3443,11 +3445,11 @@
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -3461,11 +3463,11 @@
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -3479,7 +3481,7 @@
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -3489,7 +3491,7 @@
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -3497,13 +3499,13 @@
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -3517,7 +3519,7 @@
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
@@ -3529,7 +3531,7 @@
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最大挂钟时间(毫秒)。
+ 允许 shell 命令运行的 wall-clock 最长时间(毫秒)。
- `call_id: string`
@@ -3537,13 +3539,13 @@
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
- `id: optional string or null`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -3579,7 +3581,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -3589,7 +3591,7 @@
- `ShellCallOutput object { call_id, output, type, 4 more }`
- shell 工具调用发出的流式输出项。
+ shell 工具调用发出的流式输出条目。
- `call_id: string`
@@ -3597,7 +3599,7 @@
- `output: array of ResponseFunctionShellCallOutputContent`
- stdout 和 stderr 输出的捕获块及其关联结果。
+ 捕获的 stdout 和 stderr 输出块,以及它们关联的结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -3609,13 +3611,13 @@
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -3623,27 +3625,27 @@
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
- `stderr: string`
- shell 调用捕获的 stderr 输出。
+ 为该 shell 调用捕获的 stderr 输出。
- `stdout: string`
- shell 调用捕获的 stdout 输出。
+ 为该 shell 调用捕获的 stdout 输出。
- `type: "shell_call_output"`
- 条目的类型,恒为 `shell_call_output`.
+ item 的类型。始终为 `shell_call_output`.
- `"shell_call_output"`
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -3685,11 +3687,11 @@
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 表示使用 diff 补丁创建、删除或更新文件的工具调用。
+ 表示通过 diff 补丁创建、删除或更新文件的工具调用。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
@@ -3701,7 +3703,7 @@
- `diff: string`
- 创建文件时要应用的统一 diff 内容。
+ 创建文件时应用的 unified diff 内容。
- `path: string`
@@ -3733,7 +3735,7 @@
- `diff: string`
- 要应用于现有文件的统一 diff 内容。
+ 应用于现有文件的 unified diff 内容。
- `path: string`
@@ -3747,7 +3749,7 @@
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -3755,13 +3757,13 @@
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
- `id: optional string or null`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -3789,15 +3791,15 @@
- `ApplyPatchCallOutput object { call_id, status, type, 3 more }`
- apply patch 工具调用发出的流式输出。
+ 由 apply patch 工具调用发出的流式输出。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -3805,13 +3807,13 @@
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
- `id: optional string or null`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -3867,7 +3869,7 @@
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -3875,29 +3877,29 @@
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -3905,31 +3907,31 @@
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { approval_request_id, approve, type, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
- `id: optional string or null`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `reason: optional string or null`
@@ -3937,7 +3939,7 @@
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -3945,11 +3947,11 @@
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -3957,14 +3959,14 @@
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -4004,7 +4006,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -4018,11 +4020,11 @@
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 由你的代码生成的自定义工具调用输出,将被发送回模型。
+ 由你的代码生成的自定义工具调用的输出,将发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -4039,11 +4041,11 @@
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -4057,7 +4059,7 @@
- `id: optional string`
- 自定义工具调用输出在 OpenAI 平台中的唯一 ID。
+ 在 OpenAI 平台中该自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -4107,7 +4109,7 @@
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -4135,11 +4137,11 @@
- `CompactionTrigger object { type, id }`
- 压缩当前上下文。必须是最后一个输入项。
+ 压缩当前上下文。必须作为最后一个输入项。
- `type: "compaction_trigger"`
- 条目的类型,恒为 `compaction_trigger`.
+ item 的类型。始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -4153,11 +4155,11 @@
- `id: string`
- 要引用的条目 ID。
+ 被引用条目的 ID。
- `type: optional "item_reference" or null`
- 要引用的条目类型。始终为 `item_reference`.
+ 被引用条目的类型。始终为 `item_reference`.
- `"item_reference"`
@@ -4173,7 +4175,7 @@
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -4181,7 +4183,7 @@
- `type: "program"`
- 条目类型。始终为 `program`.
+ 项的类型。始终为 `program`.
- `"program"`
@@ -4197,7 +4199,7 @@
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -4209,14 +4211,14 @@
- `type: "program_output"`
- 条目类型。始终为 `program_output`.
+ 项的类型。始终为 `program_output`.
- `"program_output"`
- `metadata: Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
格式,以及通过 API 或控制台查询对象。
键为字符串,最长 64 个字符。值为字符串
@@ -4225,8 +4227,8 @@
- `model: ResponsesModel`
用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI
- 提供了多种不同能力、性能
- 特性和定价的模型。请参阅 [模型指南](/docs/models)
+ 提供了众多功能、性能
+ 特性和价位各异的模型。请参阅 [模型指南](/docs/models)
以浏览和比较可用的模型。
- `string`
@@ -4449,12 +4451,12 @@
由模型生成的内容项数组。
- - 该数组中项的数量和顺序 `output` 取决于
- 模型的响应。
- - 与直接访问该数组的 `output` 第一项并
- 假设它是一 `assistant` 个包含模型生成内容的
- 消息相比,你也可以考虑使用 `output_text` 属性(在
- 受支持的 SDK 中可用)。
+ - 该数组中项的长度和顺序取决于 `output` 模型的响应。
+ 与其访问。
+ - 数组中的第一项并 `output` 假设它是一个
+ 包含模型生成内容的 `assistant` 消息,不如使用
+ 属性(在受支持的 开发工具包 `output_text` 中可用)。
+ SDK。
- `ResponseOutputMessage object { id, content, role, 3 more }`
@@ -4462,8 +4464,8 @@
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -4475,7 +4477,7 @@
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -4500,11 +4502,11 @@
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -4522,7 +4524,7 @@
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -4531,7 +4533,7 @@
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -4581,8 +4583,8 @@
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -4607,15 +4609,15 @@
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -4623,8 +4625,8 @@
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -4668,7 +4670,7 @@
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `name: optional string`
@@ -4681,7 +4683,7 @@
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -4689,12 +4691,12 @@
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -4704,11 +4706,11 @@
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -4726,7 +4728,7 @@
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -4740,7 +4742,7 @@
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -4758,7 +4760,7 @@
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -4770,14 +4772,14 @@
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -4789,7 +4791,7 @@
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -4805,8 +4807,8 @@
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -4826,8 +4828,8 @@
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `ComputerCallOutput object { id, call_id, output, 4 more }`
@@ -4837,16 +4839,16 @@
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"completed"`
@@ -4858,13 +4860,13 @@
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、已被
+ API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -4881,13 +4883,13 @@
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -4900,7 +4902,7 @@
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -4918,7 +4920,7 @@
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -4928,20 +4930,20 @@
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -4961,7 +4963,7 @@
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -4969,7 +4971,7 @@
- `type: "program"`
- 条目的类型,恒为 `program`.
+ item 的类型。始终为 `program`.
- `"program"`
@@ -4985,7 +4987,7 @@
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -4997,7 +4999,7 @@
- `type: "program_output"`
- 条目的类型,恒为 `program_output`.
+ item 的类型。始终为 `program_output`.
- `"program_output"`
@@ -5035,13 +5037,13 @@
- `type: "tool_search_call"`
- 条目的类型,恒为 `tool_search_call`.
+ item 的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -5107,45 +5109,45 @@
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -5153,7 +5155,7 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -5165,7 +5167,7 @@
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -5173,21 +5175,21 @@
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -5213,18 +5215,18 @@
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -5232,22 +5234,22 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -5257,23 +5259,23 @@
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -5284,11 +5286,11 @@
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -5306,21 +5308,21 @@
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -5328,14 +5330,14 @@
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -5367,32 +5369,32 @@
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -5400,13 +5402,13 @@
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -5414,9 +5416,9 @@
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -5428,22 +5430,22 @@
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -5452,7 +5454,7 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -5462,7 +5464,7 @@
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -5518,7 +5520,7 @@
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -5528,11 +5530,11 @@
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -5542,7 +5544,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -5550,7 +5552,7 @@
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -5559,13 +5561,13 @@
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -5574,7 +5576,7 @@
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -5601,7 +5603,7 @@
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -5612,7 +5614,7 @@
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -5629,13 +5631,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -5651,7 +5653,7 @@
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -5661,7 +5663,7 @@
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -5687,11 +5689,11 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -5717,19 +5719,19 @@
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -5749,19 +5751,19 @@
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -5769,11 +5771,11 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -5819,7 +5821,7 @@
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -5831,11 +5833,11 @@
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -5849,7 +5851,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -5859,7 +5861,7 @@
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -5869,23 +5871,23 @@
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -5903,13 +5905,13 @@
- `type: "tool_search_output"`
- 条目的类型,恒为 `tool_search_output`.
+ item 的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -5939,7 +5941,7 @@
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -5973,45 +5975,45 @@
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -6019,7 +6021,7 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -6031,7 +6033,7 @@
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -6039,21 +6041,21 @@
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -6079,18 +6081,18 @@
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -6098,22 +6100,22 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -6123,23 +6125,23 @@
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -6150,11 +6152,11 @@
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -6172,21 +6174,21 @@
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -6194,14 +6196,14 @@
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -6233,32 +6235,32 @@
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -6266,13 +6268,13 @@
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -6280,9 +6282,9 @@
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -6294,22 +6296,22 @@
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -6318,7 +6320,7 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -6328,7 +6330,7 @@
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -6384,7 +6386,7 @@
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -6394,11 +6396,11 @@
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -6408,7 +6410,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -6416,7 +6418,7 @@
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -6425,13 +6427,13 @@
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -6440,7 +6442,7 @@
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -6467,7 +6469,7 @@
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -6478,7 +6480,7 @@
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -6495,13 +6497,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -6517,7 +6519,7 @@
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -6527,7 +6529,7 @@
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -6553,11 +6555,11 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -6583,19 +6585,19 @@
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -6615,19 +6617,19 @@
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -6635,11 +6637,11 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -6685,7 +6687,7 @@
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -6697,11 +6699,11 @@
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -6715,7 +6717,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -6725,7 +6727,7 @@
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -6735,23 +6737,23 @@
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -6769,13 +6771,13 @@
- `type: "additional_tools"`
- 条目的类型,恒为 `additional_tools`.
+ item 的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -6783,21 +6785,21 @@
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的已加密内容。
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -6821,7 +6823,7 @@
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -6844,7 +6846,7 @@
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -6856,23 +6858,23 @@
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -6890,13 +6892,13 @@
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -6912,11 +6914,11 @@
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -6930,11 +6932,11 @@
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -6948,7 +6950,7 @@
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -6958,7 +6960,7 @@
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -6966,13 +6968,13 @@
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -6986,17 +6988,17 @@
- `id: string`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -7034,7 +7036,7 @@
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -7044,7 +7046,7 @@
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -7078,7 +7080,7 @@
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。通过 API 返回该条目时填充此字段。
- `call_id: string`
@@ -7086,15 +7088,15 @@
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -7102,13 +7104,13 @@
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -7116,7 +7118,7 @@
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -7130,11 +7132,11 @@
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`, or `incomplete`.
+ shell 调用输出的状态。可选值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -7170,7 +7172,7 @@
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -7178,15 +7180,15 @@
- `id: string`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -7202,7 +7204,7 @@
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的 diff 创建新文件。
- `"create_file"`
@@ -7216,7 +7218,7 @@
- `type: "delete_file"`
- 删除指定的文件。
+ 删除指定文件。
- `"delete_file"`
@@ -7234,13 +7236,13 @@
- `type: "update_file"`
- 使用提供的差异更新现有文件。
+ 使用提供的 diff 更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -7248,7 +7250,7 @@
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -7278,19 +7280,19 @@
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -7298,7 +7300,7 @@
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -7332,7 +7334,7 @@
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -7340,11 +7342,11 @@
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -7352,14 +7354,14 @@
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -7371,7 +7373,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -7409,7 +7411,7 @@
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -7417,29 +7419,29 @@
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -7447,29 +7449,29 @@
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `id: string`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -7501,7 +7503,7 @@
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -7535,7 +7537,7 @@
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -7552,11 +7554,11 @@
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -7564,8 +7566,8 @@
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -7605,7 +7607,7 @@
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `parallel_tool_calls: boolean`
@@ -7613,8 +7615,8 @@
- `temperature: number or null`
- 使用的采样温度,介于 0 到 2 之间。较高的值(例如 0.8)会使输出更加随机,而较低的值(例如 0.2)会使输出更加聚焦和确定。
- 我们通常建议修改此参数或 `top_p` 但不要同时修改两者。
+ 使用的采样温度,介于 0 到 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加聚焦和确定性。
+ 我们通常建议调整此项或 `top_p` 但不要同时调整两者。
- `tool_choice: ToolChoiceOptions or ToolChoiceAllowed or ToolChoiceTypes or 6 more`
@@ -7624,9 +7626,9 @@
- `ToolChoiceOptions = "none" or "auto" or "required"`
- 控制模型调用哪个工具(如果有的话)。
+ 控制模型调用哪个工具(如果有)。
- `none` 表示模型不会调用任何工具,而是生成一条消息。
+ `none` 表示模型将不会调用任何工具,而是生成一条消息。
`auto` 表示模型可以在生成消息或调用一个或
多个工具之间进行选择。
@@ -7658,7 +7660,7 @@
- `tools: array of map[unknown]`
- 模型应允许调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -7679,11 +7681,11 @@
- `ToolChoiceTypes object { type }`
指示模型应使用内置工具来生成响应。
- [了解有关内置工具的更多信息](/docs/guides/tools).
+ [了解更多关于内置工具的信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
- 模型应使用的托管工具类型。了解更多关于
+ 模型应使用的 托管工具 类型。了解更多关于
[内置工具](/docs/guides/tools).
允许的值为:
@@ -7728,7 +7730,7 @@
- `ToolChoiceMcp object { server_label, type, name }`
- 使用此选项可以强制模型调用远程 MCP 服务器上的特定工具。
+ 使用此选项可强制模型调用远程 MCP 服务器上的特定工具。
- `server_label: string`
@@ -7746,7 +7748,7 @@
- `ToolChoiceCustom object { name, type }`
- 使用此选项可以强制模型调用特定的自定义工具。
+ 使用此选项可强制模型调用特定的自定义工具。
- `name: string`
@@ -7762,27 +7764,27 @@
- `type: "programmatic_tool_calling"`
- 要调用的工具。始终为 `programmatic_tool_calling`.
+ 要调用的工具。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ToolChoiceApplyPatch object { type }`
- 在执行工具调用时强制模型调用 apply_patch 工具。
+ 强制模型在执行工具调用时调用 apply_patch 工具。
- `type: "apply_patch"`
- 要调用的工具。始终为 `apply_patch`.
+ 要调用的工具。始终 `apply_patch`.
- `"apply_patch"`
- `ToolChoiceShell object { type }`
- 在需要工具调用时强制模型调用 shell 工具。
+ 在需要工具调用时,强制模型调用 shell 工具。
- `type: "shell"`
- 要调用的工具。始终为 `shell`.
+ 要调用的工具。始终 `shell`.
- `"shell"`
@@ -7793,18 +7795,18 @@
我们支持以下类别的工具:
- - **内置工具**:由 OpenAI 提供的工具,用于扩展模型的
- 能力,例如 [网页搜索](/docs/guides/tools-web-search)
+ - **内置工具**:由 OpenAI 提供的工具,用于扩展
+ 模型的能力,例如 [网页搜索](/docs/guides/tools-web-search)
或 [文件搜索](/docs/guides/tools-file-search)。详细了解
[内置工具](/docs/guides/tools).
- - **MCP 工具**:通过自定义 MCP 服务器与第三方系统集成
- 或 Google Drive 和 SharePoint 等预定义连接器。详细了解
+ - **MCP 工具**: 通过自定义 MCP 服务器与第三方系统集成
+ 或使用 Google Drive 和 SharePoint 等预定义连接器。详细了解
[MCP 工具](/docs/guides/tools-connectors-mcp).
- - **函数调用(自定义工具)**:由你定义的函数,
+ - **函数调用(自定义工具)**: 由你定义的函数,
使模型能够使用强类型参数和输出调用你自己的代码。详细了解
。你也可以使用
- [function calling](/docs/guides/function-calling)。你还可以使用
- 自定义工具调用你自己的代码。
+ [function calling](/docs/guides/function-calling). 你也可以使用
+ 自定义工具来调用你自己的代码。
- `Function object { name, parameters, strict, 5 more }`
@@ -7838,45 +7840,45 @@
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -7884,7 +7886,7 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -7896,7 +7898,7 @@
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -7904,21 +7906,21 @@
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -7944,18 +7946,18 @@
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -7963,22 +7965,22 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -7988,23 +7990,23 @@
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -8015,11 +8017,11 @@
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -8037,21 +8039,21 @@
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -8059,14 +8061,14 @@
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -8098,32 +8100,32 @@
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -8131,13 +8133,13 @@
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -8145,9 +8147,9 @@
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -8159,22 +8161,22 @@
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -8183,7 +8185,7 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -8193,7 +8195,7 @@
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -8249,7 +8251,7 @@
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -8259,11 +8261,11 @@
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -8273,7 +8275,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -8281,7 +8283,7 @@
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -8290,13 +8292,13 @@
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -8305,7 +8307,7 @@
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -8332,7 +8334,7 @@
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -8343,7 +8345,7 @@
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -8360,13 +8362,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -8382,7 +8384,7 @@
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -8392,7 +8394,7 @@
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -8418,11 +8420,11 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -8448,19 +8450,19 @@
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -8480,19 +8482,19 @@
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -8500,11 +8502,11 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -8550,7 +8552,7 @@
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -8562,11 +8564,11 @@
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -8580,7 +8582,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -8590,7 +8592,7 @@
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -8600,23 +8602,23 @@
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -8634,12 +8636,12 @@
- `top_p: number or null`
- 一种名为核采样的温度采样替代方案,
- 其中模型会考虑 top_p 概率质量排名前列的词元结果。
- 因此,0.1 表示仅考虑构成前 10% 概率质量的词元。
+ 一种温度采样的替代方法,称为核采样,
+ 模型会考虑概率质量排名前 top_p 的标记的结果。
+ 因此 0.1 表示仅考虑构成前 10% 概率质量的标记。
会被考虑。
- 我们通常建议修改此参数或 `temperature` 但不要同时修改两者。
+ 我们通常建议调整此项或 `temperature` 但不要同时调整两者。
- `background: optional boolean or null`
@@ -8648,44 +8650,44 @@
- `completed_at: optional number or null`
- 此 Response 完成时的 Unix 时间戳(以秒为单位)。
- 仅当状态为 `completed`.
+ 此响应完成时的 Unix 时间戳(以秒为单位)。
+ 仅在状态为 `completed`.
- `conversation: optional object { id } or null`
- 此响应所属的对话。此响应的输入项和输出项已自动添加到此对话。
+ 此响应所属的对话。此次响应的输入项和输出项已自动添加到此对话中。
- `id: string`
- 与此响应关联的对话的唯一 ID。
+ 此响应关联的对话的唯一 ID。
- `max_output_tokens: optional number or null`
- 一次响应中可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
+ 响应可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
- `max_tool_calls: optional number or null`
- 响应中可以处理的内置工具调用总次数上限。该上限适用于所有内置工具调用,而非单个工具。模型任何进一步的工具调用尝试都将被忽略。
+ 一次响应中可处理的内置工具调用总次数上限。该上限适用于所有内置工具调用的总和,而非单个工具。模型后续任何再次调用工具的尝试都将被忽略。
- `moderation: optional object { input, output } or null`
- 响应输入和输出的审核结果,前提是请求了已审核的补全。
+ 响应输入与输出的内容审核结果,前提是请求了经过审核的补全。
- `input: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输入的审核结果。
+ 对响应输入的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -8693,7 +8695,7 @@
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -8701,17 +8703,17 @@
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -8723,25 +8725,25 @@
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输出的审核结果。
+ 对响应输出的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -8749,7 +8751,7 @@
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -8757,17 +8759,17 @@
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -8779,21 +8781,21 @@
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output_text: optional string or null`
- 仅限SDK的便捷属性,包含所有输出消息中聚合的文本输出
- 来自所有 `output_text` 数组中的 `output` 条目(如果有)。
+ SDK 独有的便捷属性,包含来自所有
+ 的聚合文本输出 `output_text` 数组中的 `output` 条目(如有)。
在 Python 和 JavaScript SDK 中受支持。
- `previous_response_id: optional string or null`
- 模型上一次响应的唯一 ID。使用它来
- 创建多轮对话。了解有关
- [对话状态](/docs/guides/conversation-state)。的更多信息。不能与 `conversation`.
+ 上一个模型响应的唯一 ID。使用它可以
+ 创建多轮对话。详细了解
+ [conversation state](/docs/guides/conversation-state)。不能与 `conversation`.
- `prompt: optional ResponsePrompt or null`
@@ -8806,19 +8808,19 @@
- `variables: optional map[string or ResponseInputText or ResponseInputImage or ResponseInputFile] or null`
- 用于替换提示模板中变量的可选值映射,
- prompt。替换值可以是字符串,也可以是其他
- Response 输入类型,例如图像或文件。
+ 用于替换你
+ prompt。替换的值可以是字符串,也可以是其他
+ Response 输入类型,如图像或文件。
- `string`
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -8826,19 +8828,19 @@
- `version: optional string or null`
- 提示模板的可选版本。
+ prompt 模板的可选版本。
- `prompt_cache_key: optional string or null`
- 由 OpenAI 用于缓存相似请求的响应,以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
+ 由OpenAI使用,为相似请求缓存响应以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
- `prompt_cache_options: optional object { mode, ttl }`
- 应用于该响应的提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。
+ 应用于该响应的 prompt 缓存选项。支持以下 `gpt-5.6` 及更高版本的模型。
- `mode: "implicit" or "explicit"`
- 是否启用了隐式提示缓存断点。
+ 是否启用了隐式 prompt 缓存断点。
- `"implicit"`
@@ -8846,24 +8848,24 @@
- `ttl: "30m"`
- 应用于每个缓存断点的最短生存时间。
+ 应用于每个缓存断点的最短生命周期。
- `"30m"`
- `prompt_cache_retention: optional "in_memory" or "24h" or null`
- 已弃用。请使用 `prompt_cache_options.ttl` 相反。
+ 已弃用。请使用 `prompt_cache_options.ttl` 改为。
- 提示词缓存的保留策略。设置为 `24h` 以启用扩展提示词缓存,使缓存前缀保持更长时间,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
- 此字段表示最长保留策略,而
+ 提示缓存的保留策略。设置为 `24h` 以启用扩展提示缓存,使缓存的前缀保持更长时间有效,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
+ 该字段表示最大保留策略,而
`prompt_cache_options.ttl` 表示最短缓存生命周期。这两个
- 字段彼此独立,不会相互影响。
- 对于 `gpt-5.5`, `gpt-5.5-pro`,及未来模型,仅 `24h` 受支持。
+ 字段是独立的,不会相互影响。
+ 对于 `gpt-5.5`, `gpt-5.5-pro`,以及未来的模型,仅 `24h` 。
对于同时支持两者的旧模型 `in_memory` 和 `24h`,默认值取决于你组织的数据保留策略:
- - 未启用 ZDR 的组织默认使用 `24h`.
- - 启用 ZDR 的组织默认使用 `in_memory` 当 `prompt_cache_retention` 未指定时。
+ - 未启用 ZDR 的组织默认为 `24h`.
+ - 启用 ZDR 的组织默认为 `in_memory` 当 `prompt_cache_retention` 未指定时。
- `"in_memory"`
@@ -8871,18 +8873,18 @@
- `reasoning: optional Reasoning or null`
- 配置选项,适用于
+ 适用于
[推理模型](https://platform.openai.com/docs/guides/reasoning).
- `context: optional "auto" or "current_turn" or "all_turns" or null`
- 控制在后续轮次中呈现回模型的推理项。
- 如果省略或设置为 `auto`,则由模型确定上下文模式。
+ 控制在后续回合中哪些推理项会被回传给模型。
+ 如果省略或设置为 `auto`,则由模型决定上下文模式。
`gpt-5.6` 模型系列默认为 `all_turns`;早期模型默认为
`current_turn`.
- 在响应中返回时,这是该响应使用的有效推理上下文模式
- 。
+ 在响应中返回时,这是该响应所使用 的有效推理上下文模式
+ 用于该响应。
- `"auto"`
@@ -8892,13 +8894,13 @@
- `effort: optional ReasoningEffort or null`
- 限制推理模型在推理上的投入程度。当前支持的值
- 包括 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
- 降低推理投入程度可以让响应更快,并减少响应中推理所用的 token 数。并非所有推理模型都支持每个
- 值。请参阅
- 推理指南
+ 限制推理模型在推理上的投入程度。目前支持
+ 的取值有 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
+ 降低推理投入程度可以让响应更快,并减少响应中用于推理的 token
+ 数量。并非所有推理模型都支持每个
+ 取值。有关各模型的支持情况,请参阅
[推理指南](https://platform.openai.com/docs/guides/reasoning)
- 以了解特定模型的支持情况。
+ 。
- `"none"`
@@ -8916,11 +8918,11 @@
- `generate_summary: optional "auto" or "concise" or "detailed" or null`
- **已弃用:** 请使用 `summary` 相反。
+ **已弃用:** 请使用 `summary` 改为。
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `"auto"`
@@ -8932,7 +8934,7 @@
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `string`
@@ -8940,7 +8942,7 @@
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `"standard"`
@@ -8948,11 +8950,11 @@
- `summary: optional "auto" or "concise" or "detailed" or null`
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `concise` 支持以下模型 `computer-use-preview` 以及之后的所有推理模型 `gpt-5`.
+ `concise` 支持用于 `computer-use-preview` 模型以及之后的 `gpt-5`.
- `"auto"`
@@ -8962,21 +8964,21 @@
- `safety_identifier: optional string or null`
- 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用策略的应用程序用户。
- ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份识别信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用政策的应用用户。
+ ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `service_tier: optional ServiceTier or null`
指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
+ - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则该项目将使用 'default'。
- 如果设置为 'default',则该请求将使用所选模型的标准定价和性能进行处理。
- 如果设置为 '[flex](/docs/guides/flex-processing)',则该请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别选择启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 `service_tier=fast` 或 `service_tier=priority` 参数用于 Responses 或 Chat Completions。响应将显示 `service_tier=priority` ,无论你是否在请求中指定了 `service_tier=fast` 或 `priority` 。
- - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级返回的响应将显示 `service_tier=ultrafast`.
- - 如果未设置,默认行为是 'auto'。
+ - 若要在请求级别启用 [快速模式](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过它处理的响应将显示 `service_tier=ultrafast`.
+ - 未设置时,默认行为为 'auto'。
- 当设置 `service_tier` 参数时,响应正文将包含基于实际用于处理该请求的处理模式的 `service_tier` 值。此响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应体中将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。此响应中的值可能与该参数中设置的值不同。
- `"auto"`
@@ -8994,8 +8996,8 @@
- `status: optional ResponseStatus`
- 响应生成的状态。取值之一为 `completed`, `failed`,
- `in_progress`, `cancelled`, `queued`, or `incomplete`.
+ 响应生成的状态。可选值为 `completed`, `failed`,
+ `in_progress`, `cancelled`, `queued`,或 `incomplete`.
- `"completed"`
@@ -9011,8 +9013,8 @@
- `text: optional ResponseTextConfig`
- 用于配置模型文本响应的选项。可以是纯文本,也可以是结构化的 JSON 数据。详见:
- 文本输入与输出:
+ 模型文本响应的配置选项。可以是纯
+ 文本或结构化 JSON 数据。了解更多:
- [文本输入与输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
@@ -9021,79 +9023,79 @@
用于指定模型必须输出的格式的对象。
- 设置为 `{ "type": "json_schema" }` 时,将启用结构化输出,
- 功能,从而确保模型的输出与你提供的 JSON schema 相匹配。详见
+ 配置 `{ "type": "json_schema" }` 可启用结构化输出,
+ 从而确保模型匹配你提供的 JSON schema。更多信息请参阅
[结构化输出指南](/docs/guides/structured-outputs).
- 默认的格式为 `{ "type": "text" }` ,且不包含其他选项。
+ 默认格式为 `{ "type": "text" }` ,不包含任何额外选项。
- **不建议在 gpt-4o 及更新模型上使用:**
+ **不推荐用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
- 的模型,建议优先使用该格式。
+ 设置为 `{ "type": "json_object" }` 会启用旧版 JSON 模式,该模式
+ 可确保模型生成的消息是合法 JSON。对于支持 `json_schema`
+ 的模型,建议优先使用它。
- `ResponseFormatText object { type }`
- 默认的响应格式。用于生成文本响应。
+ 默认响应格式。用于生成文本响应。
- `type: "text"`
- 正在定义的响应格式的类型。始终为 `text`.
+ 正在定义的响应格式类型。始终为 `text`.
- `"text"`
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化的 JSON 响应。
+ JSON Schema 响应格式。用于生成结构化 JSON 响应。
详细了解 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
- 下划线和连字符,最大长度为 64。
+ 下划线和短横线,最大长度为 64。
- `schema: map[unknown]`
- 响应格式的 schema,以 JSON Schema 对象描述。
- 了解如何构建 JSON schema [此处](https://json-schema.org/).
+ 响应格式的架构,以 JSON Schema 对象形式描述。
+ 了解如何构建 JSON 架构 [此处](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式的类型。始终为 `json_schema`.
+ 正在定义的响应格式类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
响应格式用途的描述,供模型用于
- 确定如何按该格式进行响应。
+ 确定如何按该格式响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 一致性。
- 如果设置为 true,模型将始终遵循
- 字段中 `schema` 定义的精确 schema。仅支持 JSON Schema 的一个子集,当
- `strict` 是 `true`。要了解更多信息,请阅读 [Structured Outputs
+ 生成输出时是否启用严格的架构遵循。
+ 如果设置为 true,模型将始终遵循 字段中定义的
+ 确切架构。当 设置为 `schema` true 时,仅支持 JSON Schema 的一个子集
+ `strict` 是 `true`。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较早的生成 JSON 响应的方法。
- 使用 `json_schema` 对支持它的模型是推荐的做法。请注意
- 模型在没有系统或用户消息指示的情况下不会生成
- JSON。
+ JSON 对象响应格式。一种较旧的 JSON 响应生成方法。建议。
+ 对于支持 的模型,使用 `json_schema` 。请注意,模型不会在没有系统或用户消息指示
+ 的情况下生成 JSON
+ 。
- `type: "json_object"`
- 正在定义的响应格式的类型。始终为 `json_object`.
+ 正在定义的响应格式类型。始终为 `json_object`.
- `"json_object"`
- `verbosity: optional "low" or "medium" or "high" or null`
- 约束模型响应的详细程度。较低的值会产生
- 更简洁的响应,较高的值会产生更详细的响应。
+ 约束模型响应的详尽程度。较低的值将导致
+ 更简洁的响应,而较高的值将导致更冗长的响应。
当前支持的值包括 `low`, `medium`,和 `high`。默认值为
`medium`.
@@ -9105,20 +9107,20 @@
- `top_logprobs: optional number or null`
- 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的最大最可能
- token 数量,每个 token 都附带对应的对数
+ 一个介于 0 到 20 之间的整数,指定在每个 token 位置返回的
+ 最可能 token 的最大数量,每个 token 都有一个关联的对数
概率。在某些情况下,返回的 token 数量可能少于
- 所请求的数量。
+ 请求的数量。
- `truncation: optional "auto" or "disabled" or null`
用于模型响应的截断策略。
- - `auto`:如果此 Response 的输入超过
- 模型的上下文窗口大小,模型将通过从对话开头丢弃条目来截断
- 响应以适配上下文窗口。
- - `disabled` (默认):如果输入大小将超出模型的上下文窗口
- 大小,请求将失败并返回 400 错误。
+ - `auto`:如果此 Response 的输入超出
+ 模型的上下文窗口大小,模型将通过从对话开头
+ 丢弃条目来截断响应以适配上下文窗口。
+ - `disabled` (默认):如果输入大小将超过模型的上下文窗口
+ 大小,请求将以 400 错误失败。
- `"auto"`
@@ -9127,7 +9129,7 @@
- `usage: optional ResponseUsage`
表示 token 使用详情,包括输入 token、输出 token,
- 的输出 token 明细,以及所使用的 token 总数。
+ 输出 token 的细分,以及使用的总 token 数。
- `input_tokens: number`
@@ -9135,16 +9137,16 @@
- `input_tokens_details: object { cache_write_tokens, cached_tokens }`
- 输入 token 的详细明细。
+ 输入 token 的详细细分。
- `cache_write_tokens: number`
- 已写入缓存的输入 token 数量。
+ 写入缓存的输入 token 的数量。
- `cached_tokens: number`
- 从缓存中检索到的 token 数量。
- [了解更多关于提示缓存的信息](/docs/guides/prompt-caching).
+ 从缓存中检索到的 token 的数量。
+ [有关 prompt caching 的更多信息](/docs/guides/prompt-caching).
- `output_tokens: number`
@@ -9152,25 +9154,21 @@
- `output_tokens_details: object { reasoning_tokens }`
- 输出令牌的详细明细。
+ 输出 token 的详细明细。
- `reasoning_tokens: number`
- 推理令牌的数量。
+ 推理 token 的数量。
- `total_tokens: number`
- 使用的令牌总数。
-
- - `compute_units: optional number or null`
-
- 该请求的计算单元。在可用时当前为 null。
+ 使用的 token 总数。
- `user: optional string`
- 此字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
- 用于标识你的最终用户的稳定标识符。
- 通过更好地对相似请求进行分桶以提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 该字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
+ 你的最终用户的稳定标识符。
+ 通过更好地对相似请求进行分桶来提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
### 示例
@@ -9180,7 +9178,7 @@ curl https://api.openai.com/v1/responses/$RESPONSE_ID/cancel \
-H "Authorization: Bearer $OPENAI_API_KEY"
```
-#### 响应
+#### Response
```json
{
@@ -9346,8 +9344,7 @@ curl https://api.openai.com/v1/responses/$RESPONSE_ID/cancel \
"output_tokens_details": {
"reasoning_tokens": 0
},
- "total_tokens": 0,
- "compute_units": 0
+ "total_tokens": 0
},
"user": "user-1234"
}
@@ -9361,7 +9358,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
-H "Authorization: Bearer $OPENAI_API_KEY"
```
-#### 响应
+#### Response
```json
{
@@ -9418,19 +9415,19 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
**post** `/responses/compact`
-压缩一段对话。返回一个压缩后的响应对象。
+压缩一段对话。返回压缩后的响应对象。
-了解在对话状态指南中何时以及如何压缩长时间运行的对话 [对话状态指南](/docs/guides/conversation-state#managing-the-context-window)。有关兼容 ZDR 的压缩细节,请参阅 [压缩(进阶)](/docs/guides/conversation-state#compaction-advanced).
+了解何时以及如何在 [对话状态指南](/docs/guides/conversation-state#managing-the-context-window)。中压缩长对话。有关兼容 ZDR 的压缩详细信息,请参阅 [压缩(高级)](/docs/guides/conversation-state#compaction-advanced).
-### 请求体参数
+### 正文参数
- `model: "gpt-5.6-sol" or "gpt-5.6-terra" or "gpt-5.6-luna" or 99 more or string or null`
- 用于生成响应的模型 ID,例如 `gpt-5.6-sol`. OpenAI 提供一系列具有不同能力、性能特征和价格点的模型。请参阅 [模型指南](/docs/models) 以浏览和比较可用的模型。
+ 用于生成响应的模型 ID,例如 `gpt-5.6-sol`. OpenAI 提供多种不同能力、性能特征和价格的模型。请参阅 [模型指南](/docs/models) 以浏览和比较可用的模型。
- `"gpt-5.6-sol" or "gpt-5.6-terra" or "gpt-5.6-luna" or 99 more`
- 用于生成响应的模型 ID,例如 `gpt-5.6-sol`. OpenAI 提供一系列具有不同能力、性能特征和价格点的模型。请参阅 [模型指南](/docs/models) 以浏览和比较可用的模型。
+ 用于生成响应的模型 ID,例如 `gpt-5.6-sol`. OpenAI 提供多种不同能力、性能特征和价格的模型。请参阅 [模型指南](/docs/models) 以浏览和比较可用的模型。
- `"gpt-5.6-sol"`
@@ -9640,69 +9637,69 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `input: optional string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more or null`
- 提供给模型的文本、图像或文件输入,用于生成响应
+ 模型的文本、图像或文件输入,用于生成响应
- `string`
- 发送给模型的文本输入,相当于使用 `user` 角色的文本输入。
+ 发送给模型的文本输入,等同于 `user` 角色的文本输入。
- `array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 包含一个或多个输入条目的列表,用于模型,包含不同的内容类型。
+ 包含一项或多项输入项的列表,可包含不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` role. Messages with the
- `assistant` role are presumed to have been generated by the model in previous
- interactions.
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色给出的指令。带有
+ `assistant` 角色的消息被视为模型在之前的
+ 交互中生成。
- `content: string or ResponseInputMessageContentList`
- Text, image, or audio input to the model, used to generate a response.
- Can also contain previous assistant responses.
+ 发送给模型的文本、图像或音频输入,用于生成响应。
+ 也可以包含之前的助手响应。
- `TextInput = string`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputMessageContentList = array of ResponseInputContent`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -9714,25 +9711,25 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -9742,13 +9739,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -9758,33 +9755,33 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `assistant`, `system`, or
+ 消息输入的角色。其一为 接口 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -9797,9 +9794,9 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -9807,24 +9804,24 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: optional "message"`
- 消息输入的类型。始终为 `message`.
+ 消息输入的类型。始终为 接口 `message`.
- `"message"`
- `Message object { content, role, status, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` 角色的文本输入。
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色的文本输入。
- `content: ResponseInputMessageContentList`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `system`, or `developer`.
+ 消息输入的角色。其一为 接口 `user`, `system`,或 `developer`.
- `"user"`
@@ -9834,8 +9831,8 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -9855,7 +9852,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -9863,15 +9860,15 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -9887,7 +9884,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -9897,25 +9894,25 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -9927,7 +9924,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -9935,11 +9932,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -9993,15 +9990,15 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -10013,8 +10010,8 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -10030,9 +10027,9 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -10040,8 +10037,8 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -10053,7 +10050,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -10078,11 +10075,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -10100,7 +10097,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -10109,7 +10106,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -10121,7 +10118,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -10137,8 +10134,8 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -10162,7 +10159,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -10176,7 +10173,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -10202,7 +10199,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -10220,7 +10217,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -10239,7 +10236,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -10249,11 +10246,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -10273,15 +10270,15 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -10313,19 +10310,19 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -10349,8 +10346,8 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -10366,7 +10363,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -10382,7 +10379,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -10390,44 +10387,44 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `ComputerCallOutput object { call_id, output, type, 3 more }`
- 一次 computer 工具调用的输出。
+ 计算机工具调用的输出。
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `id: optional string or null`
- computer 工具调用输出的 ID。
+ 计算机工具调用输出的 ID。
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 已被开发者确认的 API 所报告的安全检查结果。
+ 开发者已确认的 API 所报告的安全检查。
- `id: string`
@@ -10443,7 +10440,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值为 `in_progress`, `completed`, or `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -10454,7 +10451,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -10462,12 +10459,12 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -10477,11 +10474,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -10499,7 +10496,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -10513,7 +10510,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -10531,7 +10528,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -10543,14 +10540,14 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -10600,8 +10597,8 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -10615,7 +10612,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `output: string or array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的文本、图片或文件输出。
+ 函数工具调用的文本、图像或文件输出。
- `string`
@@ -10623,61 +10620,61 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的内容输出(文本、图片、文件)数组。
+ 函数工具调用的内容输出(文本、图像、文件)数组。
- `ResponseInputTextContent object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision)
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `detail: optional ImageDetail or null`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -10687,13 +10684,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -10707,23 +10704,23 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -10735,7 +10732,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `id: optional string or null`
- 函数工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
+ 函数工具调用输出的唯一 ID。当此项通过 API 返回时填充。
- `call_id: optional string or null`
@@ -10775,7 +10772,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -10791,7 +10788,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "tool_search_call"`
- 条目类型。始终为 `tool_search_call`.
+ 项的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
@@ -10859,37 +10856,37 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -10902,11 +10899,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -10926,7 +10923,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -10942,15 +10939,15 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -10964,7 +10961,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -10972,7 +10969,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -10984,7 +10981,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -10992,21 +10989,21 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -11032,18 +11029,18 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -11051,22 +11048,22 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -11076,23 +11073,23 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -11103,11 +11100,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -11125,21 +11122,21 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -11147,14 +11144,14 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -11186,32 +11183,32 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -11219,13 +11216,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -11233,9 +11230,9 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -11247,22 +11244,22 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -11271,7 +11268,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -11281,7 +11278,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -11311,29 +11308,29 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -11369,7 +11366,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -11379,11 +11376,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -11393,7 +11390,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -11401,7 +11398,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -11410,13 +11407,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -11425,7 +11422,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -11452,7 +11449,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -11463,7 +11460,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -11480,13 +11477,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -11502,7 +11499,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -11512,7 +11509,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -11536,7 +11533,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -11560,13 +11557,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -11590,7 +11587,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -11598,13 +11595,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -11624,7 +11621,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -11636,13 +11633,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -11656,11 +11653,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -11686,7 +11683,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -11704,7 +11701,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -11718,19 +11715,19 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -11750,19 +11747,19 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -11770,11 +11767,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -11820,7 +11817,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -11832,11 +11829,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -11850,7 +11847,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -11860,7 +11857,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -11870,23 +11867,23 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -11904,13 +11901,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "tool_search_output"`
- 条目类型。始终为 `tool_search_output`.
+ 项的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `id: optional string or null`
- 此工具搜索输出的唯一 ID。
+ 该工具搜索输出的唯一 ID。
- `call_id: optional string or null`
@@ -11938,13 +11935,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `role: "developer"`
- 提供其他工具的角色。仅 `developer` 受支持。
+ 提供这些额外工具的角色。仅支持 `developer` 。
- `"developer"`
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 此项目提供的其他工具列表。
+ 在该条目中提供的额外工具列表。
- `Function object { name, parameters, strict, 5 more }`
@@ -11978,45 +11975,45 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -12024,7 +12021,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -12036,7 +12033,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -12044,21 +12041,21 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -12084,18 +12081,18 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -12103,22 +12100,22 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -12128,23 +12125,23 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -12155,11 +12152,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -12177,21 +12174,21 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -12199,14 +12196,14 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -12238,32 +12235,32 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -12271,13 +12268,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -12285,9 +12282,9 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -12299,22 +12296,22 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -12323,7 +12320,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -12333,7 +12330,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -12389,7 +12386,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -12399,11 +12396,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -12413,7 +12410,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -12421,7 +12418,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -12430,13 +12427,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -12445,7 +12442,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -12472,7 +12469,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -12483,7 +12480,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -12500,13 +12497,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -12522,7 +12519,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -12532,7 +12529,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -12558,11 +12555,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -12588,19 +12585,19 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -12620,19 +12617,19 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -12640,11 +12637,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -12690,7 +12687,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -12702,11 +12699,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -12720,7 +12717,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -12730,7 +12727,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -12740,23 +12737,23 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -12774,19 +12771,19 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "additional_tools"`
- 条目类型。始终为 `additional_tools`.
+ 项的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `id: optional string or null`
- 此其他工具项目的唯一 ID。
+ 该额外工具条目的唯一 ID。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -12799,7 +12796,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -12819,7 +12816,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -12829,20 +12826,20 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -12852,7 +12849,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Compaction object { encrypted_content, type, id }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -12860,17 +12857,17 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `id: optional string or null`
- 压缩条目的 ID。
+ 压缩项的 ID。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -12894,7 +12891,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -12917,7 +12914,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -12929,23 +12926,23 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -12963,13 +12960,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -12985,11 +12982,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -13003,11 +13000,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -13021,7 +13018,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -13031,7 +13028,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -13039,13 +13036,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -13059,7 +13056,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
@@ -13071,7 +13068,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最大挂钟时间(毫秒)。
+ 允许 shell 命令运行的 wall-clock 最长时间(毫秒)。
- `call_id: string`
@@ -13079,13 +13076,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
- `id: optional string or null`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -13121,7 +13118,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -13131,7 +13128,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `ShellCallOutput object { call_id, output, type, 4 more }`
- shell 工具调用发出的流式输出项。
+ shell 工具调用发出的流式输出条目。
- `call_id: string`
@@ -13139,7 +13136,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `output: array of ResponseFunctionShellCallOutputContent`
- stdout 和 stderr 输出的捕获块及其关联结果。
+ 捕获的 stdout 和 stderr 输出块,以及它们关联的结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -13151,13 +13148,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -13165,27 +13162,27 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
- `stderr: string`
- shell 调用捕获的 stderr 输出。
+ 为该 shell 调用捕获的 stderr 输出。
- `stdout: string`
- shell 调用捕获的 stdout 输出。
+ 为该 shell 调用捕获的 stdout 输出。
- `type: "shell_call_output"`
- 条目的类型,恒为 `shell_call_output`.
+ item 的类型。始终为 `shell_call_output`.
- `"shell_call_output"`
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -13227,11 +13224,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 表示使用 diff 补丁创建、删除或更新文件的工具调用。
+ 表示通过 diff 补丁创建、删除或更新文件的工具调用。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
@@ -13243,7 +13240,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `diff: string`
- 创建文件时要应用的统一 diff 内容。
+ 创建文件时应用的 unified diff 内容。
- `path: string`
@@ -13275,7 +13272,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `diff: string`
- 要应用于现有文件的统一 diff 内容。
+ 应用于现有文件的 unified diff 内容。
- `path: string`
@@ -13289,7 +13286,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -13297,13 +13294,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
- `id: optional string or null`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -13331,15 +13328,15 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `ApplyPatchCallOutput object { call_id, status, type, 3 more }`
- apply patch 工具调用发出的流式输出。
+ 由 apply patch 工具调用发出的流式输出。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -13347,13 +13344,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
- `id: optional string or null`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -13409,7 +13406,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -13417,29 +13414,29 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -13447,31 +13444,31 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { approval_request_id, approve, type, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
- `id: optional string or null`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `reason: optional string or null`
@@ -13479,7 +13476,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -13487,11 +13484,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -13499,14 +13496,14 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -13546,7 +13543,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -13560,11 +13557,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 由你的代码生成的自定义工具调用输出,将被发送回模型。
+ 由你的代码生成的自定义工具调用的输出,将发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -13581,11 +13578,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -13599,7 +13596,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `id: optional string`
- 自定义工具调用输出在 OpenAI 平台中的唯一 ID。
+ 在 OpenAI 平台中该自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -13649,7 +13646,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -13677,11 +13674,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `CompactionTrigger object { type, id }`
- 压缩当前上下文。必须是最后一个输入项。
+ 压缩当前上下文。必须作为最后一个输入项。
- `type: "compaction_trigger"`
- 条目的类型,恒为 `compaction_trigger`.
+ item 的类型。始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -13695,11 +13692,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `id: string`
- 要引用的条目 ID。
+ 被引用条目的 ID。
- `type: optional "item_reference" or null`
- 要引用的条目类型。始终为 `item_reference`.
+ 被引用条目的类型。始终为 `item_reference`.
- `"item_reference"`
@@ -13715,7 +13712,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -13723,7 +13720,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "program"`
- 条目类型。始终为 `program`.
+ 项的类型。始终为 `program`.
- `"program"`
@@ -13739,7 +13736,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -13751,30 +13748,30 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "program_output"`
- 条目类型。始终为 `program_output`.
+ 项的类型。始终为 `program_output`.
- `"program_output"`
- `instructions: optional string or null`
- 插入到模型上下文中的系统(或开发者)消息。
- 与 `previous_response_id`,配合使用时,上一次响应中的指令不会延续到下一次响应。这样可以方便地在新响应中替换系统(或开发者)消息。
+ 插入模型上下文中的系统(或开发者)消息。
+ 与 `previous_response_id`,一起使用时,上一次响应的指令不会延续到下一次响应。这样就能方便地在新响应中替换系统(或开发者)消息。
- `previous_response_id: optional string or null`
- 上一次模型响应的唯一 ID。使用此 ID 可以创建多轮对话。详细了解 [对话状态](/docs/guides/conversation-state)。的更多信息。不能与 `conversation`.
+ 上一次模型响应的唯一 ID。使用它可以创建多轮对话。详细了解 [conversation state](/docs/guides/conversation-state)。不能与 `conversation`.
- `prompt_cache_key: optional string or null`
- 在读取或写入提示缓存时使用的密钥。
+ 用于读取或写入提示缓存的键。
- `prompt_cache_options: optional object { mode, ttl } or null`
- 提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。默认情况下,OpenAI 会自动选择一个隐式缓存断点。你可以使用 `prompt_cache_breakpoint`。为内容块添加显式断点。每个请求最多可以写入四个断点。对于缓存匹配,OpenAI 会考虑对话中最近的最多 80 个断点,且不受内容块回溯长度的限制。将 `mode` 设置为 `explicit` 可禁用隐式断点。 `ttl` 默认为 `30m`,这是当前唯一支持的值。请参阅 [提示缓存指南](/docs/guides/prompt-caching) 了解当前详细信息。
+ 提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。默认情况下,OpenAI 会自动选择一个隐式缓存断点。你可以通过 `prompt_cache_breakpoint`.每个请求最多可以写入四个断点。对于缓存匹配,OpenAI 会考虑对话中最多最新的 80 个断点,且没有内容块回溯限制。将 `mode` 设置为 `explicit` 可禁用隐式断点。 `ttl` 默认为 `30m`,目前这是唯一支持的值。请参阅 [提示缓存指南](/docs/guides/prompt-caching) 了解最新详情。
- `mode: optional "implicit" or "explicit"`
- 控制 OpenAI 是否自动创建隐式缓存断点。默认为 `implicit`。当 `implicit`,时,OpenAI 会创建一个隐式断点,并在请求中写入最多最近的三个显式断点。当 `explicit`,OpenAI 不会创建隐式断点,最多写入最近的四个显式断点。如果没有显式断点,则该请求不会使用提示缓存。
+ 控制 OpenAI 是否自动创建隐式缓存断点。默认为 `implicit`。当为 `implicit`,时,OpenAI 会创建一个隐式断点,并在请求中写入最多最新的三个显式断点。当为 `explicit`,OpenAI 不会创建隐式断点,并最多写入最新的四个显式断点。如果没有显式断点,则该请求不使用提示缓存。
- `"implicit"`
@@ -13782,13 +13779,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `ttl: optional "30m"`
- 应用于该请求写入的每个隐式和显式缓存断点的最短生命周期。默认为 `30m`,目前这是唯一受支持的值。后端可能会将缓存条目保留更长时间。
+ 应用于该请求所写入的每个隐式和显式缓存断点的最短生命周期。默认为 `30m`,目前这是唯一受支持的值。后端可能会将缓存条目保留更长时间。
- `"30m"`
- `prompt_cache_retention: optional "in_memory" or "24h" or null`
- 由该请求创建的提示缓存条目的保留时长。
+ 保留由该请求创建的提示缓存条目的时长。
- `"in_memory"`
@@ -13796,8 +13793,8 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `service_tier: optional "auto" or "default" or "fast" or 2 more or null`
- 指定用于处理该请求的处理类型。 - 如果设置为 'auto',则请求将使用在项目设置中配置的服务层级进行处理。除非另有配置,否则项目将使用 'default'。 - 如果设置为 'default',则请求将使用所选模型的标准定价和性能进行处理。 - 如果设置为 '[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。 - 要选择启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 `service_tier=fast` 或 `service_tier=priority` 参数用于 Responses 或 Chat Completions。响应将显示 `service_tier=priority` ,无论你是否在请求中指定了 `service_tier=fast` 或 `priority` ,请在你的请求中进行设置。 - 当未设置时,默认行为为 'auto'。
- 当设置 `service_tier` 参数时,响应正文将包含基于实际用于处理该请求的处理模式的 `service_tier` 值。此响应值可能与参数中设置的值不同。
+ 指定用于处理该请求的处理类型。 - 如果设置为 'auto',则请求将使用项目设置中配置的服务层级进行处理。除非另有配置,否则该项目将使用 'default'。 - 如果设置为 'default',则请求将使用所选模型的标准定价和性能进行处理。 - 如果设置为 '[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。 - 若要选择启用 [快速模式](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` ,请在你的请求中进行设置。 - 如果未设置,则默认行为为 'auto'。
+ 当 `service_tier` 参数被设置时,响应体中将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。此响应中的值可能与该参数中设置的值不同。
- `"auto"`
@@ -13809,7 +13806,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `"priority"`
-### 返回
+### 返回值
- `CompactedResponse object { id, created_at, object, 2 more }`
@@ -13833,7 +13830,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Message object { id, content, role, 3 more }`
- 发给模型或来自模型的消息。
+ 发送给模型或来自模型的消息。
- `id: string`
@@ -13845,39 +13842,39 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -13893,7 +13890,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -13903,25 +13900,25 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -13933,7 +13930,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -13941,11 +13938,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -14013,7 +14010,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -14027,7 +14024,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -14037,25 +14034,25 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -14067,57 +14064,57 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ComputerScreenshotContent object { detail, file_id, image_url, 2 more }`
- 计算机的屏幕截图。
+ 计算机屏幕截图。
- `detail: ImageDetail`
- 发送给模型的屏幕截图图像的细节级别。取值为 `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的截图图像的细节级别。取值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: string or null`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: string or null`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机屏幕截图,此属性始终设置为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为 `computer_screenshot`.
- `"computer_screenshot"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -14127,13 +14124,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -14143,33 +14140,33 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "unknown" or "user" or "assistant" or 5 more`
- 消息的角色。可选值为 `unknown`, `user`, `assistant`, `system`, `critic`, `discriminator`, `developer`, or `tool`.
+ 消息的角色。可选值之一 `unknown`, `user`, `assistant`, `system`, `critic`, `discriminator`, `developer`,或 `tool`.
- `"unknown"`
@@ -14189,7 +14186,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或 `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -14205,7 +14202,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`)。对于 `gpt-5.3-codex` 及更高模型,在发送后续请求时,请在所有助手消息上保留并重新发送 phase 字段——删除它可能会降低性能。用户消息不使用该字段。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`)。对于类似 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请在所有助手消息上保留并重新发送 phase,删除它可能会降低性能。不用于用户消息。
- `"commentary"`
@@ -14223,7 +14220,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -14231,7 +14228,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "program"`
- 条目的类型,恒为 `program`.
+ item 的类型。始终为 `program`.
- `"program"`
@@ -14247,7 +14244,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -14259,14 +14256,14 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "program_output"`
- 条目的类型,恒为 `program_output`.
+ item 的类型。始终为 `program_output`.
- `"program_output"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -14316,8 +14313,8 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -14359,13 +14356,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "tool_search_call"`
- 条目的类型,恒为 `tool_search_call`.
+ item 的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -14431,37 +14428,37 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -14474,11 +14471,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -14498,7 +14495,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -14514,15 +14511,15 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -14536,7 +14533,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -14544,7 +14541,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -14556,7 +14553,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -14564,21 +14561,21 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -14604,18 +14601,18 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -14623,22 +14620,22 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -14648,23 +14645,23 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -14675,11 +14672,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -14697,21 +14694,21 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -14719,14 +14716,14 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -14758,32 +14755,32 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -14791,13 +14788,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -14805,9 +14802,9 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -14819,22 +14816,22 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -14843,7 +14840,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -14853,7 +14850,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -14883,29 +14880,29 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -14941,7 +14938,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -14951,11 +14948,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -14965,7 +14962,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -14973,7 +14970,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -14982,13 +14979,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -14997,7 +14994,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -15024,7 +15021,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -15035,7 +15032,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -15052,13 +15049,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -15074,7 +15071,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -15084,7 +15081,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -15108,7 +15105,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -15132,13 +15129,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -15162,7 +15159,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -15170,13 +15167,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -15196,7 +15193,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -15208,13 +15205,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -15228,11 +15225,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -15258,7 +15255,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -15276,7 +15273,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -15290,19 +15287,19 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -15322,19 +15319,19 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -15342,11 +15339,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -15392,7 +15389,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -15404,11 +15401,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -15422,7 +15419,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -15432,7 +15429,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -15442,23 +15439,23 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -15476,13 +15473,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "tool_search_output"`
- 条目的类型,恒为 `tool_search_output`.
+ item 的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -15512,7 +15509,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -15546,45 +15543,45 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -15592,7 +15589,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -15604,7 +15601,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -15612,21 +15609,21 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -15652,18 +15649,18 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -15671,22 +15668,22 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -15696,23 +15693,23 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -15723,11 +15720,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -15745,21 +15742,21 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -15767,14 +15764,14 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -15806,32 +15803,32 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -15839,13 +15836,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -15853,9 +15850,9 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -15867,22 +15864,22 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -15891,7 +15888,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -15901,7 +15898,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -15957,7 +15954,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -15967,11 +15964,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -15981,7 +15978,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -15989,7 +15986,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -15998,13 +15995,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -16013,7 +16010,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -16040,7 +16037,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -16051,7 +16048,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -16068,13 +16065,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -16090,7 +16087,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -16100,7 +16097,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -16126,11 +16123,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -16156,19 +16153,19 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -16188,19 +16185,19 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -16208,11 +16205,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -16258,7 +16255,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -16270,11 +16267,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -16288,7 +16285,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -16298,7 +16295,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -16308,23 +16305,23 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -16342,7 +16339,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "additional_tools"`
- 条目的类型,恒为 `additional_tools`.
+ item 的类型。始终为 `additional_tools`.
- `"additional_tools"`
@@ -16361,15 +16358,15 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -16383,8 +16380,8 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `id: optional string`
- 函数工具调用输出的唯一 ID。当此项
- 通过 API 返回时填充。
+ 函数工具调用的唯一 ID。当此项通过 API 返回时填充。
+ 通过 接口 返回时填充。
- `call_id: optional string`
@@ -16424,8 +16421,8 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -16435,8 +16432,8 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -16448,7 +16445,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -16473,11 +16470,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -16495,7 +16492,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -16504,7 +16501,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -16512,12 +16509,12 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -16527,11 +16524,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -16549,7 +16546,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -16563,7 +16560,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -16581,7 +16578,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -16593,13 +16590,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -16623,14 +16620,14 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -16642,7 +16639,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -16658,8 +16655,8 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -16683,7 +16680,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -16697,7 +16694,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -16723,7 +16720,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -16741,7 +16738,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -16760,7 +16757,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -16770,11 +16767,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -16794,15 +16791,15 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -16834,19 +16831,19 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -16870,8 +16867,8 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -16887,7 +16884,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -16903,7 +16900,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -16917,31 +16914,31 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"completed"`
@@ -16953,13 +16950,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、已被
+ API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -16976,13 +16973,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -16995,7 +16992,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -17013,7 +17010,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -17023,20 +17020,20 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -17046,7 +17043,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -17054,17 +17051,17 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的已加密内容。
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `CodeInterpreterCall object { id, code, container_id, 3 more }`
@@ -17085,7 +17082,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -17097,23 +17094,23 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -17131,13 +17128,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -17153,11 +17150,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -17171,11 +17168,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -17189,7 +17186,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -17199,7 +17196,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -17207,13 +17204,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -17227,17 +17224,17 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `id: string`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -17275,7 +17272,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -17285,7 +17282,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -17319,7 +17316,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。通过 API 返回该条目时填充此字段。
- `call_id: string`
@@ -17327,15 +17324,15 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -17343,13 +17340,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -17357,7 +17354,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -17371,11 +17368,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`, or `incomplete`.
+ shell 调用输出的状态。可选值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -17411,7 +17408,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -17419,15 +17416,15 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `id: string`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -17443,7 +17440,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的 diff 创建新文件。
- `"create_file"`
@@ -17457,7 +17454,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "delete_file"`
- 删除指定的文件。
+ 删除指定文件。
- `"delete_file"`
@@ -17475,13 +17472,13 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "update_file"`
- 使用提供的差异更新现有文件。
+ 使用提供的 diff 更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -17489,7 +17486,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -17519,19 +17516,19 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -17539,7 +17536,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -17597,7 +17594,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -17605,29 +17602,29 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -17635,29 +17632,29 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `id: string`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -17667,7 +17664,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -17675,11 +17672,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -17687,14 +17684,14 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -17734,7 +17731,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -17770,7 +17767,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -17798,11 +17795,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 由你的代码生成的自定义工具调用输出,将被发送回模型。
+ 由你的代码生成的自定义工具调用的输出,将发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -17819,11 +17816,11 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -17837,7 +17834,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `id: optional string`
- 自定义工具调用输出在 OpenAI 平台中的唯一 ID。
+ 在 OpenAI 平台中该自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -17865,7 +17862,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `usage: ResponseUsage`
- 压缩过程的令牌统计,包括缓存、推理和总令牌。
+ 压缩过程的 token 统计,包括缓存 token、推理 token 和总 token。
- `input_tokens: number`
@@ -17873,16 +17870,16 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `input_tokens_details: object { cache_write_tokens, cached_tokens }`
- 输入 token 的详细明细。
+ 输入 token 的详细细分。
- `cache_write_tokens: number`
- 已写入缓存的输入 token 数量。
+ 写入缓存的输入 token 的数量。
- `cached_tokens: number`
- 从缓存中检索到的 token 数量。
- [了解更多关于提示缓存的信息](/docs/guides/prompt-caching).
+ 从缓存中检索到的 token 的数量。
+ [有关 prompt caching 的更多信息](/docs/guides/prompt-caching).
- `output_tokens: number`
@@ -17890,19 +17887,15 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
- `output_tokens_details: object { reasoning_tokens }`
- 输出令牌的详细明细。
+ 输出 token 的详细明细。
- `reasoning_tokens: number`
- 推理令牌的数量。
+ 推理 token 的数量。
- `total_tokens: number`
- 使用的令牌总数。
-
- - `compute_units: optional number or null`
-
- 该请求的计算单元。在可用时当前为 null。
+ 使用的 token 总数。
### 示例
@@ -17916,7 +17909,7 @@ curl https://api.openai.com/v1/responses/compact \
}'
```
-#### 响应
+#### Response
```json
{
@@ -17951,8 +17944,7 @@ curl https://api.openai.com/v1/responses/compact \
"output_tokens_details": {
"reasoning_tokens": 0
},
- "total_tokens": 0,
- "compute_units": 0
+ "total_tokens": 0
}
}
```
@@ -17988,7 +17980,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
}'
```
-#### 响应
+#### Response
```json
{
@@ -18033,15 +18025,15 @@ curl -X POST https://api.openai.com/v1/responses/compact \
**post** `/responses`
-创建模型响应。提供 [文本](/docs/guides/text) 或
-[图像](/docs/guides/images) 输入以生成 [文本](/docs/guides/text)
+创建一个模型响应。提供 [text](/docs/guides/text) 或
+[image](/docs/guides/images) 输入以生成 [text](/docs/guides/text)
或 [JSON](/docs/guides/structured-outputs) 输出。让模型调用
-你自己的 [自定义代码](/docs/guides/function-calling) 或使用内置的
-[工具](/docs/guides/tools) 例如 [网页搜索](/docs/guides/tools-web-search)
+你自己的 [custom code](/docs/guides/function-calling) 或使用内置
+[tools](/docs/guides/tools) 例如 [网页搜索](/docs/guides/tools-web-search)
或 [文件搜索](/docs/guides/tools-file-search) 以使用你自己的数据
作为模型响应的输入。
-### 请求体参数
+### 正文参数
- `background: optional boolean or null`
@@ -18050,7 +18042,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `context_management: optional array of object { type, compact_threshold } or null`
- 此请求的上下文管理配置。
+ 本次请求的上下文管理配置。
- `type: string`
@@ -18058,12 +18050,12 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `compact_threshold: optional number or null`
- 应触发此条目压缩的 token 阈值。
+ 触发该条目压缩的 token 阈值。
- `conversation: optional string or ResponseConversationParam or null`
- 此响应所属的对话。该对话中的条目会被添加到 `input_items` 此响应请求之前。
- 此响应的输入条目和输出条目会在该响应完成后自动添加到此对话中。
+ 本次响应所属的对话。该对话中的条目会前置拼接到 `input_items` 本次响应请求的输入中。
+ 本次响应的输入条目和输出条目会在响应完成后自动追加到该对话中。
- `ConversationID = string`
@@ -18071,7 +18063,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ResponseConversationParam object { id }`
- 此响应所属的对话。
+ 本次响应所属的对话。
- `id: string`
@@ -18079,15 +18071,15 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `include: optional array of ResponseIncludable or null`
- 指定要在模型响应中包含的其他输出数据。目前支持的值包括:
+ 指定要包含在模型响应中的其他输出数据。目前支持的值包括:
- - `web_search_call.action.sources`:包含 网页搜索 工具调用的来源。
- - `code_interpreter_call.outputs`:在代码解释器工具调用条目中包含 Python 代码执行的输出。
- - `computer_call_output.output.image_url`:包含来自计算机调用输出的图片 URL。
- - `file_search_call.results`:包含 文件搜索 工具调用的搜索结果。
- - `message.input_image.image_url`:包含来自输入消息的图片 URL。
- - `message.output_text.logprobs`:在助手消息中包含 logprobs。
- - `reasoning.encrypted_content`:在推理条目的输出中包含加密版本的推理 token。这使得在使用 Responses API 以无状态方式处理多轮对话时能够使用推理条目(例如 `store` 参数设置为 `false`,时,或组织已加入零数据留存计划时)。
+ - `web_search_call.action.sources`: 包含网页搜索工具调用的来源。
+ - `code_interpreter_call.outputs`: 在代码解释器工具调用项中包含 Python 代码执行的输出。
+ - `computer_call_output.output.image_url`: 包含来自 computer call 输出的图片链接。
+ - `file_search_call.results`: 包含文件搜索工具调用的搜索结果。
+ - `message.input_image.image_url`: 包含来自输入消息的图片链接。
+ - `message.output_text.logprobs`: 在助手消息中包含 logprobs。
+ - `reasoning.encrypted_content`: 在推理项输出中包含加密版本的推理 token。这使得在使用Responses API无状态调用时(例如当 `store` 参数设置为 `false`,或组织加入了零数据保留计划时),可以在多轮对话中使用推理项。
- `"file_search_call.results"`
@@ -18107,9 +18099,9 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `input: optional string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 提供给模型的文本、图片或文件输入,用于生成响应。
+ 模型的文本、图片或文件输入,用于生成响应。
- 了解详情:
+ 了解更多:
- [文本输入与输出](/docs/guides/text)
- [图像输入](/docs/guides/images)
@@ -18119,67 +18111,67 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `TextInput = string`
- 发送给模型的文本输入,相当于使用
+ 发送给模型的文本输入,等同于
`user` 角色的文本输入。
- `InputItemList = array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 发送给模型的一个或多个输入项的列表,包含
+ 发送给模型的一个或多个输入项列表,包含
不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` role. Messages with the
- `assistant` role are presumed to have been generated by the model in previous
- interactions.
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色给出的指令。带有
+ `assistant` 角色的消息被视为模型在之前的
+ 交互中生成。
- `content: string or ResponseInputMessageContentList`
- Text, image, or audio input to the model, used to generate a response.
- Can also contain previous assistant responses.
+ 发送给模型的文本、图像或音频输入,用于生成响应。
+ 也可以包含之前的助手响应。
- `TextInput = string`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputMessageContentList = array of ResponseInputContent`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -18191,25 +18183,25 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -18219,13 +18211,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -18235,33 +18227,33 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `assistant`, `system`, or
+ 消息输入的角色。其一为 接口 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -18274,9 +18266,9 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -18284,24 +18276,24 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: optional "message"`
- 消息输入的类型。始终为 `message`.
+ 消息输入的类型。始终为 接口 `message`.
- `"message"`
- `Message object { content, role, status, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` 角色的文本输入。
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色的文本输入。
- `content: ResponseInputMessageContentList`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `system`, or `developer`.
+ 消息输入的角色。其一为 接口 `user`, `system`,或 `developer`.
- `"user"`
@@ -18311,8 +18303,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -18332,7 +18324,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -18340,15 +18332,15 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -18364,7 +18356,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -18374,25 +18366,25 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -18404,7 +18396,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -18412,11 +18404,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -18470,15 +18462,15 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -18490,8 +18482,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -18507,9 +18499,9 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -18517,8 +18509,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -18530,7 +18522,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -18555,11 +18547,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -18577,7 +18569,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -18586,7 +18578,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -18598,7 +18590,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -18614,8 +18606,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -18639,7 +18631,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -18653,7 +18645,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -18679,7 +18671,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -18697,7 +18689,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -18716,7 +18708,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -18726,11 +18718,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -18750,15 +18742,15 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -18790,19 +18782,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -18826,8 +18818,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -18843,7 +18835,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -18859,7 +18851,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -18867,44 +18859,44 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ComputerCallOutput object { call_id, output, type, 3 more }`
- 一次 computer 工具调用的输出。
+ 计算机工具调用的输出。
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `id: optional string or null`
- computer 工具调用输出的 ID。
+ 计算机工具调用输出的 ID。
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 已被开发者确认的 API 所报告的安全检查结果。
+ 开发者已确认的 API 所报告的安全检查。
- `id: string`
@@ -18920,7 +18912,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值为 `in_progress`, `completed`, or `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -18931,7 +18923,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -18939,12 +18931,12 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -18954,11 +18946,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -18976,7 +18968,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -18990,7 +18982,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -19008,7 +19000,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -19020,14 +19012,14 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -19077,8 +19069,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -19092,7 +19084,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `output: string or array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的文本、图片或文件输出。
+ 函数工具调用的文本、图像或文件输出。
- `string`
@@ -19100,61 +19092,61 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的内容输出(文本、图片、文件)数组。
+ 函数工具调用的内容输出(文本、图像、文件)数组。
- `ResponseInputTextContent object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision)
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `detail: optional ImageDetail or null`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -19164,13 +19156,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -19184,23 +19176,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -19212,7 +19204,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `id: optional string or null`
- 函数工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
+ 函数工具调用输出的唯一 ID。当此项通过 API 返回时填充。
- `call_id: optional string or null`
@@ -19252,7 +19244,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -19268,7 +19260,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "tool_search_call"`
- 条目类型。始终为 `tool_search_call`.
+ 项的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
@@ -19336,37 +19328,37 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -19379,11 +19371,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -19403,7 +19395,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -19419,15 +19411,15 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -19441,7 +19433,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -19449,7 +19441,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -19461,7 +19453,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -19469,21 +19461,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -19509,18 +19501,18 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -19528,22 +19520,22 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -19553,23 +19545,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -19580,11 +19572,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -19602,21 +19594,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -19624,14 +19616,14 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -19663,32 +19655,32 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -19696,13 +19688,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -19710,9 +19702,9 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -19724,22 +19716,22 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -19748,7 +19740,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -19758,7 +19750,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -19788,29 +19780,29 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -19846,7 +19838,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -19856,11 +19848,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -19870,7 +19862,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -19878,7 +19870,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -19887,13 +19879,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -19902,7 +19894,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -19929,7 +19921,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -19940,7 +19932,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -19957,13 +19949,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -19979,7 +19971,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -19989,7 +19981,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -20013,7 +20005,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -20037,13 +20029,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -20067,7 +20059,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -20075,13 +20067,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -20101,7 +20093,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -20113,13 +20105,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -20133,11 +20125,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -20163,7 +20155,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -20181,7 +20173,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -20195,19 +20187,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -20227,19 +20219,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -20247,11 +20239,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -20297,7 +20289,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -20309,11 +20301,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -20327,7 +20319,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -20337,7 +20329,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -20347,23 +20339,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -20381,13 +20373,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "tool_search_output"`
- 条目类型。始终为 `tool_search_output`.
+ 项的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `id: optional string or null`
- 此工具搜索输出的唯一 ID。
+ 该工具搜索输出的唯一 ID。
- `call_id: optional string or null`
@@ -20415,13 +20407,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `role: "developer"`
- 提供其他工具的角色。仅 `developer` 受支持。
+ 提供这些额外工具的角色。仅支持 `developer` 。
- `"developer"`
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 此项目提供的其他工具列表。
+ 在该条目中提供的额外工具列表。
- `Function object { name, parameters, strict, 5 more }`
@@ -20455,45 +20447,45 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -20501,7 +20493,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -20513,7 +20505,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -20521,21 +20513,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -20561,18 +20553,18 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -20580,22 +20572,22 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -20605,23 +20597,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -20632,11 +20624,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -20654,21 +20646,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -20676,14 +20668,14 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -20715,32 +20707,32 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -20748,13 +20740,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -20762,9 +20754,9 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -20776,22 +20768,22 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -20800,7 +20792,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -20810,7 +20802,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -20866,7 +20858,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -20876,11 +20868,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -20890,7 +20882,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -20898,7 +20890,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -20907,13 +20899,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -20922,7 +20914,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -20949,7 +20941,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -20960,7 +20952,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -20977,13 +20969,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -20999,7 +20991,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -21009,7 +21001,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -21035,11 +21027,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -21065,19 +21057,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -21097,19 +21089,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -21117,11 +21109,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -21167,7 +21159,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -21179,11 +21171,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -21197,7 +21189,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -21207,7 +21199,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -21217,23 +21209,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -21251,19 +21243,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "additional_tools"`
- 条目类型。始终为 `additional_tools`.
+ 项的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `id: optional string or null`
- 此其他工具项目的唯一 ID。
+ 该额外工具条目的唯一 ID。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -21276,7 +21268,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -21296,7 +21288,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -21306,20 +21298,20 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -21329,7 +21321,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Compaction object { encrypted_content, type, id }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -21337,17 +21329,17 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `id: optional string or null`
- 压缩条目的 ID。
+ 压缩项的 ID。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -21371,7 +21363,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -21394,7 +21386,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -21406,23 +21398,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -21440,13 +21432,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -21462,11 +21454,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -21480,11 +21472,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -21498,7 +21490,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -21508,7 +21500,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -21516,13 +21508,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -21536,7 +21528,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
@@ -21548,7 +21540,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最大挂钟时间(毫秒)。
+ 允许 shell 命令运行的 wall-clock 最长时间(毫秒)。
- `call_id: string`
@@ -21556,13 +21548,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
- `id: optional string or null`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -21598,7 +21590,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -21608,7 +21600,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ShellCallOutput object { call_id, output, type, 4 more }`
- shell 工具调用发出的流式输出项。
+ shell 工具调用发出的流式输出条目。
- `call_id: string`
@@ -21616,7 +21608,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `output: array of ResponseFunctionShellCallOutputContent`
- stdout 和 stderr 输出的捕获块及其关联结果。
+ 捕获的 stdout 和 stderr 输出块,以及它们关联的结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -21628,13 +21620,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -21642,27 +21634,27 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
- `stderr: string`
- shell 调用捕获的 stderr 输出。
+ 为该 shell 调用捕获的 stderr 输出。
- `stdout: string`
- shell 调用捕获的 stdout 输出。
+ 为该 shell 调用捕获的 stdout 输出。
- `type: "shell_call_output"`
- 条目的类型,恒为 `shell_call_output`.
+ item 的类型。始终为 `shell_call_output`.
- `"shell_call_output"`
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -21704,11 +21696,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 表示使用 diff 补丁创建、删除或更新文件的工具调用。
+ 表示通过 diff 补丁创建、删除或更新文件的工具调用。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
@@ -21720,7 +21712,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `diff: string`
- 创建文件时要应用的统一 diff 内容。
+ 创建文件时应用的 unified diff 内容。
- `path: string`
@@ -21752,7 +21744,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `diff: string`
- 要应用于现有文件的统一 diff 内容。
+ 应用于现有文件的 unified diff 内容。
- `path: string`
@@ -21766,7 +21758,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -21774,13 +21766,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
- `id: optional string or null`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -21808,15 +21800,15 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ApplyPatchCallOutput object { call_id, status, type, 3 more }`
- apply patch 工具调用发出的流式输出。
+ 由 apply patch 工具调用发出的流式输出。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -21824,13 +21816,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
- `id: optional string or null`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -21886,7 +21878,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -21894,29 +21886,29 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -21924,31 +21916,31 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { approval_request_id, approve, type, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
- `id: optional string or null`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `reason: optional string or null`
@@ -21956,7 +21948,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -21964,11 +21956,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -21976,14 +21968,14 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -22023,7 +22015,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -22037,11 +22029,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 由你的代码生成的自定义工具调用输出,将被发送回模型。
+ 由你的代码生成的自定义工具调用的输出,将发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -22058,11 +22050,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -22076,7 +22068,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `id: optional string`
- 自定义工具调用输出在 OpenAI 平台中的唯一 ID。
+ 在 OpenAI 平台中该自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -22126,7 +22118,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -22154,11 +22146,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `CompactionTrigger object { type, id }`
- 压缩当前上下文。必须是最后一个输入项。
+ 压缩当前上下文。必须作为最后一个输入项。
- `type: "compaction_trigger"`
- 条目的类型,恒为 `compaction_trigger`.
+ item 的类型。始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -22172,11 +22164,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `id: string`
- 要引用的条目 ID。
+ 被引用条目的 ID。
- `type: optional "item_reference" or null`
- 要引用的条目类型。始终为 `item_reference`.
+ 被引用条目的类型。始终为 `item_reference`.
- `"item_reference"`
@@ -22192,7 +22184,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -22200,7 +22192,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "program"`
- 条目类型。始终为 `program`.
+ 项的类型。始终为 `program`.
- `"program"`
@@ -22216,7 +22208,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -22228,7 +22220,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "program_output"`
- 条目类型。始终为 `program_output`.
+ 项的类型。始终为 `program_output`.
- `"program_output"`
@@ -22236,22 +22228,22 @@ curl -X POST https://api.openai.com/v1/responses/compact \
插入到模型上下文中的系统(或开发者)消息。
- 当与 `previous_response_id`,配合使用时,前一次
- 响应的指令不会延续到下一次响应。这便于在新响应中
- 替换系统(或开发者)消息。
+ 当与 `previous_response_id`,配合使用时,上一个
+ response 中的 instructions 不会延续到下一个 response。这样可以轻松地
+ 在新的 response 中替换系统(或开发者)消息。
- `max_output_tokens: optional number or null`
- 一次响应中可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
+ 响应可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
- `max_tool_calls: optional number or null`
- 响应中可以处理的内置工具调用总次数上限。该上限适用于所有内置工具调用,而非单个工具。模型任何进一步的工具调用尝试都将被忽略。
+ 一次响应中可处理的内置工具调用总次数上限。该上限适用于所有内置工具调用的总和,而非单个工具。模型后续任何再次调用工具的尝试都将被忽略。
- `metadata: optional Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
格式,以及通过 API 或控制台查询对象。
键为字符串,最长 64 个字符。值为字符串
@@ -22260,8 +22252,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `model: optional ResponsesModel`
用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI
- 提供了多种不同能力、性能
- 特性和定价的模型。请参阅 [模型指南](/docs/models)
+ 提供了众多功能、性能
+ 特性和价位各异的模型。请参阅 [模型指南](/docs/models)
以浏览和比较可用的模型。
- `string`
@@ -22476,19 +22468,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `moderation: optional object { model, policy } or null`
- 用于对此响应的输入和输出运行审核的配置。
+ 用于对此次响应输入和输出运行审核的配置。
- `model: string`
- 用于受审核补全的审核模型,例如 'omni-moderation-latest'。
+ 用于审核补全的审核模型,例如 'omni-moderation-latest'。
- `policy: optional object { input, output } or null`
- 应用于受审核响应输入和输出的策略。
+ 应用于审核响应输入和输出的策略。
- `input: optional object { mode } or null`
- 用于响应输入的审核策略。
+ 响应输入的审核策略。
- `mode: "score" or "block"`
@@ -22498,7 +22490,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `output: optional object { mode } or null`
- 用于响应输出的审核策略。
+ 响应输出的审核策略。
- `mode: "score" or "block"`
@@ -22512,9 +22504,9 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `previous_response_id: optional string or null`
- 模型上一次响应的唯一 ID。使用它来
- 创建多轮对话。了解有关
- [对话状态](/docs/guides/conversation-state)。的更多信息。不能与 `conversation`.
+ 上一个模型响应的唯一 ID。使用它可以
+ 创建多轮对话。详细了解
+ [conversation state](/docs/guides/conversation-state)。不能与 `conversation`.
- `prompt: optional ResponsePrompt or null`
@@ -22527,19 +22519,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `variables: optional map[string or ResponseInputText or ResponseInputImage or ResponseInputFile] or null`
- 用于替换提示模板中变量的可选值映射,
- prompt。替换值可以是字符串,也可以是其他
- Response 输入类型,例如图像或文件。
+ 用于替换你
+ prompt。替换的值可以是字符串,也可以是其他
+ Response 输入类型,如图像或文件。
- `string`
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -22547,19 +22539,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `version: optional string or null`
- 提示模板的可选版本。
+ prompt 模板的可选版本。
- `prompt_cache_key: optional string or null`
- 由 OpenAI 用于缓存相似请求的响应,以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
+ 由OpenAI使用,为相似请求缓存响应以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
- `prompt_cache_options: optional object { mode, ttl }`
- 提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。默认情况下,OpenAI 会自动选择一个隐式缓存断点。你可以使用 `prompt_cache_breakpoint`。为内容块添加显式断点。每个请求最多可以写入四个断点。对于缓存匹配,OpenAI 会考虑对话中最近的最多 80 个断点,且不受内容块回溯长度的限制。将 `mode` 设置为 `explicit` 可禁用隐式断点。 `ttl` 默认为 `30m`,这是当前唯一支持的值。请参阅 [提示缓存指南](/docs/guides/prompt-caching) 了解当前详细信息。
+ 提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。默认情况下,OpenAI 会自动选择一个隐式缓存断点。你可以通过 `prompt_cache_breakpoint`.每个请求最多可以写入四个断点。对于缓存匹配,OpenAI 会考虑对话中最多最新的 80 个断点,且没有内容块回溯限制。将 `mode` 设置为 `explicit` 可禁用隐式断点。 `ttl` 默认为 `30m`,目前这是唯一支持的值。请参阅 [提示缓存指南](/docs/guides/prompt-caching) 了解最新详情。
- `mode: optional "implicit" or "explicit"`
- 控制 OpenAI 是否自动创建隐式缓存断点。默认为 `implicit`。当 `implicit`,时,OpenAI 会创建一个隐式断点,并在请求中写入最多最近的三个显式断点。当 `explicit`,OpenAI 不会创建隐式断点,最多写入最近的四个显式断点。如果没有显式断点,则该请求不会使用提示缓存。
+ 控制 OpenAI 是否自动创建隐式缓存断点。默认为 `implicit`。当为 `implicit`,时,OpenAI 会创建一个隐式断点,并在请求中写入最多最新的三个显式断点。当为 `explicit`,OpenAI 不会创建隐式断点,并最多写入最新的四个显式断点。如果没有显式断点,则该请求不使用提示缓存。
- `"implicit"`
@@ -22567,24 +22559,24 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ttl: optional "30m"`
- 应用于该请求写入的每个隐式和显式缓存断点的最短生命周期。默认为 `30m`,目前这是唯一受支持的值。后端可能会将缓存条目保留更长时间。
+ 应用于该请求所写入的每个隐式和显式缓存断点的最短生命周期。默认为 `30m`,目前这是唯一受支持的值。后端可能会将缓存条目保留更长时间。
- `"30m"`
- `prompt_cache_retention: optional "in_memory" or "24h" or null`
- 已弃用。请使用 `prompt_cache_options.ttl` 相反。
+ 已弃用。请使用 `prompt_cache_options.ttl` 改为。
- 提示词缓存的保留策略。设置为 `24h` 以启用扩展提示词缓存,使缓存前缀保持更长时间,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
- 此字段表示最长保留策略,而
+ 提示缓存的保留策略。设置为 `24h` 以启用扩展提示缓存,使缓存的前缀保持更长时间有效,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
+ 该字段表示最大保留策略,而
`prompt_cache_options.ttl` 表示最短缓存生命周期。这两个
- 字段彼此独立,不会相互影响。
- 对于 `gpt-5.5`, `gpt-5.5-pro`,及未来模型,仅 `24h` 受支持。
+ 字段是独立的,不会相互影响。
+ 对于 `gpt-5.5`, `gpt-5.5-pro`,以及未来的模型,仅 `24h` 。
对于同时支持两者的旧模型 `in_memory` 和 `24h`,默认值取决于你组织的数据保留策略:
- - 未启用 ZDR 的组织默认使用 `24h`.
- - 启用 ZDR 的组织默认使用 `in_memory` 当 `prompt_cache_retention` 未指定时。
+ - 未启用 ZDR 的组织默认为 `24h`.
+ - 启用 ZDR 的组织默认为 `in_memory` 当 `prompt_cache_retention` 未指定时。
- `"in_memory"`
@@ -22592,18 +22584,18 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `reasoning: optional Reasoning or null`
- 配置选项,适用于
+ 适用于
[推理模型](https://platform.openai.com/docs/guides/reasoning).
- `context: optional "auto" or "current_turn" or "all_turns" or null`
- 控制在后续轮次中呈现回模型的推理项。
- 如果省略或设置为 `auto`,则由模型确定上下文模式。
+ 控制在后续回合中哪些推理项会被回传给模型。
+ 如果省略或设置为 `auto`,则由模型决定上下文模式。
`gpt-5.6` 模型系列默认为 `all_turns`;早期模型默认为
`current_turn`.
- 在响应中返回时,这是该响应使用的有效推理上下文模式
- 。
+ 在响应中返回时,这是该响应所使用 的有效推理上下文模式
+ 用于该响应。
- `"auto"`
@@ -22613,13 +22605,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `effort: optional ReasoningEffort or null`
- 限制推理模型在推理上的投入程度。当前支持的值
- 包括 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
- 降低推理投入程度可以让响应更快,并减少响应中推理所用的 token 数。并非所有推理模型都支持每个
- 值。请参阅
- 推理指南
+ 限制推理模型在推理上的投入程度。目前支持
+ 的取值有 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
+ 降低推理投入程度可以让响应更快,并减少响应中用于推理的 token
+ 数量。并非所有推理模型都支持每个
+ 取值。有关各模型的支持情况,请参阅
[推理指南](https://platform.openai.com/docs/guides/reasoning)
- 以了解特定模型的支持情况。
+ 。
- `"none"`
@@ -22637,11 +22629,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `generate_summary: optional "auto" or "concise" or "detailed" or null`
- **已弃用:** 请使用 `summary` 相反。
+ **已弃用:** 请使用 `summary` 改为。
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `"auto"`
@@ -22653,7 +22645,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `string`
@@ -22661,7 +22653,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `"standard"`
@@ -22669,11 +22661,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `summary: optional "auto" or "concise" or "detailed" or null`
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `concise` 支持以下模型 `computer-use-preview` 以及之后的所有推理模型 `gpt-5`.
+ `concise` 支持用于 `computer-use-preview` 模型以及之后的 `gpt-5`.
- `"auto"`
@@ -22683,21 +22675,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `safety_identifier: optional string or null`
- 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用策略的应用程序用户。
- ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份识别信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用政策的应用用户。
+ ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `service_tier: optional ServiceTier or null`
指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
+ - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则该项目将使用 'default'。
- 如果设置为 'default',则该请求将使用所选模型的标准定价和性能进行处理。
- 如果设置为 '[flex](/docs/guides/flex-processing)',则该请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别选择启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 `service_tier=fast` 或 `service_tier=priority` 参数用于 Responses 或 Chat Completions。响应将显示 `service_tier=priority` ,无论你是否在请求中指定了 `service_tier=fast` 或 `priority` 。
- - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级返回的响应将显示 `service_tier=ultrafast`.
- - 如果未设置,默认行为是 'auto'。
+ - 若要在请求级别启用 [快速模式](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过它处理的响应将显示 `service_tier=ultrafast`.
+ - 未设置时,默认行为为 'auto'。
- 当设置 `service_tier` 参数时,响应正文将包含基于实际用于处理该请求的处理模式的 `service_tier` 值。此响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应体中将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。此响应中的值可能与该参数中设置的值不同。
- `"auto"`
@@ -22720,34 +22712,34 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `stream: optional boolean or null`
- 如果设置为 true,模型响应数据将流式传输到客户端
- ,使用 [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
+ 如果设置为 true,则模型响应数据将在生成时通过
+ 流式传输到客户端,使用 [服务端发送事件](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
参见下方 [流式传输部分](/docs/api-reference/responses-streaming)
- 了解更多信息。
+ 以了解更多信息。
- `stream_options: optional object { include_obfuscation } or null`
- 用于流式响应选项。仅当你设置了 `stream: true`.
+ 流式响应选项。仅当设置了 `stream: true`.
- `include_obfuscation: optional boolean`
- 为 true 时,将启用流混淆。流混淆会向流式增量事件上的
- 字段添加 `obfuscation` 随机字符
- 将载荷大小归一化,作为对某些侧信道攻击的缓解措施。
- 默认会包含这些混淆字段,但会为数据流带来少量
- 开销。你可以将 `include_obfuscation` 设置为
- 设为 false 以优化带宽,前提是你信任应用与
- OpenAI API 之间的网络链路。
+ 为 true 时,将启用流混淆。流混淆会向流式 delta 事件中的某个
+ 字段添加随机字符,以 `obfuscation` 字段进行混淆。
+ 将负载大小归一化,作为对某些侧信道攻击的缓解措施。
+ 默认情况下会包含这些混淆字段,但会在数据流中增加少量
+ 开销。你可以设置 `include_obfuscation` 设置为
+ 如果你信任你的应用与
+ OpenAI API 之间的网络链路,可以设为 false 以优化带宽。
- `temperature: optional number or null`
- 使用的采样温度,介于 0 到 2 之间。较高的值(例如 0.8)会使输出更加随机,而较低的值(例如 0.2)会使输出更加聚焦和确定。
- 我们通常建议修改此参数或 `top_p` 但不要同时修改两者。
+ 使用的采样温度,介于 0 到 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加聚焦和确定性。
+ 我们通常建议调整此项或 `top_p` 但不要同时调整两者。
- `text: optional ResponseTextConfig`
- 用于配置模型文本响应的选项。可以是纯文本,也可以是结构化的 JSON 数据。详见:
- 文本输入与输出:
+ 模型文本响应的配置选项。可以是纯
+ 文本或结构化 JSON 数据。了解更多:
- [文本输入与输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
@@ -22756,79 +22748,79 @@ curl -X POST https://api.openai.com/v1/responses/compact \
用于指定模型必须输出的格式的对象。
- 设置为 `{ "type": "json_schema" }` 时,将启用结构化输出,
- 功能,从而确保模型的输出与你提供的 JSON schema 相匹配。详见
+ 配置 `{ "type": "json_schema" }` 可启用结构化输出,
+ 从而确保模型匹配你提供的 JSON schema。更多信息请参阅
[结构化输出指南](/docs/guides/structured-outputs).
- 默认的格式为 `{ "type": "text" }` ,且不包含其他选项。
+ 默认格式为 `{ "type": "text" }` ,不包含任何额外选项。
- **不建议在 gpt-4o 及更新模型上使用:**
+ **不推荐用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
- 的模型,建议优先使用该格式。
+ 设置为 `{ "type": "json_object" }` 会启用旧版 JSON 模式,该模式
+ 可确保模型生成的消息是合法 JSON。对于支持 `json_schema`
+ 的模型,建议优先使用它。
- `ResponseFormatText object { type }`
- 默认的响应格式。用于生成文本响应。
+ 默认响应格式。用于生成文本响应。
- `type: "text"`
- 正在定义的响应格式的类型。始终为 `text`.
+ 正在定义的响应格式类型。始终为 `text`.
- `"text"`
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化的 JSON 响应。
+ JSON Schema 响应格式。用于生成结构化 JSON 响应。
详细了解 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
- 下划线和连字符,最大长度为 64。
+ 下划线和短横线,最大长度为 64。
- `schema: map[unknown]`
- 响应格式的 schema,以 JSON Schema 对象描述。
- 了解如何构建 JSON schema [此处](https://json-schema.org/).
+ 响应格式的架构,以 JSON Schema 对象形式描述。
+ 了解如何构建 JSON 架构 [此处](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式的类型。始终为 `json_schema`.
+ 正在定义的响应格式类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
响应格式用途的描述,供模型用于
- 确定如何按该格式进行响应。
+ 确定如何按该格式响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 一致性。
- 如果设置为 true,模型将始终遵循
- 字段中 `schema` 定义的精确 schema。仅支持 JSON Schema 的一个子集,当
- `strict` 是 `true`。要了解更多信息,请阅读 [Structured Outputs
+ 生成输出时是否启用严格的架构遵循。
+ 如果设置为 true,模型将始终遵循 字段中定义的
+ 确切架构。当 设置为 `schema` true 时,仅支持 JSON Schema 的一个子集
+ `strict` 是 `true`。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较早的生成 JSON 响应的方法。
- 使用 `json_schema` 对支持它的模型是推荐的做法。请注意
- 模型在没有系统或用户消息指示的情况下不会生成
- JSON。
+ JSON 对象响应格式。一种较旧的 JSON 响应生成方法。建议。
+ 对于支持 的模型,使用 `json_schema` 。请注意,模型不会在没有系统或用户消息指示
+ 的情况下生成 JSON
+ 。
- `type: "json_object"`
- 正在定义的响应格式的类型。始终为 `json_object`.
+ 正在定义的响应格式类型。始终为 `json_object`.
- `"json_object"`
- `verbosity: optional "low" or "medium" or "high" or null`
- 约束模型响应的详细程度。较低的值会产生
- 更简洁的响应,较高的值会产生更详细的响应。
+ 约束模型响应的详尽程度。较低的值将导致
+ 更简洁的响应,而较高的值将导致更冗长的响应。
当前支持的值包括 `low`, `medium`,和 `high`。默认值为
`medium`.
@@ -22846,9 +22838,9 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ToolChoiceOptions = "none" or "auto" or "required"`
- 控制模型调用哪个工具(如果有的话)。
+ 控制模型调用哪个工具(如果有)。
- `none` 表示模型不会调用任何工具,而是生成一条消息。
+ `none` 表示模型将不会调用任何工具,而是生成一条消息。
`auto` 表示模型可以在生成消息或调用一个或
多个工具之间进行选择。
@@ -22880,7 +22872,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `tools: array of map[unknown]`
- 模型应允许调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -22901,11 +22893,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ToolChoiceTypes object { type }`
指示模型应使用内置工具来生成响应。
- [了解有关内置工具的更多信息](/docs/guides/tools).
+ [了解更多关于内置工具的信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
- 模型应使用的托管工具类型。了解更多关于
+ 模型应使用的 托管工具 类型。了解更多关于
[内置工具](/docs/guides/tools).
允许的值为:
@@ -22950,7 +22942,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ToolChoiceMcp object { server_label, type, name }`
- 使用此选项可以强制模型调用远程 MCP 服务器上的特定工具。
+ 使用此选项可强制模型调用远程 MCP 服务器上的特定工具。
- `server_label: string`
@@ -22968,7 +22960,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ToolChoiceCustom object { name, type }`
- 使用此选项可以强制模型调用特定的自定义工具。
+ 使用此选项可强制模型调用特定的自定义工具。
- `name: string`
@@ -22984,27 +22976,27 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "programmatic_tool_calling"`
- 要调用的工具。始终为 `programmatic_tool_calling`.
+ 要调用的工具。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ToolChoiceApplyPatch object { type }`
- 在执行工具调用时强制模型调用 apply_patch 工具。
+ 强制模型在执行工具调用时调用 apply_patch 工具。
- `type: "apply_patch"`
- 要调用的工具。始终为 `apply_patch`.
+ 要调用的工具。始终 `apply_patch`.
- `"apply_patch"`
- `ToolChoiceShell object { type }`
- 在需要工具调用时强制模型调用 shell 工具。
+ 在需要工具调用时,强制模型调用 shell 工具。
- `type: "shell"`
- 要调用的工具。始终为 `shell`.
+ 要调用的工具。始终 `shell`.
- `"shell"`
@@ -23015,18 +23007,18 @@ curl -X POST https://api.openai.com/v1/responses/compact \
我们支持以下类别的工具:
- - **内置工具**:由 OpenAI 提供的工具,用于扩展模型的
- 能力,例如 [网页搜索](/docs/guides/tools-web-search)
+ - **内置工具**:由 OpenAI 提供的工具,用于扩展
+ 模型的能力,例如 [网页搜索](/docs/guides/tools-web-search)
或 [文件搜索](/docs/guides/tools-file-search)。详细了解
[内置工具](/docs/guides/tools).
- - **MCP 工具**:通过自定义 MCP 服务器与第三方系统集成
- 或 Google Drive 和 SharePoint 等预定义连接器。详细了解
+ - **MCP 工具**: 通过自定义 MCP 服务器与第三方系统集成
+ 或使用 Google Drive 和 SharePoint 等预定义连接器。详细了解
[MCP 工具](/docs/guides/tools-connectors-mcp).
- - **函数调用(自定义工具)**:由你定义的函数,
+ - **函数调用(自定义工具)**: 由你定义的函数,
使模型能够使用强类型参数和输出调用你自己的代码。详细了解
。你也可以使用
- [function calling](/docs/guides/function-calling)。你还可以使用
- 自定义工具调用你自己的代码。
+ [function calling](/docs/guides/function-calling). 你也可以使用
+ 自定义工具来调用你自己的代码。
- `Function object { name, parameters, strict, 5 more }`
@@ -23060,45 +23052,45 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -23106,7 +23098,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -23118,7 +23110,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -23126,21 +23118,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -23166,18 +23158,18 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -23185,22 +23177,22 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -23210,23 +23202,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -23237,11 +23229,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -23259,21 +23251,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -23281,14 +23273,14 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -23320,32 +23312,32 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -23353,13 +23345,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -23367,9 +23359,9 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -23381,22 +23373,22 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -23405,7 +23397,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -23415,7 +23407,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -23471,7 +23463,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -23481,11 +23473,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -23495,7 +23487,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -23503,7 +23495,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -23512,13 +23504,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -23527,7 +23519,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -23554,7 +23546,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -23565,7 +23557,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -23582,13 +23574,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -23604,7 +23596,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -23614,7 +23606,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -23640,11 +23632,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -23670,19 +23662,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -23702,19 +23694,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -23722,11 +23714,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -23772,7 +23764,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -23784,11 +23776,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -23802,7 +23794,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -23812,7 +23804,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -23822,23 +23814,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -23856,29 +23848,29 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `top_logprobs: optional number or null`
- 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的最大最可能
- token 数量,每个 token 都附带对应的对数
+ 一个介于 0 到 20 之间的整数,指定在每个 token 位置返回的
+ 最可能 token 的最大数量,每个 token 都有一个关联的对数
概率。在某些情况下,返回的 token 数量可能少于
- 所请求的数量。
+ 请求的数量。
- `top_p: optional number or null`
- 一种名为核采样的温度采样替代方案,
- 其中模型会考虑 top_p 概率质量排名前列的词元结果。
- 因此,0.1 表示仅考虑构成前 10% 概率质量的词元。
+ 一种温度采样的替代方法,称为核采样,
+ 模型会考虑概率质量排名前 top_p 的标记的结果。
+ 因此 0.1 表示仅考虑构成前 10% 概率质量的标记。
会被考虑。
- 我们通常建议修改此参数或 `temperature` 但不要同时修改两者。
+ 我们通常建议调整此项或 `temperature` 但不要同时调整两者。
- `truncation: optional "auto" or "disabled" or null`
用于模型响应的截断策略。
- - `auto`:如果此 Response 的输入超过
- 模型的上下文窗口大小,模型将通过从对话开头丢弃条目来截断
- 响应以适配上下文窗口。
- - `disabled` (默认):如果输入大小将超出模型的上下文窗口
- 大小,请求将失败并返回 400 错误。
+ - `auto`:如果此 Response 的输入超出
+ 模型的上下文窗口大小,模型将通过从对话开头
+ 丢弃条目来截断响应以适配上下文窗口。
+ - `disabled` (默认):如果输入大小将超过模型的上下文窗口
+ 大小,请求将以 400 错误失败。
- `"auto"`
@@ -23886,11 +23878,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `user: optional string`
- 此字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
- 用于标识你的最终用户的稳定标识符。
- 通过更好地对相似请求进行分桶以提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 该字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
+ 你的最终用户的稳定标识符。
+ 通过更好地对相似请求进行分桶来提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
-### 返回
+### 返回值
- `Response object { id, created_at, error, 32 more }`
@@ -23900,7 +23892,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `created_at: number`
- 创建此 Response 时的 Unix 时间戳(以秒为单位)。
+ 此 Response 创建时的 Unix 时间戳(以秒为单位)。
- `error: ResponseError or null`
@@ -23956,87 +23948,89 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `incomplete_details: object { reason } or null`
- 有关响应未完成原因的详细信息。
+ 有关响应不完整的详细原因。
- - `reason: optional "max_output_tokens" or "content_filter"`
+ - `reason: optional "max_output_tokens" or "max_messages" or "content_filter"`
- 响应未完成的原因。
+ 响应不完整的原因。
- `"max_output_tokens"`
+ - `"max_messages"`
+
- `"content_filter"`
- `instructions: string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more or null`
插入到模型上下文中的系统(或开发者)消息。
- 当与 `previous_response_id`,配合使用时,前一次
- 响应的指令不会延续到下一次响应。这便于在新响应中
- 替换系统(或开发者)消息。
+ 当与 `previous_response_id`,配合使用时,上一个
+ response 中的 instructions 不会延续到下一个 response。这样可以轻松地
+ 在新的 response 中替换系统(或开发者)消息。
- `string`
- 发送给模型的文本输入,相当于使用
+ 发送给模型的文本输入,等同于
`developer` 角色的文本输入。
- `InputItemList = array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 发送给模型的一个或多个输入项的列表,包含
+ 发送给模型的一个或多个输入项列表,包含
不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` role. Messages with the
- `assistant` role are presumed to have been generated by the model in previous
- interactions.
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色给出的指令。带有
+ `assistant` 角色的消息被视为模型在之前的
+ 交互中生成。
- `content: string or ResponseInputMessageContentList`
- Text, image, or audio input to the model, used to generate a response.
- Can also contain previous assistant responses.
+ 发送给模型的文本、图像或音频输入,用于生成响应。
+ 也可以包含之前的助手响应。
- `TextInput = string`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputMessageContentList = array of ResponseInputContent`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -24048,25 +24042,25 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -24076,13 +24070,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -24092,33 +24086,33 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `assistant`, `system`, or
+ 消息输入的角色。其一为 接口 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -24131,9 +24125,9 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -24141,24 +24135,24 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: optional "message"`
- 消息输入的类型。始终为 `message`.
+ 消息输入的类型。始终为 接口 `message`.
- `"message"`
- `Message object { content, role, status, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` 角色的文本输入。
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色的文本输入。
- `content: ResponseInputMessageContentList`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `system`, or `developer`.
+ 消息输入的角色。其一为 接口 `user`, `system`,或 `developer`.
- `"user"`
@@ -24168,8 +24162,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -24189,7 +24183,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -24197,15 +24191,15 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -24221,7 +24215,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -24231,25 +24225,25 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -24261,7 +24255,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -24269,11 +24263,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -24327,15 +24321,15 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -24347,8 +24341,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -24364,9 +24358,9 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -24374,8 +24368,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -24387,7 +24381,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -24412,11 +24406,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -24434,7 +24428,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -24443,7 +24437,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -24455,7 +24449,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -24471,8 +24465,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -24496,7 +24490,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -24510,7 +24504,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -24536,7 +24530,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -24554,7 +24548,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -24573,7 +24567,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -24583,11 +24577,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -24607,15 +24601,15 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -24647,19 +24641,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -24683,8 +24677,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -24700,7 +24694,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -24716,7 +24710,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -24724,44 +24718,44 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ComputerCallOutput object { call_id, output, type, 3 more }`
- 一次 computer 工具调用的输出。
+ 计算机工具调用的输出。
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `id: optional string or null`
- computer 工具调用输出的 ID。
+ 计算机工具调用输出的 ID。
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 已被开发者确认的 API 所报告的安全检查结果。
+ 开发者已确认的 API 所报告的安全检查。
- `id: string`
@@ -24777,7 +24771,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值为 `in_progress`, `completed`, or `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -24788,7 +24782,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -24796,12 +24790,12 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -24811,11 +24805,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -24833,7 +24827,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -24847,7 +24841,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -24865,7 +24859,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -24877,14 +24871,14 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -24934,8 +24928,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -24949,7 +24943,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `output: string or array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的文本、图片或文件输出。
+ 函数工具调用的文本、图像或文件输出。
- `string`
@@ -24957,61 +24951,61 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的内容输出(文本、图片、文件)数组。
+ 函数工具调用的内容输出(文本、图像、文件)数组。
- `ResponseInputTextContent object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision)
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `detail: optional ImageDetail or null`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -25021,13 +25015,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -25041,23 +25035,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -25069,7 +25063,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `id: optional string or null`
- 函数工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
+ 函数工具调用输出的唯一 ID。当此项通过 API 返回时填充。
- `call_id: optional string or null`
@@ -25109,7 +25103,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -25125,7 +25119,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "tool_search_call"`
- 条目类型。始终为 `tool_search_call`.
+ 项的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
@@ -25193,37 +25187,37 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -25236,11 +25230,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -25260,7 +25254,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -25276,15 +25270,15 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -25298,7 +25292,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -25306,7 +25300,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -25318,7 +25312,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -25326,21 +25320,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -25366,18 +25360,18 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -25385,22 +25379,22 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -25410,23 +25404,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -25437,11 +25431,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -25459,21 +25453,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -25481,14 +25475,14 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -25520,32 +25514,32 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -25553,13 +25547,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -25567,9 +25561,9 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -25581,22 +25575,22 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -25605,7 +25599,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -25615,7 +25609,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -25645,29 +25639,29 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -25703,7 +25697,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -25713,11 +25707,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -25727,7 +25721,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -25735,7 +25729,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -25744,13 +25738,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -25759,7 +25753,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -25786,7 +25780,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -25797,7 +25791,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -25814,13 +25808,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -25836,7 +25830,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -25846,7 +25840,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -25870,7 +25864,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -25894,13 +25888,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -25924,7 +25918,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -25932,13 +25926,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -25958,7 +25952,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -25970,13 +25964,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -25990,11 +25984,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -26020,7 +26014,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -26038,7 +26032,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -26052,19 +26046,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -26084,19 +26078,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -26104,11 +26098,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -26154,7 +26148,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -26166,11 +26160,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -26184,7 +26178,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -26194,7 +26188,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -26204,23 +26198,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -26238,13 +26232,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "tool_search_output"`
- 条目类型。始终为 `tool_search_output`.
+ 项的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `id: optional string or null`
- 此工具搜索输出的唯一 ID。
+ 该工具搜索输出的唯一 ID。
- `call_id: optional string or null`
@@ -26272,13 +26266,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `role: "developer"`
- 提供其他工具的角色。仅 `developer` 受支持。
+ 提供这些额外工具的角色。仅支持 `developer` 。
- `"developer"`
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 此项目提供的其他工具列表。
+ 在该条目中提供的额外工具列表。
- `Function object { name, parameters, strict, 5 more }`
@@ -26312,45 +26306,45 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -26358,7 +26352,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -26370,7 +26364,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -26378,21 +26372,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -26418,18 +26412,18 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -26437,22 +26431,22 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -26462,23 +26456,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -26489,11 +26483,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -26511,21 +26505,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -26533,14 +26527,14 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -26572,32 +26566,32 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -26605,13 +26599,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -26619,9 +26613,9 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -26633,22 +26627,22 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -26657,7 +26651,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -26667,7 +26661,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -26723,7 +26717,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -26733,11 +26727,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -26747,7 +26741,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -26755,7 +26749,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -26764,13 +26758,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -26779,7 +26773,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -26806,7 +26800,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -26817,7 +26811,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -26834,13 +26828,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -26856,7 +26850,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -26866,7 +26860,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -26892,11 +26886,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -26922,19 +26916,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -26954,19 +26948,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -26974,11 +26968,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -27024,7 +27018,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -27036,11 +27030,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -27054,7 +27048,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -27064,7 +27058,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -27074,23 +27068,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -27108,19 +27102,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "additional_tools"`
- 条目类型。始终为 `additional_tools`.
+ 项的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `id: optional string or null`
- 此其他工具项目的唯一 ID。
+ 该额外工具条目的唯一 ID。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -27133,7 +27127,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -27153,7 +27147,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -27163,20 +27157,20 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -27186,7 +27180,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Compaction object { encrypted_content, type, id }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -27194,17 +27188,17 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `id: optional string or null`
- 压缩条目的 ID。
+ 压缩项的 ID。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -27228,7 +27222,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -27251,7 +27245,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -27263,23 +27257,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -27297,13 +27291,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -27319,11 +27313,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -27337,11 +27331,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -27355,7 +27349,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -27365,7 +27359,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -27373,13 +27367,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -27393,7 +27387,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
@@ -27405,7 +27399,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最大挂钟时间(毫秒)。
+ 允许 shell 命令运行的 wall-clock 最长时间(毫秒)。
- `call_id: string`
@@ -27413,13 +27407,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
- `id: optional string or null`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -27455,7 +27449,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -27465,7 +27459,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ShellCallOutput object { call_id, output, type, 4 more }`
- shell 工具调用发出的流式输出项。
+ shell 工具调用发出的流式输出条目。
- `call_id: string`
@@ -27473,7 +27467,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `output: array of ResponseFunctionShellCallOutputContent`
- stdout 和 stderr 输出的捕获块及其关联结果。
+ 捕获的 stdout 和 stderr 输出块,以及它们关联的结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -27485,13 +27479,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -27499,27 +27493,27 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
- `stderr: string`
- shell 调用捕获的 stderr 输出。
+ 为该 shell 调用捕获的 stderr 输出。
- `stdout: string`
- shell 调用捕获的 stdout 输出。
+ 为该 shell 调用捕获的 stdout 输出。
- `type: "shell_call_output"`
- 条目的类型,恒为 `shell_call_output`.
+ item 的类型。始终为 `shell_call_output`.
- `"shell_call_output"`
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -27561,11 +27555,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 表示使用 diff 补丁创建、删除或更新文件的工具调用。
+ 表示通过 diff 补丁创建、删除或更新文件的工具调用。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
@@ -27577,7 +27571,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `diff: string`
- 创建文件时要应用的统一 diff 内容。
+ 创建文件时应用的 unified diff 内容。
- `path: string`
@@ -27609,7 +27603,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `diff: string`
- 要应用于现有文件的统一 diff 内容。
+ 应用于现有文件的 unified diff 内容。
- `path: string`
@@ -27623,7 +27617,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -27631,13 +27625,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
- `id: optional string or null`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -27665,15 +27659,15 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ApplyPatchCallOutput object { call_id, status, type, 3 more }`
- apply patch 工具调用发出的流式输出。
+ 由 apply patch 工具调用发出的流式输出。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -27681,13 +27675,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
- `id: optional string or null`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -27743,7 +27737,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -27751,29 +27745,29 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -27781,31 +27775,31 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { approval_request_id, approve, type, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
- `id: optional string or null`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `reason: optional string or null`
@@ -27813,7 +27807,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -27821,11 +27815,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -27833,14 +27827,14 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -27880,7 +27874,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -27894,11 +27888,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 由你的代码生成的自定义工具调用输出,将被发送回模型。
+ 由你的代码生成的自定义工具调用的输出,将发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -27915,11 +27909,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -27933,7 +27927,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `id: optional string`
- 自定义工具调用输出在 OpenAI 平台中的唯一 ID。
+ 在 OpenAI 平台中该自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -27983,7 +27977,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -28011,11 +28005,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `CompactionTrigger object { type, id }`
- 压缩当前上下文。必须是最后一个输入项。
+ 压缩当前上下文。必须作为最后一个输入项。
- `type: "compaction_trigger"`
- 条目的类型,恒为 `compaction_trigger`.
+ item 的类型。始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -28029,11 +28023,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `id: string`
- 要引用的条目 ID。
+ 被引用条目的 ID。
- `type: optional "item_reference" or null`
- 要引用的条目类型。始终为 `item_reference`.
+ 被引用条目的类型。始终为 `item_reference`.
- `"item_reference"`
@@ -28049,7 +28043,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -28057,7 +28051,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "program"`
- 条目类型。始终为 `program`.
+ 项的类型。始终为 `program`.
- `"program"`
@@ -28073,7 +28067,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -28085,14 +28079,14 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "program_output"`
- 条目类型。始终为 `program_output`.
+ 项的类型。始终为 `program_output`.
- `"program_output"`
- `metadata: Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
格式,以及通过 API 或控制台查询对象。
键为字符串,最长 64 个字符。值为字符串
@@ -28101,8 +28095,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `model: ResponsesModel`
用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI
- 提供了多种不同能力、性能
- 特性和定价的模型。请参阅 [模型指南](/docs/models)
+ 提供了众多功能、性能
+ 特性和价位各异的模型。请参阅 [模型指南](/docs/models)
以浏览和比较可用的模型。
- `string`
@@ -28325,12 +28319,12 @@ curl -X POST https://api.openai.com/v1/responses/compact \
由模型生成的内容项数组。
- - 该数组中项的数量和顺序 `output` 取决于
- 模型的响应。
- - 与直接访问该数组的 `output` 第一项并
- 假设它是一 `assistant` 个包含模型生成内容的
- 消息相比,你也可以考虑使用 `output_text` 属性(在
- 受支持的 SDK 中可用)。
+ - 该数组中项的长度和顺序取决于 `output` 模型的响应。
+ 与其访问。
+ - 数组中的第一项并 `output` 假设它是一个
+ 包含模型生成内容的 `assistant` 消息,不如使用
+ 属性(在受支持的 开发工具包 `output_text` 中可用)。
+ SDK。
- `ResponseOutputMessage object { id, content, role, 3 more }`
@@ -28338,8 +28332,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -28351,7 +28345,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -28376,11 +28370,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -28398,7 +28392,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -28407,7 +28401,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -28457,8 +28451,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -28483,15 +28477,15 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -28499,8 +28493,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -28544,7 +28538,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `name: optional string`
@@ -28557,7 +28551,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -28565,12 +28559,12 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -28580,11 +28574,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -28602,7 +28596,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -28616,7 +28610,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -28634,7 +28628,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -28646,14 +28640,14 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -28665,7 +28659,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -28681,8 +28675,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -28702,8 +28696,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `ComputerCallOutput object { id, call_id, output, 4 more }`
@@ -28713,16 +28707,16 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"completed"`
@@ -28734,13 +28728,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、已被
+ API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -28757,13 +28751,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -28776,7 +28770,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -28794,7 +28788,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -28804,20 +28798,20 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -28837,7 +28831,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -28845,7 +28839,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "program"`
- 条目的类型,恒为 `program`.
+ item 的类型。始终为 `program`.
- `"program"`
@@ -28861,7 +28855,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -28873,7 +28867,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "program_output"`
- 条目的类型,恒为 `program_output`.
+ item 的类型。始终为 `program_output`.
- `"program_output"`
@@ -28911,13 +28905,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "tool_search_call"`
- 条目的类型,恒为 `tool_search_call`.
+ item 的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -28983,45 +28977,45 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -29029,7 +29023,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -29041,7 +29035,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -29049,21 +29043,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -29089,18 +29083,18 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -29108,22 +29102,22 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -29133,23 +29127,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -29160,11 +29154,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -29182,21 +29176,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -29204,14 +29198,14 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -29243,32 +29237,32 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -29276,13 +29270,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -29290,9 +29284,9 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -29304,22 +29298,22 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -29328,7 +29322,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -29338,7 +29332,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -29394,7 +29388,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -29404,11 +29398,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -29418,7 +29412,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -29426,7 +29420,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -29435,13 +29429,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -29450,7 +29444,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -29477,7 +29471,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -29488,7 +29482,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -29505,13 +29499,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -29527,7 +29521,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -29537,7 +29531,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -29563,11 +29557,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -29593,19 +29587,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -29625,19 +29619,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -29645,11 +29639,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -29695,7 +29689,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -29707,11 +29701,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -29725,7 +29719,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -29735,7 +29729,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -29745,23 +29739,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -29779,13 +29773,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "tool_search_output"`
- 条目的类型,恒为 `tool_search_output`.
+ item 的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -29815,7 +29809,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -29849,45 +29843,45 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -29895,7 +29889,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -29907,7 +29901,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -29915,21 +29909,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -29955,18 +29949,18 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -29974,22 +29968,22 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -29999,23 +29993,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -30026,11 +30020,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -30048,21 +30042,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -30070,14 +30064,14 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -30109,32 +30103,32 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -30142,13 +30136,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -30156,9 +30150,9 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -30170,22 +30164,22 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -30194,7 +30188,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -30204,7 +30198,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -30260,7 +30254,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -30270,11 +30264,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -30284,7 +30278,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -30292,7 +30286,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -30301,13 +30295,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -30316,7 +30310,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -30343,7 +30337,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -30354,7 +30348,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -30371,13 +30365,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -30393,7 +30387,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -30403,7 +30397,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -30429,11 +30423,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -30459,19 +30453,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -30491,19 +30485,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -30511,11 +30505,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -30561,7 +30555,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -30573,11 +30567,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -30591,7 +30585,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -30601,7 +30595,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -30611,23 +30605,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -30645,13 +30639,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "additional_tools"`
- 条目的类型,恒为 `additional_tools`.
+ item 的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -30659,21 +30653,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的已加密内容。
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -30697,7 +30691,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -30720,7 +30714,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -30732,23 +30726,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -30766,13 +30760,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -30788,11 +30782,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -30806,11 +30800,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -30824,7 +30818,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -30834,7 +30828,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -30842,13 +30836,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -30862,17 +30856,17 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `id: string`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -30910,7 +30904,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -30920,7 +30914,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -30954,7 +30948,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。通过 API 返回该条目时填充此字段。
- `call_id: string`
@@ -30962,15 +30956,15 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -30978,13 +30972,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -30992,7 +30986,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -31006,11 +31000,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`, or `incomplete`.
+ shell 调用输出的状态。可选值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -31046,7 +31040,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -31054,15 +31048,15 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `id: string`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -31078,7 +31072,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的 diff 创建新文件。
- `"create_file"`
@@ -31092,7 +31086,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "delete_file"`
- 删除指定的文件。
+ 删除指定文件。
- `"delete_file"`
@@ -31110,13 +31104,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "update_file"`
- 使用提供的差异更新现有文件。
+ 使用提供的 diff 更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -31124,7 +31118,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -31154,19 +31148,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -31174,7 +31168,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -31208,7 +31202,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -31216,11 +31210,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -31228,14 +31222,14 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -31247,7 +31241,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -31285,7 +31279,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -31293,29 +31287,29 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -31323,29 +31317,29 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `id: string`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -31377,7 +31371,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -31411,7 +31405,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -31428,11 +31422,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -31440,8 +31434,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -31481,7 +31475,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `parallel_tool_calls: boolean`
@@ -31489,8 +31483,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `temperature: number or null`
- 使用的采样温度,介于 0 到 2 之间。较高的值(例如 0.8)会使输出更加随机,而较低的值(例如 0.2)会使输出更加聚焦和确定。
- 我们通常建议修改此参数或 `top_p` 但不要同时修改两者。
+ 使用的采样温度,介于 0 到 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加聚焦和确定性。
+ 我们通常建议调整此项或 `top_p` 但不要同时调整两者。
- `tool_choice: ToolChoiceOptions or ToolChoiceAllowed or ToolChoiceTypes or 6 more`
@@ -31500,9 +31494,9 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ToolChoiceOptions = "none" or "auto" or "required"`
- 控制模型调用哪个工具(如果有的话)。
+ 控制模型调用哪个工具(如果有)。
- `none` 表示模型不会调用任何工具,而是生成一条消息。
+ `none` 表示模型将不会调用任何工具,而是生成一条消息。
`auto` 表示模型可以在生成消息或调用一个或
多个工具之间进行选择。
@@ -31534,7 +31528,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `tools: array of map[unknown]`
- 模型应允许调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -31555,11 +31549,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ToolChoiceTypes object { type }`
指示模型应使用内置工具来生成响应。
- [了解有关内置工具的更多信息](/docs/guides/tools).
+ [了解更多关于内置工具的信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
- 模型应使用的托管工具类型。了解更多关于
+ 模型应使用的 托管工具 类型。了解更多关于
[内置工具](/docs/guides/tools).
允许的值为:
@@ -31604,7 +31598,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ToolChoiceMcp object { server_label, type, name }`
- 使用此选项可以强制模型调用远程 MCP 服务器上的特定工具。
+ 使用此选项可强制模型调用远程 MCP 服务器上的特定工具。
- `server_label: string`
@@ -31622,7 +31616,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ToolChoiceCustom object { name, type }`
- 使用此选项可以强制模型调用特定的自定义工具。
+ 使用此选项可强制模型调用特定的自定义工具。
- `name: string`
@@ -31638,27 +31632,27 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "programmatic_tool_calling"`
- 要调用的工具。始终为 `programmatic_tool_calling`.
+ 要调用的工具。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ToolChoiceApplyPatch object { type }`
- 在执行工具调用时强制模型调用 apply_patch 工具。
+ 强制模型在执行工具调用时调用 apply_patch 工具。
- `type: "apply_patch"`
- 要调用的工具。始终为 `apply_patch`.
+ 要调用的工具。始终 `apply_patch`.
- `"apply_patch"`
- `ToolChoiceShell object { type }`
- 在需要工具调用时强制模型调用 shell 工具。
+ 在需要工具调用时,强制模型调用 shell 工具。
- `type: "shell"`
- 要调用的工具。始终为 `shell`.
+ 要调用的工具。始终 `shell`.
- `"shell"`
@@ -31669,18 +31663,18 @@ curl -X POST https://api.openai.com/v1/responses/compact \
我们支持以下类别的工具:
- - **内置工具**:由 OpenAI 提供的工具,用于扩展模型的
- 能力,例如 [网页搜索](/docs/guides/tools-web-search)
+ - **内置工具**:由 OpenAI 提供的工具,用于扩展
+ 模型的能力,例如 [网页搜索](/docs/guides/tools-web-search)
或 [文件搜索](/docs/guides/tools-file-search)。详细了解
[内置工具](/docs/guides/tools).
- - **MCP 工具**:通过自定义 MCP 服务器与第三方系统集成
- 或 Google Drive 和 SharePoint 等预定义连接器。详细了解
+ - **MCP 工具**: 通过自定义 MCP 服务器与第三方系统集成
+ 或使用 Google Drive 和 SharePoint 等预定义连接器。详细了解
[MCP 工具](/docs/guides/tools-connectors-mcp).
- - **函数调用(自定义工具)**:由你定义的函数,
+ - **函数调用(自定义工具)**: 由你定义的函数,
使模型能够使用强类型参数和输出调用你自己的代码。详细了解
。你也可以使用
- [function calling](/docs/guides/function-calling)。你还可以使用
- 自定义工具调用你自己的代码。
+ [function calling](/docs/guides/function-calling). 你也可以使用
+ 自定义工具来调用你自己的代码。
- `Function object { name, parameters, strict, 5 more }`
@@ -31714,45 +31708,45 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -31760,7 +31754,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -31772,7 +31766,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -31780,21 +31774,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -31820,18 +31814,18 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -31839,22 +31833,22 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -31864,23 +31858,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -31891,11 +31885,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -31913,21 +31907,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -31935,14 +31929,14 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -31974,32 +31968,32 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -32007,13 +32001,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -32021,9 +32015,9 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -32035,22 +32029,22 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -32059,7 +32053,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -32069,7 +32063,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -32125,7 +32119,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -32135,11 +32129,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -32149,7 +32143,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -32157,7 +32151,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -32166,13 +32160,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -32181,7 +32175,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -32208,7 +32202,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -32219,7 +32213,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -32236,13 +32230,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -32258,7 +32252,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -32268,7 +32262,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -32294,11 +32288,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -32324,19 +32318,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -32356,19 +32350,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -32376,11 +32370,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -32426,7 +32420,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -32438,11 +32432,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -32456,7 +32450,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -32466,7 +32460,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -32476,23 +32470,23 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -32510,12 +32504,12 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `top_p: number or null`
- 一种名为核采样的温度采样替代方案,
- 其中模型会考虑 top_p 概率质量排名前列的词元结果。
- 因此,0.1 表示仅考虑构成前 10% 概率质量的词元。
+ 一种温度采样的替代方法,称为核采样,
+ 模型会考虑概率质量排名前 top_p 的标记的结果。
+ 因此 0.1 表示仅考虑构成前 10% 概率质量的标记。
会被考虑。
- 我们通常建议修改此参数或 `temperature` 但不要同时修改两者。
+ 我们通常建议调整此项或 `temperature` 但不要同时调整两者。
- `background: optional boolean or null`
@@ -32524,44 +32518,44 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `completed_at: optional number or null`
- 此 Response 完成时的 Unix 时间戳(以秒为单位)。
- 仅当状态为 `completed`.
+ 此响应完成时的 Unix 时间戳(以秒为单位)。
+ 仅在状态为 `completed`.
- `conversation: optional object { id } or null`
- 此响应所属的对话。此响应的输入项和输出项已自动添加到此对话。
+ 此响应所属的对话。此次响应的输入项和输出项已自动添加到此对话中。
- `id: string`
- 与此响应关联的对话的唯一 ID。
+ 此响应关联的对话的唯一 ID。
- `max_output_tokens: optional number or null`
- 一次响应中可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
+ 响应可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
- `max_tool_calls: optional number or null`
- 响应中可以处理的内置工具调用总次数上限。该上限适用于所有内置工具调用,而非单个工具。模型任何进一步的工具调用尝试都将被忽略。
+ 一次响应中可处理的内置工具调用总次数上限。该上限适用于所有内置工具调用的总和,而非单个工具。模型后续任何再次调用工具的尝试都将被忽略。
- `moderation: optional object { input, output } or null`
- 响应输入和输出的审核结果,前提是请求了已审核的补全。
+ 响应输入与输出的内容审核结果,前提是请求了经过审核的补全。
- `input: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输入的审核结果。
+ 对响应输入的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -32569,7 +32563,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -32577,17 +32571,17 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -32599,25 +32593,25 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输出的审核结果。
+ 对响应输出的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -32625,7 +32619,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -32633,17 +32627,17 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -32655,21 +32649,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output_text: optional string or null`
- 仅限SDK的便捷属性,包含所有输出消息中聚合的文本输出
- 来自所有 `output_text` 数组中的 `output` 条目(如果有)。
+ SDK 独有的便捷属性,包含来自所有
+ 的聚合文本输出 `output_text` 数组中的 `output` 条目(如有)。
在 Python 和 JavaScript SDK 中受支持。
- `previous_response_id: optional string or null`
- 模型上一次响应的唯一 ID。使用它来
- 创建多轮对话。了解有关
- [对话状态](/docs/guides/conversation-state)。的更多信息。不能与 `conversation`.
+ 上一个模型响应的唯一 ID。使用它可以
+ 创建多轮对话。详细了解
+ [conversation state](/docs/guides/conversation-state)。不能与 `conversation`.
- `prompt: optional ResponsePrompt or null`
@@ -32682,19 +32676,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `variables: optional map[string or ResponseInputText or ResponseInputImage or ResponseInputFile] or null`
- 用于替换提示模板中变量的可选值映射,
- prompt。替换值可以是字符串,也可以是其他
- Response 输入类型,例如图像或文件。
+ 用于替换你
+ prompt。替换的值可以是字符串,也可以是其他
+ Response 输入类型,如图像或文件。
- `string`
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -32702,19 +32696,19 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `version: optional string or null`
- 提示模板的可选版本。
+ prompt 模板的可选版本。
- `prompt_cache_key: optional string or null`
- 由 OpenAI 用于缓存相似请求的响应,以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
+ 由OpenAI使用,为相似请求缓存响应以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
- `prompt_cache_options: optional object { mode, ttl }`
- 应用于该响应的提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。
+ 应用于该响应的 prompt 缓存选项。支持以下 `gpt-5.6` 及更高版本的模型。
- `mode: "implicit" or "explicit"`
- 是否启用了隐式提示缓存断点。
+ 是否启用了隐式 prompt 缓存断点。
- `"implicit"`
@@ -32722,24 +32716,24 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `ttl: "30m"`
- 应用于每个缓存断点的最短生存时间。
+ 应用于每个缓存断点的最短生命周期。
- `"30m"`
- `prompt_cache_retention: optional "in_memory" or "24h" or null`
- 已弃用。请使用 `prompt_cache_options.ttl` 相反。
+ 已弃用。请使用 `prompt_cache_options.ttl` 改为。
- 提示词缓存的保留策略。设置为 `24h` 以启用扩展提示词缓存,使缓存前缀保持更长时间,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
- 此字段表示最长保留策略,而
+ 提示缓存的保留策略。设置为 `24h` 以启用扩展提示缓存,使缓存的前缀保持更长时间有效,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
+ 该字段表示最大保留策略,而
`prompt_cache_options.ttl` 表示最短缓存生命周期。这两个
- 字段彼此独立,不会相互影响。
- 对于 `gpt-5.5`, `gpt-5.5-pro`,及未来模型,仅 `24h` 受支持。
+ 字段是独立的,不会相互影响。
+ 对于 `gpt-5.5`, `gpt-5.5-pro`,以及未来的模型,仅 `24h` 。
对于同时支持两者的旧模型 `in_memory` 和 `24h`,默认值取决于你组织的数据保留策略:
- - 未启用 ZDR 的组织默认使用 `24h`.
- - 启用 ZDR 的组织默认使用 `in_memory` 当 `prompt_cache_retention` 未指定时。
+ - 未启用 ZDR 的组织默认为 `24h`.
+ - 启用 ZDR 的组织默认为 `in_memory` 当 `prompt_cache_retention` 未指定时。
- `"in_memory"`
@@ -32747,18 +32741,18 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `reasoning: optional Reasoning or null`
- 配置选项,适用于
+ 适用于
[推理模型](https://platform.openai.com/docs/guides/reasoning).
- `context: optional "auto" or "current_turn" or "all_turns" or null`
- 控制在后续轮次中呈现回模型的推理项。
- 如果省略或设置为 `auto`,则由模型确定上下文模式。
+ 控制在后续回合中哪些推理项会被回传给模型。
+ 如果省略或设置为 `auto`,则由模型决定上下文模式。
`gpt-5.6` 模型系列默认为 `all_turns`;早期模型默认为
`current_turn`.
- 在响应中返回时,这是该响应使用的有效推理上下文模式
- 。
+ 在响应中返回时,这是该响应所使用 的有效推理上下文模式
+ 用于该响应。
- `"auto"`
@@ -32768,13 +32762,13 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `effort: optional ReasoningEffort or null`
- 限制推理模型在推理上的投入程度。当前支持的值
- 包括 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
- 降低推理投入程度可以让响应更快,并减少响应中推理所用的 token 数。并非所有推理模型都支持每个
- 值。请参阅
- 推理指南
+ 限制推理模型在推理上的投入程度。目前支持
+ 的取值有 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
+ 降低推理投入程度可以让响应更快,并减少响应中用于推理的 token
+ 数量。并非所有推理模型都支持每个
+ 取值。有关各模型的支持情况,请参阅
[推理指南](https://platform.openai.com/docs/guides/reasoning)
- 以了解特定模型的支持情况。
+ 。
- `"none"`
@@ -32792,11 +32786,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `generate_summary: optional "auto" or "concise" or "detailed" or null`
- **已弃用:** 请使用 `summary` 相反。
+ **已弃用:** 请使用 `summary` 改为。
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `"auto"`
@@ -32808,7 +32802,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `string`
@@ -32816,7 +32810,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `"standard"`
@@ -32824,11 +32818,11 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `summary: optional "auto" or "concise" or "detailed" or null`
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `concise` 支持以下模型 `computer-use-preview` 以及之后的所有推理模型 `gpt-5`.
+ `concise` 支持用于 `computer-use-preview` 模型以及之后的 `gpt-5`.
- `"auto"`
@@ -32838,21 +32832,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `safety_identifier: optional string or null`
- 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用策略的应用程序用户。
- ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份识别信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用政策的应用用户。
+ ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `service_tier: optional ServiceTier or null`
指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
+ - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则该项目将使用 'default'。
- 如果设置为 'default',则该请求将使用所选模型的标准定价和性能进行处理。
- 如果设置为 '[flex](/docs/guides/flex-processing)',则该请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别选择启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 `service_tier=fast` 或 `service_tier=priority` 参数用于 Responses 或 Chat Completions。响应将显示 `service_tier=priority` ,无论你是否在请求中指定了 `service_tier=fast` 或 `priority` 。
- - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级返回的响应将显示 `service_tier=ultrafast`.
- - 如果未设置,默认行为是 'auto'。
+ - 若要在请求级别启用 [快速模式](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过它处理的响应将显示 `service_tier=ultrafast`.
+ - 未设置时,默认行为为 'auto'。
- 当设置 `service_tier` 参数时,响应正文将包含基于实际用于处理该请求的处理模式的 `service_tier` 值。此响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应体中将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。此响应中的值可能与该参数中设置的值不同。
- `"auto"`
@@ -32870,8 +32864,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `status: optional ResponseStatus`
- 响应生成的状态。取值之一为 `completed`, `failed`,
- `in_progress`, `cancelled`, `queued`, or `incomplete`.
+ 响应生成的状态。可选值为 `completed`, `failed`,
+ `in_progress`, `cancelled`, `queued`,或 `incomplete`.
- `"completed"`
@@ -32887,8 +32881,8 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `text: optional ResponseTextConfig`
- 用于配置模型文本响应的选项。可以是纯文本,也可以是结构化的 JSON 数据。详见:
- 文本输入与输出:
+ 模型文本响应的配置选项。可以是纯
+ 文本或结构化 JSON 数据。了解更多:
- [文本输入与输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
@@ -32897,79 +32891,79 @@ curl -X POST https://api.openai.com/v1/responses/compact \
用于指定模型必须输出的格式的对象。
- 设置为 `{ "type": "json_schema" }` 时,将启用结构化输出,
- 功能,从而确保模型的输出与你提供的 JSON schema 相匹配。详见
+ 配置 `{ "type": "json_schema" }` 可启用结构化输出,
+ 从而确保模型匹配你提供的 JSON schema。更多信息请参阅
[结构化输出指南](/docs/guides/structured-outputs).
- 默认的格式为 `{ "type": "text" }` ,且不包含其他选项。
+ 默认格式为 `{ "type": "text" }` ,不包含任何额外选项。
- **不建议在 gpt-4o 及更新模型上使用:**
+ **不推荐用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
- 的模型,建议优先使用该格式。
+ 设置为 `{ "type": "json_object" }` 会启用旧版 JSON 模式,该模式
+ 可确保模型生成的消息是合法 JSON。对于支持 `json_schema`
+ 的模型,建议优先使用它。
- `ResponseFormatText object { type }`
- 默认的响应格式。用于生成文本响应。
+ 默认响应格式。用于生成文本响应。
- `type: "text"`
- 正在定义的响应格式的类型。始终为 `text`.
+ 正在定义的响应格式类型。始终为 `text`.
- `"text"`
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化的 JSON 响应。
+ JSON Schema 响应格式。用于生成结构化 JSON 响应。
详细了解 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
- 下划线和连字符,最大长度为 64。
+ 下划线和短横线,最大长度为 64。
- `schema: map[unknown]`
- 响应格式的 schema,以 JSON Schema 对象描述。
- 了解如何构建 JSON schema [此处](https://json-schema.org/).
+ 响应格式的架构,以 JSON Schema 对象形式描述。
+ 了解如何构建 JSON 架构 [此处](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式的类型。始终为 `json_schema`.
+ 正在定义的响应格式类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
响应格式用途的描述,供模型用于
- 确定如何按该格式进行响应。
+ 确定如何按该格式响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 一致性。
- 如果设置为 true,模型将始终遵循
- 字段中 `schema` 定义的精确 schema。仅支持 JSON Schema 的一个子集,当
- `strict` 是 `true`。要了解更多信息,请阅读 [Structured Outputs
+ 生成输出时是否启用严格的架构遵循。
+ 如果设置为 true,模型将始终遵循 字段中定义的
+ 确切架构。当 设置为 `schema` true 时,仅支持 JSON Schema 的一个子集
+ `strict` 是 `true`。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较早的生成 JSON 响应的方法。
- 使用 `json_schema` 对支持它的模型是推荐的做法。请注意
- 模型在没有系统或用户消息指示的情况下不会生成
- JSON。
+ JSON 对象响应格式。一种较旧的 JSON 响应生成方法。建议。
+ 对于支持 的模型,使用 `json_schema` 。请注意,模型不会在没有系统或用户消息指示
+ 的情况下生成 JSON
+ 。
- `type: "json_object"`
- 正在定义的响应格式的类型。始终为 `json_object`.
+ 正在定义的响应格式类型。始终为 `json_object`.
- `"json_object"`
- `verbosity: optional "low" or "medium" or "high" or null`
- 约束模型响应的详细程度。较低的值会产生
- 更简洁的响应,较高的值会产生更详细的响应。
+ 约束模型响应的详尽程度。较低的值将导致
+ 更简洁的响应,而较高的值将导致更冗长的响应。
当前支持的值包括 `low`, `medium`,和 `high`。默认值为
`medium`.
@@ -32981,20 +32975,20 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `top_logprobs: optional number or null`
- 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的最大最可能
- token 数量,每个 token 都附带对应的对数
+ 一个介于 0 到 20 之间的整数,指定在每个 token 位置返回的
+ 最可能 token 的最大数量,每个 token 都有一个关联的对数
概率。在某些情况下,返回的 token 数量可能少于
- 所请求的数量。
+ 请求的数量。
- `truncation: optional "auto" or "disabled" or null`
用于模型响应的截断策略。
- - `auto`:如果此 Response 的输入超过
- 模型的上下文窗口大小,模型将通过从对话开头丢弃条目来截断
- 响应以适配上下文窗口。
- - `disabled` (默认):如果输入大小将超出模型的上下文窗口
- 大小,请求将失败并返回 400 错误。
+ - `auto`:如果此 Response 的输入超出
+ 模型的上下文窗口大小,模型将通过从对话开头
+ 丢弃条目来截断响应以适配上下文窗口。
+ - `disabled` (默认):如果输入大小将超过模型的上下文窗口
+ 大小,请求将以 400 错误失败。
- `"auto"`
@@ -33003,7 +32997,7 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `usage: optional ResponseUsage`
表示 token 使用详情,包括输入 token、输出 token,
- 的输出 token 明细,以及所使用的 token 总数。
+ 输出 token 的细分,以及使用的总 token 数。
- `input_tokens: number`
@@ -33011,16 +33005,16 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `input_tokens_details: object { cache_write_tokens, cached_tokens }`
- 输入 token 的详细明细。
+ 输入 token 的详细细分。
- `cache_write_tokens: number`
- 已写入缓存的输入 token 数量。
+ 写入缓存的输入 token 的数量。
- `cached_tokens: number`
- 从缓存中检索到的 token 数量。
- [了解更多关于提示缓存的信息](/docs/guides/prompt-caching).
+ 从缓存中检索到的 token 的数量。
+ [有关 prompt caching 的更多信息](/docs/guides/prompt-caching).
- `output_tokens: number`
@@ -33028,25 +33022,21 @@ curl -X POST https://api.openai.com/v1/responses/compact \
- `output_tokens_details: object { reasoning_tokens }`
- 输出令牌的详细明细。
+ 输出 token 的详细明细。
- `reasoning_tokens: number`
- 推理令牌的数量。
+ 推理 token 的数量。
- `total_tokens: number`
- 使用的令牌总数。
-
- - `compute_units: optional number or null`
-
- 该请求的计算单元。在可用时当前为 null。
+ 使用的 token 总数。
- `user: optional string`
- 此字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
- 用于标识你的最终用户的稳定标识符。
- 通过更好地对相似请求进行分桶以提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 该字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
+ 你的最终用户的稳定标识符。
+ 通过更好地对相似请求进行分桶来提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
### 示例
@@ -33064,7 +33054,7 @@ curl https://api.openai.com/v1/responses \
}'
```
-#### 响应
+#### Response
```json
{
@@ -33230,14 +33220,13 @@ curl https://api.openai.com/v1/responses \
"output_tokens_details": {
"reasoning_tokens": 0
},
- "total_tokens": 0,
- "compute_units": 0
+ "total_tokens": 0
},
"user": "user-1234"
}
```
-### 文件输入
+### File input
```http
curl https://api.openai.com/v1/responses \
@@ -33261,7 +33250,7 @@ curl https://api.openai.com/v1/responses \
}'
```
-#### 响应
+#### Response
```json
{
@@ -33346,7 +33335,7 @@ curl https://api.openai.com/v1/responses \
}'
```
-#### 响应
+#### Response
```json
{
@@ -33480,7 +33469,7 @@ curl https://api.openai.com/v1/responses \
}
```
-### 函数
+### Functions
```http
curl https://api.openai.com/v1/responses \
@@ -33514,7 +33503,7 @@ curl https://api.openai.com/v1/responses \
}'
```
-#### 响应
+#### Response
```json
{
@@ -33595,7 +33584,7 @@ curl https://api.openai.com/v1/responses \
}
```
-### 图像输入
+### Image input
```http
curl https://api.openai.com/v1/responses \
@@ -33618,7 +33607,7 @@ curl https://api.openai.com/v1/responses \
}'
```
-#### 响应
+#### Response
```json
{
@@ -33681,7 +33670,7 @@ curl https://api.openai.com/v1/responses \
}
```
-### 推理
+### Reasoning
```http
curl https://api.openai.com/v1/responses \
@@ -33696,7 +33685,7 @@ curl https://api.openai.com/v1/responses \
}'
```
-#### 响应
+#### Response
```json
{
@@ -33759,7 +33748,7 @@ curl https://api.openai.com/v1/responses \
}
```
-### 流式传输
+### Streaming
```http
curl https://api.openai.com/v1/responses \
@@ -33773,7 +33762,7 @@ curl https://api.openai.com/v1/responses \
}'
```
-#### 响应
+#### Response
```json
event: response.created
@@ -33806,7 +33795,7 @@ event: response.completed
data: {"type":"response.completed","response":{"id":"resp_67c9fdcecf488190bdd9a0409de3a1ec07b8b0ad4e5eb654","object":"response","created_at":1741290958,"status":"completed","error":null,"incomplete_details":null,"instructions":"You are a helpful assistant.","max_output_tokens":null,"model":"gpt-5.6-sol","output":[{"id":"msg_67c9fdcf37fc8190ba82116e33fb28c507b8b0ad4e5eb654","type":"message","status":"completed","role":"assistant","content":[{"type":"output_text","text":"Hi there! How can I assist you today?","annotations":[]}]}],"parallel_tool_calls":true,"previous_response_id":null,"reasoning":{"effort":null,"summary":null},"store":true,"temperature":1.0,"text":{"format":{"type":"text"}},"tool_choice":"auto","tools":[],"top_p":1.0,"truncation":"disabled","usage":{"input_tokens":37,"output_tokens":11,"output_tokens_details":{"reasoning_tokens":0},"total_tokens":48},"user":null,"metadata":{}}}
```
-### 文本输入
+### Text input
```http
curl https://api.openai.com/v1/responses \
@@ -33818,7 +33807,7 @@ curl https://api.openai.com/v1/responses \
}'
```
-#### 响应
+#### Response
```json
{
@@ -33894,7 +33883,7 @@ curl https://api.openai.com/v1/responses \
}'
```
-#### 响应
+#### Response
```json
{
@@ -33997,11 +33986,11 @@ curl https://api.openai.com/v1/responses \
}
```
-## 删除模型响应
+## Delete a model response
**delete** `/responses/{response_id}`
-删除具有指定 ID 的模型响应。
+删除具有给定 ID 的模型响应。
### 路径参数
@@ -34023,7 +34012,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
-H "Authorization: Bearer $OPENAI_API_KEY"
```
-#### 响应
+#### Response
```json
{
@@ -34037,7 +34026,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
**get** `/responses/{response_id}`
-使用给定的 ID 检索模型响应。
+根据给定 ID 检索模型响应。
### 路径参数
@@ -34047,8 +34036,8 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `include: optional array of ResponseIncludable`
- 要在响应中包含的其他字段。详见上方 `include`
- 参数的 Response 创建部分以了解更多信息。
+ 响应中要包含的其他字段。更多信息请参阅上面的 Response 创建 `include`
+ 参数。
- `"file_search_call.results"`
@@ -34068,28 +34057,28 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `include_obfuscation: optional boolean`
- 为 true 时,将启用流混淆。流混淆会向流式增量事件上的
- 字段添加 `obfuscation` 流式增量事件上的字段
- 用于规范化负载大小,作为对某些侧信道的缓解措施
- 攻击。这些混淆字段默认包含在内,但会给数据流带来
- 少量开销。如果你信任你的应用程序与 OpenAI API 之间的网络链路,可以将
- `include_obfuscation` 设为 false 以优化带宽。
- 设为 false 以优化带宽。
+ 为 true 时,将启用流混淆。流混淆会向流式 delta 事件中的某个
+ 字段添加随机字符,以 `obfuscation` 流式增量事件上的
+ 字段,用于对载荷大小进行归一化,作为对某些侧信道
+ 攻击的缓解措施。这些混淆字段默认包含,但会为数据流增加
+ 少量开销。如果你信任你的应用程序与
+ `include_obfuscation` 之间的网络链路,可以将
+ 设为 false 以优化带宽OpenAI API。
- `starting_after: optional number`
- 开始流式传输的目标事件之后的事件序列号。
+ 开始流式传输之前的事件序列号。
- `stream: optional false`
- 如果设置为 true,模型响应数据将流式传输到客户端
- ,使用 [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
+ 如果设置为 true,则模型响应数据将在生成时通过
+ 流式传输到客户端,使用 [服务端发送事件](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
参见下方 [流式传输部分](/docs/api-reference/responses-streaming)
- 了解更多信息。
+ 以了解更多信息。
- `false`
-### 返回
+### 返回值
- `Response object { id, created_at, error, 32 more }`
@@ -34099,7 +34088,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `created_at: number`
- 创建此 Response 时的 Unix 时间戳(以秒为单位)。
+ 此 Response 创建时的 Unix 时间戳(以秒为单位)。
- `error: ResponseError or null`
@@ -34155,87 +34144,89 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `incomplete_details: object { reason } or null`
- 有关响应未完成原因的详细信息。
+ 有关响应不完整的详细原因。
- - `reason: optional "max_output_tokens" or "content_filter"`
+ - `reason: optional "max_output_tokens" or "max_messages" or "content_filter"`
- 响应未完成的原因。
+ 响应不完整的原因。
- `"max_output_tokens"`
+ - `"max_messages"`
+
- `"content_filter"`
- `instructions: string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more or null`
插入到模型上下文中的系统(或开发者)消息。
- 当与 `previous_response_id`,配合使用时,前一次
- 响应的指令不会延续到下一次响应。这便于在新响应中
- 替换系统(或开发者)消息。
+ 当与 `previous_response_id`,配合使用时,上一个
+ response 中的 instructions 不会延续到下一个 response。这样可以轻松地
+ 在新的 response 中替换系统(或开发者)消息。
- `string`
- 发送给模型的文本输入,相当于使用
+ 发送给模型的文本输入,等同于
`developer` 角色的文本输入。
- `InputItemList = array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 发送给模型的一个或多个输入项的列表,包含
+ 发送给模型的一个或多个输入项列表,包含
不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` role. Messages with the
- `assistant` role are presumed to have been generated by the model in previous
- interactions.
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色给出的指令。带有
+ `assistant` 角色的消息被视为模型在之前的
+ 交互中生成。
- `content: string or ResponseInputMessageContentList`
- Text, image, or audio input to the model, used to generate a response.
- Can also contain previous assistant responses.
+ 发送给模型的文本、图像或音频输入,用于生成响应。
+ 也可以包含之前的助手响应。
- `TextInput = string`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputMessageContentList = array of ResponseInputContent`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -34247,25 +34238,25 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -34275,13 +34266,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -34291,33 +34282,33 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `assistant`, `system`, or
+ 消息输入的角色。其一为 接口 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -34330,9 +34321,9 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -34340,24 +34331,24 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: optional "message"`
- 消息输入的类型。始终为 `message`.
+ 消息输入的类型。始终为 接口 `message`.
- `"message"`
- `Message object { content, role, status, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` 角色的文本输入。
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色的文本输入。
- `content: ResponseInputMessageContentList`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `system`, or `developer`.
+ 消息输入的角色。其一为 接口 `user`, `system`,或 `developer`.
- `"user"`
@@ -34367,8 +34358,8 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -34388,7 +34379,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -34396,15 +34387,15 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -34420,7 +34411,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -34430,25 +34421,25 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -34460,7 +34451,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -34468,11 +34459,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -34526,15 +34517,15 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -34546,8 +34537,8 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -34563,9 +34554,9 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -34573,8 +34564,8 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -34586,7 +34577,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -34611,11 +34602,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -34633,7 +34624,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -34642,7 +34633,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -34654,7 +34645,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -34670,8 +34661,8 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -34695,7 +34686,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -34709,7 +34700,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -34735,7 +34726,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -34753,7 +34744,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -34772,7 +34763,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -34782,11 +34773,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -34806,15 +34797,15 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -34846,19 +34837,19 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -34882,8 +34873,8 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -34899,7 +34890,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -34915,7 +34906,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -34923,44 +34914,44 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ComputerCallOutput object { call_id, output, type, 3 more }`
- 一次 computer 工具调用的输出。
+ 计算机工具调用的输出。
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `id: optional string or null`
- computer 工具调用输出的 ID。
+ 计算机工具调用输出的 ID。
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 已被开发者确认的 API 所报告的安全检查结果。
+ 开发者已确认的 API 所报告的安全检查。
- `id: string`
@@ -34976,7 +34967,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值为 `in_progress`, `completed`, or `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -34987,7 +34978,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -34995,12 +34986,12 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -35010,11 +35001,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -35032,7 +35023,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -35046,7 +35037,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -35064,7 +35055,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -35076,14 +35067,14 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -35133,8 +35124,8 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -35148,7 +35139,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `output: string or array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的文本、图片或文件输出。
+ 函数工具调用的文本、图像或文件输出。
- `string`
@@ -35156,61 +35147,61 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的内容输出(文本、图片、文件)数组。
+ 函数工具调用的内容输出(文本、图像、文件)数组。
- `ResponseInputTextContent object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision)
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `detail: optional ImageDetail or null`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -35220,13 +35211,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -35240,23 +35231,23 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -35268,7 +35259,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `id: optional string or null`
- 函数工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
+ 函数工具调用输出的唯一 ID。当此项通过 API 返回时填充。
- `call_id: optional string or null`
@@ -35308,7 +35299,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -35324,7 +35315,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目类型。始终为 `tool_search_call`.
+ 项的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
@@ -35392,37 +35383,37 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -35435,11 +35426,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -35459,7 +35450,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -35475,15 +35466,15 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -35497,7 +35488,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -35505,7 +35496,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -35517,7 +35508,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -35525,21 +35516,21 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -35565,18 +35556,18 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -35584,22 +35575,22 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -35609,23 +35600,23 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -35636,11 +35627,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -35658,21 +35649,21 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -35680,14 +35671,14 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -35719,32 +35710,32 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -35752,13 +35743,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -35766,9 +35757,9 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -35780,22 +35771,22 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -35804,7 +35795,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -35814,7 +35805,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -35844,29 +35835,29 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -35902,7 +35893,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -35912,11 +35903,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -35926,7 +35917,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -35934,7 +35925,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -35943,13 +35934,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -35958,7 +35949,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -35985,7 +35976,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -35996,7 +35987,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -36013,13 +36004,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -36035,7 +36026,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -36045,7 +36036,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -36069,7 +36060,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -36093,13 +36084,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -36123,7 +36114,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -36131,13 +36122,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -36157,7 +36148,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -36169,13 +36160,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -36189,11 +36180,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -36219,7 +36210,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -36237,7 +36228,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -36251,19 +36242,19 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -36283,19 +36274,19 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -36303,11 +36294,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -36353,7 +36344,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -36365,11 +36356,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -36383,7 +36374,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -36393,7 +36384,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -36403,23 +36394,23 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -36437,13 +36428,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目类型。始终为 `tool_search_output`.
+ 项的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `id: optional string or null`
- 此工具搜索输出的唯一 ID。
+ 该工具搜索输出的唯一 ID。
- `call_id: optional string or null`
@@ -36471,13 +36462,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `role: "developer"`
- 提供其他工具的角色。仅 `developer` 受支持。
+ 提供这些额外工具的角色。仅支持 `developer` 。
- `"developer"`
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 此项目提供的其他工具列表。
+ 在该条目中提供的额外工具列表。
- `Function object { name, parameters, strict, 5 more }`
@@ -36511,45 +36502,45 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -36557,7 +36548,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -36569,7 +36560,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -36577,21 +36568,21 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -36617,18 +36608,18 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -36636,22 +36627,22 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -36661,23 +36652,23 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -36688,11 +36679,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -36710,21 +36701,21 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -36732,14 +36723,14 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -36771,32 +36762,32 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -36804,13 +36795,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -36818,9 +36809,9 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -36832,22 +36823,22 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -36856,7 +36847,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -36866,7 +36857,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -36922,7 +36913,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -36932,11 +36923,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -36946,7 +36937,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -36954,7 +36945,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -36963,13 +36954,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -36978,7 +36969,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -37005,7 +36996,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -37016,7 +37007,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -37033,13 +37024,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -37055,7 +37046,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -37065,7 +37056,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -37091,11 +37082,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -37121,19 +37112,19 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -37153,19 +37144,19 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -37173,11 +37164,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -37223,7 +37214,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -37235,11 +37226,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -37253,7 +37244,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -37263,7 +37254,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -37273,23 +37264,23 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -37307,19 +37298,19 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目类型。始终为 `additional_tools`.
+ 项的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `id: optional string or null`
- 此其他工具项目的唯一 ID。
+ 该额外工具条目的唯一 ID。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -37332,7 +37323,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -37352,7 +37343,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -37362,20 +37353,20 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -37385,7 +37376,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `Compaction object { encrypted_content, type, id }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -37393,17 +37384,17 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `id: optional string or null`
- 压缩条目的 ID。
+ 压缩项的 ID。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -37427,7 +37418,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -37450,7 +37441,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -37462,23 +37453,23 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -37496,13 +37487,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -37518,11 +37509,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -37536,11 +37527,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -37554,7 +37545,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -37564,7 +37555,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -37572,13 +37563,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -37592,7 +37583,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
@@ -37604,7 +37595,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最大挂钟时间(毫秒)。
+ 允许 shell 命令运行的 wall-clock 最长时间(毫秒)。
- `call_id: string`
@@ -37612,13 +37603,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
- `id: optional string or null`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -37654,7 +37645,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -37664,7 +37655,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ShellCallOutput object { call_id, output, type, 4 more }`
- shell 工具调用发出的流式输出项。
+ shell 工具调用发出的流式输出条目。
- `call_id: string`
@@ -37672,7 +37663,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `output: array of ResponseFunctionShellCallOutputContent`
- stdout 和 stderr 输出的捕获块及其关联结果。
+ 捕获的 stdout 和 stderr 输出块,以及它们关联的结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -37684,13 +37675,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -37698,27 +37689,27 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
- `stderr: string`
- shell 调用捕获的 stderr 输出。
+ 为该 shell 调用捕获的 stderr 输出。
- `stdout: string`
- shell 调用捕获的 stdout 输出。
+ 为该 shell 调用捕获的 stdout 输出。
- `type: "shell_call_output"`
- 条目的类型,恒为 `shell_call_output`.
+ item 的类型。始终为 `shell_call_output`.
- `"shell_call_output"`
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -37760,11 +37751,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 表示使用 diff 补丁创建、删除或更新文件的工具调用。
+ 表示通过 diff 补丁创建、删除或更新文件的工具调用。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
@@ -37776,7 +37767,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 创建文件时要应用的统一 diff 内容。
+ 创建文件时应用的 unified diff 内容。
- `path: string`
@@ -37808,7 +37799,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 要应用于现有文件的统一 diff 内容。
+ 应用于现有文件的 unified diff 内容。
- `path: string`
@@ -37822,7 +37813,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -37830,13 +37821,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
- `id: optional string or null`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -37864,15 +37855,15 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { call_id, status, type, 3 more }`
- apply patch 工具调用发出的流式输出。
+ 由 apply patch 工具调用发出的流式输出。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -37880,13 +37871,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
- `id: optional string or null`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -37942,7 +37933,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -37950,29 +37941,29 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -37980,31 +37971,31 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { approval_request_id, approve, type, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
- `id: optional string or null`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `reason: optional string or null`
@@ -38012,7 +38003,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -38020,11 +38011,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -38032,14 +38023,14 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -38079,7 +38070,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -38093,11 +38084,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 由你的代码生成的自定义工具调用输出,将被发送回模型。
+ 由你的代码生成的自定义工具调用的输出,将发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -38114,11 +38105,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -38132,7 +38123,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- 自定义工具调用输出在 OpenAI 平台中的唯一 ID。
+ 在 OpenAI 平台中该自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -38182,7 +38173,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -38210,11 +38201,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `CompactionTrigger object { type, id }`
- 压缩当前上下文。必须是最后一个输入项。
+ 压缩当前上下文。必须作为最后一个输入项。
- `type: "compaction_trigger"`
- 条目的类型,恒为 `compaction_trigger`.
+ item 的类型。始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -38228,11 +38219,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 要引用的条目 ID。
+ 被引用条目的 ID。
- `type: optional "item_reference" or null`
- 要引用的条目类型。始终为 `item_reference`.
+ 被引用条目的类型。始终为 `item_reference`.
- `"item_reference"`
@@ -38248,7 +38239,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -38256,7 +38247,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目类型。始终为 `program`.
+ 项的类型。始终为 `program`.
- `"program"`
@@ -38272,7 +38263,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -38284,14 +38275,14 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目类型。始终为 `program_output`.
+ 项的类型。始终为 `program_output`.
- `"program_output"`
- `metadata: Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
格式,以及通过 API 或控制台查询对象。
键为字符串,最长 64 个字符。值为字符串
@@ -38300,8 +38291,8 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `model: ResponsesModel`
用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI
- 提供了多种不同能力、性能
- 特性和定价的模型。请参阅 [模型指南](/docs/models)
+ 提供了众多功能、性能
+ 特性和价位各异的模型。请参阅 [模型指南](/docs/models)
以浏览和比较可用的模型。
- `string`
@@ -38524,12 +38515,12 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
由模型生成的内容项数组。
- - 该数组中项的数量和顺序 `output` 取决于
- 模型的响应。
- - 与直接访问该数组的 `output` 第一项并
- 假设它是一 `assistant` 个包含模型生成内容的
- 消息相比,你也可以考虑使用 `output_text` 属性(在
- 受支持的 SDK 中可用)。
+ - 该数组中项的长度和顺序取决于 `output` 模型的响应。
+ 与其访问。
+ - 数组中的第一项并 `output` 假设它是一个
+ 包含模型生成内容的 `assistant` 消息,不如使用
+ 属性(在受支持的 开发工具包 `output_text` 中可用)。
+ SDK。
- `ResponseOutputMessage object { id, content, role, 3 more }`
@@ -38537,8 +38528,8 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -38550,7 +38541,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -38575,11 +38566,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -38597,7 +38588,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -38606,7 +38597,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -38656,8 +38647,8 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -38682,15 +38673,15 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -38698,8 +38689,8 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -38743,7 +38734,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `name: optional string`
@@ -38756,7 +38747,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -38764,12 +38755,12 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -38779,11 +38770,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -38801,7 +38792,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -38815,7 +38806,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -38833,7 +38824,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -38845,14 +38836,14 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -38864,7 +38855,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -38880,8 +38871,8 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -38901,8 +38892,8 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `ComputerCallOutput object { id, call_id, output, 4 more }`
@@ -38912,16 +38903,16 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"completed"`
@@ -38933,13 +38924,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、已被
+ API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -38956,13 +38947,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -38975,7 +38966,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -38993,7 +38984,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -39003,20 +38994,20 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -39036,7 +39027,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -39044,7 +39035,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目的类型,恒为 `program`.
+ item 的类型。始终为 `program`.
- `"program"`
@@ -39060,7 +39051,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -39072,7 +39063,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目的类型,恒为 `program_output`.
+ item 的类型。始终为 `program_output`.
- `"program_output"`
@@ -39110,13 +39101,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目的类型,恒为 `tool_search_call`.
+ item 的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -39182,45 +39173,45 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -39228,7 +39219,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -39240,7 +39231,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -39248,21 +39239,21 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -39288,18 +39279,18 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -39307,22 +39298,22 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -39332,23 +39323,23 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -39359,11 +39350,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -39381,21 +39372,21 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -39403,14 +39394,14 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -39442,32 +39433,32 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -39475,13 +39466,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -39489,9 +39480,9 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -39503,22 +39494,22 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -39527,7 +39518,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -39537,7 +39528,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -39593,7 +39584,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -39603,11 +39594,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -39617,7 +39608,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -39625,7 +39616,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -39634,13 +39625,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -39649,7 +39640,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -39676,7 +39667,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -39687,7 +39678,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -39704,13 +39695,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -39726,7 +39717,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -39736,7 +39727,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -39762,11 +39753,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -39792,19 +39783,19 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -39824,19 +39815,19 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -39844,11 +39835,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -39894,7 +39885,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -39906,11 +39897,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -39924,7 +39915,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -39934,7 +39925,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -39944,23 +39935,23 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -39978,13 +39969,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目的类型,恒为 `tool_search_output`.
+ item 的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -40014,7 +40005,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -40048,45 +40039,45 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -40094,7 +40085,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -40106,7 +40097,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -40114,21 +40105,21 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -40154,18 +40145,18 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -40173,22 +40164,22 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -40198,23 +40189,23 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -40225,11 +40216,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -40247,21 +40238,21 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -40269,14 +40260,14 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -40308,32 +40299,32 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -40341,13 +40332,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -40355,9 +40346,9 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -40369,22 +40360,22 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -40393,7 +40384,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -40403,7 +40394,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -40459,7 +40450,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -40469,11 +40460,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -40483,7 +40474,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -40491,7 +40482,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -40500,13 +40491,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -40515,7 +40506,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -40542,7 +40533,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -40553,7 +40544,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -40570,13 +40561,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -40592,7 +40583,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -40602,7 +40593,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -40628,11 +40619,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -40658,19 +40649,19 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -40690,19 +40681,19 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -40710,11 +40701,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -40760,7 +40751,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -40772,11 +40763,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -40790,7 +40781,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -40800,7 +40791,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -40810,23 +40801,23 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -40844,13 +40835,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目的类型,恒为 `additional_tools`.
+ item 的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -40858,21 +40849,21 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的已加密内容。
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -40896,7 +40887,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -40919,7 +40910,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -40931,23 +40922,23 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -40965,13 +40956,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -40987,11 +40978,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -41005,11 +40996,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -41023,7 +41014,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -41033,7 +41024,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -41041,13 +41032,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -41061,17 +41052,17 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -41109,7 +41100,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -41119,7 +41110,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -41153,7 +41144,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。通过 API 返回该条目时填充此字段。
- `call_id: string`
@@ -41161,15 +41152,15 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -41177,13 +41168,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -41191,7 +41182,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -41205,11 +41196,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`, or `incomplete`.
+ shell 调用输出的状态。可选值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -41245,7 +41236,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -41253,15 +41244,15 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -41277,7 +41268,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的 diff 创建新文件。
- `"create_file"`
@@ -41291,7 +41282,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "delete_file"`
- 删除指定的文件。
+ 删除指定文件。
- `"delete_file"`
@@ -41309,13 +41300,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "update_file"`
- 使用提供的差异更新现有文件。
+ 使用提供的 diff 更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -41323,7 +41314,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -41353,19 +41344,19 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -41373,7 +41364,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -41407,7 +41398,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -41415,11 +41406,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -41427,14 +41418,14 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -41446,7 +41437,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -41484,7 +41475,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -41492,29 +41483,29 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -41522,29 +41513,29 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `id: string`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -41576,7 +41567,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -41610,7 +41601,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -41627,11 +41618,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -41639,8 +41630,8 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -41680,7 +41671,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `parallel_tool_calls: boolean`
@@ -41688,8 +41679,8 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `temperature: number or null`
- 使用的采样温度,介于 0 到 2 之间。较高的值(例如 0.8)会使输出更加随机,而较低的值(例如 0.2)会使输出更加聚焦和确定。
- 我们通常建议修改此参数或 `top_p` 但不要同时修改两者。
+ 使用的采样温度,介于 0 到 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加聚焦和确定性。
+ 我们通常建议调整此项或 `top_p` 但不要同时调整两者。
- `tool_choice: ToolChoiceOptions or ToolChoiceAllowed or ToolChoiceTypes or 6 more`
@@ -41699,9 +41690,9 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceOptions = "none" or "auto" or "required"`
- 控制模型调用哪个工具(如果有的话)。
+ 控制模型调用哪个工具(如果有)。
- `none` 表示模型不会调用任何工具,而是生成一条消息。
+ `none` 表示模型将不会调用任何工具,而是生成一条消息。
`auto` 表示模型可以在生成消息或调用一个或
多个工具之间进行选择。
@@ -41733,7 +41724,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `tools: array of map[unknown]`
- 模型应允许调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -41754,11 +41745,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceTypes object { type }`
指示模型应使用内置工具来生成响应。
- [了解有关内置工具的更多信息](/docs/guides/tools).
+ [了解更多关于内置工具的信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
- 模型应使用的托管工具类型。了解更多关于
+ 模型应使用的 托管工具 类型。了解更多关于
[内置工具](/docs/guides/tools).
允许的值为:
@@ -41803,7 +41794,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceMcp object { server_label, type, name }`
- 使用此选项可以强制模型调用远程 MCP 服务器上的特定工具。
+ 使用此选项可强制模型调用远程 MCP 服务器上的特定工具。
- `server_label: string`
@@ -41821,7 +41812,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceCustom object { name, type }`
- 使用此选项可以强制模型调用特定的自定义工具。
+ 使用此选项可强制模型调用特定的自定义工具。
- `name: string`
@@ -41837,27 +41828,27 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "programmatic_tool_calling"`
- 要调用的工具。始终为 `programmatic_tool_calling`.
+ 要调用的工具。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ToolChoiceApplyPatch object { type }`
- 在执行工具调用时强制模型调用 apply_patch 工具。
+ 强制模型在执行工具调用时调用 apply_patch 工具。
- `type: "apply_patch"`
- 要调用的工具。始终为 `apply_patch`.
+ 要调用的工具。始终 `apply_patch`.
- `"apply_patch"`
- `ToolChoiceShell object { type }`
- 在需要工具调用时强制模型调用 shell 工具。
+ 在需要工具调用时,强制模型调用 shell 工具。
- `type: "shell"`
- 要调用的工具。始终为 `shell`.
+ 要调用的工具。始终 `shell`.
- `"shell"`
@@ -41868,18 +41859,18 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
我们支持以下类别的工具:
- - **内置工具**:由 OpenAI 提供的工具,用于扩展模型的
- 能力,例如 [网页搜索](/docs/guides/tools-web-search)
+ - **内置工具**:由 OpenAI 提供的工具,用于扩展
+ 模型的能力,例如 [网页搜索](/docs/guides/tools-web-search)
或 [文件搜索](/docs/guides/tools-file-search)。详细了解
[内置工具](/docs/guides/tools).
- - **MCP 工具**:通过自定义 MCP 服务器与第三方系统集成
- 或 Google Drive 和 SharePoint 等预定义连接器。详细了解
+ - **MCP 工具**: 通过自定义 MCP 服务器与第三方系统集成
+ 或使用 Google Drive 和 SharePoint 等预定义连接器。详细了解
[MCP 工具](/docs/guides/tools-connectors-mcp).
- - **函数调用(自定义工具)**:由你定义的函数,
+ - **函数调用(自定义工具)**: 由你定义的函数,
使模型能够使用强类型参数和输出调用你自己的代码。详细了解
。你也可以使用
- [function calling](/docs/guides/function-calling)。你还可以使用
- 自定义工具调用你自己的代码。
+ [function calling](/docs/guides/function-calling). 你也可以使用
+ 自定义工具来调用你自己的代码。
- `Function object { name, parameters, strict, 5 more }`
@@ -41913,45 +41904,45 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -41959,7 +41950,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -41971,7 +41962,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -41979,21 +41970,21 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -42019,18 +42010,18 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -42038,22 +42029,22 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -42063,23 +42054,23 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -42090,11 +42081,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -42112,21 +42103,21 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -42134,14 +42125,14 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -42173,32 +42164,32 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -42206,13 +42197,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -42220,9 +42211,9 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -42234,22 +42225,22 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -42258,7 +42249,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -42268,7 +42259,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -42324,7 +42315,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -42334,11 +42325,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -42348,7 +42339,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -42356,7 +42347,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -42365,13 +42356,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -42380,7 +42371,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -42407,7 +42398,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -42418,7 +42409,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -42435,13 +42426,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -42457,7 +42448,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -42467,7 +42458,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -42493,11 +42484,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -42523,19 +42514,19 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -42555,19 +42546,19 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -42575,11 +42566,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -42625,7 +42616,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -42637,11 +42628,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -42655,7 +42646,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -42665,7 +42656,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -42675,23 +42666,23 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -42709,12 +42700,12 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `top_p: number or null`
- 一种名为核采样的温度采样替代方案,
- 其中模型会考虑 top_p 概率质量排名前列的词元结果。
- 因此,0.1 表示仅考虑构成前 10% 概率质量的词元。
+ 一种温度采样的替代方法,称为核采样,
+ 模型会考虑概率质量排名前 top_p 的标记的结果。
+ 因此 0.1 表示仅考虑构成前 10% 概率质量的标记。
会被考虑。
- 我们通常建议修改此参数或 `temperature` 但不要同时修改两者。
+ 我们通常建议调整此项或 `temperature` 但不要同时调整两者。
- `background: optional boolean or null`
@@ -42723,44 +42714,44 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `completed_at: optional number or null`
- 此 Response 完成时的 Unix 时间戳(以秒为单位)。
- 仅当状态为 `completed`.
+ 此响应完成时的 Unix 时间戳(以秒为单位)。
+ 仅在状态为 `completed`.
- `conversation: optional object { id } or null`
- 此响应所属的对话。此响应的输入项和输出项已自动添加到此对话。
+ 此响应所属的对话。此次响应的输入项和输出项已自动添加到此对话中。
- `id: string`
- 与此响应关联的对话的唯一 ID。
+ 此响应关联的对话的唯一 ID。
- `max_output_tokens: optional number or null`
- 一次响应中可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
+ 响应可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
- `max_tool_calls: optional number or null`
- 响应中可以处理的内置工具调用总次数上限。该上限适用于所有内置工具调用,而非单个工具。模型任何进一步的工具调用尝试都将被忽略。
+ 一次响应中可处理的内置工具调用总次数上限。该上限适用于所有内置工具调用的总和,而非单个工具。模型后续任何再次调用工具的尝试都将被忽略。
- `moderation: optional object { input, output } or null`
- 响应输入和输出的审核结果,前提是请求了已审核的补全。
+ 响应输入与输出的内容审核结果,前提是请求了经过审核的补全。
- `input: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输入的审核结果。
+ 对响应输入的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -42768,7 +42759,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -42776,17 +42767,17 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -42798,25 +42789,25 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输出的审核结果。
+ 对响应输出的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -42824,7 +42815,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -42832,17 +42823,17 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -42854,21 +42845,21 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output_text: optional string or null`
- 仅限SDK的便捷属性,包含所有输出消息中聚合的文本输出
- 来自所有 `output_text` 数组中的 `output` 条目(如果有)。
+ SDK 独有的便捷属性,包含来自所有
+ 的聚合文本输出 `output_text` 数组中的 `output` 条目(如有)。
在 Python 和 JavaScript SDK 中受支持。
- `previous_response_id: optional string or null`
- 模型上一次响应的唯一 ID。使用它来
- 创建多轮对话。了解有关
- [对话状态](/docs/guides/conversation-state)。的更多信息。不能与 `conversation`.
+ 上一个模型响应的唯一 ID。使用它可以
+ 创建多轮对话。详细了解
+ [conversation state](/docs/guides/conversation-state)。不能与 `conversation`.
- `prompt: optional ResponsePrompt or null`
@@ -42881,19 +42872,19 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `variables: optional map[string or ResponseInputText or ResponseInputImage or ResponseInputFile] or null`
- 用于替换提示模板中变量的可选值映射,
- prompt。替换值可以是字符串,也可以是其他
- Response 输入类型,例如图像或文件。
+ 用于替换你
+ prompt。替换的值可以是字符串,也可以是其他
+ Response 输入类型,如图像或文件。
- `string`
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -42901,19 +42892,19 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `version: optional string or null`
- 提示模板的可选版本。
+ prompt 模板的可选版本。
- `prompt_cache_key: optional string or null`
- 由 OpenAI 用于缓存相似请求的响应,以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
+ 由OpenAI使用,为相似请求缓存响应以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
- `prompt_cache_options: optional object { mode, ttl }`
- 应用于该响应的提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。
+ 应用于该响应的 prompt 缓存选项。支持以下 `gpt-5.6` 及更高版本的模型。
- `mode: "implicit" or "explicit"`
- 是否启用了隐式提示缓存断点。
+ 是否启用了隐式 prompt 缓存断点。
- `"implicit"`
@@ -42921,24 +42912,24 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `ttl: "30m"`
- 应用于每个缓存断点的最短生存时间。
+ 应用于每个缓存断点的最短生命周期。
- `"30m"`
- `prompt_cache_retention: optional "in_memory" or "24h" or null`
- 已弃用。请使用 `prompt_cache_options.ttl` 相反。
+ 已弃用。请使用 `prompt_cache_options.ttl` 改为。
- 提示词缓存的保留策略。设置为 `24h` 以启用扩展提示词缓存,使缓存前缀保持更长时间,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
- 此字段表示最长保留策略,而
+ 提示缓存的保留策略。设置为 `24h` 以启用扩展提示缓存,使缓存的前缀保持更长时间有效,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
+ 该字段表示最大保留策略,而
`prompt_cache_options.ttl` 表示最短缓存生命周期。这两个
- 字段彼此独立,不会相互影响。
- 对于 `gpt-5.5`, `gpt-5.5-pro`,及未来模型,仅 `24h` 受支持。
+ 字段是独立的,不会相互影响。
+ 对于 `gpt-5.5`, `gpt-5.5-pro`,以及未来的模型,仅 `24h` 。
对于同时支持两者的旧模型 `in_memory` 和 `24h`,默认值取决于你组织的数据保留策略:
- - 未启用 ZDR 的组织默认使用 `24h`.
- - 启用 ZDR 的组织默认使用 `in_memory` 当 `prompt_cache_retention` 未指定时。
+ - 未启用 ZDR 的组织默认为 `24h`.
+ - 启用 ZDR 的组织默认为 `in_memory` 当 `prompt_cache_retention` 未指定时。
- `"in_memory"`
@@ -42946,18 +42937,18 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `reasoning: optional Reasoning or null`
- 配置选项,适用于
+ 适用于
[推理模型](https://platform.openai.com/docs/guides/reasoning).
- `context: optional "auto" or "current_turn" or "all_turns" or null`
- 控制在后续轮次中呈现回模型的推理项。
- 如果省略或设置为 `auto`,则由模型确定上下文模式。
+ 控制在后续回合中哪些推理项会被回传给模型。
+ 如果省略或设置为 `auto`,则由模型决定上下文模式。
`gpt-5.6` 模型系列默认为 `all_turns`;早期模型默认为
`current_turn`.
- 在响应中返回时,这是该响应使用的有效推理上下文模式
- 。
+ 在响应中返回时,这是该响应所使用 的有效推理上下文模式
+ 用于该响应。
- `"auto"`
@@ -42967,13 +42958,13 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `effort: optional ReasoningEffort or null`
- 限制推理模型在推理上的投入程度。当前支持的值
- 包括 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
- 降低推理投入程度可以让响应更快,并减少响应中推理所用的 token 数。并非所有推理模型都支持每个
- 值。请参阅
- 推理指南
+ 限制推理模型在推理上的投入程度。目前支持
+ 的取值有 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
+ 降低推理投入程度可以让响应更快,并减少响应中用于推理的 token
+ 数量。并非所有推理模型都支持每个
+ 取值。有关各模型的支持情况,请参阅
[推理指南](https://platform.openai.com/docs/guides/reasoning)
- 以了解特定模型的支持情况。
+ 。
- `"none"`
@@ -42991,11 +42982,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `generate_summary: optional "auto" or "concise" or "detailed" or null`
- **已弃用:** 请使用 `summary` 相反。
+ **已弃用:** 请使用 `summary` 改为。
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `"auto"`
@@ -43007,7 +42998,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `string`
@@ -43015,7 +43006,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `"standard"`
@@ -43023,11 +43014,11 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `summary: optional "auto" or "concise" or "detailed" or null`
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `concise` 支持以下模型 `computer-use-preview` 以及之后的所有推理模型 `gpt-5`.
+ `concise` 支持用于 `computer-use-preview` 模型以及之后的 `gpt-5`.
- `"auto"`
@@ -43037,21 +43028,21 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `safety_identifier: optional string or null`
- 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用策略的应用程序用户。
- ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份识别信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用政策的应用用户。
+ ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `service_tier: optional ServiceTier or null`
指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
+ - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则该项目将使用 'default'。
- 如果设置为 'default',则该请求将使用所选模型的标准定价和性能进行处理。
- 如果设置为 '[flex](/docs/guides/flex-processing)',则该请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别选择启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 `service_tier=fast` 或 `service_tier=priority` 参数用于 Responses 或 Chat Completions。响应将显示 `service_tier=priority` ,无论你是否在请求中指定了 `service_tier=fast` 或 `priority` 。
- - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级返回的响应将显示 `service_tier=ultrafast`.
- - 如果未设置,默认行为是 'auto'。
+ - 若要在请求级别启用 [快速模式](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过它处理的响应将显示 `service_tier=ultrafast`.
+ - 未设置时,默认行为为 'auto'。
- 当设置 `service_tier` 参数时,响应正文将包含基于实际用于处理该请求的处理模式的 `service_tier` 值。此响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应体中将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。此响应中的值可能与该参数中设置的值不同。
- `"auto"`
@@ -43069,8 +43060,8 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `status: optional ResponseStatus`
- 响应生成的状态。取值之一为 `completed`, `failed`,
- `in_progress`, `cancelled`, `queued`, or `incomplete`.
+ 响应生成的状态。可选值为 `completed`, `failed`,
+ `in_progress`, `cancelled`, `queued`,或 `incomplete`.
- `"completed"`
@@ -43086,8 +43077,8 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `text: optional ResponseTextConfig`
- 用于配置模型文本响应的选项。可以是纯文本,也可以是结构化的 JSON 数据。详见:
- 文本输入与输出:
+ 模型文本响应的配置选项。可以是纯
+ 文本或结构化 JSON 数据。了解更多:
- [文本输入与输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
@@ -43096,79 +43087,79 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
用于指定模型必须输出的格式的对象。
- 设置为 `{ "type": "json_schema" }` 时,将启用结构化输出,
- 功能,从而确保模型的输出与你提供的 JSON schema 相匹配。详见
+ 配置 `{ "type": "json_schema" }` 可启用结构化输出,
+ 从而确保模型匹配你提供的 JSON schema。更多信息请参阅
[结构化输出指南](/docs/guides/structured-outputs).
- 默认的格式为 `{ "type": "text" }` ,且不包含其他选项。
+ 默认格式为 `{ "type": "text" }` ,不包含任何额外选项。
- **不建议在 gpt-4o 及更新模型上使用:**
+ **不推荐用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
- 的模型,建议优先使用该格式。
+ 设置为 `{ "type": "json_object" }` 会启用旧版 JSON 模式,该模式
+ 可确保模型生成的消息是合法 JSON。对于支持 `json_schema`
+ 的模型,建议优先使用它。
- `ResponseFormatText object { type }`
- 默认的响应格式。用于生成文本响应。
+ 默认响应格式。用于生成文本响应。
- `type: "text"`
- 正在定义的响应格式的类型。始终为 `text`.
+ 正在定义的响应格式类型。始终为 `text`.
- `"text"`
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化的 JSON 响应。
+ JSON Schema 响应格式。用于生成结构化 JSON 响应。
详细了解 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
- 下划线和连字符,最大长度为 64。
+ 下划线和短横线,最大长度为 64。
- `schema: map[unknown]`
- 响应格式的 schema,以 JSON Schema 对象描述。
- 了解如何构建 JSON schema [此处](https://json-schema.org/).
+ 响应格式的架构,以 JSON Schema 对象形式描述。
+ 了解如何构建 JSON 架构 [此处](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式的类型。始终为 `json_schema`.
+ 正在定义的响应格式类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
响应格式用途的描述,供模型用于
- 确定如何按该格式进行响应。
+ 确定如何按该格式响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 一致性。
- 如果设置为 true,模型将始终遵循
- 字段中 `schema` 定义的精确 schema。仅支持 JSON Schema 的一个子集,当
- `strict` 是 `true`。要了解更多信息,请阅读 [Structured Outputs
+ 生成输出时是否启用严格的架构遵循。
+ 如果设置为 true,模型将始终遵循 字段中定义的
+ 确切架构。当 设置为 `schema` true 时,仅支持 JSON Schema 的一个子集
+ `strict` 是 `true`。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较早的生成 JSON 响应的方法。
- 使用 `json_schema` 对支持它的模型是推荐的做法。请注意
- 模型在没有系统或用户消息指示的情况下不会生成
- JSON。
+ JSON 对象响应格式。一种较旧的 JSON 响应生成方法。建议。
+ 对于支持 的模型,使用 `json_schema` 。请注意,模型不会在没有系统或用户消息指示
+ 的情况下生成 JSON
+ 。
- `type: "json_object"`
- 正在定义的响应格式的类型。始终为 `json_object`.
+ 正在定义的响应格式类型。始终为 `json_object`.
- `"json_object"`
- `verbosity: optional "low" or "medium" or "high" or null`
- 约束模型响应的详细程度。较低的值会产生
- 更简洁的响应,较高的值会产生更详细的响应。
+ 约束模型响应的详尽程度。较低的值将导致
+ 更简洁的响应,而较高的值将导致更冗长的响应。
当前支持的值包括 `low`, `medium`,和 `high`。默认值为
`medium`.
@@ -43180,20 +43171,20 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `top_logprobs: optional number or null`
- 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的最大最可能
- token 数量,每个 token 都附带对应的对数
+ 一个介于 0 到 20 之间的整数,指定在每个 token 位置返回的
+ 最可能 token 的最大数量,每个 token 都有一个关联的对数
概率。在某些情况下,返回的 token 数量可能少于
- 所请求的数量。
+ 请求的数量。
- `truncation: optional "auto" or "disabled" or null`
用于模型响应的截断策略。
- - `auto`:如果此 Response 的输入超过
- 模型的上下文窗口大小,模型将通过从对话开头丢弃条目来截断
- 响应以适配上下文窗口。
- - `disabled` (默认):如果输入大小将超出模型的上下文窗口
- 大小,请求将失败并返回 400 错误。
+ - `auto`:如果此 Response 的输入超出
+ 模型的上下文窗口大小,模型将通过从对话开头
+ 丢弃条目来截断响应以适配上下文窗口。
+ - `disabled` (默认):如果输入大小将超过模型的上下文窗口
+ 大小,请求将以 400 错误失败。
- `"auto"`
@@ -43202,7 +43193,7 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `usage: optional ResponseUsage`
表示 token 使用详情,包括输入 token、输出 token,
- 的输出 token 明细,以及所使用的 token 总数。
+ 输出 token 的细分,以及使用的总 token 数。
- `input_tokens: number`
@@ -43210,16 +43201,16 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `input_tokens_details: object { cache_write_tokens, cached_tokens }`
- 输入 token 的详细明细。
+ 输入 token 的详细细分。
- `cache_write_tokens: number`
- 已写入缓存的输入 token 数量。
+ 写入缓存的输入 token 的数量。
- `cached_tokens: number`
- 从缓存中检索到的 token 数量。
- [了解更多关于提示缓存的信息](/docs/guides/prompt-caching).
+ 从缓存中检索到的 token 的数量。
+ [有关 prompt caching 的更多信息](/docs/guides/prompt-caching).
- `output_tokens: number`
@@ -43227,25 +43218,21 @@ curl -X DELETE https://api.openai.com/v1/responses/resp_123 \
- `output_tokens_details: object { reasoning_tokens }`
- 输出令牌的详细明细。
+ 输出 token 的详细明细。
- `reasoning_tokens: number`
- 推理令牌的数量。
+ 推理 token 的数量。
- `total_tokens: number`
- 使用的令牌总数。
-
- - `compute_units: optional number or null`
-
- 该请求的计算单元。在可用时当前为 null。
+ 使用的 token 总数。
- `user: optional string`
- 此字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
- 用于标识你的最终用户的稳定标识符。
- 通过更好地对相似请求进行分桶以提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 该字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
+ 你的最终用户的稳定标识符。
+ 通过更好地对相似请求进行分桶来提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
### 示例
@@ -43254,7 +43241,7 @@ curl https://api.openai.com/v1/responses/$RESPONSE_ID \
-H "Authorization: Bearer $OPENAI_API_KEY"
```
-#### 响应
+#### Response
```json
{
@@ -43420,8 +43407,7 @@ curl https://api.openai.com/v1/responses/$RESPONSE_ID \
"output_tokens_details": {
"reasoning_tokens": 0
},
- "total_tokens": 0,
- "compute_units": 0
+ "total_tokens": 0
},
"user": "user-1234"
}
@@ -43435,7 +43421,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
-H "Authorization: Bearer $OPENAI_API_KEY"
```
-#### 响应
+#### Response
```json
{
@@ -43524,7 +43510,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Message object { id, content, role, 3 more }`
- 发给模型或来自模型的消息。
+ 发送给模型或来自模型的消息。
- `id: string`
@@ -43536,39 +43522,39 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -43584,7 +43570,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -43594,25 +43580,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -43624,7 +43610,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -43632,11 +43618,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -43704,7 +43690,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -43718,7 +43704,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -43728,25 +43714,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -43758,57 +43744,57 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ComputerScreenshotContent object { detail, file_id, image_url, 2 more }`
- 计算机的屏幕截图。
+ 计算机屏幕截图。
- `detail: ImageDetail`
- 发送给模型的屏幕截图图像的细节级别。取值为 `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的截图图像的细节级别。取值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: string or null`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: string or null`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机屏幕截图,此属性始终设置为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为 `computer_screenshot`.
- `"computer_screenshot"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -43818,13 +43804,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -43834,33 +43820,33 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "unknown" or "user" or "assistant" or 5 more`
- 消息的角色。可选值为 `unknown`, `user`, `assistant`, `system`, `critic`, `discriminator`, `developer`, or `tool`.
+ 消息的角色。可选值之一 `unknown`, `user`, `assistant`, `system`, `critic`, `discriminator`, `developer`,或 `tool`.
- `"unknown"`
@@ -43880,7 +43866,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或 `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -43896,7 +43882,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`)。对于 `gpt-5.3-codex` 及更高模型,在发送后续请求时,请在所有助手消息上保留并重新发送 phase 字段——删除它可能会降低性能。用户消息不使用该字段。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`)。对于类似 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请在所有助手消息上保留并重新发送 phase,删除它可能会降低性能。不用于用户消息。
- `"commentary"`
@@ -43914,7 +43900,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -43922,7 +43908,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目的类型,恒为 `program`.
+ item 的类型。始终为 `program`.
- `"program"`
@@ -43938,7 +43924,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -43950,14 +43936,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目的类型,恒为 `program_output`.
+ item 的类型。始终为 `program_output`.
- `"program_output"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -44007,8 +43993,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -44050,13 +44036,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目的类型,恒为 `tool_search_call`.
+ item 的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -44122,37 +44108,37 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -44165,11 +44151,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -44189,7 +44175,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -44205,15 +44191,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -44227,7 +44213,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -44235,7 +44221,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -44247,7 +44233,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -44255,21 +44241,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -44295,18 +44281,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -44314,22 +44300,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -44339,23 +44325,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -44366,11 +44352,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -44388,21 +44374,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -44410,14 +44396,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -44449,32 +44435,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -44482,13 +44468,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -44496,9 +44482,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -44510,22 +44496,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -44534,7 +44520,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -44544,7 +44530,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -44574,29 +44560,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -44632,7 +44618,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -44642,11 +44628,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -44656,7 +44642,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -44664,7 +44650,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -44673,13 +44659,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -44688,7 +44674,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -44715,7 +44701,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -44726,7 +44712,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -44743,13 +44729,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -44765,7 +44751,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -44775,7 +44761,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -44799,7 +44785,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -44823,13 +44809,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -44853,7 +44839,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -44861,13 +44847,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -44887,7 +44873,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -44899,13 +44885,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -44919,11 +44905,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -44949,7 +44935,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -44967,7 +44953,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -44981,19 +44967,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -45013,19 +44999,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -45033,11 +45019,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -45083,7 +45069,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -45095,11 +45081,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -45113,7 +45099,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -45123,7 +45109,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -45133,23 +45119,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -45167,13 +45153,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目的类型,恒为 `tool_search_output`.
+ item 的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -45203,7 +45189,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -45237,45 +45223,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -45283,7 +45269,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -45295,7 +45281,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -45303,21 +45289,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -45343,18 +45329,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -45362,22 +45348,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -45387,23 +45373,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -45414,11 +45400,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -45436,21 +45422,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -45458,14 +45444,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -45497,32 +45483,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -45530,13 +45516,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -45544,9 +45530,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -45558,22 +45544,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -45582,7 +45568,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -45592,7 +45578,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -45648,7 +45634,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -45658,11 +45644,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -45672,7 +45658,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -45680,7 +45666,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -45689,13 +45675,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -45704,7 +45690,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -45731,7 +45717,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -45742,7 +45728,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -45759,13 +45745,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -45781,7 +45767,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -45791,7 +45777,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -45817,11 +45803,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -45847,19 +45833,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -45879,19 +45865,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -45899,11 +45885,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -45949,7 +45935,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -45961,11 +45947,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -45979,7 +45965,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -45989,7 +45975,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -45999,23 +45985,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -46033,7 +46019,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目的类型,恒为 `additional_tools`.
+ item 的类型。始终为 `additional_tools`.
- `"additional_tools"`
@@ -46052,15 +46038,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -46074,8 +46060,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- 函数工具调用输出的唯一 ID。当此项
- 通过 API 返回时填充。
+ 函数工具调用的唯一 ID。当此项通过 API 返回时填充。
+ 通过 接口 返回时填充。
- `call_id: optional string`
@@ -46115,8 +46101,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -46126,8 +46112,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -46139,7 +46125,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -46164,11 +46150,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -46186,7 +46172,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -46195,7 +46181,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -46203,12 +46189,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -46218,11 +46204,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -46240,7 +46226,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -46254,7 +46240,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -46272,7 +46258,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -46284,13 +46270,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -46314,14 +46300,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -46333,7 +46319,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -46349,8 +46335,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -46374,7 +46360,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -46388,7 +46374,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -46414,7 +46400,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -46432,7 +46418,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -46451,7 +46437,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -46461,11 +46447,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -46485,15 +46471,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -46525,19 +46511,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -46561,8 +46547,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -46578,7 +46564,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -46594,7 +46580,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -46608,31 +46594,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"completed"`
@@ -46644,13 +46630,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、已被
+ API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -46667,13 +46653,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -46686,7 +46672,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -46704,7 +46690,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -46714,20 +46700,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -46737,7 +46723,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -46745,17 +46731,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的已加密内容。
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `CodeInterpreterCall object { id, code, container_id, 3 more }`
@@ -46776,7 +46762,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -46788,23 +46774,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -46822,13 +46808,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -46844,11 +46830,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -46862,11 +46848,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -46880,7 +46866,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -46890,7 +46876,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -46898,13 +46884,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -46918,17 +46904,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -46966,7 +46952,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -46976,7 +46962,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -47010,7 +46996,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。通过 API 返回该条目时填充此字段。
- `call_id: string`
@@ -47018,15 +47004,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -47034,13 +47020,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -47048,7 +47034,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -47062,11 +47048,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`, or `incomplete`.
+ shell 调用输出的状态。可选值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -47102,7 +47088,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -47110,15 +47096,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -47134,7 +47120,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的 diff 创建新文件。
- `"create_file"`
@@ -47148,7 +47134,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "delete_file"`
- 删除指定的文件。
+ 删除指定文件。
- `"delete_file"`
@@ -47166,13 +47152,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "update_file"`
- 使用提供的差异更新现有文件。
+ 使用提供的 diff 更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -47180,7 +47166,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -47210,19 +47196,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -47230,7 +47216,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -47288,7 +47274,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -47296,29 +47282,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -47326,29 +47312,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `id: string`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -47358,7 +47344,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -47366,11 +47352,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -47378,14 +47364,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -47425,7 +47411,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -47461,7 +47447,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -47489,11 +47475,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 由你的代码生成的自定义工具调用输出,将被发送回模型。
+ 由你的代码生成的自定义工具调用的输出,将发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -47510,11 +47496,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -47528,7 +47514,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- 自定义工具调用输出在 OpenAI 平台中的唯一 ID。
+ 在 OpenAI 平台中该自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -47556,7 +47542,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `usage: ResponseUsage`
- 压缩过程的令牌统计,包括缓存、推理和总令牌。
+ 压缩过程的 token 统计,包括缓存 token、推理 token 和总 token。
- `input_tokens: number`
@@ -47564,16 +47550,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_tokens_details: object { cache_write_tokens, cached_tokens }`
- 输入 token 的详细明细。
+ 输入 token 的详细细分。
- `cache_write_tokens: number`
- 已写入缓存的输入 token 数量。
+ 写入缓存的输入 token 的数量。
- `cached_tokens: number`
- 从缓存中检索到的 token 数量。
- [了解更多关于提示缓存的信息](/docs/guides/prompt-caching).
+ 从缓存中检索到的 token 的数量。
+ [有关 prompt caching 的更多信息](/docs/guides/prompt-caching).
- `output_tokens: number`
@@ -47581,19 +47567,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_tokens_details: object { reasoning_tokens }`
- 输出令牌的详细明细。
+ 输出 token 的详细明细。
- `reasoning_tokens: number`
- 推理令牌的数量。
+ 推理 token 的数量。
- `total_tokens: number`
- 使用的令牌总数。
-
- - `compute_units: optional number or null`
-
- 该请求的计算单元。在可用时当前为 null。
+ 使用的 token 总数。
### Computer Action
@@ -47607,7 +47589,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -47621,7 +47603,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -47647,7 +47629,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -47665,7 +47647,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -47684,7 +47666,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -47694,11 +47676,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -47718,15 +47700,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -47758,19 +47740,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -47796,8 +47778,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerActionList = array of ComputerAction`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -47805,7 +47787,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -47819,7 +47801,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -47845,7 +47827,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -47863,7 +47845,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -47882,7 +47864,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -47892,11 +47874,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -47916,15 +47898,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -47956,19 +47938,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -48002,7 +47984,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -48032,39 +48014,39 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -48088,7 +48070,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -48096,13 +48078,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -48118,29 +48100,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
### Container Network Policy Disabled
@@ -48158,15 +48140,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
### Container Reference
@@ -48174,7 +48156,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -48186,57 +48168,57 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `EasyInputMessage object { content, role, phase, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` role. Messages with the
- `assistant` role are presumed to have been generated by the model in previous
- interactions.
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色给出的指令。带有
+ `assistant` 角色的消息被视为模型在之前的
+ 交互中生成。
- `content: string or ResponseInputMessageContentList`
- Text, image, or audio input to the model, used to generate a response.
- Can also contain previous assistant responses.
+ 发送给模型的文本、图像或音频输入,用于生成响应。
+ 也可以包含之前的助手响应。
- `TextInput = string`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputMessageContentList = array of ResponseInputContent`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -48248,25 +48230,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -48276,13 +48258,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -48292,33 +48274,33 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `assistant`, `system`, or
+ 消息输入的角色。其一为 接口 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -48331,9 +48313,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -48341,7 +48323,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: optional "message"`
- 消息输入的类型。始终为 `message`.
+ 消息输入的类型。始终为 接口 `message`.
- `"message"`
@@ -48371,7 +48353,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -48379,13 +48361,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -48399,7 +48381,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `InlineSkillSource object { data, media_type, type }`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -48407,13 +48389,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -48429,7 +48411,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -48441,7 +48423,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
### Local Skill
@@ -48457,7 +48439,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
### Mcp Tool Call Error
@@ -48491,7 +48473,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"http_error"`
-### 响应
+### Response
- `Response object { id, created_at, error, 32 more }`
@@ -48501,7 +48483,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_at: number`
- 创建此 Response 时的 Unix 时间戳(以秒为单位)。
+ 此 Response 创建时的 Unix 时间戳(以秒为单位)。
- `error: ResponseError or null`
@@ -48557,87 +48539,89 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `incomplete_details: object { reason } or null`
- 有关响应未完成原因的详细信息。
+ 有关响应不完整的详细原因。
- - `reason: optional "max_output_tokens" or "content_filter"`
+ - `reason: optional "max_output_tokens" or "max_messages" or "content_filter"`
- 响应未完成的原因。
+ 响应不完整的原因。
- `"max_output_tokens"`
+ - `"max_messages"`
+
- `"content_filter"`
- `instructions: string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more or null`
插入到模型上下文中的系统(或开发者)消息。
- 当与 `previous_response_id`,配合使用时,前一次
- 响应的指令不会延续到下一次响应。这便于在新响应中
- 替换系统(或开发者)消息。
+ 当与 `previous_response_id`,配合使用时,上一个
+ response 中的 instructions 不会延续到下一个 response。这样可以轻松地
+ 在新的 response 中替换系统(或开发者)消息。
- `string`
- 发送给模型的文本输入,相当于使用
+ 发送给模型的文本输入,等同于
`developer` 角色的文本输入。
- `InputItemList = array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 发送给模型的一个或多个输入项的列表,包含
+ 发送给模型的一个或多个输入项列表,包含
不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` role. Messages with the
- `assistant` role are presumed to have been generated by the model in previous
- interactions.
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色给出的指令。带有
+ `assistant` 角色的消息被视为模型在之前的
+ 交互中生成。
- `content: string or ResponseInputMessageContentList`
- Text, image, or audio input to the model, used to generate a response.
- Can also contain previous assistant responses.
+ 发送给模型的文本、图像或音频输入,用于生成响应。
+ 也可以包含之前的助手响应。
- `TextInput = string`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputMessageContentList = array of ResponseInputContent`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -48649,25 +48633,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -48677,13 +48661,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -48693,33 +48677,33 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `assistant`, `system`, or
+ 消息输入的角色。其一为 接口 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -48732,9 +48716,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -48742,24 +48726,24 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: optional "message"`
- 消息输入的类型。始终为 `message`.
+ 消息输入的类型。始终为 接口 `message`.
- `"message"`
- `Message object { content, role, status, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` 角色的文本输入。
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色的文本输入。
- `content: ResponseInputMessageContentList`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `system`, or `developer`.
+ 消息输入的角色。其一为 接口 `user`, `system`,或 `developer`.
- `"user"`
@@ -48769,8 +48753,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -48790,7 +48774,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -48798,15 +48782,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -48822,7 +48806,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -48832,25 +48816,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -48862,7 +48846,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -48870,11 +48854,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -48928,15 +48912,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -48948,8 +48932,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -48965,9 +48949,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -48975,8 +48959,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -48988,7 +48972,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -49013,11 +48997,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -49035,7 +49019,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -49044,7 +49028,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -49056,7 +49040,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -49072,8 +49056,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -49097,7 +49081,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -49111,7 +49095,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -49137,7 +49121,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -49155,7 +49139,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -49174,7 +49158,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -49184,11 +49168,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -49208,15 +49192,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -49248,19 +49232,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -49284,8 +49268,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -49301,7 +49285,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -49317,7 +49301,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -49325,44 +49309,44 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCallOutput object { call_id, output, type, 3 more }`
- 一次 computer 工具调用的输出。
+ 计算机工具调用的输出。
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `id: optional string or null`
- computer 工具调用输出的 ID。
+ 计算机工具调用输出的 ID。
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 已被开发者确认的 API 所报告的安全检查结果。
+ 开发者已确认的 API 所报告的安全检查。
- `id: string`
@@ -49378,7 +49362,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值为 `in_progress`, `completed`, or `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -49389,7 +49373,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -49397,12 +49381,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -49412,11 +49396,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -49434,7 +49418,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -49448,7 +49432,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -49466,7 +49450,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -49478,14 +49462,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -49535,8 +49519,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -49550,7 +49534,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: string or array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的文本、图片或文件输出。
+ 函数工具调用的文本、图像或文件输出。
- `string`
@@ -49558,61 +49542,61 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的内容输出(文本、图片、文件)数组。
+ 函数工具调用的内容输出(文本、图像、文件)数组。
- `ResponseInputTextContent object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision)
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `detail: optional ImageDetail or null`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -49622,13 +49606,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -49642,23 +49626,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -49670,7 +49654,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string or null`
- 函数工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
+ 函数工具调用输出的唯一 ID。当此项通过 API 返回时填充。
- `call_id: optional string or null`
@@ -49710,7 +49694,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -49726,7 +49710,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目类型。始终为 `tool_search_call`.
+ 项的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
@@ -49794,37 +49778,37 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -49837,11 +49821,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -49861,7 +49845,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -49877,15 +49861,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -49899,7 +49883,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -49907,7 +49891,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -49919,7 +49903,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -49927,21 +49911,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -49967,18 +49951,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -49986,22 +49970,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -50011,23 +49995,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -50038,11 +50022,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -50060,21 +50044,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -50082,14 +50066,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -50121,32 +50105,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -50154,13 +50138,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -50168,9 +50152,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -50182,22 +50166,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -50206,7 +50190,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -50216,7 +50200,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -50246,29 +50230,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -50304,7 +50288,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -50314,11 +50298,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -50328,7 +50312,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -50336,7 +50320,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -50345,13 +50329,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -50360,7 +50344,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -50387,7 +50371,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -50398,7 +50382,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -50415,13 +50399,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -50437,7 +50421,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -50447,7 +50431,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -50471,7 +50455,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -50495,13 +50479,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -50525,7 +50509,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -50533,13 +50517,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -50559,7 +50543,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -50571,13 +50555,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -50591,11 +50575,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -50621,7 +50605,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -50639,7 +50623,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -50653,19 +50637,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -50685,19 +50669,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -50705,11 +50689,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -50755,7 +50739,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -50767,11 +50751,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -50785,7 +50769,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -50795,7 +50779,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -50805,23 +50789,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -50839,13 +50823,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目类型。始终为 `tool_search_output`.
+ 项的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `id: optional string or null`
- 此工具搜索输出的唯一 ID。
+ 该工具搜索输出的唯一 ID。
- `call_id: optional string or null`
@@ -50873,13 +50857,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `role: "developer"`
- 提供其他工具的角色。仅 `developer` 受支持。
+ 提供这些额外工具的角色。仅支持 `developer` 。
- `"developer"`
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 此项目提供的其他工具列表。
+ 在该条目中提供的额外工具列表。
- `Function object { name, parameters, strict, 5 more }`
@@ -50913,45 +50897,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -50959,7 +50943,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -50971,7 +50955,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -50979,21 +50963,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -51019,18 +51003,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -51038,22 +51022,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -51063,23 +51047,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -51090,11 +51074,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -51112,21 +51096,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -51134,14 +51118,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -51173,32 +51157,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -51206,13 +51190,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -51220,9 +51204,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -51234,22 +51218,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -51258,7 +51242,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -51268,7 +51252,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -51324,7 +51308,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -51334,11 +51318,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -51348,7 +51332,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -51356,7 +51340,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -51365,13 +51349,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -51380,7 +51364,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -51407,7 +51391,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -51418,7 +51402,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -51435,13 +51419,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -51457,7 +51441,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -51467,7 +51451,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -51493,11 +51477,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -51523,19 +51507,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -51555,19 +51539,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -51575,11 +51559,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -51625,7 +51609,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -51637,11 +51621,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -51655,7 +51639,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -51665,7 +51649,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -51675,23 +51659,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -51709,19 +51693,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目类型。始终为 `additional_tools`.
+ 项的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `id: optional string or null`
- 此其他工具项目的唯一 ID。
+ 该额外工具条目的唯一 ID。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -51734,7 +51718,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -51754,7 +51738,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -51764,20 +51748,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -51787,7 +51771,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Compaction object { encrypted_content, type, id }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -51795,17 +51779,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `id: optional string or null`
- 压缩条目的 ID。
+ 压缩项的 ID。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -51829,7 +51813,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -51852,7 +51836,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -51864,23 +51848,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -51898,13 +51882,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -51920,11 +51904,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -51938,11 +51922,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -51956,7 +51940,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -51966,7 +51950,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -51974,13 +51958,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -51994,7 +51978,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
@@ -52006,7 +51990,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最大挂钟时间(毫秒)。
+ 允许 shell 命令运行的 wall-clock 最长时间(毫秒)。
- `call_id: string`
@@ -52014,13 +51998,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
- `id: optional string or null`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -52056,7 +52040,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -52066,7 +52050,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ShellCallOutput object { call_id, output, type, 4 more }`
- shell 工具调用发出的流式输出项。
+ shell 工具调用发出的流式输出条目。
- `call_id: string`
@@ -52074,7 +52058,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: array of ResponseFunctionShellCallOutputContent`
- stdout 和 stderr 输出的捕获块及其关联结果。
+ 捕获的 stdout 和 stderr 输出块,以及它们关联的结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -52086,13 +52070,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -52100,27 +52084,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
- `stderr: string`
- shell 调用捕获的 stderr 输出。
+ 为该 shell 调用捕获的 stderr 输出。
- `stdout: string`
- shell 调用捕获的 stdout 输出。
+ 为该 shell 调用捕获的 stdout 输出。
- `type: "shell_call_output"`
- 条目的类型,恒为 `shell_call_output`.
+ item 的类型。始终为 `shell_call_output`.
- `"shell_call_output"`
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -52162,11 +52146,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 表示使用 diff 补丁创建、删除或更新文件的工具调用。
+ 表示通过 diff 补丁创建、删除或更新文件的工具调用。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
@@ -52178,7 +52162,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 创建文件时要应用的统一 diff 内容。
+ 创建文件时应用的 unified diff 内容。
- `path: string`
@@ -52210,7 +52194,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 要应用于现有文件的统一 diff 内容。
+ 应用于现有文件的 unified diff 内容。
- `path: string`
@@ -52224,7 +52208,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -52232,13 +52216,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
- `id: optional string or null`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -52266,15 +52250,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { call_id, status, type, 3 more }`
- apply patch 工具调用发出的流式输出。
+ 由 apply patch 工具调用发出的流式输出。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -52282,13 +52266,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
- `id: optional string or null`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -52344,7 +52328,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -52352,29 +52336,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -52382,31 +52366,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { approval_request_id, approve, type, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
- `id: optional string or null`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `reason: optional string or null`
@@ -52414,7 +52398,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -52422,11 +52406,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -52434,14 +52418,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -52481,7 +52465,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -52495,11 +52479,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 由你的代码生成的自定义工具调用输出,将被发送回模型。
+ 由你的代码生成的自定义工具调用的输出,将发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -52516,11 +52500,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -52534,7 +52518,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- 自定义工具调用输出在 OpenAI 平台中的唯一 ID。
+ 在 OpenAI 平台中该自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -52584,7 +52568,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -52612,11 +52596,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompactionTrigger object { type, id }`
- 压缩当前上下文。必须是最后一个输入项。
+ 压缩当前上下文。必须作为最后一个输入项。
- `type: "compaction_trigger"`
- 条目的类型,恒为 `compaction_trigger`.
+ item 的类型。始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -52630,11 +52614,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 要引用的条目 ID。
+ 被引用条目的 ID。
- `type: optional "item_reference" or null`
- 要引用的条目类型。始终为 `item_reference`.
+ 被引用条目的类型。始终为 `item_reference`.
- `"item_reference"`
@@ -52650,7 +52634,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -52658,7 +52642,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目类型。始终为 `program`.
+ 项的类型。始终为 `program`.
- `"program"`
@@ -52674,7 +52658,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -52686,14 +52670,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目类型。始终为 `program_output`.
+ 项的类型。始终为 `program_output`.
- `"program_output"`
- `metadata: Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
格式,以及通过 API 或控制台查询对象。
键为字符串,最长 64 个字符。值为字符串
@@ -52702,8 +52686,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: ResponsesModel`
用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI
- 提供了多种不同能力、性能
- 特性和定价的模型。请参阅 [模型指南](/docs/models)
+ 提供了众多功能、性能
+ 特性和价位各异的模型。请参阅 [模型指南](/docs/models)
以浏览和比较可用的模型。
- `string`
@@ -52926,12 +52910,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
由模型生成的内容项数组。
- - 该数组中项的数量和顺序 `output` 取决于
- 模型的响应。
- - 与直接访问该数组的 `output` 第一项并
- 假设它是一 `assistant` 个包含模型生成内容的
- 消息相比,你也可以考虑使用 `output_text` 属性(在
- 受支持的 SDK 中可用)。
+ - 该数组中项的长度和顺序取决于 `output` 模型的响应。
+ 与其访问。
+ - 数组中的第一项并 `output` 假设它是一个
+ 包含模型生成内容的 `assistant` 消息,不如使用
+ 属性(在受支持的 开发工具包 `output_text` 中可用)。
+ SDK。
- `ResponseOutputMessage object { id, content, role, 3 more }`
@@ -52939,8 +52923,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -52952,7 +52936,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -52977,11 +52961,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -52999,7 +52983,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -53008,7 +52992,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -53058,8 +53042,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -53084,15 +53068,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -53100,8 +53084,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -53145,7 +53129,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `name: optional string`
@@ -53158,7 +53142,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -53166,12 +53150,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -53181,11 +53165,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -53203,7 +53187,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -53217,7 +53201,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -53235,7 +53219,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -53247,14 +53231,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -53266,7 +53250,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -53282,8 +53266,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -53303,8 +53287,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `ComputerCallOutput object { id, call_id, output, 4 more }`
@@ -53314,16 +53298,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"completed"`
@@ -53335,13 +53319,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、已被
+ API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -53358,13 +53342,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -53377,7 +53361,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -53395,7 +53379,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -53405,20 +53389,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -53438,7 +53422,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -53446,7 +53430,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目的类型,恒为 `program`.
+ item 的类型。始终为 `program`.
- `"program"`
@@ -53462,7 +53446,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -53474,7 +53458,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目的类型,恒为 `program_output`.
+ item 的类型。始终为 `program_output`.
- `"program_output"`
@@ -53512,13 +53496,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目的类型,恒为 `tool_search_call`.
+ item 的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -53584,45 +53568,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -53630,7 +53614,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -53642,7 +53626,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -53650,21 +53634,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -53690,18 +53674,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -53709,22 +53693,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -53734,23 +53718,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -53761,11 +53745,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -53783,21 +53767,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -53805,14 +53789,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -53844,32 +53828,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -53877,13 +53861,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -53891,9 +53875,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -53905,22 +53889,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -53929,7 +53913,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -53939,7 +53923,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -53995,7 +53979,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -54005,11 +53989,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -54019,7 +54003,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -54027,7 +54011,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -54036,13 +54020,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -54051,7 +54035,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -54078,7 +54062,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -54089,7 +54073,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -54106,13 +54090,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -54128,7 +54112,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -54138,7 +54122,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -54164,11 +54148,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -54194,19 +54178,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -54226,19 +54210,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -54246,11 +54230,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -54296,7 +54280,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -54308,11 +54292,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -54326,7 +54310,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -54336,7 +54320,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -54346,23 +54330,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -54380,13 +54364,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目的类型,恒为 `tool_search_output`.
+ item 的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -54416,7 +54400,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -54450,45 +54434,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -54496,7 +54480,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -54508,7 +54492,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -54516,21 +54500,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -54556,18 +54540,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -54575,22 +54559,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -54600,23 +54584,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -54627,11 +54611,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -54649,21 +54633,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -54671,14 +54655,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -54710,32 +54694,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -54743,13 +54727,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -54757,9 +54741,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -54771,22 +54755,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -54795,7 +54779,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -54805,7 +54789,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -54861,7 +54845,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -54871,11 +54855,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -54885,7 +54869,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -54893,7 +54877,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -54902,13 +54886,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -54917,7 +54901,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -54944,7 +54928,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -54955,7 +54939,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -54972,13 +54956,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -54994,7 +54978,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -55004,7 +54988,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -55030,11 +55014,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -55060,19 +55044,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -55092,19 +55076,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -55112,11 +55096,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -55162,7 +55146,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -55174,11 +55158,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -55192,7 +55176,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -55202,7 +55186,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -55212,23 +55196,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -55246,13 +55230,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目的类型,恒为 `additional_tools`.
+ item 的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -55260,21 +55244,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的已加密内容。
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -55298,7 +55282,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -55321,7 +55305,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -55333,23 +55317,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -55367,13 +55351,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -55389,11 +55373,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -55407,11 +55391,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -55425,7 +55409,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -55435,7 +55419,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -55443,13 +55427,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -55463,17 +55447,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -55511,7 +55495,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -55521,7 +55505,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -55555,7 +55539,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。通过 API 返回该条目时填充此字段。
- `call_id: string`
@@ -55563,15 +55547,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -55579,13 +55563,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -55593,7 +55577,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -55607,11 +55591,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`, or `incomplete`.
+ shell 调用输出的状态。可选值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -55647,7 +55631,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -55655,15 +55639,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -55679,7 +55663,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的 diff 创建新文件。
- `"create_file"`
@@ -55693,7 +55677,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "delete_file"`
- 删除指定的文件。
+ 删除指定文件。
- `"delete_file"`
@@ -55711,13 +55695,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "update_file"`
- 使用提供的差异更新现有文件。
+ 使用提供的 diff 更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -55725,7 +55709,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -55755,19 +55739,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -55775,7 +55759,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -55809,7 +55793,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -55817,11 +55801,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -55829,14 +55813,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -55848,7 +55832,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -55886,7 +55870,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -55894,29 +55878,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -55924,29 +55908,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `id: string`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -55978,7 +55962,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -56012,7 +55996,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -56029,11 +56013,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -56041,8 +56025,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -56082,7 +56066,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `parallel_tool_calls: boolean`
@@ -56090,8 +56074,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `temperature: number or null`
- 使用的采样温度,介于 0 到 2 之间。较高的值(例如 0.8)会使输出更加随机,而较低的值(例如 0.2)会使输出更加聚焦和确定。
- 我们通常建议修改此参数或 `top_p` 但不要同时修改两者。
+ 使用的采样温度,介于 0 到 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加聚焦和确定性。
+ 我们通常建议调整此项或 `top_p` 但不要同时调整两者。
- `tool_choice: ToolChoiceOptions or ToolChoiceAllowed or ToolChoiceTypes or 6 more`
@@ -56101,9 +56085,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceOptions = "none" or "auto" or "required"`
- 控制模型调用哪个工具(如果有的话)。
+ 控制模型调用哪个工具(如果有)。
- `none` 表示模型不会调用任何工具,而是生成一条消息。
+ `none` 表示模型将不会调用任何工具,而是生成一条消息。
`auto` 表示模型可以在生成消息或调用一个或
多个工具之间进行选择。
@@ -56135,7 +56119,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of map[unknown]`
- 模型应允许调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -56156,11 +56140,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceTypes object { type }`
指示模型应使用内置工具来生成响应。
- [了解有关内置工具的更多信息](/docs/guides/tools).
+ [了解更多关于内置工具的信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
- 模型应使用的托管工具类型。了解更多关于
+ 模型应使用的 托管工具 类型。了解更多关于
[内置工具](/docs/guides/tools).
允许的值为:
@@ -56205,7 +56189,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceMcp object { server_label, type, name }`
- 使用此选项可以强制模型调用远程 MCP 服务器上的特定工具。
+ 使用此选项可强制模型调用远程 MCP 服务器上的特定工具。
- `server_label: string`
@@ -56223,7 +56207,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceCustom object { name, type }`
- 使用此选项可以强制模型调用特定的自定义工具。
+ 使用此选项可强制模型调用特定的自定义工具。
- `name: string`
@@ -56239,27 +56223,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "programmatic_tool_calling"`
- 要调用的工具。始终为 `programmatic_tool_calling`.
+ 要调用的工具。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ToolChoiceApplyPatch object { type }`
- 在执行工具调用时强制模型调用 apply_patch 工具。
+ 强制模型在执行工具调用时调用 apply_patch 工具。
- `type: "apply_patch"`
- 要调用的工具。始终为 `apply_patch`.
+ 要调用的工具。始终 `apply_patch`.
- `"apply_patch"`
- `ToolChoiceShell object { type }`
- 在需要工具调用时强制模型调用 shell 工具。
+ 在需要工具调用时,强制模型调用 shell 工具。
- `type: "shell"`
- 要调用的工具。始终为 `shell`.
+ 要调用的工具。始终 `shell`.
- `"shell"`
@@ -56270,18 +56254,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
我们支持以下类别的工具:
- - **内置工具**:由 OpenAI 提供的工具,用于扩展模型的
- 能力,例如 [网页搜索](/docs/guides/tools-web-search)
+ - **内置工具**:由 OpenAI 提供的工具,用于扩展
+ 模型的能力,例如 [网页搜索](/docs/guides/tools-web-search)
或 [文件搜索](/docs/guides/tools-file-search)。详细了解
[内置工具](/docs/guides/tools).
- - **MCP 工具**:通过自定义 MCP 服务器与第三方系统集成
- 或 Google Drive 和 SharePoint 等预定义连接器。详细了解
+ - **MCP 工具**: 通过自定义 MCP 服务器与第三方系统集成
+ 或使用 Google Drive 和 SharePoint 等预定义连接器。详细了解
[MCP 工具](/docs/guides/tools-connectors-mcp).
- - **函数调用(自定义工具)**:由你定义的函数,
+ - **函数调用(自定义工具)**: 由你定义的函数,
使模型能够使用强类型参数和输出调用你自己的代码。详细了解
。你也可以使用
- [function calling](/docs/guides/function-calling)。你还可以使用
- 自定义工具调用你自己的代码。
+ [function calling](/docs/guides/function-calling). 你也可以使用
+ 自定义工具来调用你自己的代码。
- `Function object { name, parameters, strict, 5 more }`
@@ -56315,45 +56299,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -56361,7 +56345,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -56373,7 +56357,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -56381,21 +56365,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -56421,18 +56405,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -56440,22 +56424,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -56465,23 +56449,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -56492,11 +56476,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -56514,21 +56498,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -56536,14 +56520,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -56575,32 +56559,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -56608,13 +56592,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -56622,9 +56606,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -56636,22 +56620,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -56660,7 +56644,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -56670,7 +56654,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -56726,7 +56710,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -56736,11 +56720,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -56750,7 +56734,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -56758,7 +56742,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -56767,13 +56751,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -56782,7 +56766,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -56809,7 +56793,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -56820,7 +56804,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -56837,13 +56821,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -56859,7 +56843,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -56869,7 +56853,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -56895,11 +56879,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -56925,19 +56909,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -56957,19 +56941,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -56977,11 +56961,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -57027,7 +57011,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -57039,11 +57023,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -57057,7 +57041,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -57067,7 +57051,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -57077,23 +57061,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -57111,12 +57095,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `top_p: number or null`
- 一种名为核采样的温度采样替代方案,
- 其中模型会考虑 top_p 概率质量排名前列的词元结果。
- 因此,0.1 表示仅考虑构成前 10% 概率质量的词元。
+ 一种温度采样的替代方法,称为核采样,
+ 模型会考虑概率质量排名前 top_p 的标记的结果。
+ 因此 0.1 表示仅考虑构成前 10% 概率质量的标记。
会被考虑。
- 我们通常建议修改此参数或 `temperature` 但不要同时修改两者。
+ 我们通常建议调整此项或 `temperature` 但不要同时调整两者。
- `background: optional boolean or null`
@@ -57125,44 +57109,44 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `completed_at: optional number or null`
- 此 Response 完成时的 Unix 时间戳(以秒为单位)。
- 仅当状态为 `completed`.
+ 此响应完成时的 Unix 时间戳(以秒为单位)。
+ 仅在状态为 `completed`.
- `conversation: optional object { id } or null`
- 此响应所属的对话。此响应的输入项和输出项已自动添加到此对话。
+ 此响应所属的对话。此次响应的输入项和输出项已自动添加到此对话中。
- `id: string`
- 与此响应关联的对话的唯一 ID。
+ 此响应关联的对话的唯一 ID。
- `max_output_tokens: optional number or null`
- 一次响应中可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
+ 响应可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
- `max_tool_calls: optional number or null`
- 响应中可以处理的内置工具调用总次数上限。该上限适用于所有内置工具调用,而非单个工具。模型任何进一步的工具调用尝试都将被忽略。
+ 一次响应中可处理的内置工具调用总次数上限。该上限适用于所有内置工具调用的总和,而非单个工具。模型后续任何再次调用工具的尝试都将被忽略。
- `moderation: optional object { input, output } or null`
- 响应输入和输出的审核结果,前提是请求了已审核的补全。
+ 响应输入与输出的内容审核结果,前提是请求了经过审核的补全。
- `input: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输入的审核结果。
+ 对响应输入的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -57170,7 +57154,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -57178,17 +57162,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -57200,25 +57184,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输出的审核结果。
+ 对响应输出的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -57226,7 +57210,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -57234,17 +57218,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -57256,21 +57240,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output_text: optional string or null`
- 仅限SDK的便捷属性,包含所有输出消息中聚合的文本输出
- 来自所有 `output_text` 数组中的 `output` 条目(如果有)。
+ SDK 独有的便捷属性,包含来自所有
+ 的聚合文本输出 `output_text` 数组中的 `output` 条目(如有)。
在 Python 和 JavaScript SDK 中受支持。
- `previous_response_id: optional string or null`
- 模型上一次响应的唯一 ID。使用它来
- 创建多轮对话。了解有关
- [对话状态](/docs/guides/conversation-state)。的更多信息。不能与 `conversation`.
+ 上一个模型响应的唯一 ID。使用它可以
+ 创建多轮对话。详细了解
+ [conversation state](/docs/guides/conversation-state)。不能与 `conversation`.
- `prompt: optional ResponsePrompt or null`
@@ -57283,19 +57267,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `variables: optional map[string or ResponseInputText or ResponseInputImage or ResponseInputFile] or null`
- 用于替换提示模板中变量的可选值映射,
- prompt。替换值可以是字符串,也可以是其他
- Response 输入类型,例如图像或文件。
+ 用于替换你
+ prompt。替换的值可以是字符串,也可以是其他
+ Response 输入类型,如图像或文件。
- `string`
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -57303,19 +57287,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `version: optional string or null`
- 提示模板的可选版本。
+ prompt 模板的可选版本。
- `prompt_cache_key: optional string or null`
- 由 OpenAI 用于缓存相似请求的响应,以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
+ 由OpenAI使用,为相似请求缓存响应以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
- `prompt_cache_options: optional object { mode, ttl }`
- 应用于该响应的提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。
+ 应用于该响应的 prompt 缓存选项。支持以下 `gpt-5.6` 及更高版本的模型。
- `mode: "implicit" or "explicit"`
- 是否启用了隐式提示缓存断点。
+ 是否启用了隐式 prompt 缓存断点。
- `"implicit"`
@@ -57323,24 +57307,24 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ttl: "30m"`
- 应用于每个缓存断点的最短生存时间。
+ 应用于每个缓存断点的最短生命周期。
- `"30m"`
- `prompt_cache_retention: optional "in_memory" or "24h" or null`
- 已弃用。请使用 `prompt_cache_options.ttl` 相反。
+ 已弃用。请使用 `prompt_cache_options.ttl` 改为。
- 提示词缓存的保留策略。设置为 `24h` 以启用扩展提示词缓存,使缓存前缀保持更长时间,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
- 此字段表示最长保留策略,而
+ 提示缓存的保留策略。设置为 `24h` 以启用扩展提示缓存,使缓存的前缀保持更长时间有效,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
+ 该字段表示最大保留策略,而
`prompt_cache_options.ttl` 表示最短缓存生命周期。这两个
- 字段彼此独立,不会相互影响。
- 对于 `gpt-5.5`, `gpt-5.5-pro`,及未来模型,仅 `24h` 受支持。
+ 字段是独立的,不会相互影响。
+ 对于 `gpt-5.5`, `gpt-5.5-pro`,以及未来的模型,仅 `24h` 。
对于同时支持两者的旧模型 `in_memory` 和 `24h`,默认值取决于你组织的数据保留策略:
- - 未启用 ZDR 的组织默认使用 `24h`.
- - 启用 ZDR 的组织默认使用 `in_memory` 当 `prompt_cache_retention` 未指定时。
+ - 未启用 ZDR 的组织默认为 `24h`.
+ - 启用 ZDR 的组织默认为 `in_memory` 当 `prompt_cache_retention` 未指定时。
- `"in_memory"`
@@ -57348,18 +57332,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `reasoning: optional Reasoning or null`
- 配置选项,适用于
+ 适用于
[推理模型](https://platform.openai.com/docs/guides/reasoning).
- `context: optional "auto" or "current_turn" or "all_turns" or null`
- 控制在后续轮次中呈现回模型的推理项。
- 如果省略或设置为 `auto`,则由模型确定上下文模式。
+ 控制在后续回合中哪些推理项会被回传给模型。
+ 如果省略或设置为 `auto`,则由模型决定上下文模式。
`gpt-5.6` 模型系列默认为 `all_turns`;早期模型默认为
`current_turn`.
- 在响应中返回时,这是该响应使用的有效推理上下文模式
- 。
+ 在响应中返回时,这是该响应所使用 的有效推理上下文模式
+ 用于该响应。
- `"auto"`
@@ -57369,13 +57353,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `effort: optional ReasoningEffort or null`
- 限制推理模型在推理上的投入程度。当前支持的值
- 包括 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
- 降低推理投入程度可以让响应更快,并减少响应中推理所用的 token 数。并非所有推理模型都支持每个
- 值。请参阅
- 推理指南
+ 限制推理模型在推理上的投入程度。目前支持
+ 的取值有 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
+ 降低推理投入程度可以让响应更快,并减少响应中用于推理的 token
+ 数量。并非所有推理模型都支持每个
+ 取值。有关各模型的支持情况,请参阅
[推理指南](https://platform.openai.com/docs/guides/reasoning)
- 以了解特定模型的支持情况。
+ 。
- `"none"`
@@ -57393,11 +57377,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `generate_summary: optional "auto" or "concise" or "detailed" or null`
- **已弃用:** 请使用 `summary` 相反。
+ **已弃用:** 请使用 `summary` 改为。
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `"auto"`
@@ -57409,7 +57393,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `string`
@@ -57417,7 +57401,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `"standard"`
@@ -57425,11 +57409,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `summary: optional "auto" or "concise" or "detailed" or null`
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `concise` 支持以下模型 `computer-use-preview` 以及之后的所有推理模型 `gpt-5`.
+ `concise` 支持用于 `computer-use-preview` 模型以及之后的 `gpt-5`.
- `"auto"`
@@ -57439,21 +57423,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `safety_identifier: optional string or null`
- 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用策略的应用程序用户。
- ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份识别信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用政策的应用用户。
+ ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `service_tier: optional ServiceTier or null`
指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
+ - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则该项目将使用 'default'。
- 如果设置为 'default',则该请求将使用所选模型的标准定价和性能进行处理。
- 如果设置为 '[flex](/docs/guides/flex-processing)',则该请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别选择启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 `service_tier=fast` 或 `service_tier=priority` 参数用于 Responses 或 Chat Completions。响应将显示 `service_tier=priority` ,无论你是否在请求中指定了 `service_tier=fast` 或 `priority` 。
- - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级返回的响应将显示 `service_tier=ultrafast`.
- - 如果未设置,默认行为是 'auto'。
+ - 若要在请求级别启用 [快速模式](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过它处理的响应将显示 `service_tier=ultrafast`.
+ - 未设置时,默认行为为 'auto'。
- 当设置 `service_tier` 参数时,响应正文将包含基于实际用于处理该请求的处理模式的 `service_tier` 值。此响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应体中将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。此响应中的值可能与该参数中设置的值不同。
- `"auto"`
@@ -57471,8 +57455,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional ResponseStatus`
- 响应生成的状态。取值之一为 `completed`, `failed`,
- `in_progress`, `cancelled`, `queued`, or `incomplete`.
+ 响应生成的状态。可选值为 `completed`, `failed`,
+ `in_progress`, `cancelled`, `queued`,或 `incomplete`.
- `"completed"`
@@ -57488,8 +57472,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: optional ResponseTextConfig`
- 用于配置模型文本响应的选项。可以是纯文本,也可以是结构化的 JSON 数据。详见:
- 文本输入与输出:
+ 模型文本响应的配置选项。可以是纯
+ 文本或结构化 JSON 数据。了解更多:
- [文本输入与输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
@@ -57498,79 +57482,79 @@ curl https://api.openai.com/v1/responses/resp_123 \
用于指定模型必须输出的格式的对象。
- 设置为 `{ "type": "json_schema" }` 时,将启用结构化输出,
- 功能,从而确保模型的输出与你提供的 JSON schema 相匹配。详见
+ 配置 `{ "type": "json_schema" }` 可启用结构化输出,
+ 从而确保模型匹配你提供的 JSON schema。更多信息请参阅
[结构化输出指南](/docs/guides/structured-outputs).
- 默认的格式为 `{ "type": "text" }` ,且不包含其他选项。
+ 默认格式为 `{ "type": "text" }` ,不包含任何额外选项。
- **不建议在 gpt-4o 及更新模型上使用:**
+ **不推荐用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
- 的模型,建议优先使用该格式。
+ 设置为 `{ "type": "json_object" }` 会启用旧版 JSON 模式,该模式
+ 可确保模型生成的消息是合法 JSON。对于支持 `json_schema`
+ 的模型,建议优先使用它。
- `ResponseFormatText object { type }`
- 默认的响应格式。用于生成文本响应。
+ 默认响应格式。用于生成文本响应。
- `type: "text"`
- 正在定义的响应格式的类型。始终为 `text`.
+ 正在定义的响应格式类型。始终为 `text`.
- `"text"`
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化的 JSON 响应。
+ JSON Schema 响应格式。用于生成结构化 JSON 响应。
详细了解 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
- 下划线和连字符,最大长度为 64。
+ 下划线和短横线,最大长度为 64。
- `schema: map[unknown]`
- 响应格式的 schema,以 JSON Schema 对象描述。
- 了解如何构建 JSON schema [此处](https://json-schema.org/).
+ 响应格式的架构,以 JSON Schema 对象形式描述。
+ 了解如何构建 JSON 架构 [此处](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式的类型。始终为 `json_schema`.
+ 正在定义的响应格式类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
响应格式用途的描述,供模型用于
- 确定如何按该格式进行响应。
+ 确定如何按该格式响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 一致性。
- 如果设置为 true,模型将始终遵循
- 字段中 `schema` 定义的精确 schema。仅支持 JSON Schema 的一个子集,当
- `strict` 是 `true`。要了解更多信息,请阅读 [Structured Outputs
+ 生成输出时是否启用严格的架构遵循。
+ 如果设置为 true,模型将始终遵循 字段中定义的
+ 确切架构。当 设置为 `schema` true 时,仅支持 JSON Schema 的一个子集
+ `strict` 是 `true`。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较早的生成 JSON 响应的方法。
- 使用 `json_schema` 对支持它的模型是推荐的做法。请注意
- 模型在没有系统或用户消息指示的情况下不会生成
- JSON。
+ JSON 对象响应格式。一种较旧的 JSON 响应生成方法。建议。
+ 对于支持 的模型,使用 `json_schema` 。请注意,模型不会在没有系统或用户消息指示
+ 的情况下生成 JSON
+ 。
- `type: "json_object"`
- 正在定义的响应格式的类型。始终为 `json_object`.
+ 正在定义的响应格式类型。始终为 `json_object`.
- `"json_object"`
- `verbosity: optional "low" or "medium" or "high" or null`
- 约束模型响应的详细程度。较低的值会产生
- 更简洁的响应,较高的值会产生更详细的响应。
+ 约束模型响应的详尽程度。较低的值将导致
+ 更简洁的响应,而较高的值将导致更冗长的响应。
当前支持的值包括 `low`, `medium`,和 `high`。默认值为
`medium`.
@@ -57582,20 +57566,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `top_logprobs: optional number or null`
- 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的最大最可能
- token 数量,每个 token 都附带对应的对数
+ 一个介于 0 到 20 之间的整数,指定在每个 token 位置返回的
+ 最可能 token 的最大数量,每个 token 都有一个关联的对数
概率。在某些情况下,返回的 token 数量可能少于
- 所请求的数量。
+ 请求的数量。
- `truncation: optional "auto" or "disabled" or null`
用于模型响应的截断策略。
- - `auto`:如果此 Response 的输入超过
- 模型的上下文窗口大小,模型将通过从对话开头丢弃条目来截断
- 响应以适配上下文窗口。
- - `disabled` (默认):如果输入大小将超出模型的上下文窗口
- 大小,请求将失败并返回 400 错误。
+ - `auto`:如果此 Response 的输入超出
+ 模型的上下文窗口大小,模型将通过从对话开头
+ 丢弃条目来截断响应以适配上下文窗口。
+ - `disabled` (默认):如果输入大小将超过模型的上下文窗口
+ 大小,请求将以 400 错误失败。
- `"auto"`
@@ -57604,7 +57588,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `usage: optional ResponseUsage`
表示 token 使用详情,包括输入 token、输出 token,
- 的输出 token 明细,以及所使用的 token 总数。
+ 输出 token 的细分,以及使用的总 token 数。
- `input_tokens: number`
@@ -57612,16 +57596,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_tokens_details: object { cache_write_tokens, cached_tokens }`
- 输入 token 的详细明细。
+ 输入 token 的详细细分。
- `cache_write_tokens: number`
- 已写入缓存的输入 token 数量。
+ 写入缓存的输入 token 的数量。
- `cached_tokens: number`
- 从缓存中检索到的 token 数量。
- [了解更多关于提示缓存的信息](/docs/guides/prompt-caching).
+ 从缓存中检索到的 token 的数量。
+ [有关 prompt caching 的更多信息](/docs/guides/prompt-caching).
- `output_tokens: number`
@@ -57629,39 +57613,35 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_tokens_details: object { reasoning_tokens }`
- 输出令牌的详细明细。
+ 输出 token 的详细明细。
- `reasoning_tokens: number`
- 推理令牌的数量。
+ 推理 token 的数量。
- `total_tokens: number`
- 使用的令牌总数。
-
- - `compute_units: optional number or null`
-
- 该请求的计算单元。在可用时当前为 null。
+ 使用的 token 总数。
- `user: optional string`
- 此字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
- 用于标识你的最终用户的稳定标识符。
- 通过更好地对相似请求进行分桶以提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 该字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
+ 你的最终用户的稳定标识符。
+ 通过更好地对相似请求进行分桶来提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
### Response Audio Delta Event
- `ResponseAudioDeltaEvent object { delta, sequence_number, type }`
- 当出现部分音频响应时发出。
+ 当存在部分音频响应时发出。
- `delta: string`
- 一段 Base64 编码的响应音频字节。
+ Base64 编码的响应音频字节块。
- `sequence_number: number`
- 该流式响应片段的序列号。
+ 流响应中此块的序列号。
- `type: "response.audio.delta"`
@@ -57669,15 +57649,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.audio.delta"`
-### Response Audio Done 事件
+### Response Audio Done Event
- `ResponseAudioDoneEvent object { sequence_number, type }`
- 当音频响应完成时发出。
+ 音频响应完成时触发。
- `sequence_number: number`
- 增量事件的序列号。
+ 增量数据的序列号。
- `type: "response.audio.done"`
@@ -57685,7 +57665,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.audio.done"`
-### 响应音频转录增量事件
+### Response Audio Transcript Delta Event
- `ResponseAudioTranscriptDeltaEvent object { delta, sequence_number, type }`
@@ -57705,11 +57685,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.audio.transcript.delta"`
-### Response Audio Transcript Done Event
+### Response Audio Transcript Done 事件
- `ResponseAudioTranscriptDoneEvent object { sequence_number, type }`
- 当完整音频转写完成时发出。
+ 在完整音频转录完成时发出。
- `sequence_number: number`
@@ -57721,27 +57701,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.audio.transcript.done"`
-### Response Code Interpreter Call Code Delta 事件
+### Response Code Interpreter 调用代码增量事件
- `ResponseCodeInterpreterCallCodeDeltaEvent object { delta, item_id, output_index, 2 more }`
- 当代码解释器流式传输出部分代码片段时发出。
+ 当代码解释器流式输出部分代码片段时触发。
- `delta: string`
- 代码解释器正在流式传输的部分代码片段。
+ 由代码解释器流式输出的部分代码片段。
- `item_id: string`
- 代码解释器工具调用条目的唯一标识符。
+ 代码解释器工具调用项的唯一标识符。
- `output_index: number`
- 响应中正在流式传输代码的输出条目的索引。
+ 响应中正在流式输出代码的输出项的索引。
- `sequence_number: number`
- 该事件的序列号,用于对流式传输事件进行排序。
+ 此事件的序列号,用于对流式事件进行排序。
- `type: "response.code_interpreter_call_code.delta"`
@@ -57749,11 +57729,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.code_interpreter_call_code.delta"`
-### 响应代码解释器调用完成事件
+### Response Code Interpreter 调用代码完成事件
- `ResponseCodeInterpreterCallCodeDoneEvent object { code, item_id, output_index, 2 more }`
- 当代码解释器最终确定代码片段时发出。
+ 当代码解释器最终确定代码片段时触发。
- `code: string`
@@ -57761,15 +57741,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 代码解释器工具调用条目的唯一标识符。
+ 代码解释器工具调用项的唯一标识符。
- `output_index: number`
- 响应中输出项的索引,该输出项的代码已最终确定。
+ 响应中已最终确定代码的输出项的索引。
- `sequence_number: number`
- 该事件的序列号,用于对流式传输事件进行排序。
+ 此事件的序列号,用于对流式事件进行排序。
- `type: "response.code_interpreter_call_code.done"`
@@ -57785,7 +57765,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 代码解释器工具调用条目的唯一标识符。
+ 代码解释器工具调用项的唯一标识符。
- `output_index: number`
@@ -57793,7 +57773,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `sequence_number: number`
- 该事件的序列号,用于对流式传输事件进行排序。
+ 此事件的序列号,用于对流式事件进行排序。
- `type: "response.code_interpreter_call.completed"`
@@ -57801,7 +57781,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.code_interpreter_call.completed"`
-### Response Code Interpreter Call In Progress 事件
+### Response 代码解释器调用进行中事件
- `ResponseCodeInterpreterCallInProgressEvent object { item_id, output_index, sequence_number, type }`
@@ -57809,15 +57789,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 代码解释器工具调用条目的唯一标识符。
+ 代码解释器工具调用项的唯一标识符。
- `output_index: number`
- 响应中正在执行代码解释器调用的输出项的索引。
+ 响应中代码解释器调用正在进行的输出项索引。
- `sequence_number: number`
- 该事件的序列号,用于对流式传输事件进行排序。
+ 此事件的序列号,用于对流式事件进行排序。
- `type: "response.code_interpreter_call.in_progress"`
@@ -57825,7 +57805,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.code_interpreter_call.in_progress"`
-### Response 代码解释器调用解释事件
+### Response Code Interpreter 调用解释事件
- `ResponseCodeInterpreterCallInterpretingEvent object { item_id, output_index, sequence_number, type }`
@@ -57833,15 +57813,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 代码解释器工具调用条目的唯一标识符。
+ 代码解释器工具调用项的唯一标识符。
- `output_index: number`
- 响应中代码解释器正在解释代码的输出项索引。
+ 响应中代码解释器正在解释代码的输出项的索引。
- `sequence_number: number`
- 该事件的序列号,用于对流式传输事件进行排序。
+ 此事件的序列号,用于对流式事件进行排序。
- `type: "response.code_interpreter_call.interpreting"`
@@ -57849,7 +57829,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.code_interpreter_call.interpreting"`
-### Response Completed Event
+### 响应完成事件
- `ResponseCompletedEvent object { response, sequence_number, type }`
@@ -57865,7 +57845,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_at: number`
- 创建此 Response 时的 Unix 时间戳(以秒为单位)。
+ 此 Response 创建时的 Unix 时间戳(以秒为单位)。
- `error: ResponseError or null`
@@ -57921,87 +57901,89 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `incomplete_details: object { reason } or null`
- 有关响应未完成原因的详细信息。
+ 有关响应不完整的详细原因。
- - `reason: optional "max_output_tokens" or "content_filter"`
+ - `reason: optional "max_output_tokens" or "max_messages" or "content_filter"`
- 响应未完成的原因。
+ 响应不完整的原因。
- `"max_output_tokens"`
+ - `"max_messages"`
+
- `"content_filter"`
- `instructions: string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more or null`
插入到模型上下文中的系统(或开发者)消息。
- 当与 `previous_response_id`,配合使用时,前一次
- 响应的指令不会延续到下一次响应。这便于在新响应中
- 替换系统(或开发者)消息。
+ 当与 `previous_response_id`,配合使用时,上一个
+ response 中的 instructions 不会延续到下一个 response。这样可以轻松地
+ 在新的 response 中替换系统(或开发者)消息。
- `string`
- 发送给模型的文本输入,相当于使用
+ 发送给模型的文本输入,等同于
`developer` 角色的文本输入。
- `InputItemList = array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 发送给模型的一个或多个输入项的列表,包含
+ 发送给模型的一个或多个输入项列表,包含
不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` role. Messages with the
- `assistant` role are presumed to have been generated by the model in previous
- interactions.
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色给出的指令。带有
+ `assistant` 角色的消息被视为模型在之前的
+ 交互中生成。
- `content: string or ResponseInputMessageContentList`
- Text, image, or audio input to the model, used to generate a response.
- Can also contain previous assistant responses.
+ 发送给模型的文本、图像或音频输入,用于生成响应。
+ 也可以包含之前的助手响应。
- `TextInput = string`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputMessageContentList = array of ResponseInputContent`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -58013,25 +57995,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -58041,13 +58023,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -58057,33 +58039,33 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `assistant`, `system`, or
+ 消息输入的角色。其一为 接口 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -58096,9 +58078,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -58106,24 +58088,24 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: optional "message"`
- 消息输入的类型。始终为 `message`.
+ 消息输入的类型。始终为 接口 `message`.
- `"message"`
- `Message object { content, role, status, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` 角色的文本输入。
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色的文本输入。
- `content: ResponseInputMessageContentList`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `system`, or `developer`.
+ 消息输入的角色。其一为 接口 `user`, `system`,或 `developer`.
- `"user"`
@@ -58133,8 +58115,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -58154,7 +58136,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -58162,15 +58144,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -58186,7 +58168,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -58196,25 +58178,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -58226,7 +58208,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -58234,11 +58216,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -58292,15 +58274,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -58312,8 +58294,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -58329,9 +58311,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -58339,8 +58321,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -58352,7 +58334,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -58377,11 +58359,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -58399,7 +58381,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -58408,7 +58390,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -58420,7 +58402,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -58436,8 +58418,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -58461,7 +58443,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -58475,7 +58457,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -58501,7 +58483,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -58519,7 +58501,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -58538,7 +58520,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -58548,11 +58530,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -58572,15 +58554,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -58612,19 +58594,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -58648,8 +58630,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -58665,7 +58647,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -58681,7 +58663,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -58689,44 +58671,44 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCallOutput object { call_id, output, type, 3 more }`
- 一次 computer 工具调用的输出。
+ 计算机工具调用的输出。
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `id: optional string or null`
- computer 工具调用输出的 ID。
+ 计算机工具调用输出的 ID。
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 已被开发者确认的 API 所报告的安全检查结果。
+ 开发者已确认的 API 所报告的安全检查。
- `id: string`
@@ -58742,7 +58724,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值为 `in_progress`, `completed`, or `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -58753,7 +58735,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -58761,12 +58743,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -58776,11 +58758,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -58798,7 +58780,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -58812,7 +58794,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -58830,7 +58812,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -58842,14 +58824,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -58899,8 +58881,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -58914,7 +58896,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: string or array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的文本、图片或文件输出。
+ 函数工具调用的文本、图像或文件输出。
- `string`
@@ -58922,61 +58904,61 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的内容输出(文本、图片、文件)数组。
+ 函数工具调用的内容输出(文本、图像、文件)数组。
- `ResponseInputTextContent object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision)
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `detail: optional ImageDetail or null`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -58986,13 +58968,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -59006,23 +58988,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -59034,7 +59016,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string or null`
- 函数工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
+ 函数工具调用输出的唯一 ID。当此项通过 API 返回时填充。
- `call_id: optional string or null`
@@ -59074,7 +59056,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -59090,7 +59072,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目类型。始终为 `tool_search_call`.
+ 项的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
@@ -59158,37 +59140,37 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -59201,11 +59183,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -59225,7 +59207,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -59241,15 +59223,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -59263,7 +59245,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -59271,7 +59253,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -59283,7 +59265,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -59291,21 +59273,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -59331,18 +59313,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -59350,22 +59332,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -59375,23 +59357,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -59402,11 +59384,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -59424,21 +59406,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -59446,14 +59428,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -59485,32 +59467,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -59518,13 +59500,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -59532,9 +59514,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -59546,22 +59528,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -59570,7 +59552,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -59580,7 +59562,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -59610,29 +59592,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -59668,7 +59650,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -59678,11 +59660,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -59692,7 +59674,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -59700,7 +59682,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -59709,13 +59691,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -59724,7 +59706,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -59751,7 +59733,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -59762,7 +59744,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -59779,13 +59761,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -59801,7 +59783,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -59811,7 +59793,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -59835,7 +59817,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -59859,13 +59841,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -59889,7 +59871,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -59897,13 +59879,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -59923,7 +59905,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -59935,13 +59917,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -59955,11 +59937,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -59985,7 +59967,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -60003,7 +59985,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -60017,19 +59999,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -60049,19 +60031,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -60069,11 +60051,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -60119,7 +60101,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -60131,11 +60113,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -60149,7 +60131,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -60159,7 +60141,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -60169,23 +60151,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -60203,13 +60185,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目类型。始终为 `tool_search_output`.
+ 项的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `id: optional string or null`
- 此工具搜索输出的唯一 ID。
+ 该工具搜索输出的唯一 ID。
- `call_id: optional string or null`
@@ -60237,13 +60219,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `role: "developer"`
- 提供其他工具的角色。仅 `developer` 受支持。
+ 提供这些额外工具的角色。仅支持 `developer` 。
- `"developer"`
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 此项目提供的其他工具列表。
+ 在该条目中提供的额外工具列表。
- `Function object { name, parameters, strict, 5 more }`
@@ -60277,45 +60259,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -60323,7 +60305,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -60335,7 +60317,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -60343,21 +60325,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -60383,18 +60365,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -60402,22 +60384,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -60427,23 +60409,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -60454,11 +60436,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -60476,21 +60458,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -60498,14 +60480,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -60537,32 +60519,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -60570,13 +60552,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -60584,9 +60566,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -60598,22 +60580,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -60622,7 +60604,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -60632,7 +60614,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -60688,7 +60670,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -60698,11 +60680,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -60712,7 +60694,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -60720,7 +60702,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -60729,13 +60711,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -60744,7 +60726,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -60771,7 +60753,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -60782,7 +60764,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -60799,13 +60781,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -60821,7 +60803,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -60831,7 +60813,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -60857,11 +60839,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -60887,19 +60869,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -60919,19 +60901,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -60939,11 +60921,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -60989,7 +60971,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -61001,11 +60983,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -61019,7 +61001,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -61029,7 +61011,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -61039,23 +61021,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -61073,19 +61055,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目类型。始终为 `additional_tools`.
+ 项的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `id: optional string or null`
- 此其他工具项目的唯一 ID。
+ 该额外工具条目的唯一 ID。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -61098,7 +61080,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -61118,7 +61100,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -61128,20 +61110,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -61151,7 +61133,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Compaction object { encrypted_content, type, id }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -61159,17 +61141,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `id: optional string or null`
- 压缩条目的 ID。
+ 压缩项的 ID。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -61193,7 +61175,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -61216,7 +61198,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -61228,23 +61210,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -61262,13 +61244,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -61284,11 +61266,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -61302,11 +61284,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -61320,7 +61302,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -61330,7 +61312,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -61338,13 +61320,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -61358,7 +61340,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
@@ -61370,7 +61352,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最大挂钟时间(毫秒)。
+ 允许 shell 命令运行的 wall-clock 最长时间(毫秒)。
- `call_id: string`
@@ -61378,13 +61360,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
- `id: optional string or null`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -61420,7 +61402,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -61430,7 +61412,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ShellCallOutput object { call_id, output, type, 4 more }`
- shell 工具调用发出的流式输出项。
+ shell 工具调用发出的流式输出条目。
- `call_id: string`
@@ -61438,7 +61420,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: array of ResponseFunctionShellCallOutputContent`
- stdout 和 stderr 输出的捕获块及其关联结果。
+ 捕获的 stdout 和 stderr 输出块,以及它们关联的结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -61450,13 +61432,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -61464,27 +61446,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
- `stderr: string`
- shell 调用捕获的 stderr 输出。
+ 为该 shell 调用捕获的 stderr 输出。
- `stdout: string`
- shell 调用捕获的 stdout 输出。
+ 为该 shell 调用捕获的 stdout 输出。
- `type: "shell_call_output"`
- 条目的类型,恒为 `shell_call_output`.
+ item 的类型。始终为 `shell_call_output`.
- `"shell_call_output"`
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -61526,11 +61508,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 表示使用 diff 补丁创建、删除或更新文件的工具调用。
+ 表示通过 diff 补丁创建、删除或更新文件的工具调用。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
@@ -61542,7 +61524,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 创建文件时要应用的统一 diff 内容。
+ 创建文件时应用的 unified diff 内容。
- `path: string`
@@ -61574,7 +61556,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 要应用于现有文件的统一 diff 内容。
+ 应用于现有文件的 unified diff 内容。
- `path: string`
@@ -61588,7 +61570,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -61596,13 +61578,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
- `id: optional string or null`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -61630,15 +61612,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { call_id, status, type, 3 more }`
- apply patch 工具调用发出的流式输出。
+ 由 apply patch 工具调用发出的流式输出。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -61646,13 +61628,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
- `id: optional string or null`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -61708,7 +61690,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -61716,29 +61698,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -61746,31 +61728,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { approval_request_id, approve, type, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
- `id: optional string or null`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `reason: optional string or null`
@@ -61778,7 +61760,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -61786,11 +61768,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -61798,14 +61780,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -61845,7 +61827,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -61859,11 +61841,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 由你的代码生成的自定义工具调用输出,将被发送回模型。
+ 由你的代码生成的自定义工具调用的输出,将发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -61880,11 +61862,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -61898,7 +61880,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- 自定义工具调用输出在 OpenAI 平台中的唯一 ID。
+ 在 OpenAI 平台中该自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -61948,7 +61930,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -61976,11 +61958,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompactionTrigger object { type, id }`
- 压缩当前上下文。必须是最后一个输入项。
+ 压缩当前上下文。必须作为最后一个输入项。
- `type: "compaction_trigger"`
- 条目的类型,恒为 `compaction_trigger`.
+ item 的类型。始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -61994,11 +61976,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 要引用的条目 ID。
+ 被引用条目的 ID。
- `type: optional "item_reference" or null`
- 要引用的条目类型。始终为 `item_reference`.
+ 被引用条目的类型。始终为 `item_reference`.
- `"item_reference"`
@@ -62014,7 +61996,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -62022,7 +62004,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目类型。始终为 `program`.
+ 项的类型。始终为 `program`.
- `"program"`
@@ -62038,7 +62020,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -62050,14 +62032,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目类型。始终为 `program_output`.
+ 项的类型。始终为 `program_output`.
- `"program_output"`
- `metadata: Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
格式,以及通过 API 或控制台查询对象。
键为字符串,最长 64 个字符。值为字符串
@@ -62066,8 +62048,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: ResponsesModel`
用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI
- 提供了多种不同能力、性能
- 特性和定价的模型。请参阅 [模型指南](/docs/models)
+ 提供了众多功能、性能
+ 特性和价位各异的模型。请参阅 [模型指南](/docs/models)
以浏览和比较可用的模型。
- `string`
@@ -62290,12 +62272,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
由模型生成的内容项数组。
- - 该数组中项的数量和顺序 `output` 取决于
- 模型的响应。
- - 与直接访问该数组的 `output` 第一项并
- 假设它是一 `assistant` 个包含模型生成内容的
- 消息相比,你也可以考虑使用 `output_text` 属性(在
- 受支持的 SDK 中可用)。
+ - 该数组中项的长度和顺序取决于 `output` 模型的响应。
+ 与其访问。
+ - 数组中的第一项并 `output` 假设它是一个
+ 包含模型生成内容的 `assistant` 消息,不如使用
+ 属性(在受支持的 开发工具包 `output_text` 中可用)。
+ SDK。
- `ResponseOutputMessage object { id, content, role, 3 more }`
@@ -62303,8 +62285,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -62316,7 +62298,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -62341,11 +62323,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -62363,7 +62345,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -62372,7 +62354,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -62422,8 +62404,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -62448,15 +62430,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -62464,8 +62446,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -62509,7 +62491,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `name: optional string`
@@ -62522,7 +62504,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -62530,12 +62512,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -62545,11 +62527,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -62567,7 +62549,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -62581,7 +62563,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -62599,7 +62581,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -62611,14 +62593,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -62630,7 +62612,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -62646,8 +62628,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -62667,8 +62649,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `ComputerCallOutput object { id, call_id, output, 4 more }`
@@ -62678,16 +62660,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"completed"`
@@ -62699,13 +62681,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、已被
+ API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -62722,13 +62704,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -62741,7 +62723,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -62759,7 +62741,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -62769,20 +62751,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -62802,7 +62784,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -62810,7 +62792,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目的类型,恒为 `program`.
+ item 的类型。始终为 `program`.
- `"program"`
@@ -62826,7 +62808,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -62838,7 +62820,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目的类型,恒为 `program_output`.
+ item 的类型。始终为 `program_output`.
- `"program_output"`
@@ -62876,13 +62858,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目的类型,恒为 `tool_search_call`.
+ item 的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -62948,45 +62930,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -62994,7 +62976,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -63006,7 +62988,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -63014,21 +62996,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -63054,18 +63036,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -63073,22 +63055,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -63098,23 +63080,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -63125,11 +63107,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -63147,21 +63129,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -63169,14 +63151,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -63208,32 +63190,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -63241,13 +63223,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -63255,9 +63237,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -63269,22 +63251,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -63293,7 +63275,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -63303,7 +63285,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -63359,7 +63341,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -63369,11 +63351,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -63383,7 +63365,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -63391,7 +63373,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -63400,13 +63382,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -63415,7 +63397,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -63442,7 +63424,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -63453,7 +63435,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -63470,13 +63452,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -63492,7 +63474,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -63502,7 +63484,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -63528,11 +63510,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -63558,19 +63540,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -63590,19 +63572,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -63610,11 +63592,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -63660,7 +63642,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -63672,11 +63654,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -63690,7 +63672,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -63700,7 +63682,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -63710,23 +63692,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -63744,13 +63726,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目的类型,恒为 `tool_search_output`.
+ item 的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -63780,7 +63762,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -63814,45 +63796,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -63860,7 +63842,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -63872,7 +63854,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -63880,21 +63862,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -63920,18 +63902,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -63939,22 +63921,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -63964,23 +63946,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -63991,11 +63973,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -64013,21 +63995,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -64035,14 +64017,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -64074,32 +64056,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -64107,13 +64089,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -64121,9 +64103,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -64135,22 +64117,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -64159,7 +64141,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -64169,7 +64151,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -64225,7 +64207,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -64235,11 +64217,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -64249,7 +64231,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -64257,7 +64239,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -64266,13 +64248,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -64281,7 +64263,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -64308,7 +64290,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -64319,7 +64301,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -64336,13 +64318,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -64358,7 +64340,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -64368,7 +64350,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -64394,11 +64376,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -64424,19 +64406,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -64456,19 +64438,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -64476,11 +64458,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -64526,7 +64508,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -64538,11 +64520,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -64556,7 +64538,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -64566,7 +64548,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -64576,23 +64558,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -64610,13 +64592,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目的类型,恒为 `additional_tools`.
+ item 的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -64624,21 +64606,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的已加密内容。
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -64662,7 +64644,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -64685,7 +64667,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -64697,23 +64679,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -64731,13 +64713,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -64753,11 +64735,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -64771,11 +64753,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -64789,7 +64771,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -64799,7 +64781,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -64807,13 +64789,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -64827,17 +64809,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -64875,7 +64857,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -64885,7 +64867,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -64919,7 +64901,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。通过 API 返回该条目时填充此字段。
- `call_id: string`
@@ -64927,15 +64909,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -64943,13 +64925,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -64957,7 +64939,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -64971,11 +64953,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`, or `incomplete`.
+ shell 调用输出的状态。可选值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -65011,7 +64993,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -65019,15 +65001,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -65043,7 +65025,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的 diff 创建新文件。
- `"create_file"`
@@ -65057,7 +65039,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "delete_file"`
- 删除指定的文件。
+ 删除指定文件。
- `"delete_file"`
@@ -65075,13 +65057,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "update_file"`
- 使用提供的差异更新现有文件。
+ 使用提供的 diff 更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -65089,7 +65071,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -65119,19 +65101,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -65139,7 +65121,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -65173,7 +65155,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -65181,11 +65163,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -65193,14 +65175,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -65212,7 +65194,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -65250,7 +65232,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -65258,29 +65240,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -65288,29 +65270,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `id: string`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -65342,7 +65324,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -65376,7 +65358,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -65393,11 +65375,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -65405,8 +65387,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -65446,7 +65428,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `parallel_tool_calls: boolean`
@@ -65454,8 +65436,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `temperature: number or null`
- 使用的采样温度,介于 0 到 2 之间。较高的值(例如 0.8)会使输出更加随机,而较低的值(例如 0.2)会使输出更加聚焦和确定。
- 我们通常建议修改此参数或 `top_p` 但不要同时修改两者。
+ 使用的采样温度,介于 0 到 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加聚焦和确定性。
+ 我们通常建议调整此项或 `top_p` 但不要同时调整两者。
- `tool_choice: ToolChoiceOptions or ToolChoiceAllowed or ToolChoiceTypes or 6 more`
@@ -65465,9 +65447,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceOptions = "none" or "auto" or "required"`
- 控制模型调用哪个工具(如果有的话)。
+ 控制模型调用哪个工具(如果有)。
- `none` 表示模型不会调用任何工具,而是生成一条消息。
+ `none` 表示模型将不会调用任何工具,而是生成一条消息。
`auto` 表示模型可以在生成消息或调用一个或
多个工具之间进行选择。
@@ -65499,7 +65481,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of map[unknown]`
- 模型应允许调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -65520,11 +65502,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceTypes object { type }`
指示模型应使用内置工具来生成响应。
- [了解有关内置工具的更多信息](/docs/guides/tools).
+ [了解更多关于内置工具的信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
- 模型应使用的托管工具类型。了解更多关于
+ 模型应使用的 托管工具 类型。了解更多关于
[内置工具](/docs/guides/tools).
允许的值为:
@@ -65569,7 +65551,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceMcp object { server_label, type, name }`
- 使用此选项可以强制模型调用远程 MCP 服务器上的特定工具。
+ 使用此选项可强制模型调用远程 MCP 服务器上的特定工具。
- `server_label: string`
@@ -65587,7 +65569,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceCustom object { name, type }`
- 使用此选项可以强制模型调用特定的自定义工具。
+ 使用此选项可强制模型调用特定的自定义工具。
- `name: string`
@@ -65603,27 +65585,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "programmatic_tool_calling"`
- 要调用的工具。始终为 `programmatic_tool_calling`.
+ 要调用的工具。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ToolChoiceApplyPatch object { type }`
- 在执行工具调用时强制模型调用 apply_patch 工具。
+ 强制模型在执行工具调用时调用 apply_patch 工具。
- `type: "apply_patch"`
- 要调用的工具。始终为 `apply_patch`.
+ 要调用的工具。始终 `apply_patch`.
- `"apply_patch"`
- `ToolChoiceShell object { type }`
- 在需要工具调用时强制模型调用 shell 工具。
+ 在需要工具调用时,强制模型调用 shell 工具。
- `type: "shell"`
- 要调用的工具。始终为 `shell`.
+ 要调用的工具。始终 `shell`.
- `"shell"`
@@ -65634,18 +65616,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
我们支持以下类别的工具:
- - **内置工具**:由 OpenAI 提供的工具,用于扩展模型的
- 能力,例如 [网页搜索](/docs/guides/tools-web-search)
+ - **内置工具**:由 OpenAI 提供的工具,用于扩展
+ 模型的能力,例如 [网页搜索](/docs/guides/tools-web-search)
或 [文件搜索](/docs/guides/tools-file-search)。详细了解
[内置工具](/docs/guides/tools).
- - **MCP 工具**:通过自定义 MCP 服务器与第三方系统集成
- 或 Google Drive 和 SharePoint 等预定义连接器。详细了解
+ - **MCP 工具**: 通过自定义 MCP 服务器与第三方系统集成
+ 或使用 Google Drive 和 SharePoint 等预定义连接器。详细了解
[MCP 工具](/docs/guides/tools-connectors-mcp).
- - **函数调用(自定义工具)**:由你定义的函数,
+ - **函数调用(自定义工具)**: 由你定义的函数,
使模型能够使用强类型参数和输出调用你自己的代码。详细了解
。你也可以使用
- [function calling](/docs/guides/function-calling)。你还可以使用
- 自定义工具调用你自己的代码。
+ [function calling](/docs/guides/function-calling). 你也可以使用
+ 自定义工具来调用你自己的代码。
- `Function object { name, parameters, strict, 5 more }`
@@ -65679,45 +65661,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -65725,7 +65707,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -65737,7 +65719,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -65745,21 +65727,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -65785,18 +65767,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -65804,22 +65786,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -65829,23 +65811,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -65856,11 +65838,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -65878,21 +65860,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -65900,14 +65882,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -65939,32 +65921,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -65972,13 +65954,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -65986,9 +65968,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -66000,22 +65982,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -66024,7 +66006,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -66034,7 +66016,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -66090,7 +66072,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -66100,11 +66082,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -66114,7 +66096,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -66122,7 +66104,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -66131,13 +66113,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -66146,7 +66128,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -66173,7 +66155,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -66184,7 +66166,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -66201,13 +66183,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -66223,7 +66205,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -66233,7 +66215,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -66259,11 +66241,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -66289,19 +66271,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -66321,19 +66303,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -66341,11 +66323,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -66391,7 +66373,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -66403,11 +66385,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -66421,7 +66403,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -66431,7 +66413,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -66441,23 +66423,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -66475,12 +66457,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `top_p: number or null`
- 一种名为核采样的温度采样替代方案,
- 其中模型会考虑 top_p 概率质量排名前列的词元结果。
- 因此,0.1 表示仅考虑构成前 10% 概率质量的词元。
+ 一种温度采样的替代方法,称为核采样,
+ 模型会考虑概率质量排名前 top_p 的标记的结果。
+ 因此 0.1 表示仅考虑构成前 10% 概率质量的标记。
会被考虑。
- 我们通常建议修改此参数或 `temperature` 但不要同时修改两者。
+ 我们通常建议调整此项或 `temperature` 但不要同时调整两者。
- `background: optional boolean or null`
@@ -66489,44 +66471,44 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `completed_at: optional number or null`
- 此 Response 完成时的 Unix 时间戳(以秒为单位)。
- 仅当状态为 `completed`.
+ 此响应完成时的 Unix 时间戳(以秒为单位)。
+ 仅在状态为 `completed`.
- `conversation: optional object { id } or null`
- 此响应所属的对话。此响应的输入项和输出项已自动添加到此对话。
+ 此响应所属的对话。此次响应的输入项和输出项已自动添加到此对话中。
- `id: string`
- 与此响应关联的对话的唯一 ID。
+ 此响应关联的对话的唯一 ID。
- `max_output_tokens: optional number or null`
- 一次响应中可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
+ 响应可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
- `max_tool_calls: optional number or null`
- 响应中可以处理的内置工具调用总次数上限。该上限适用于所有内置工具调用,而非单个工具。模型任何进一步的工具调用尝试都将被忽略。
+ 一次响应中可处理的内置工具调用总次数上限。该上限适用于所有内置工具调用的总和,而非单个工具。模型后续任何再次调用工具的尝试都将被忽略。
- `moderation: optional object { input, output } or null`
- 响应输入和输出的审核结果,前提是请求了已审核的补全。
+ 响应输入与输出的内容审核结果,前提是请求了经过审核的补全。
- `input: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输入的审核结果。
+ 对响应输入的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -66534,7 +66516,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -66542,17 +66524,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -66564,25 +66546,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输出的审核结果。
+ 对响应输出的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -66590,7 +66572,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -66598,17 +66580,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -66620,21 +66602,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output_text: optional string or null`
- 仅限SDK的便捷属性,包含所有输出消息中聚合的文本输出
- 来自所有 `output_text` 数组中的 `output` 条目(如果有)。
+ SDK 独有的便捷属性,包含来自所有
+ 的聚合文本输出 `output_text` 数组中的 `output` 条目(如有)。
在 Python 和 JavaScript SDK 中受支持。
- `previous_response_id: optional string or null`
- 模型上一次响应的唯一 ID。使用它来
- 创建多轮对话。了解有关
- [对话状态](/docs/guides/conversation-state)。的更多信息。不能与 `conversation`.
+ 上一个模型响应的唯一 ID。使用它可以
+ 创建多轮对话。详细了解
+ [conversation state](/docs/guides/conversation-state)。不能与 `conversation`.
- `prompt: optional ResponsePrompt or null`
@@ -66647,19 +66629,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `variables: optional map[string or ResponseInputText or ResponseInputImage or ResponseInputFile] or null`
- 用于替换提示模板中变量的可选值映射,
- prompt。替换值可以是字符串,也可以是其他
- Response 输入类型,例如图像或文件。
+ 用于替换你
+ prompt。替换的值可以是字符串,也可以是其他
+ Response 输入类型,如图像或文件。
- `string`
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -66667,19 +66649,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `version: optional string or null`
- 提示模板的可选版本。
+ prompt 模板的可选版本。
- `prompt_cache_key: optional string or null`
- 由 OpenAI 用于缓存相似请求的响应,以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
+ 由OpenAI使用,为相似请求缓存响应以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
- `prompt_cache_options: optional object { mode, ttl }`
- 应用于该响应的提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。
+ 应用于该响应的 prompt 缓存选项。支持以下 `gpt-5.6` 及更高版本的模型。
- `mode: "implicit" or "explicit"`
- 是否启用了隐式提示缓存断点。
+ 是否启用了隐式 prompt 缓存断点。
- `"implicit"`
@@ -66687,24 +66669,24 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ttl: "30m"`
- 应用于每个缓存断点的最短生存时间。
+ 应用于每个缓存断点的最短生命周期。
- `"30m"`
- `prompt_cache_retention: optional "in_memory" or "24h" or null`
- 已弃用。请使用 `prompt_cache_options.ttl` 相反。
+ 已弃用。请使用 `prompt_cache_options.ttl` 改为。
- 提示词缓存的保留策略。设置为 `24h` 以启用扩展提示词缓存,使缓存前缀保持更长时间,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
- 此字段表示最长保留策略,而
+ 提示缓存的保留策略。设置为 `24h` 以启用扩展提示缓存,使缓存的前缀保持更长时间有效,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
+ 该字段表示最大保留策略,而
`prompt_cache_options.ttl` 表示最短缓存生命周期。这两个
- 字段彼此独立,不会相互影响。
- 对于 `gpt-5.5`, `gpt-5.5-pro`,及未来模型,仅 `24h` 受支持。
+ 字段是独立的,不会相互影响。
+ 对于 `gpt-5.5`, `gpt-5.5-pro`,以及未来的模型,仅 `24h` 。
对于同时支持两者的旧模型 `in_memory` 和 `24h`,默认值取决于你组织的数据保留策略:
- - 未启用 ZDR 的组织默认使用 `24h`.
- - 启用 ZDR 的组织默认使用 `in_memory` 当 `prompt_cache_retention` 未指定时。
+ - 未启用 ZDR 的组织默认为 `24h`.
+ - 启用 ZDR 的组织默认为 `in_memory` 当 `prompt_cache_retention` 未指定时。
- `"in_memory"`
@@ -66712,18 +66694,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `reasoning: optional Reasoning or null`
- 配置选项,适用于
+ 适用于
[推理模型](https://platform.openai.com/docs/guides/reasoning).
- `context: optional "auto" or "current_turn" or "all_turns" or null`
- 控制在后续轮次中呈现回模型的推理项。
- 如果省略或设置为 `auto`,则由模型确定上下文模式。
+ 控制在后续回合中哪些推理项会被回传给模型。
+ 如果省略或设置为 `auto`,则由模型决定上下文模式。
`gpt-5.6` 模型系列默认为 `all_turns`;早期模型默认为
`current_turn`.
- 在响应中返回时,这是该响应使用的有效推理上下文模式
- 。
+ 在响应中返回时,这是该响应所使用 的有效推理上下文模式
+ 用于该响应。
- `"auto"`
@@ -66733,13 +66715,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `effort: optional ReasoningEffort or null`
- 限制推理模型在推理上的投入程度。当前支持的值
- 包括 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
- 降低推理投入程度可以让响应更快,并减少响应中推理所用的 token 数。并非所有推理模型都支持每个
- 值。请参阅
- 推理指南
+ 限制推理模型在推理上的投入程度。目前支持
+ 的取值有 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
+ 降低推理投入程度可以让响应更快,并减少响应中用于推理的 token
+ 数量。并非所有推理模型都支持每个
+ 取值。有关各模型的支持情况,请参阅
[推理指南](https://platform.openai.com/docs/guides/reasoning)
- 以了解特定模型的支持情况。
+ 。
- `"none"`
@@ -66757,11 +66739,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `generate_summary: optional "auto" or "concise" or "detailed" or null`
- **已弃用:** 请使用 `summary` 相反。
+ **已弃用:** 请使用 `summary` 改为。
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `"auto"`
@@ -66773,7 +66755,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `string`
@@ -66781,7 +66763,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `"standard"`
@@ -66789,11 +66771,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `summary: optional "auto" or "concise" or "detailed" or null`
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `concise` 支持以下模型 `computer-use-preview` 以及之后的所有推理模型 `gpt-5`.
+ `concise` 支持用于 `computer-use-preview` 模型以及之后的 `gpt-5`.
- `"auto"`
@@ -66803,21 +66785,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `safety_identifier: optional string or null`
- 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用策略的应用程序用户。
- ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份识别信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用政策的应用用户。
+ ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `service_tier: optional ServiceTier or null`
指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
+ - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则该项目将使用 'default'。
- 如果设置为 'default',则该请求将使用所选模型的标准定价和性能进行处理。
- 如果设置为 '[flex](/docs/guides/flex-processing)',则该请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别选择启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 `service_tier=fast` 或 `service_tier=priority` 参数用于 Responses 或 Chat Completions。响应将显示 `service_tier=priority` ,无论你是否在请求中指定了 `service_tier=fast` 或 `priority` 。
- - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级返回的响应将显示 `service_tier=ultrafast`.
- - 如果未设置,默认行为是 'auto'。
+ - 若要在请求级别启用 [快速模式](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过它处理的响应将显示 `service_tier=ultrafast`.
+ - 未设置时,默认行为为 'auto'。
- 当设置 `service_tier` 参数时,响应正文将包含基于实际用于处理该请求的处理模式的 `service_tier` 值。此响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应体中将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。此响应中的值可能与该参数中设置的值不同。
- `"auto"`
@@ -66835,8 +66817,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional ResponseStatus`
- 响应生成的状态。取值之一为 `completed`, `failed`,
- `in_progress`, `cancelled`, `queued`, or `incomplete`.
+ 响应生成的状态。可选值为 `completed`, `failed`,
+ `in_progress`, `cancelled`, `queued`,或 `incomplete`.
- `"completed"`
@@ -66852,8 +66834,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: optional ResponseTextConfig`
- 用于配置模型文本响应的选项。可以是纯文本,也可以是结构化的 JSON 数据。详见:
- 文本输入与输出:
+ 模型文本响应的配置选项。可以是纯
+ 文本或结构化 JSON 数据。了解更多:
- [文本输入与输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
@@ -66862,79 +66844,79 @@ curl https://api.openai.com/v1/responses/resp_123 \
用于指定模型必须输出的格式的对象。
- 设置为 `{ "type": "json_schema" }` 时,将启用结构化输出,
- 功能,从而确保模型的输出与你提供的 JSON schema 相匹配。详见
+ 配置 `{ "type": "json_schema" }` 可启用结构化输出,
+ 从而确保模型匹配你提供的 JSON schema。更多信息请参阅
[结构化输出指南](/docs/guides/structured-outputs).
- 默认的格式为 `{ "type": "text" }` ,且不包含其他选项。
+ 默认格式为 `{ "type": "text" }` ,不包含任何额外选项。
- **不建议在 gpt-4o 及更新模型上使用:**
+ **不推荐用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
- 的模型,建议优先使用该格式。
+ 设置为 `{ "type": "json_object" }` 会启用旧版 JSON 模式,该模式
+ 可确保模型生成的消息是合法 JSON。对于支持 `json_schema`
+ 的模型,建议优先使用它。
- `ResponseFormatText object { type }`
- 默认的响应格式。用于生成文本响应。
+ 默认响应格式。用于生成文本响应。
- `type: "text"`
- 正在定义的响应格式的类型。始终为 `text`.
+ 正在定义的响应格式类型。始终为 `text`.
- `"text"`
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化的 JSON 响应。
+ JSON Schema 响应格式。用于生成结构化 JSON 响应。
详细了解 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
- 下划线和连字符,最大长度为 64。
+ 下划线和短横线,最大长度为 64。
- `schema: map[unknown]`
- 响应格式的 schema,以 JSON Schema 对象描述。
- 了解如何构建 JSON schema [此处](https://json-schema.org/).
+ 响应格式的架构,以 JSON Schema 对象形式描述。
+ 了解如何构建 JSON 架构 [此处](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式的类型。始终为 `json_schema`.
+ 正在定义的响应格式类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
响应格式用途的描述,供模型用于
- 确定如何按该格式进行响应。
+ 确定如何按该格式响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 一致性。
- 如果设置为 true,模型将始终遵循
- 字段中 `schema` 定义的精确 schema。仅支持 JSON Schema 的一个子集,当
- `strict` 是 `true`。要了解更多信息,请阅读 [Structured Outputs
+ 生成输出时是否启用严格的架构遵循。
+ 如果设置为 true,模型将始终遵循 字段中定义的
+ 确切架构。当 设置为 `schema` true 时,仅支持 JSON Schema 的一个子集
+ `strict` 是 `true`。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较早的生成 JSON 响应的方法。
- 使用 `json_schema` 对支持它的模型是推荐的做法。请注意
- 模型在没有系统或用户消息指示的情况下不会生成
- JSON。
+ JSON 对象响应格式。一种较旧的 JSON 响应生成方法。建议。
+ 对于支持 的模型,使用 `json_schema` 。请注意,模型不会在没有系统或用户消息指示
+ 的情况下生成 JSON
+ 。
- `type: "json_object"`
- 正在定义的响应格式的类型。始终为 `json_object`.
+ 正在定义的响应格式类型。始终为 `json_object`.
- `"json_object"`
- `verbosity: optional "low" or "medium" or "high" or null`
- 约束模型响应的详细程度。较低的值会产生
- 更简洁的响应,较高的值会产生更详细的响应。
+ 约束模型响应的详尽程度。较低的值将导致
+ 更简洁的响应,而较高的值将导致更冗长的响应。
当前支持的值包括 `low`, `medium`,和 `high`。默认值为
`medium`.
@@ -66946,20 +66928,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `top_logprobs: optional number or null`
- 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的最大最可能
- token 数量,每个 token 都附带对应的对数
+ 一个介于 0 到 20 之间的整数,指定在每个 token 位置返回的
+ 最可能 token 的最大数量,每个 token 都有一个关联的对数
概率。在某些情况下,返回的 token 数量可能少于
- 所请求的数量。
+ 请求的数量。
- `truncation: optional "auto" or "disabled" or null`
用于模型响应的截断策略。
- - `auto`:如果此 Response 的输入超过
- 模型的上下文窗口大小,模型将通过从对话开头丢弃条目来截断
- 响应以适配上下文窗口。
- - `disabled` (默认):如果输入大小将超出模型的上下文窗口
- 大小,请求将失败并返回 400 错误。
+ - `auto`:如果此 Response 的输入超出
+ 模型的上下文窗口大小,模型将通过从对话开头
+ 丢弃条目来截断响应以适配上下文窗口。
+ - `disabled` (默认):如果输入大小将超过模型的上下文窗口
+ 大小,请求将以 400 错误失败。
- `"auto"`
@@ -66968,7 +66950,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `usage: optional ResponseUsage`
表示 token 使用详情,包括输入 token、输出 token,
- 的输出 token 明细,以及所使用的 token 总数。
+ 输出 token 的细分,以及使用的总 token 数。
- `input_tokens: number`
@@ -66976,16 +66958,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_tokens_details: object { cache_write_tokens, cached_tokens }`
- 输入 token 的详细明细。
+ 输入 token 的详细细分。
- `cache_write_tokens: number`
- 已写入缓存的输入 token 数量。
+ 写入缓存的输入 token 的数量。
- `cached_tokens: number`
- 从缓存中检索到的 token 数量。
- [了解更多关于提示缓存的信息](/docs/guides/prompt-caching).
+ 从缓存中检索到的 token 的数量。
+ [有关 prompt caching 的更多信息](/docs/guides/prompt-caching).
- `output_tokens: number`
@@ -66993,25 +66975,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_tokens_details: object { reasoning_tokens }`
- 输出令牌的详细明细。
+ 输出 token 的详细明细。
- `reasoning_tokens: number`
- 推理令牌的数量。
+ 推理 token 的数量。
- `total_tokens: number`
- 使用的令牌总数。
-
- - `compute_units: optional number or null`
-
- 该请求的计算单元。在可用时当前为 null。
+ 使用的 token 总数。
- `user: optional string`
- 此字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
- 用于标识你的最终用户的稳定标识符。
- 通过更好地对相似请求进行分桶以提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 该字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
+ 你的最终用户的稳定标识符。
+ 通过更好地对相似请求进行分桶来提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `sequence_number: number`
@@ -67023,28 +67001,28 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.completed"`
-### Response 计算机工具调用输出截图
+### Response Computer Tool Call Output Screenshot
- `ResponseComputerToolCallOutputScreenshot object { type, file_id, image_url }`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
-### Response 容器引用
+### Response Container Reference
- `ResponseContainerReference object { container_id, type }`
@@ -67058,7 +67036,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"container_reference"`
-### Response 内容
+### Response Content
- `ResponseContent = ResponseInputText or ResponseInputImage or ResponseInputFile or 3 more`
@@ -67066,35 +67044,35 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -67106,25 +67084,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -67134,13 +67112,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -67150,41 +67128,41 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -67200,7 +67178,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -67210,25 +67188,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -67240,7 +67218,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -67248,11 +67226,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -67306,15 +67284,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -67324,7 +67302,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -67332,39 +67310,39 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"reasoning_text"`
-### Response Content Part Added 事件
+### Response 内容部分已添加事件
- `ResponseContentPartAddedEvent object { content_index, item_id, output_index, 3 more }`
- 在新增内容部分时触发。
+ 当新增一个内容分块时发出。
- `content_index: number`
- 被新增内容部分的索引。
+ 被添加的内容分块的索引。
- `item_id: string`
- 内容部分所添加到的输出项的 ID。
+ 内容分块所添加到的输出项的 ID。
- `output_index: number`
- 内容部分所添加到的输出项的索引。
+ 内容分块所添加到的输出项的索引。
- `part: ResponseOutputText or ResponseOutputRefusal or object { text, type }`
- 被新增的内容部分。
+ 被添加的内容分块。
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -67380,7 +67358,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -67390,25 +67368,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -67420,7 +67398,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -67428,11 +67406,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -67486,15 +67464,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -67504,7 +67482,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -67522,11 +67500,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.content_part.added"`
-### 响应内容片段完成事件
+### Response Content Part Done Event
- `ResponseContentPartDoneEvent object { content_index, item_id, output_index, 3 more }`
- 当某个内容部分完成时触发。
+ 在内容部分完成时发出。
- `content_index: number`
@@ -67534,11 +67512,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 内容部分所添加到的输出项的 ID。
+ 内容分块所添加到的输出项的 ID。
- `output_index: number`
- 内容部分所添加到的输出项的索引。
+ 内容分块所添加到的输出项的索引。
- `part: ResponseOutputText or ResponseOutputRefusal or object { text, type }`
@@ -67546,15 +67524,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -67570,7 +67548,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -67580,25 +67558,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -67610,7 +67588,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -67618,11 +67596,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -67676,15 +67654,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -67694,7 +67672,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -67712,25 +67690,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.content_part.done"`
-### Response 对话参数
+### Response Conversation Param
- `ResponseConversationParam object { id }`
- 此响应所属的对话。
+ 本次响应所属的对话。
- `id: string`
对话的唯一 ID。
-### Response 创建事件
+### Response Created 事件
- `ResponseCreatedEvent object { response, sequence_number, type }`
- 在创建响应时发出的事件。
+ 在创建 response 时发出的事件。
- `response: Response`
- 已创建的响应。
+ The response that was created.
- `id: string`
@@ -67738,7 +67716,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_at: number`
- 创建此 Response 时的 Unix 时间戳(以秒为单位)。
+ 此 Response 创建时的 Unix 时间戳(以秒为单位)。
- `error: ResponseError or null`
@@ -67794,87 +67772,89 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `incomplete_details: object { reason } or null`
- 有关响应未完成原因的详细信息。
+ 有关响应不完整的详细原因。
- - `reason: optional "max_output_tokens" or "content_filter"`
+ - `reason: optional "max_output_tokens" or "max_messages" or "content_filter"`
- 响应未完成的原因。
+ 响应不完整的原因。
- `"max_output_tokens"`
+ - `"max_messages"`
+
- `"content_filter"`
- `instructions: string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more or null`
插入到模型上下文中的系统(或开发者)消息。
- 当与 `previous_response_id`,配合使用时,前一次
- 响应的指令不会延续到下一次响应。这便于在新响应中
- 替换系统(或开发者)消息。
+ 当与 `previous_response_id`,配合使用时,上一个
+ response 中的 instructions 不会延续到下一个 response。这样可以轻松地
+ 在新的 response 中替换系统(或开发者)消息。
- `string`
- 发送给模型的文本输入,相当于使用
+ 发送给模型的文本输入,等同于
`developer` 角色的文本输入。
- `InputItemList = array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 发送给模型的一个或多个输入项的列表,包含
+ 发送给模型的一个或多个输入项列表,包含
不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` role. Messages with the
- `assistant` role are presumed to have been generated by the model in previous
- interactions.
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色给出的指令。带有
+ `assistant` 角色的消息被视为模型在之前的
+ 交互中生成。
- `content: string or ResponseInputMessageContentList`
- Text, image, or audio input to the model, used to generate a response.
- Can also contain previous assistant responses.
+ 发送给模型的文本、图像或音频输入,用于生成响应。
+ 也可以包含之前的助手响应。
- `TextInput = string`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputMessageContentList = array of ResponseInputContent`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -67886,25 +67866,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -67914,13 +67894,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -67930,33 +67910,33 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `assistant`, `system`, or
+ 消息输入的角色。其一为 接口 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -67969,9 +67949,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -67979,24 +67959,24 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: optional "message"`
- 消息输入的类型。始终为 `message`.
+ 消息输入的类型。始终为 接口 `message`.
- `"message"`
- `Message object { content, role, status, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` 角色的文本输入。
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色的文本输入。
- `content: ResponseInputMessageContentList`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `system`, or `developer`.
+ 消息输入的角色。其一为 接口 `user`, `system`,或 `developer`.
- `"user"`
@@ -68006,8 +67986,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -68027,7 +68007,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -68035,15 +68015,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -68059,7 +68039,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -68069,25 +68049,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -68099,7 +68079,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -68107,11 +68087,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -68165,15 +68145,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -68185,8 +68165,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -68202,9 +68182,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -68212,8 +68192,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -68225,7 +68205,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -68250,11 +68230,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -68272,7 +68252,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -68281,7 +68261,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -68293,7 +68273,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -68309,8 +68289,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -68334,7 +68314,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -68348,7 +68328,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -68374,7 +68354,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -68392,7 +68372,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -68411,7 +68391,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -68421,11 +68401,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -68445,15 +68425,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -68485,19 +68465,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -68521,8 +68501,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -68538,7 +68518,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -68554,7 +68534,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -68562,44 +68542,44 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCallOutput object { call_id, output, type, 3 more }`
- 一次 computer 工具调用的输出。
+ 计算机工具调用的输出。
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `id: optional string or null`
- computer 工具调用输出的 ID。
+ 计算机工具调用输出的 ID。
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 已被开发者确认的 API 所报告的安全检查结果。
+ 开发者已确认的 API 所报告的安全检查。
- `id: string`
@@ -68615,7 +68595,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值为 `in_progress`, `completed`, or `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -68626,7 +68606,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -68634,12 +68614,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -68649,11 +68629,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -68671,7 +68651,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -68685,7 +68665,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -68703,7 +68683,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -68715,14 +68695,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -68772,8 +68752,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -68787,7 +68767,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: string or array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的文本、图片或文件输出。
+ 函数工具调用的文本、图像或文件输出。
- `string`
@@ -68795,61 +68775,61 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的内容输出(文本、图片、文件)数组。
+ 函数工具调用的内容输出(文本、图像、文件)数组。
- `ResponseInputTextContent object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision)
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `detail: optional ImageDetail or null`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -68859,13 +68839,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -68879,23 +68859,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -68907,7 +68887,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string or null`
- 函数工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
+ 函数工具调用输出的唯一 ID。当此项通过 API 返回时填充。
- `call_id: optional string or null`
@@ -68947,7 +68927,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -68963,7 +68943,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目类型。始终为 `tool_search_call`.
+ 项的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
@@ -69031,37 +69011,37 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -69074,11 +69054,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -69098,7 +69078,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -69114,15 +69094,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -69136,7 +69116,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -69144,7 +69124,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -69156,7 +69136,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -69164,21 +69144,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -69204,18 +69184,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -69223,22 +69203,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -69248,23 +69228,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -69275,11 +69255,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -69297,21 +69277,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -69319,14 +69299,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -69358,32 +69338,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -69391,13 +69371,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -69405,9 +69385,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -69419,22 +69399,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -69443,7 +69423,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -69453,7 +69433,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -69483,29 +69463,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -69541,7 +69521,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -69551,11 +69531,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -69565,7 +69545,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -69573,7 +69553,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -69582,13 +69562,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -69597,7 +69577,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -69624,7 +69604,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -69635,7 +69615,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -69652,13 +69632,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -69674,7 +69654,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -69684,7 +69664,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -69708,7 +69688,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -69732,13 +69712,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -69762,7 +69742,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -69770,13 +69750,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -69796,7 +69776,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -69808,13 +69788,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -69828,11 +69808,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -69858,7 +69838,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -69876,7 +69856,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -69890,19 +69870,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -69922,19 +69902,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -69942,11 +69922,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -69992,7 +69972,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -70004,11 +69984,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -70022,7 +70002,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -70032,7 +70012,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -70042,23 +70022,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -70076,13 +70056,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目类型。始终为 `tool_search_output`.
+ 项的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `id: optional string or null`
- 此工具搜索输出的唯一 ID。
+ 该工具搜索输出的唯一 ID。
- `call_id: optional string or null`
@@ -70110,13 +70090,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `role: "developer"`
- 提供其他工具的角色。仅 `developer` 受支持。
+ 提供这些额外工具的角色。仅支持 `developer` 。
- `"developer"`
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 此项目提供的其他工具列表。
+ 在该条目中提供的额外工具列表。
- `Function object { name, parameters, strict, 5 more }`
@@ -70150,45 +70130,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -70196,7 +70176,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -70208,7 +70188,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -70216,21 +70196,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -70256,18 +70236,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -70275,22 +70255,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -70300,23 +70280,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -70327,11 +70307,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -70349,21 +70329,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -70371,14 +70351,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -70410,32 +70390,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -70443,13 +70423,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -70457,9 +70437,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -70471,22 +70451,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -70495,7 +70475,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -70505,7 +70485,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -70561,7 +70541,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -70571,11 +70551,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -70585,7 +70565,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -70593,7 +70573,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -70602,13 +70582,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -70617,7 +70597,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -70644,7 +70624,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -70655,7 +70635,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -70672,13 +70652,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -70694,7 +70674,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -70704,7 +70684,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -70730,11 +70710,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -70760,19 +70740,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -70792,19 +70772,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -70812,11 +70792,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -70862,7 +70842,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -70874,11 +70854,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -70892,7 +70872,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -70902,7 +70882,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -70912,23 +70892,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -70946,19 +70926,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目类型。始终为 `additional_tools`.
+ 项的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `id: optional string or null`
- 此其他工具项目的唯一 ID。
+ 该额外工具条目的唯一 ID。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -70971,7 +70951,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -70991,7 +70971,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -71001,20 +70981,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -71024,7 +71004,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Compaction object { encrypted_content, type, id }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -71032,17 +71012,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `id: optional string or null`
- 压缩条目的 ID。
+ 压缩项的 ID。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -71066,7 +71046,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -71089,7 +71069,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -71101,23 +71081,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -71135,13 +71115,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -71157,11 +71137,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -71175,11 +71155,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -71193,7 +71173,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -71203,7 +71183,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -71211,13 +71191,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -71231,7 +71211,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
@@ -71243,7 +71223,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最大挂钟时间(毫秒)。
+ 允许 shell 命令运行的 wall-clock 最长时间(毫秒)。
- `call_id: string`
@@ -71251,13 +71231,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
- `id: optional string or null`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -71293,7 +71273,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -71303,7 +71283,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ShellCallOutput object { call_id, output, type, 4 more }`
- shell 工具调用发出的流式输出项。
+ shell 工具调用发出的流式输出条目。
- `call_id: string`
@@ -71311,7 +71291,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: array of ResponseFunctionShellCallOutputContent`
- stdout 和 stderr 输出的捕获块及其关联结果。
+ 捕获的 stdout 和 stderr 输出块,以及它们关联的结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -71323,13 +71303,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -71337,27 +71317,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
- `stderr: string`
- shell 调用捕获的 stderr 输出。
+ 为该 shell 调用捕获的 stderr 输出。
- `stdout: string`
- shell 调用捕获的 stdout 输出。
+ 为该 shell 调用捕获的 stdout 输出。
- `type: "shell_call_output"`
- 条目的类型,恒为 `shell_call_output`.
+ item 的类型。始终为 `shell_call_output`.
- `"shell_call_output"`
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -71399,11 +71379,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 表示使用 diff 补丁创建、删除或更新文件的工具调用。
+ 表示通过 diff 补丁创建、删除或更新文件的工具调用。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
@@ -71415,7 +71395,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 创建文件时要应用的统一 diff 内容。
+ 创建文件时应用的 unified diff 内容。
- `path: string`
@@ -71447,7 +71427,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 要应用于现有文件的统一 diff 内容。
+ 应用于现有文件的 unified diff 内容。
- `path: string`
@@ -71461,7 +71441,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -71469,13 +71449,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
- `id: optional string or null`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -71503,15 +71483,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { call_id, status, type, 3 more }`
- apply patch 工具调用发出的流式输出。
+ 由 apply patch 工具调用发出的流式输出。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -71519,13 +71499,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
- `id: optional string or null`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -71581,7 +71561,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -71589,29 +71569,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -71619,31 +71599,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { approval_request_id, approve, type, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
- `id: optional string or null`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `reason: optional string or null`
@@ -71651,7 +71631,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -71659,11 +71639,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -71671,14 +71651,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -71718,7 +71698,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -71732,11 +71712,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 由你的代码生成的自定义工具调用输出,将被发送回模型。
+ 由你的代码生成的自定义工具调用的输出,将发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -71753,11 +71733,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -71771,7 +71751,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- 自定义工具调用输出在 OpenAI 平台中的唯一 ID。
+ 在 OpenAI 平台中该自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -71821,7 +71801,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -71849,11 +71829,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompactionTrigger object { type, id }`
- 压缩当前上下文。必须是最后一个输入项。
+ 压缩当前上下文。必须作为最后一个输入项。
- `type: "compaction_trigger"`
- 条目的类型,恒为 `compaction_trigger`.
+ item 的类型。始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -71867,11 +71847,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 要引用的条目 ID。
+ 被引用条目的 ID。
- `type: optional "item_reference" or null`
- 要引用的条目类型。始终为 `item_reference`.
+ 被引用条目的类型。始终为 `item_reference`.
- `"item_reference"`
@@ -71887,7 +71867,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -71895,7 +71875,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目类型。始终为 `program`.
+ 项的类型。始终为 `program`.
- `"program"`
@@ -71911,7 +71891,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -71923,14 +71903,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目类型。始终为 `program_output`.
+ 项的类型。始终为 `program_output`.
- `"program_output"`
- `metadata: Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
格式,以及通过 API 或控制台查询对象。
键为字符串,最长 64 个字符。值为字符串
@@ -71939,8 +71919,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: ResponsesModel`
用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI
- 提供了多种不同能力、性能
- 特性和定价的模型。请参阅 [模型指南](/docs/models)
+ 提供了众多功能、性能
+ 特性和价位各异的模型。请参阅 [模型指南](/docs/models)
以浏览和比较可用的模型。
- `string`
@@ -72163,12 +72143,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
由模型生成的内容项数组。
- - 该数组中项的数量和顺序 `output` 取决于
- 模型的响应。
- - 与直接访问该数组的 `output` 第一项并
- 假设它是一 `assistant` 个包含模型生成内容的
- 消息相比,你也可以考虑使用 `output_text` 属性(在
- 受支持的 SDK 中可用)。
+ - 该数组中项的长度和顺序取决于 `output` 模型的响应。
+ 与其访问。
+ - 数组中的第一项并 `output` 假设它是一个
+ 包含模型生成内容的 `assistant` 消息,不如使用
+ 属性(在受支持的 开发工具包 `output_text` 中可用)。
+ SDK。
- `ResponseOutputMessage object { id, content, role, 3 more }`
@@ -72176,8 +72156,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -72189,7 +72169,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -72214,11 +72194,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -72236,7 +72216,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -72245,7 +72225,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -72295,8 +72275,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -72321,15 +72301,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -72337,8 +72317,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -72382,7 +72362,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `name: optional string`
@@ -72395,7 +72375,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -72403,12 +72383,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -72418,11 +72398,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -72440,7 +72420,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -72454,7 +72434,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -72472,7 +72452,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -72484,14 +72464,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -72503,7 +72483,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -72519,8 +72499,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -72540,8 +72520,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `ComputerCallOutput object { id, call_id, output, 4 more }`
@@ -72551,16 +72531,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"completed"`
@@ -72572,13 +72552,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、已被
+ API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -72595,13 +72575,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -72614,7 +72594,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -72632,7 +72612,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -72642,20 +72622,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -72675,7 +72655,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -72683,7 +72663,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目的类型,恒为 `program`.
+ item 的类型。始终为 `program`.
- `"program"`
@@ -72699,7 +72679,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -72711,7 +72691,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目的类型,恒为 `program_output`.
+ item 的类型。始终为 `program_output`.
- `"program_output"`
@@ -72749,13 +72729,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目的类型,恒为 `tool_search_call`.
+ item 的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -72821,45 +72801,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -72867,7 +72847,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -72879,7 +72859,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -72887,21 +72867,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -72927,18 +72907,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -72946,22 +72926,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -72971,23 +72951,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -72998,11 +72978,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -73020,21 +73000,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -73042,14 +73022,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -73081,32 +73061,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -73114,13 +73094,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -73128,9 +73108,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -73142,22 +73122,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -73166,7 +73146,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -73176,7 +73156,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -73232,7 +73212,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -73242,11 +73222,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -73256,7 +73236,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -73264,7 +73244,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -73273,13 +73253,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -73288,7 +73268,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -73315,7 +73295,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -73326,7 +73306,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -73343,13 +73323,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -73365,7 +73345,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -73375,7 +73355,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -73401,11 +73381,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -73431,19 +73411,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -73463,19 +73443,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -73483,11 +73463,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -73533,7 +73513,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -73545,11 +73525,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -73563,7 +73543,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -73573,7 +73553,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -73583,23 +73563,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -73617,13 +73597,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目的类型,恒为 `tool_search_output`.
+ item 的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -73653,7 +73633,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -73687,45 +73667,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -73733,7 +73713,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -73745,7 +73725,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -73753,21 +73733,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -73793,18 +73773,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -73812,22 +73792,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -73837,23 +73817,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -73864,11 +73844,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -73886,21 +73866,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -73908,14 +73888,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -73947,32 +73927,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -73980,13 +73960,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -73994,9 +73974,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -74008,22 +73988,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -74032,7 +74012,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -74042,7 +74022,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -74098,7 +74078,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -74108,11 +74088,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -74122,7 +74102,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -74130,7 +74110,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -74139,13 +74119,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -74154,7 +74134,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -74181,7 +74161,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -74192,7 +74172,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -74209,13 +74189,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -74231,7 +74211,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -74241,7 +74221,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -74267,11 +74247,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -74297,19 +74277,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -74329,19 +74309,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -74349,11 +74329,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -74399,7 +74379,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -74411,11 +74391,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -74429,7 +74409,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -74439,7 +74419,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -74449,23 +74429,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -74483,13 +74463,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目的类型,恒为 `additional_tools`.
+ item 的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -74497,21 +74477,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的已加密内容。
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -74535,7 +74515,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -74558,7 +74538,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -74570,23 +74550,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -74604,13 +74584,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -74626,11 +74606,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -74644,11 +74624,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -74662,7 +74642,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -74672,7 +74652,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -74680,13 +74660,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -74700,17 +74680,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -74748,7 +74728,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -74758,7 +74738,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -74792,7 +74772,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。通过 API 返回该条目时填充此字段。
- `call_id: string`
@@ -74800,15 +74780,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -74816,13 +74796,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -74830,7 +74810,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -74844,11 +74824,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`, or `incomplete`.
+ shell 调用输出的状态。可选值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -74884,7 +74864,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -74892,15 +74872,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -74916,7 +74896,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的 diff 创建新文件。
- `"create_file"`
@@ -74930,7 +74910,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "delete_file"`
- 删除指定的文件。
+ 删除指定文件。
- `"delete_file"`
@@ -74948,13 +74928,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "update_file"`
- 使用提供的差异更新现有文件。
+ 使用提供的 diff 更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -74962,7 +74942,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -74992,19 +74972,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -75012,7 +74992,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -75046,7 +75026,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -75054,11 +75034,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -75066,14 +75046,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -75085,7 +75065,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -75123,7 +75103,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -75131,29 +75111,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -75161,29 +75141,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `id: string`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -75215,7 +75195,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -75249,7 +75229,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -75266,11 +75246,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -75278,8 +75258,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -75319,7 +75299,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `parallel_tool_calls: boolean`
@@ -75327,8 +75307,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `temperature: number or null`
- 使用的采样温度,介于 0 到 2 之间。较高的值(例如 0.8)会使输出更加随机,而较低的值(例如 0.2)会使输出更加聚焦和确定。
- 我们通常建议修改此参数或 `top_p` 但不要同时修改两者。
+ 使用的采样温度,介于 0 到 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加聚焦和确定性。
+ 我们通常建议调整此项或 `top_p` 但不要同时调整两者。
- `tool_choice: ToolChoiceOptions or ToolChoiceAllowed or ToolChoiceTypes or 6 more`
@@ -75338,9 +75318,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceOptions = "none" or "auto" or "required"`
- 控制模型调用哪个工具(如果有的话)。
+ 控制模型调用哪个工具(如果有)。
- `none` 表示模型不会调用任何工具,而是生成一条消息。
+ `none` 表示模型将不会调用任何工具,而是生成一条消息。
`auto` 表示模型可以在生成消息或调用一个或
多个工具之间进行选择。
@@ -75372,7 +75352,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of map[unknown]`
- 模型应允许调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -75393,11 +75373,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceTypes object { type }`
指示模型应使用内置工具来生成响应。
- [了解有关内置工具的更多信息](/docs/guides/tools).
+ [了解更多关于内置工具的信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
- 模型应使用的托管工具类型。了解更多关于
+ 模型应使用的 托管工具 类型。了解更多关于
[内置工具](/docs/guides/tools).
允许的值为:
@@ -75442,7 +75422,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceMcp object { server_label, type, name }`
- 使用此选项可以强制模型调用远程 MCP 服务器上的特定工具。
+ 使用此选项可强制模型调用远程 MCP 服务器上的特定工具。
- `server_label: string`
@@ -75460,7 +75440,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceCustom object { name, type }`
- 使用此选项可以强制模型调用特定的自定义工具。
+ 使用此选项可强制模型调用特定的自定义工具。
- `name: string`
@@ -75476,27 +75456,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "programmatic_tool_calling"`
- 要调用的工具。始终为 `programmatic_tool_calling`.
+ 要调用的工具。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ToolChoiceApplyPatch object { type }`
- 在执行工具调用时强制模型调用 apply_patch 工具。
+ 强制模型在执行工具调用时调用 apply_patch 工具。
- `type: "apply_patch"`
- 要调用的工具。始终为 `apply_patch`.
+ 要调用的工具。始终 `apply_patch`.
- `"apply_patch"`
- `ToolChoiceShell object { type }`
- 在需要工具调用时强制模型调用 shell 工具。
+ 在需要工具调用时,强制模型调用 shell 工具。
- `type: "shell"`
- 要调用的工具。始终为 `shell`.
+ 要调用的工具。始终 `shell`.
- `"shell"`
@@ -75507,18 +75487,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
我们支持以下类别的工具:
- - **内置工具**:由 OpenAI 提供的工具,用于扩展模型的
- 能力,例如 [网页搜索](/docs/guides/tools-web-search)
+ - **内置工具**:由 OpenAI 提供的工具,用于扩展
+ 模型的能力,例如 [网页搜索](/docs/guides/tools-web-search)
或 [文件搜索](/docs/guides/tools-file-search)。详细了解
[内置工具](/docs/guides/tools).
- - **MCP 工具**:通过自定义 MCP 服务器与第三方系统集成
- 或 Google Drive 和 SharePoint 等预定义连接器。详细了解
+ - **MCP 工具**: 通过自定义 MCP 服务器与第三方系统集成
+ 或使用 Google Drive 和 SharePoint 等预定义连接器。详细了解
[MCP 工具](/docs/guides/tools-connectors-mcp).
- - **函数调用(自定义工具)**:由你定义的函数,
+ - **函数调用(自定义工具)**: 由你定义的函数,
使模型能够使用强类型参数和输出调用你自己的代码。详细了解
。你也可以使用
- [function calling](/docs/guides/function-calling)。你还可以使用
- 自定义工具调用你自己的代码。
+ [function calling](/docs/guides/function-calling). 你也可以使用
+ 自定义工具来调用你自己的代码。
- `Function object { name, parameters, strict, 5 more }`
@@ -75552,45 +75532,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -75598,7 +75578,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -75610,7 +75590,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -75618,21 +75598,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -75658,18 +75638,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -75677,22 +75657,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -75702,23 +75682,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -75729,11 +75709,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -75751,21 +75731,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -75773,14 +75753,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -75812,32 +75792,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -75845,13 +75825,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -75859,9 +75839,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -75873,22 +75853,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -75897,7 +75877,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -75907,7 +75887,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -75963,7 +75943,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -75973,11 +75953,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -75987,7 +75967,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -75995,7 +75975,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -76004,13 +75984,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -76019,7 +75999,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -76046,7 +76026,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -76057,7 +76037,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -76074,13 +76054,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -76096,7 +76076,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -76106,7 +76086,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -76132,11 +76112,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -76162,19 +76142,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -76194,19 +76174,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -76214,11 +76194,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -76264,7 +76244,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -76276,11 +76256,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -76294,7 +76274,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -76304,7 +76284,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -76314,23 +76294,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -76348,12 +76328,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `top_p: number or null`
- 一种名为核采样的温度采样替代方案,
- 其中模型会考虑 top_p 概率质量排名前列的词元结果。
- 因此,0.1 表示仅考虑构成前 10% 概率质量的词元。
+ 一种温度采样的替代方法,称为核采样,
+ 模型会考虑概率质量排名前 top_p 的标记的结果。
+ 因此 0.1 表示仅考虑构成前 10% 概率质量的标记。
会被考虑。
- 我们通常建议修改此参数或 `temperature` 但不要同时修改两者。
+ 我们通常建议调整此项或 `temperature` 但不要同时调整两者。
- `background: optional boolean or null`
@@ -76362,44 +76342,44 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `completed_at: optional number or null`
- 此 Response 完成时的 Unix 时间戳(以秒为单位)。
- 仅当状态为 `completed`.
+ 此响应完成时的 Unix 时间戳(以秒为单位)。
+ 仅在状态为 `completed`.
- `conversation: optional object { id } or null`
- 此响应所属的对话。此响应的输入项和输出项已自动添加到此对话。
+ 此响应所属的对话。此次响应的输入项和输出项已自动添加到此对话中。
- `id: string`
- 与此响应关联的对话的唯一 ID。
+ 此响应关联的对话的唯一 ID。
- `max_output_tokens: optional number or null`
- 一次响应中可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
+ 响应可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
- `max_tool_calls: optional number or null`
- 响应中可以处理的内置工具调用总次数上限。该上限适用于所有内置工具调用,而非单个工具。模型任何进一步的工具调用尝试都将被忽略。
+ 一次响应中可处理的内置工具调用总次数上限。该上限适用于所有内置工具调用的总和,而非单个工具。模型后续任何再次调用工具的尝试都将被忽略。
- `moderation: optional object { input, output } or null`
- 响应输入和输出的审核结果,前提是请求了已审核的补全。
+ 响应输入与输出的内容审核结果,前提是请求了经过审核的补全。
- `input: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输入的审核结果。
+ 对响应输入的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -76407,7 +76387,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -76415,17 +76395,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -76437,25 +76417,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输出的审核结果。
+ 对响应输出的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -76463,7 +76443,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -76471,17 +76451,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -76493,21 +76473,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output_text: optional string or null`
- 仅限SDK的便捷属性,包含所有输出消息中聚合的文本输出
- 来自所有 `output_text` 数组中的 `output` 条目(如果有)。
+ SDK 独有的便捷属性,包含来自所有
+ 的聚合文本输出 `output_text` 数组中的 `output` 条目(如有)。
在 Python 和 JavaScript SDK 中受支持。
- `previous_response_id: optional string or null`
- 模型上一次响应的唯一 ID。使用它来
- 创建多轮对话。了解有关
- [对话状态](/docs/guides/conversation-state)。的更多信息。不能与 `conversation`.
+ 上一个模型响应的唯一 ID。使用它可以
+ 创建多轮对话。详细了解
+ [conversation state](/docs/guides/conversation-state)。不能与 `conversation`.
- `prompt: optional ResponsePrompt or null`
@@ -76520,19 +76500,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `variables: optional map[string or ResponseInputText or ResponseInputImage or ResponseInputFile] or null`
- 用于替换提示模板中变量的可选值映射,
- prompt。替换值可以是字符串,也可以是其他
- Response 输入类型,例如图像或文件。
+ 用于替换你
+ prompt。替换的值可以是字符串,也可以是其他
+ Response 输入类型,如图像或文件。
- `string`
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -76540,19 +76520,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `version: optional string or null`
- 提示模板的可选版本。
+ prompt 模板的可选版本。
- `prompt_cache_key: optional string or null`
- 由 OpenAI 用于缓存相似请求的响应,以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
+ 由OpenAI使用,为相似请求缓存响应以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
- `prompt_cache_options: optional object { mode, ttl }`
- 应用于该响应的提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。
+ 应用于该响应的 prompt 缓存选项。支持以下 `gpt-5.6` 及更高版本的模型。
- `mode: "implicit" or "explicit"`
- 是否启用了隐式提示缓存断点。
+ 是否启用了隐式 prompt 缓存断点。
- `"implicit"`
@@ -76560,24 +76540,24 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ttl: "30m"`
- 应用于每个缓存断点的最短生存时间。
+ 应用于每个缓存断点的最短生命周期。
- `"30m"`
- `prompt_cache_retention: optional "in_memory" or "24h" or null`
- 已弃用。请使用 `prompt_cache_options.ttl` 相反。
+ 已弃用。请使用 `prompt_cache_options.ttl` 改为。
- 提示词缓存的保留策略。设置为 `24h` 以启用扩展提示词缓存,使缓存前缀保持更长时间,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
- 此字段表示最长保留策略,而
+ 提示缓存的保留策略。设置为 `24h` 以启用扩展提示缓存,使缓存的前缀保持更长时间有效,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
+ 该字段表示最大保留策略,而
`prompt_cache_options.ttl` 表示最短缓存生命周期。这两个
- 字段彼此独立,不会相互影响。
- 对于 `gpt-5.5`, `gpt-5.5-pro`,及未来模型,仅 `24h` 受支持。
+ 字段是独立的,不会相互影响。
+ 对于 `gpt-5.5`, `gpt-5.5-pro`,以及未来的模型,仅 `24h` 。
对于同时支持两者的旧模型 `in_memory` 和 `24h`,默认值取决于你组织的数据保留策略:
- - 未启用 ZDR 的组织默认使用 `24h`.
- - 启用 ZDR 的组织默认使用 `in_memory` 当 `prompt_cache_retention` 未指定时。
+ - 未启用 ZDR 的组织默认为 `24h`.
+ - 启用 ZDR 的组织默认为 `in_memory` 当 `prompt_cache_retention` 未指定时。
- `"in_memory"`
@@ -76585,18 +76565,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `reasoning: optional Reasoning or null`
- 配置选项,适用于
+ 适用于
[推理模型](https://platform.openai.com/docs/guides/reasoning).
- `context: optional "auto" or "current_turn" or "all_turns" or null`
- 控制在后续轮次中呈现回模型的推理项。
- 如果省略或设置为 `auto`,则由模型确定上下文模式。
+ 控制在后续回合中哪些推理项会被回传给模型。
+ 如果省略或设置为 `auto`,则由模型决定上下文模式。
`gpt-5.6` 模型系列默认为 `all_turns`;早期模型默认为
`current_turn`.
- 在响应中返回时,这是该响应使用的有效推理上下文模式
- 。
+ 在响应中返回时,这是该响应所使用 的有效推理上下文模式
+ 用于该响应。
- `"auto"`
@@ -76606,13 +76586,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `effort: optional ReasoningEffort or null`
- 限制推理模型在推理上的投入程度。当前支持的值
- 包括 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
- 降低推理投入程度可以让响应更快,并减少响应中推理所用的 token 数。并非所有推理模型都支持每个
- 值。请参阅
- 推理指南
+ 限制推理模型在推理上的投入程度。目前支持
+ 的取值有 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
+ 降低推理投入程度可以让响应更快,并减少响应中用于推理的 token
+ 数量。并非所有推理模型都支持每个
+ 取值。有关各模型的支持情况,请参阅
[推理指南](https://platform.openai.com/docs/guides/reasoning)
- 以了解特定模型的支持情况。
+ 。
- `"none"`
@@ -76630,11 +76610,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `generate_summary: optional "auto" or "concise" or "detailed" or null`
- **已弃用:** 请使用 `summary` 相反。
+ **已弃用:** 请使用 `summary` 改为。
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `"auto"`
@@ -76646,7 +76626,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `string`
@@ -76654,7 +76634,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `"standard"`
@@ -76662,11 +76642,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `summary: optional "auto" or "concise" or "detailed" or null`
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `concise` 支持以下模型 `computer-use-preview` 以及之后的所有推理模型 `gpt-5`.
+ `concise` 支持用于 `computer-use-preview` 模型以及之后的 `gpt-5`.
- `"auto"`
@@ -76676,21 +76656,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `safety_identifier: optional string or null`
- 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用策略的应用程序用户。
- ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份识别信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用政策的应用用户。
+ ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `service_tier: optional ServiceTier or null`
指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
+ - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则该项目将使用 'default'。
- 如果设置为 'default',则该请求将使用所选模型的标准定价和性能进行处理。
- 如果设置为 '[flex](/docs/guides/flex-processing)',则该请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别选择启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 `service_tier=fast` 或 `service_tier=priority` 参数用于 Responses 或 Chat Completions。响应将显示 `service_tier=priority` ,无论你是否在请求中指定了 `service_tier=fast` 或 `priority` 。
- - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级返回的响应将显示 `service_tier=ultrafast`.
- - 如果未设置,默认行为是 'auto'。
+ - 若要在请求级别启用 [快速模式](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过它处理的响应将显示 `service_tier=ultrafast`.
+ - 未设置时,默认行为为 'auto'。
- 当设置 `service_tier` 参数时,响应正文将包含基于实际用于处理该请求的处理模式的 `service_tier` 值。此响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应体中将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。此响应中的值可能与该参数中设置的值不同。
- `"auto"`
@@ -76708,8 +76688,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional ResponseStatus`
- 响应生成的状态。取值之一为 `completed`, `failed`,
- `in_progress`, `cancelled`, `queued`, or `incomplete`.
+ 响应生成的状态。可选值为 `completed`, `failed`,
+ `in_progress`, `cancelled`, `queued`,或 `incomplete`.
- `"completed"`
@@ -76725,8 +76705,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: optional ResponseTextConfig`
- 用于配置模型文本响应的选项。可以是纯文本,也可以是结构化的 JSON 数据。详见:
- 文本输入与输出:
+ 模型文本响应的配置选项。可以是纯
+ 文本或结构化 JSON 数据。了解更多:
- [文本输入与输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
@@ -76735,79 +76715,79 @@ curl https://api.openai.com/v1/responses/resp_123 \
用于指定模型必须输出的格式的对象。
- 设置为 `{ "type": "json_schema" }` 时,将启用结构化输出,
- 功能,从而确保模型的输出与你提供的 JSON schema 相匹配。详见
+ 配置 `{ "type": "json_schema" }` 可启用结构化输出,
+ 从而确保模型匹配你提供的 JSON schema。更多信息请参阅
[结构化输出指南](/docs/guides/structured-outputs).
- 默认的格式为 `{ "type": "text" }` ,且不包含其他选项。
+ 默认格式为 `{ "type": "text" }` ,不包含任何额外选项。
- **不建议在 gpt-4o 及更新模型上使用:**
+ **不推荐用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
- 的模型,建议优先使用该格式。
+ 设置为 `{ "type": "json_object" }` 会启用旧版 JSON 模式,该模式
+ 可确保模型生成的消息是合法 JSON。对于支持 `json_schema`
+ 的模型,建议优先使用它。
- `ResponseFormatText object { type }`
- 默认的响应格式。用于生成文本响应。
+ 默认响应格式。用于生成文本响应。
- `type: "text"`
- 正在定义的响应格式的类型。始终为 `text`.
+ 正在定义的响应格式类型。始终为 `text`.
- `"text"`
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化的 JSON 响应。
+ JSON Schema 响应格式。用于生成结构化 JSON 响应。
详细了解 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
- 下划线和连字符,最大长度为 64。
+ 下划线和短横线,最大长度为 64。
- `schema: map[unknown]`
- 响应格式的 schema,以 JSON Schema 对象描述。
- 了解如何构建 JSON schema [此处](https://json-schema.org/).
+ 响应格式的架构,以 JSON Schema 对象形式描述。
+ 了解如何构建 JSON 架构 [此处](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式的类型。始终为 `json_schema`.
+ 正在定义的响应格式类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
响应格式用途的描述,供模型用于
- 确定如何按该格式进行响应。
+ 确定如何按该格式响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 一致性。
- 如果设置为 true,模型将始终遵循
- 字段中 `schema` 定义的精确 schema。仅支持 JSON Schema 的一个子集,当
- `strict` 是 `true`。要了解更多信息,请阅读 [Structured Outputs
+ 生成输出时是否启用严格的架构遵循。
+ 如果设置为 true,模型将始终遵循 字段中定义的
+ 确切架构。当 设置为 `schema` true 时,仅支持 JSON Schema 的一个子集
+ `strict` 是 `true`。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较早的生成 JSON 响应的方法。
- 使用 `json_schema` 对支持它的模型是推荐的做法。请注意
- 模型在没有系统或用户消息指示的情况下不会生成
- JSON。
+ JSON 对象响应格式。一种较旧的 JSON 响应生成方法。建议。
+ 对于支持 的模型,使用 `json_schema` 。请注意,模型不会在没有系统或用户消息指示
+ 的情况下生成 JSON
+ 。
- `type: "json_object"`
- 正在定义的响应格式的类型。始终为 `json_object`.
+ 正在定义的响应格式类型。始终为 `json_object`.
- `"json_object"`
- `verbosity: optional "low" or "medium" or "high" or null`
- 约束模型响应的详细程度。较低的值会产生
- 更简洁的响应,较高的值会产生更详细的响应。
+ 约束模型响应的详尽程度。较低的值将导致
+ 更简洁的响应,而较高的值将导致更冗长的响应。
当前支持的值包括 `low`, `medium`,和 `high`。默认值为
`medium`.
@@ -76819,20 +76799,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `top_logprobs: optional number or null`
- 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的最大最可能
- token 数量,每个 token 都附带对应的对数
+ 一个介于 0 到 20 之间的整数,指定在每个 token 位置返回的
+ 最可能 token 的最大数量,每个 token 都有一个关联的对数
概率。在某些情况下,返回的 token 数量可能少于
- 所请求的数量。
+ 请求的数量。
- `truncation: optional "auto" or "disabled" or null`
用于模型响应的截断策略。
- - `auto`:如果此 Response 的输入超过
- 模型的上下文窗口大小,模型将通过从对话开头丢弃条目来截断
- 响应以适配上下文窗口。
- - `disabled` (默认):如果输入大小将超出模型的上下文窗口
- 大小,请求将失败并返回 400 错误。
+ - `auto`:如果此 Response 的输入超出
+ 模型的上下文窗口大小,模型将通过从对话开头
+ 丢弃条目来截断响应以适配上下文窗口。
+ - `disabled` (默认):如果输入大小将超过模型的上下文窗口
+ 大小,请求将以 400 错误失败。
- `"auto"`
@@ -76841,7 +76821,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `usage: optional ResponseUsage`
表示 token 使用详情,包括输入 token、输出 token,
- 的输出 token 明细,以及所使用的 token 总数。
+ 输出 token 的细分,以及使用的总 token 数。
- `input_tokens: number`
@@ -76849,16 +76829,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_tokens_details: object { cache_write_tokens, cached_tokens }`
- 输入 token 的详细明细。
+ 输入 token 的详细细分。
- `cache_write_tokens: number`
- 已写入缓存的输入 token 数量。
+ 写入缓存的输入 token 的数量。
- `cached_tokens: number`
- 从缓存中检索到的 token 数量。
- [了解更多关于提示缓存的信息](/docs/guides/prompt-caching).
+ 从缓存中检索到的 token 的数量。
+ [有关 prompt caching 的更多信息](/docs/guides/prompt-caching).
- `output_tokens: number`
@@ -76866,25 +76846,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_tokens_details: object { reasoning_tokens }`
- 输出令牌的详细明细。
+ 输出 token 的详细明细。
- `reasoning_tokens: number`
- 推理令牌的数量。
+ 推理 token 的数量。
- `total_tokens: number`
- 使用的令牌总数。
-
- - `compute_units: optional number or null`
-
- 该请求的计算单元。在可用时当前为 null。
+ 使用的 token 总数。
- `user: optional string`
- 此字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
- 用于标识你的最终用户的稳定标识符。
- 通过更好地对相似请求进行分桶以提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 该字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
+ 你的最终用户的稳定标识符。
+ 通过更好地对相似请求进行分桶来提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `sequence_number: number`
@@ -76908,11 +76884,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 与此事件关联的 API 项的唯一标识符。
+ 与此事件关联的 API 条目的唯一标识符。
- `output_index: number`
- 此增量所应用的输出索引。
+ 此增量所适用的输出索引。
- `sequence_number: number`
@@ -76936,11 +76912,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 与此事件关联的 API 项的唯一标识符。
+ 与此事件关联的 API 条目的唯一标识符。
- `output_index: number`
- 此事件适用的输出索引。
+ 此事件所适用的输出索引。
- `sequence_number: number`
@@ -77010,7 +76986,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseErrorEvent object { code, message, param, 2 more }`
- 发生错误时触发。
+ 在发生错误时触发。
- `code: string or null`
@@ -77038,11 +77014,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseFailedEvent object { response, sequence_number, type }`
- 当 response 失败时发出的事件。
+ 当响应失败时发出的事件。
- `response: Response`
- 失败的 response。
+ 失败的响应。
- `id: string`
@@ -77050,7 +77026,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_at: number`
- 创建此 Response 时的 Unix 时间戳(以秒为单位)。
+ 此 Response 创建时的 Unix 时间戳(以秒为单位)。
- `error: ResponseError or null`
@@ -77106,87 +77082,89 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `incomplete_details: object { reason } or null`
- 有关响应未完成原因的详细信息。
+ 有关响应不完整的详细原因。
- - `reason: optional "max_output_tokens" or "content_filter"`
+ - `reason: optional "max_output_tokens" or "max_messages" or "content_filter"`
- 响应未完成的原因。
+ 响应不完整的原因。
- `"max_output_tokens"`
+ - `"max_messages"`
+
- `"content_filter"`
- `instructions: string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more or null`
插入到模型上下文中的系统(或开发者)消息。
- 当与 `previous_response_id`,配合使用时,前一次
- 响应的指令不会延续到下一次响应。这便于在新响应中
- 替换系统(或开发者)消息。
+ 当与 `previous_response_id`,配合使用时,上一个
+ response 中的 instructions 不会延续到下一个 response。这样可以轻松地
+ 在新的 response 中替换系统(或开发者)消息。
- `string`
- 发送给模型的文本输入,相当于使用
+ 发送给模型的文本输入,等同于
`developer` 角色的文本输入。
- `InputItemList = array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 发送给模型的一个或多个输入项的列表,包含
+ 发送给模型的一个或多个输入项列表,包含
不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` role. Messages with the
- `assistant` role are presumed to have been generated by the model in previous
- interactions.
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色给出的指令。带有
+ `assistant` 角色的消息被视为模型在之前的
+ 交互中生成。
- `content: string or ResponseInputMessageContentList`
- Text, image, or audio input to the model, used to generate a response.
- Can also contain previous assistant responses.
+ 发送给模型的文本、图像或音频输入,用于生成响应。
+ 也可以包含之前的助手响应。
- `TextInput = string`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputMessageContentList = array of ResponseInputContent`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -77198,25 +77176,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -77226,13 +77204,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -77242,33 +77220,33 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `assistant`, `system`, or
+ 消息输入的角色。其一为 接口 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -77281,9 +77259,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -77291,24 +77269,24 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: optional "message"`
- 消息输入的类型。始终为 `message`.
+ 消息输入的类型。始终为 接口 `message`.
- `"message"`
- `Message object { content, role, status, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` 角色的文本输入。
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色的文本输入。
- `content: ResponseInputMessageContentList`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `system`, or `developer`.
+ 消息输入的角色。其一为 接口 `user`, `system`,或 `developer`.
- `"user"`
@@ -77318,8 +77296,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -77339,7 +77317,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -77347,15 +77325,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -77371,7 +77349,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -77381,25 +77359,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -77411,7 +77389,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -77419,11 +77397,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -77477,15 +77455,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -77497,8 +77475,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -77514,9 +77492,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -77524,8 +77502,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -77537,7 +77515,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -77562,11 +77540,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -77584,7 +77562,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -77593,7 +77571,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -77605,7 +77583,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -77621,8 +77599,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -77646,7 +77624,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -77660,7 +77638,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -77686,7 +77664,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -77704,7 +77682,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -77723,7 +77701,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -77733,11 +77711,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -77757,15 +77735,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -77797,19 +77775,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -77833,8 +77811,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -77850,7 +77828,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -77866,7 +77844,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -77874,44 +77852,44 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCallOutput object { call_id, output, type, 3 more }`
- 一次 computer 工具调用的输出。
+ 计算机工具调用的输出。
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `id: optional string or null`
- computer 工具调用输出的 ID。
+ 计算机工具调用输出的 ID。
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 已被开发者确认的 API 所报告的安全检查结果。
+ 开发者已确认的 API 所报告的安全检查。
- `id: string`
@@ -77927,7 +77905,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值为 `in_progress`, `completed`, or `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -77938,7 +77916,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -77946,12 +77924,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -77961,11 +77939,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -77983,7 +77961,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -77997,7 +77975,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -78015,7 +77993,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -78027,14 +78005,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -78084,8 +78062,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -78099,7 +78077,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: string or array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的文本、图片或文件输出。
+ 函数工具调用的文本、图像或文件输出。
- `string`
@@ -78107,61 +78085,61 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的内容输出(文本、图片、文件)数组。
+ 函数工具调用的内容输出(文本、图像、文件)数组。
- `ResponseInputTextContent object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision)
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `detail: optional ImageDetail or null`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -78171,13 +78149,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -78191,23 +78169,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -78219,7 +78197,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string or null`
- 函数工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
+ 函数工具调用输出的唯一 ID。当此项通过 API 返回时填充。
- `call_id: optional string or null`
@@ -78259,7 +78237,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -78275,7 +78253,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目类型。始终为 `tool_search_call`.
+ 项的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
@@ -78343,37 +78321,37 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -78386,11 +78364,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -78410,7 +78388,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -78426,15 +78404,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -78448,7 +78426,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -78456,7 +78434,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -78468,7 +78446,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -78476,21 +78454,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -78516,18 +78494,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -78535,22 +78513,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -78560,23 +78538,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -78587,11 +78565,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -78609,21 +78587,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -78631,14 +78609,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -78670,32 +78648,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -78703,13 +78681,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -78717,9 +78695,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -78731,22 +78709,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -78755,7 +78733,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -78765,7 +78743,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -78795,29 +78773,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -78853,7 +78831,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -78863,11 +78841,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -78877,7 +78855,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -78885,7 +78863,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -78894,13 +78872,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -78909,7 +78887,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -78936,7 +78914,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -78947,7 +78925,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -78964,13 +78942,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -78986,7 +78964,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -78996,7 +78974,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -79020,7 +78998,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -79044,13 +79022,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -79074,7 +79052,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -79082,13 +79060,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -79108,7 +79086,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -79120,13 +79098,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -79140,11 +79118,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -79170,7 +79148,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -79188,7 +79166,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -79202,19 +79180,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -79234,19 +79212,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -79254,11 +79232,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -79304,7 +79282,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -79316,11 +79294,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -79334,7 +79312,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -79344,7 +79322,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -79354,23 +79332,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -79388,13 +79366,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目类型。始终为 `tool_search_output`.
+ 项的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `id: optional string or null`
- 此工具搜索输出的唯一 ID。
+ 该工具搜索输出的唯一 ID。
- `call_id: optional string or null`
@@ -79422,13 +79400,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `role: "developer"`
- 提供其他工具的角色。仅 `developer` 受支持。
+ 提供这些额外工具的角色。仅支持 `developer` 。
- `"developer"`
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 此项目提供的其他工具列表。
+ 在该条目中提供的额外工具列表。
- `Function object { name, parameters, strict, 5 more }`
@@ -79462,45 +79440,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -79508,7 +79486,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -79520,7 +79498,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -79528,21 +79506,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -79568,18 +79546,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -79587,22 +79565,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -79612,23 +79590,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -79639,11 +79617,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -79661,21 +79639,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -79683,14 +79661,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -79722,32 +79700,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -79755,13 +79733,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -79769,9 +79747,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -79783,22 +79761,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -79807,7 +79785,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -79817,7 +79795,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -79873,7 +79851,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -79883,11 +79861,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -79897,7 +79875,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -79905,7 +79883,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -79914,13 +79892,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -79929,7 +79907,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -79956,7 +79934,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -79967,7 +79945,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -79984,13 +79962,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -80006,7 +79984,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -80016,7 +79994,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -80042,11 +80020,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -80072,19 +80050,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -80104,19 +80082,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -80124,11 +80102,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -80174,7 +80152,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -80186,11 +80164,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -80204,7 +80182,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -80214,7 +80192,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -80224,23 +80202,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -80258,19 +80236,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目类型。始终为 `additional_tools`.
+ 项的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `id: optional string or null`
- 此其他工具项目的唯一 ID。
+ 该额外工具条目的唯一 ID。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -80283,7 +80261,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -80303,7 +80281,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -80313,20 +80291,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -80336,7 +80314,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Compaction object { encrypted_content, type, id }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -80344,17 +80322,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `id: optional string or null`
- 压缩条目的 ID。
+ 压缩项的 ID。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -80378,7 +80356,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -80401,7 +80379,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -80413,23 +80391,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -80447,13 +80425,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -80469,11 +80447,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -80487,11 +80465,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -80505,7 +80483,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -80515,7 +80493,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -80523,13 +80501,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -80543,7 +80521,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
@@ -80555,7 +80533,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最大挂钟时间(毫秒)。
+ 允许 shell 命令运行的 wall-clock 最长时间(毫秒)。
- `call_id: string`
@@ -80563,13 +80541,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
- `id: optional string or null`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -80605,7 +80583,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -80615,7 +80593,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ShellCallOutput object { call_id, output, type, 4 more }`
- shell 工具调用发出的流式输出项。
+ shell 工具调用发出的流式输出条目。
- `call_id: string`
@@ -80623,7 +80601,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: array of ResponseFunctionShellCallOutputContent`
- stdout 和 stderr 输出的捕获块及其关联结果。
+ 捕获的 stdout 和 stderr 输出块,以及它们关联的结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -80635,13 +80613,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -80649,27 +80627,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
- `stderr: string`
- shell 调用捕获的 stderr 输出。
+ 为该 shell 调用捕获的 stderr 输出。
- `stdout: string`
- shell 调用捕获的 stdout 输出。
+ 为该 shell 调用捕获的 stdout 输出。
- `type: "shell_call_output"`
- 条目的类型,恒为 `shell_call_output`.
+ item 的类型。始终为 `shell_call_output`.
- `"shell_call_output"`
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -80711,11 +80689,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 表示使用 diff 补丁创建、删除或更新文件的工具调用。
+ 表示通过 diff 补丁创建、删除或更新文件的工具调用。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
@@ -80727,7 +80705,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 创建文件时要应用的统一 diff 内容。
+ 创建文件时应用的 unified diff 内容。
- `path: string`
@@ -80759,7 +80737,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 要应用于现有文件的统一 diff 内容。
+ 应用于现有文件的 unified diff 内容。
- `path: string`
@@ -80773,7 +80751,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -80781,13 +80759,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
- `id: optional string or null`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -80815,15 +80793,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { call_id, status, type, 3 more }`
- apply patch 工具调用发出的流式输出。
+ 由 apply patch 工具调用发出的流式输出。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -80831,13 +80809,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
- `id: optional string or null`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -80893,7 +80871,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -80901,29 +80879,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -80931,31 +80909,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { approval_request_id, approve, type, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
- `id: optional string or null`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `reason: optional string or null`
@@ -80963,7 +80941,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -80971,11 +80949,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -80983,14 +80961,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -81030,7 +81008,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -81044,11 +81022,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 由你的代码生成的自定义工具调用输出,将被发送回模型。
+ 由你的代码生成的自定义工具调用的输出,将发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -81065,11 +81043,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -81083,7 +81061,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- 自定义工具调用输出在 OpenAI 平台中的唯一 ID。
+ 在 OpenAI 平台中该自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -81133,7 +81111,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -81161,11 +81139,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompactionTrigger object { type, id }`
- 压缩当前上下文。必须是最后一个输入项。
+ 压缩当前上下文。必须作为最后一个输入项。
- `type: "compaction_trigger"`
- 条目的类型,恒为 `compaction_trigger`.
+ item 的类型。始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -81179,11 +81157,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 要引用的条目 ID。
+ 被引用条目的 ID。
- `type: optional "item_reference" or null`
- 要引用的条目类型。始终为 `item_reference`.
+ 被引用条目的类型。始终为 `item_reference`.
- `"item_reference"`
@@ -81199,7 +81177,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -81207,7 +81185,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目类型。始终为 `program`.
+ 项的类型。始终为 `program`.
- `"program"`
@@ -81223,7 +81201,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -81235,14 +81213,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目类型。始终为 `program_output`.
+ 项的类型。始终为 `program_output`.
- `"program_output"`
- `metadata: Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
格式,以及通过 API 或控制台查询对象。
键为字符串,最长 64 个字符。值为字符串
@@ -81251,8 +81229,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: ResponsesModel`
用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI
- 提供了多种不同能力、性能
- 特性和定价的模型。请参阅 [模型指南](/docs/models)
+ 提供了众多功能、性能
+ 特性和价位各异的模型。请参阅 [模型指南](/docs/models)
以浏览和比较可用的模型。
- `string`
@@ -81475,12 +81453,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
由模型生成的内容项数组。
- - 该数组中项的数量和顺序 `output` 取决于
- 模型的响应。
- - 与直接访问该数组的 `output` 第一项并
- 假设它是一 `assistant` 个包含模型生成内容的
- 消息相比,你也可以考虑使用 `output_text` 属性(在
- 受支持的 SDK 中可用)。
+ - 该数组中项的长度和顺序取决于 `output` 模型的响应。
+ 与其访问。
+ - 数组中的第一项并 `output` 假设它是一个
+ 包含模型生成内容的 `assistant` 消息,不如使用
+ 属性(在受支持的 开发工具包 `output_text` 中可用)。
+ SDK。
- `ResponseOutputMessage object { id, content, role, 3 more }`
@@ -81488,8 +81466,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -81501,7 +81479,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -81526,11 +81504,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -81548,7 +81526,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -81557,7 +81535,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -81607,8 +81585,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -81633,15 +81611,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -81649,8 +81627,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -81694,7 +81672,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `name: optional string`
@@ -81707,7 +81685,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -81715,12 +81693,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -81730,11 +81708,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -81752,7 +81730,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -81766,7 +81744,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -81784,7 +81762,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -81796,14 +81774,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -81815,7 +81793,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -81831,8 +81809,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -81852,8 +81830,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `ComputerCallOutput object { id, call_id, output, 4 more }`
@@ -81863,16 +81841,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"completed"`
@@ -81884,13 +81862,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、已被
+ API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -81907,13 +81885,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -81926,7 +81904,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -81944,7 +81922,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -81954,20 +81932,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -81987,7 +81965,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -81995,7 +81973,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目的类型,恒为 `program`.
+ item 的类型。始终为 `program`.
- `"program"`
@@ -82011,7 +81989,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -82023,7 +82001,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目的类型,恒为 `program_output`.
+ item 的类型。始终为 `program_output`.
- `"program_output"`
@@ -82061,13 +82039,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目的类型,恒为 `tool_search_call`.
+ item 的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -82133,45 +82111,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -82179,7 +82157,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -82191,7 +82169,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -82199,21 +82177,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -82239,18 +82217,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -82258,22 +82236,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -82283,23 +82261,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -82310,11 +82288,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -82332,21 +82310,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -82354,14 +82332,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -82393,32 +82371,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -82426,13 +82404,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -82440,9 +82418,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -82454,22 +82432,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -82478,7 +82456,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -82488,7 +82466,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -82544,7 +82522,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -82554,11 +82532,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -82568,7 +82546,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -82576,7 +82554,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -82585,13 +82563,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -82600,7 +82578,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -82627,7 +82605,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -82638,7 +82616,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -82655,13 +82633,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -82677,7 +82655,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -82687,7 +82665,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -82713,11 +82691,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -82743,19 +82721,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -82775,19 +82753,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -82795,11 +82773,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -82845,7 +82823,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -82857,11 +82835,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -82875,7 +82853,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -82885,7 +82863,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -82895,23 +82873,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -82929,13 +82907,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目的类型,恒为 `tool_search_output`.
+ item 的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -82965,7 +82943,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -82999,45 +82977,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -83045,7 +83023,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -83057,7 +83035,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -83065,21 +83043,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -83105,18 +83083,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -83124,22 +83102,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -83149,23 +83127,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -83176,11 +83154,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -83198,21 +83176,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -83220,14 +83198,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -83259,32 +83237,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -83292,13 +83270,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -83306,9 +83284,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -83320,22 +83298,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -83344,7 +83322,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -83354,7 +83332,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -83410,7 +83388,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -83420,11 +83398,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -83434,7 +83412,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -83442,7 +83420,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -83451,13 +83429,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -83466,7 +83444,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -83493,7 +83471,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -83504,7 +83482,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -83521,13 +83499,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -83543,7 +83521,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -83553,7 +83531,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -83579,11 +83557,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -83609,19 +83587,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -83641,19 +83619,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -83661,11 +83639,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -83711,7 +83689,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -83723,11 +83701,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -83741,7 +83719,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -83751,7 +83729,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -83761,23 +83739,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -83795,13 +83773,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目的类型,恒为 `additional_tools`.
+ item 的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -83809,21 +83787,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的已加密内容。
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -83847,7 +83825,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -83870,7 +83848,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -83882,23 +83860,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -83916,13 +83894,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -83938,11 +83916,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -83956,11 +83934,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -83974,7 +83952,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -83984,7 +83962,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -83992,13 +83970,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -84012,17 +83990,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -84060,7 +84038,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -84070,7 +84048,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -84104,7 +84082,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。通过 API 返回该条目时填充此字段。
- `call_id: string`
@@ -84112,15 +84090,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -84128,13 +84106,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -84142,7 +84120,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -84156,11 +84134,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`, or `incomplete`.
+ shell 调用输出的状态。可选值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -84196,7 +84174,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -84204,15 +84182,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -84228,7 +84206,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的 diff 创建新文件。
- `"create_file"`
@@ -84242,7 +84220,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "delete_file"`
- 删除指定的文件。
+ 删除指定文件。
- `"delete_file"`
@@ -84260,13 +84238,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "update_file"`
- 使用提供的差异更新现有文件。
+ 使用提供的 diff 更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -84274,7 +84252,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -84304,19 +84282,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -84324,7 +84302,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -84358,7 +84336,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -84366,11 +84344,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -84378,14 +84356,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -84397,7 +84375,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -84435,7 +84413,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -84443,29 +84421,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -84473,29 +84451,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `id: string`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -84527,7 +84505,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -84561,7 +84539,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -84578,11 +84556,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -84590,8 +84568,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -84631,7 +84609,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `parallel_tool_calls: boolean`
@@ -84639,8 +84617,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `temperature: number or null`
- 使用的采样温度,介于 0 到 2 之间。较高的值(例如 0.8)会使输出更加随机,而较低的值(例如 0.2)会使输出更加聚焦和确定。
- 我们通常建议修改此参数或 `top_p` 但不要同时修改两者。
+ 使用的采样温度,介于 0 到 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加聚焦和确定性。
+ 我们通常建议调整此项或 `top_p` 但不要同时调整两者。
- `tool_choice: ToolChoiceOptions or ToolChoiceAllowed or ToolChoiceTypes or 6 more`
@@ -84650,9 +84628,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceOptions = "none" or "auto" or "required"`
- 控制模型调用哪个工具(如果有的话)。
+ 控制模型调用哪个工具(如果有)。
- `none` 表示模型不会调用任何工具,而是生成一条消息。
+ `none` 表示模型将不会调用任何工具,而是生成一条消息。
`auto` 表示模型可以在生成消息或调用一个或
多个工具之间进行选择。
@@ -84684,7 +84662,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of map[unknown]`
- 模型应允许调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -84705,11 +84683,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceTypes object { type }`
指示模型应使用内置工具来生成响应。
- [了解有关内置工具的更多信息](/docs/guides/tools).
+ [了解更多关于内置工具的信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
- 模型应使用的托管工具类型。了解更多关于
+ 模型应使用的 托管工具 类型。了解更多关于
[内置工具](/docs/guides/tools).
允许的值为:
@@ -84754,7 +84732,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceMcp object { server_label, type, name }`
- 使用此选项可以强制模型调用远程 MCP 服务器上的特定工具。
+ 使用此选项可强制模型调用远程 MCP 服务器上的特定工具。
- `server_label: string`
@@ -84772,7 +84750,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceCustom object { name, type }`
- 使用此选项可以强制模型调用特定的自定义工具。
+ 使用此选项可强制模型调用特定的自定义工具。
- `name: string`
@@ -84788,27 +84766,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "programmatic_tool_calling"`
- 要调用的工具。始终为 `programmatic_tool_calling`.
+ 要调用的工具。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ToolChoiceApplyPatch object { type }`
- 在执行工具调用时强制模型调用 apply_patch 工具。
+ 强制模型在执行工具调用时调用 apply_patch 工具。
- `type: "apply_patch"`
- 要调用的工具。始终为 `apply_patch`.
+ 要调用的工具。始终 `apply_patch`.
- `"apply_patch"`
- `ToolChoiceShell object { type }`
- 在需要工具调用时强制模型调用 shell 工具。
+ 在需要工具调用时,强制模型调用 shell 工具。
- `type: "shell"`
- 要调用的工具。始终为 `shell`.
+ 要调用的工具。始终 `shell`.
- `"shell"`
@@ -84819,18 +84797,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
我们支持以下类别的工具:
- - **内置工具**:由 OpenAI 提供的工具,用于扩展模型的
- 能力,例如 [网页搜索](/docs/guides/tools-web-search)
+ - **内置工具**:由 OpenAI 提供的工具,用于扩展
+ 模型的能力,例如 [网页搜索](/docs/guides/tools-web-search)
或 [文件搜索](/docs/guides/tools-file-search)。详细了解
[内置工具](/docs/guides/tools).
- - **MCP 工具**:通过自定义 MCP 服务器与第三方系统集成
- 或 Google Drive 和 SharePoint 等预定义连接器。详细了解
+ - **MCP 工具**: 通过自定义 MCP 服务器与第三方系统集成
+ 或使用 Google Drive 和 SharePoint 等预定义连接器。详细了解
[MCP 工具](/docs/guides/tools-connectors-mcp).
- - **函数调用(自定义工具)**:由你定义的函数,
+ - **函数调用(自定义工具)**: 由你定义的函数,
使模型能够使用强类型参数和输出调用你自己的代码。详细了解
。你也可以使用
- [function calling](/docs/guides/function-calling)。你还可以使用
- 自定义工具调用你自己的代码。
+ [function calling](/docs/guides/function-calling). 你也可以使用
+ 自定义工具来调用你自己的代码。
- `Function object { name, parameters, strict, 5 more }`
@@ -84864,45 +84842,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -84910,7 +84888,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -84922,7 +84900,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -84930,21 +84908,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -84970,18 +84948,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -84989,22 +84967,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -85014,23 +84992,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -85041,11 +85019,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -85063,21 +85041,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -85085,14 +85063,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -85124,32 +85102,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -85157,13 +85135,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -85171,9 +85149,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -85185,22 +85163,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -85209,7 +85187,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -85219,7 +85197,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -85275,7 +85253,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -85285,11 +85263,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -85299,7 +85277,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -85307,7 +85285,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -85316,13 +85294,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -85331,7 +85309,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -85358,7 +85336,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -85369,7 +85347,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -85386,13 +85364,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -85408,7 +85386,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -85418,7 +85396,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -85444,11 +85422,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -85474,19 +85452,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -85506,19 +85484,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -85526,11 +85504,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -85576,7 +85554,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -85588,11 +85566,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -85606,7 +85584,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -85616,7 +85594,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -85626,23 +85604,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -85660,12 +85638,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `top_p: number or null`
- 一种名为核采样的温度采样替代方案,
- 其中模型会考虑 top_p 概率质量排名前列的词元结果。
- 因此,0.1 表示仅考虑构成前 10% 概率质量的词元。
+ 一种温度采样的替代方法,称为核采样,
+ 模型会考虑概率质量排名前 top_p 的标记的结果。
+ 因此 0.1 表示仅考虑构成前 10% 概率质量的标记。
会被考虑。
- 我们通常建议修改此参数或 `temperature` 但不要同时修改两者。
+ 我们通常建议调整此项或 `temperature` 但不要同时调整两者。
- `background: optional boolean or null`
@@ -85674,44 +85652,44 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `completed_at: optional number or null`
- 此 Response 完成时的 Unix 时间戳(以秒为单位)。
- 仅当状态为 `completed`.
+ 此响应完成时的 Unix 时间戳(以秒为单位)。
+ 仅在状态为 `completed`.
- `conversation: optional object { id } or null`
- 此响应所属的对话。此响应的输入项和输出项已自动添加到此对话。
+ 此响应所属的对话。此次响应的输入项和输出项已自动添加到此对话中。
- `id: string`
- 与此响应关联的对话的唯一 ID。
+ 此响应关联的对话的唯一 ID。
- `max_output_tokens: optional number or null`
- 一次响应中可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
+ 响应可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
- `max_tool_calls: optional number or null`
- 响应中可以处理的内置工具调用总次数上限。该上限适用于所有内置工具调用,而非单个工具。模型任何进一步的工具调用尝试都将被忽略。
+ 一次响应中可处理的内置工具调用总次数上限。该上限适用于所有内置工具调用的总和,而非单个工具。模型后续任何再次调用工具的尝试都将被忽略。
- `moderation: optional object { input, output } or null`
- 响应输入和输出的审核结果,前提是请求了已审核的补全。
+ 响应输入与输出的内容审核结果,前提是请求了经过审核的补全。
- `input: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输入的审核结果。
+ 对响应输入的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -85719,7 +85697,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -85727,17 +85705,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -85749,25 +85727,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输出的审核结果。
+ 对响应输出的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -85775,7 +85753,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -85783,17 +85761,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -85805,21 +85783,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output_text: optional string or null`
- 仅限SDK的便捷属性,包含所有输出消息中聚合的文本输出
- 来自所有 `output_text` 数组中的 `output` 条目(如果有)。
+ SDK 独有的便捷属性,包含来自所有
+ 的聚合文本输出 `output_text` 数组中的 `output` 条目(如有)。
在 Python 和 JavaScript SDK 中受支持。
- `previous_response_id: optional string or null`
- 模型上一次响应的唯一 ID。使用它来
- 创建多轮对话。了解有关
- [对话状态](/docs/guides/conversation-state)。的更多信息。不能与 `conversation`.
+ 上一个模型响应的唯一 ID。使用它可以
+ 创建多轮对话。详细了解
+ [conversation state](/docs/guides/conversation-state)。不能与 `conversation`.
- `prompt: optional ResponsePrompt or null`
@@ -85832,19 +85810,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `variables: optional map[string or ResponseInputText or ResponseInputImage or ResponseInputFile] or null`
- 用于替换提示模板中变量的可选值映射,
- prompt。替换值可以是字符串,也可以是其他
- Response 输入类型,例如图像或文件。
+ 用于替换你
+ prompt。替换的值可以是字符串,也可以是其他
+ Response 输入类型,如图像或文件。
- `string`
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -85852,19 +85830,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `version: optional string or null`
- 提示模板的可选版本。
+ prompt 模板的可选版本。
- `prompt_cache_key: optional string or null`
- 由 OpenAI 用于缓存相似请求的响应,以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
+ 由OpenAI使用,为相似请求缓存响应以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
- `prompt_cache_options: optional object { mode, ttl }`
- 应用于该响应的提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。
+ 应用于该响应的 prompt 缓存选项。支持以下 `gpt-5.6` 及更高版本的模型。
- `mode: "implicit" or "explicit"`
- 是否启用了隐式提示缓存断点。
+ 是否启用了隐式 prompt 缓存断点。
- `"implicit"`
@@ -85872,24 +85850,24 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ttl: "30m"`
- 应用于每个缓存断点的最短生存时间。
+ 应用于每个缓存断点的最短生命周期。
- `"30m"`
- `prompt_cache_retention: optional "in_memory" or "24h" or null`
- 已弃用。请使用 `prompt_cache_options.ttl` 相反。
+ 已弃用。请使用 `prompt_cache_options.ttl` 改为。
- 提示词缓存的保留策略。设置为 `24h` 以启用扩展提示词缓存,使缓存前缀保持更长时间,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
- 此字段表示最长保留策略,而
+ 提示缓存的保留策略。设置为 `24h` 以启用扩展提示缓存,使缓存的前缀保持更长时间有效,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
+ 该字段表示最大保留策略,而
`prompt_cache_options.ttl` 表示最短缓存生命周期。这两个
- 字段彼此独立,不会相互影响。
- 对于 `gpt-5.5`, `gpt-5.5-pro`,及未来模型,仅 `24h` 受支持。
+ 字段是独立的,不会相互影响。
+ 对于 `gpt-5.5`, `gpt-5.5-pro`,以及未来的模型,仅 `24h` 。
对于同时支持两者的旧模型 `in_memory` 和 `24h`,默认值取决于你组织的数据保留策略:
- - 未启用 ZDR 的组织默认使用 `24h`.
- - 启用 ZDR 的组织默认使用 `in_memory` 当 `prompt_cache_retention` 未指定时。
+ - 未启用 ZDR 的组织默认为 `24h`.
+ - 启用 ZDR 的组织默认为 `in_memory` 当 `prompt_cache_retention` 未指定时。
- `"in_memory"`
@@ -85897,18 +85875,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `reasoning: optional Reasoning or null`
- 配置选项,适用于
+ 适用于
[推理模型](https://platform.openai.com/docs/guides/reasoning).
- `context: optional "auto" or "current_turn" or "all_turns" or null`
- 控制在后续轮次中呈现回模型的推理项。
- 如果省略或设置为 `auto`,则由模型确定上下文模式。
+ 控制在后续回合中哪些推理项会被回传给模型。
+ 如果省略或设置为 `auto`,则由模型决定上下文模式。
`gpt-5.6` 模型系列默认为 `all_turns`;早期模型默认为
`current_turn`.
- 在响应中返回时,这是该响应使用的有效推理上下文模式
- 。
+ 在响应中返回时,这是该响应所使用 的有效推理上下文模式
+ 用于该响应。
- `"auto"`
@@ -85918,13 +85896,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `effort: optional ReasoningEffort or null`
- 限制推理模型在推理上的投入程度。当前支持的值
- 包括 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
- 降低推理投入程度可以让响应更快,并减少响应中推理所用的 token 数。并非所有推理模型都支持每个
- 值。请参阅
- 推理指南
+ 限制推理模型在推理上的投入程度。目前支持
+ 的取值有 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
+ 降低推理投入程度可以让响应更快,并减少响应中用于推理的 token
+ 数量。并非所有推理模型都支持每个
+ 取值。有关各模型的支持情况,请参阅
[推理指南](https://platform.openai.com/docs/guides/reasoning)
- 以了解特定模型的支持情况。
+ 。
- `"none"`
@@ -85942,11 +85920,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `generate_summary: optional "auto" or "concise" or "detailed" or null`
- **已弃用:** 请使用 `summary` 相反。
+ **已弃用:** 请使用 `summary` 改为。
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `"auto"`
@@ -85958,7 +85936,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `string`
@@ -85966,7 +85944,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `"standard"`
@@ -85974,11 +85952,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `summary: optional "auto" or "concise" or "detailed" or null`
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `concise` 支持以下模型 `computer-use-preview` 以及之后的所有推理模型 `gpt-5`.
+ `concise` 支持用于 `computer-use-preview` 模型以及之后的 `gpt-5`.
- `"auto"`
@@ -85988,21 +85966,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `safety_identifier: optional string or null`
- 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用策略的应用程序用户。
- ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份识别信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用政策的应用用户。
+ ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `service_tier: optional ServiceTier or null`
指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
+ - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则该项目将使用 'default'。
- 如果设置为 'default',则该请求将使用所选模型的标准定价和性能进行处理。
- 如果设置为 '[flex](/docs/guides/flex-processing)',则该请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别选择启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 `service_tier=fast` 或 `service_tier=priority` 参数用于 Responses 或 Chat Completions。响应将显示 `service_tier=priority` ,无论你是否在请求中指定了 `service_tier=fast` 或 `priority` 。
- - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级返回的响应将显示 `service_tier=ultrafast`.
- - 如果未设置,默认行为是 'auto'。
+ - 若要在请求级别启用 [快速模式](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过它处理的响应将显示 `service_tier=ultrafast`.
+ - 未设置时,默认行为为 'auto'。
- 当设置 `service_tier` 参数时,响应正文将包含基于实际用于处理该请求的处理模式的 `service_tier` 值。此响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应体中将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。此响应中的值可能与该参数中设置的值不同。
- `"auto"`
@@ -86020,8 +85998,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional ResponseStatus`
- 响应生成的状态。取值之一为 `completed`, `failed`,
- `in_progress`, `cancelled`, `queued`, or `incomplete`.
+ 响应生成的状态。可选值为 `completed`, `failed`,
+ `in_progress`, `cancelled`, `queued`,或 `incomplete`.
- `"completed"`
@@ -86037,8 +86015,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: optional ResponseTextConfig`
- 用于配置模型文本响应的选项。可以是纯文本,也可以是结构化的 JSON 数据。详见:
- 文本输入与输出:
+ 模型文本响应的配置选项。可以是纯
+ 文本或结构化 JSON 数据。了解更多:
- [文本输入与输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
@@ -86047,79 +86025,79 @@ curl https://api.openai.com/v1/responses/resp_123 \
用于指定模型必须输出的格式的对象。
- 设置为 `{ "type": "json_schema" }` 时,将启用结构化输出,
- 功能,从而确保模型的输出与你提供的 JSON schema 相匹配。详见
+ 配置 `{ "type": "json_schema" }` 可启用结构化输出,
+ 从而确保模型匹配你提供的 JSON schema。更多信息请参阅
[结构化输出指南](/docs/guides/structured-outputs).
- 默认的格式为 `{ "type": "text" }` ,且不包含其他选项。
+ 默认格式为 `{ "type": "text" }` ,不包含任何额外选项。
- **不建议在 gpt-4o 及更新模型上使用:**
+ **不推荐用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
- 的模型,建议优先使用该格式。
+ 设置为 `{ "type": "json_object" }` 会启用旧版 JSON 模式,该模式
+ 可确保模型生成的消息是合法 JSON。对于支持 `json_schema`
+ 的模型,建议优先使用它。
- `ResponseFormatText object { type }`
- 默认的响应格式。用于生成文本响应。
+ 默认响应格式。用于生成文本响应。
- `type: "text"`
- 正在定义的响应格式的类型。始终为 `text`.
+ 正在定义的响应格式类型。始终为 `text`.
- `"text"`
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化的 JSON 响应。
+ JSON Schema 响应格式。用于生成结构化 JSON 响应。
详细了解 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
- 下划线和连字符,最大长度为 64。
+ 下划线和短横线,最大长度为 64。
- `schema: map[unknown]`
- 响应格式的 schema,以 JSON Schema 对象描述。
- 了解如何构建 JSON schema [此处](https://json-schema.org/).
+ 响应格式的架构,以 JSON Schema 对象形式描述。
+ 了解如何构建 JSON 架构 [此处](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式的类型。始终为 `json_schema`.
+ 正在定义的响应格式类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
响应格式用途的描述,供模型用于
- 确定如何按该格式进行响应。
+ 确定如何按该格式响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 一致性。
- 如果设置为 true,模型将始终遵循
- 字段中 `schema` 定义的精确 schema。仅支持 JSON Schema 的一个子集,当
- `strict` 是 `true`。要了解更多信息,请阅读 [Structured Outputs
+ 生成输出时是否启用严格的架构遵循。
+ 如果设置为 true,模型将始终遵循 字段中定义的
+ 确切架构。当 设置为 `schema` true 时,仅支持 JSON Schema 的一个子集
+ `strict` 是 `true`。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较早的生成 JSON 响应的方法。
- 使用 `json_schema` 对支持它的模型是推荐的做法。请注意
- 模型在没有系统或用户消息指示的情况下不会生成
- JSON。
+ JSON 对象响应格式。一种较旧的 JSON 响应生成方法。建议。
+ 对于支持 的模型,使用 `json_schema` 。请注意,模型不会在没有系统或用户消息指示
+ 的情况下生成 JSON
+ 。
- `type: "json_object"`
- 正在定义的响应格式的类型。始终为 `json_object`.
+ 正在定义的响应格式类型。始终为 `json_object`.
- `"json_object"`
- `verbosity: optional "low" or "medium" or "high" or null`
- 约束模型响应的详细程度。较低的值会产生
- 更简洁的响应,较高的值会产生更详细的响应。
+ 约束模型响应的详尽程度。较低的值将导致
+ 更简洁的响应,而较高的值将导致更冗长的响应。
当前支持的值包括 `low`, `medium`,和 `high`。默认值为
`medium`.
@@ -86131,20 +86109,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `top_logprobs: optional number or null`
- 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的最大最可能
- token 数量,每个 token 都附带对应的对数
+ 一个介于 0 到 20 之间的整数,指定在每个 token 位置返回的
+ 最可能 token 的最大数量,每个 token 都有一个关联的对数
概率。在某些情况下,返回的 token 数量可能少于
- 所请求的数量。
+ 请求的数量。
- `truncation: optional "auto" or "disabled" or null`
用于模型响应的截断策略。
- - `auto`:如果此 Response 的输入超过
- 模型的上下文窗口大小,模型将通过从对话开头丢弃条目来截断
- 响应以适配上下文窗口。
- - `disabled` (默认):如果输入大小将超出模型的上下文窗口
- 大小,请求将失败并返回 400 错误。
+ - `auto`:如果此 Response 的输入超出
+ 模型的上下文窗口大小,模型将通过从对话开头
+ 丢弃条目来截断响应以适配上下文窗口。
+ - `disabled` (默认):如果输入大小将超过模型的上下文窗口
+ 大小,请求将以 400 错误失败。
- `"auto"`
@@ -86153,7 +86131,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `usage: optional ResponseUsage`
表示 token 使用详情,包括输入 token、输出 token,
- 的输出 token 明细,以及所使用的 token 总数。
+ 输出 token 的细分,以及使用的总 token 数。
- `input_tokens: number`
@@ -86161,16 +86139,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_tokens_details: object { cache_write_tokens, cached_tokens }`
- 输入 token 的详细明细。
+ 输入 token 的详细细分。
- `cache_write_tokens: number`
- 已写入缓存的输入 token 数量。
+ 写入缓存的输入 token 的数量。
- `cached_tokens: number`
- 从缓存中检索到的 token 数量。
- [了解更多关于提示缓存的信息](/docs/guides/prompt-caching).
+ 从缓存中检索到的 token 的数量。
+ [有关 prompt caching 的更多信息](/docs/guides/prompt-caching).
- `output_tokens: number`
@@ -86178,25 +86156,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_tokens_details: object { reasoning_tokens }`
- 输出令牌的详细明细。
+ 输出 token 的详细明细。
- `reasoning_tokens: number`
- 推理令牌的数量。
+ 推理 token 的数量。
- `total_tokens: number`
- 使用的令牌总数。
-
- - `compute_units: optional number or null`
-
- 该请求的计算单元。在可用时当前为 null。
+ 使用的 token 总数。
- `user: optional string`
- 此字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
- 用于标识你的最终用户的稳定标识符。
- 通过更好地对相似请求进行分桶以提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 该字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
+ 你的最终用户的稳定标识符。
+ 通过更好地对相似请求进行分桶来提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `sequence_number: number`
@@ -86212,15 +86186,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseFileSearchCallCompletedEvent object { item_id, output_index, sequence_number, type }`
- 在文件搜索调用完成(找到结果)时发出。
+ 在文件搜索调用完成时触发(已找到结果)。
- `item_id: string`
- 发起文件搜索调用的输出项的 ID。
+ 发起文件搜索调用的输出项 ID。
- `output_index: number`
- 发起文件搜索调用的输出项的索引。
+ 发起文件搜索调用的输出项索引。
- `sequence_number: number`
@@ -86232,19 +86206,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.file_search_call.completed"`
-### 响应中的文件搜索调用进行中事件
+### 响应文件搜索调用进行中事件
- `ResponseFileSearchCallInProgressEvent object { item_id, output_index, sequence_number, type }`
- 在发起 文件搜索 调用时发出。
+ 在发起文件搜索调用时发出。
- `item_id: string`
- 发起文件搜索调用的输出项的 ID。
+ 发起文件搜索调用的输出项 ID。
- `output_index: number`
- 发起文件搜索调用的输出项的索引。
+ 发起文件搜索调用的输出项索引。
- `sequence_number: number`
@@ -86260,15 +86234,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseFileSearchCallSearchingEvent object { item_id, output_index, sequence_number, type }`
- 在文件搜索正在执行检索时发出。
+ 当 文件搜索 正在搜索时发出。
- `item_id: string`
- 发起文件搜索调用的输出项的 ID。
+ 发起文件搜索调用的输出项 ID。
- `output_index: number`
- 文件搜索调用正在搜索的输出项的索引。
+ 文件搜索 调用正在搜索的输出项的索引。
- `sequence_number: number`
@@ -86280,122 +86254,122 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.file_search_call.searching"`
-### Response Format Text Config
+### 响应格式文本配置
- `ResponseFormatTextConfig = ResponseFormatText or ResponseFormatTextJSONSchemaConfig or ResponseFormatJSONObject`
用于指定模型必须输出的格式的对象。
- 设置为 `{ "type": "json_schema" }` 时,将启用结构化输出,
- 功能,从而确保模型的输出与你提供的 JSON schema 相匹配。详见
+ 配置 `{ "type": "json_schema" }` 可启用结构化输出,
+ 从而确保模型匹配你提供的 JSON schema。更多信息请参阅
[结构化输出指南](/docs/guides/structured-outputs).
- 默认的格式为 `{ "type": "text" }` ,且不包含其他选项。
+ 默认格式为 `{ "type": "text" }` ,不包含任何额外选项。
- **不建议在 gpt-4o 及更新模型上使用:**
+ **不推荐用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
- 的模型,建议优先使用该格式。
+ 设置为 `{ "type": "json_object" }` 会启用旧版 JSON 模式,该模式
+ 可确保模型生成的消息是合法 JSON。对于支持 `json_schema`
+ 的模型,建议优先使用它。
- `ResponseFormatText object { type }`
- 默认的响应格式。用于生成文本响应。
+ 默认响应格式。用于生成文本响应。
- `type: "text"`
- 正在定义的响应格式的类型。始终为 `text`.
+ 正在定义的响应格式类型。始终为 `text`.
- `"text"`
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化的 JSON 响应。
+ JSON Schema 响应格式。用于生成结构化 JSON 响应。
详细了解 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
- 下划线和连字符,最大长度为 64。
+ 下划线和短横线,最大长度为 64。
- `schema: map[unknown]`
- 响应格式的 schema,以 JSON Schema 对象描述。
- 了解如何构建 JSON schema [此处](https://json-schema.org/).
+ 响应格式的架构,以 JSON Schema 对象形式描述。
+ 了解如何构建 JSON 架构 [此处](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式的类型。始终为 `json_schema`.
+ 正在定义的响应格式类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
响应格式用途的描述,供模型用于
- 确定如何按该格式进行响应。
+ 确定如何按该格式响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 一致性。
- 如果设置为 true,模型将始终遵循
- 字段中 `schema` 定义的精确 schema。仅支持 JSON Schema 的一个子集,当
- `strict` 是 `true`。要了解更多信息,请阅读 [Structured Outputs
+ 生成输出时是否启用严格的架构遵循。
+ 如果设置为 true,模型将始终遵循 字段中定义的
+ 确切架构。当 设置为 `schema` true 时,仅支持 JSON Schema 的一个子集
+ `strict` 是 `true`。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较早的生成 JSON 响应的方法。
- 使用 `json_schema` 对支持它的模型是推荐的做法。请注意
- 模型在没有系统或用户消息指示的情况下不会生成
- JSON。
+ JSON 对象响应格式。一种较旧的 JSON 响应生成方法。建议。
+ 对于支持 的模型,使用 `json_schema` 。请注意,模型不会在没有系统或用户消息指示
+ 的情况下生成 JSON
+ 。
- `type: "json_object"`
- 正在定义的响应格式的类型。始终为 `json_object`.
+ 正在定义的响应格式类型。始终为 `json_object`.
- `"json_object"`
-### Response Format Text JSON Schema Config
+### 响应格式文本 JSON Schema 配置
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化的 JSON 响应。
+ JSON Schema 响应格式。用于生成结构化 JSON 响应。
详细了解 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
- 下划线和连字符,最大长度为 64。
+ 下划线和短横线,最大长度为 64。
- `schema: map[unknown]`
- 响应格式的 schema,以 JSON Schema 对象描述。
- 了解如何构建 JSON schema [此处](https://json-schema.org/).
+ 响应格式的架构,以 JSON Schema 对象形式描述。
+ 了解如何构建 JSON 架构 [此处](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式的类型。始终为 `json_schema`.
+ 正在定义的响应格式类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
响应格式用途的描述,供模型用于
- 确定如何按该格式进行响应。
+ 确定如何按该格式响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 一致性。
- 如果设置为 true,模型将始终遵循
- 字段中 `schema` 定义的精确 schema。仅支持 JSON Schema 的一个子集,当
- `strict` 是 `true`。要了解更多信息,请阅读 [Structured Outputs
+ 生成输出时是否启用严格的架构遵循。
+ 如果设置为 true,模型将始终遵循 字段中定义的
+ 确切架构。当 设置为 `schema` true 时,仅支持 JSON Schema 的一个子集
+ `strict` 是 `true`。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
-### Response Function Call Arguments Delta Event
+### 响应函数调用参数增量事件
- `ResponseFunctionCallArgumentsDeltaEvent object { delta, item_id, output_index, 2 more }`
- 当存在部分函数调用参数的增量时发出。
+ 当存在部分函数调用参数增量时发出。
- `delta: string`
@@ -86403,11 +86377,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 添加函数调用参数增量的输出项的 ID。
+ 被添加函数调用参数增量的输出项的 ID。
- `output_index: number`
- 添加函数调用参数增量的输出项的索引。
+ 被添加函数调用参数增量的输出项的索引。
- `sequence_number: number`
@@ -86419,11 +86393,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.function_call_arguments.delta"`
-### Response Function Call Arguments Done Event
+### Response 函数调用参数完成事件
- `ResponseFunctionCallArgumentsDoneEvent object { arguments, item_id, name, 3 more }`
- 在函数调用参数被最终确定时发出。
+ 在函数调用参数确定时发出。
- `arguments: string`
@@ -86449,11 +86423,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.function_call_arguments.done"`
-### Response Function Shell Call 输出内容
+### Response Function Shell Call Output Content
- `ResponseFunctionShellCallOutputContent object { outcome, stderr, stdout }`
- 捕获 shell 工具调用输出中部分的 stdout 和 stderr。
+ 捕获 shell 工具调用输出的一部分 stdout 和 stderr。
- `outcome: object { type } or object { exit_code, type }`
@@ -86465,13 +86439,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -86479,23 +86453,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
- `stderr: string`
- shell 调用捕获的 stderr 输出。
+ 为该 shell 调用捕获的 stderr 输出。
- `stdout: string`
- shell 调用捕获的 stdout 输出。
+ 为该 shell 调用捕获的 stdout 输出。
-### Response Image Gen Call Completed 事件
+### Response 图像生成调用完成事件
- `ResponseImageGenCallCompletedEvent object { item_id, output_index, sequence_number, type }`
- 当一个图像生成工具调用已完成且最终图像可用时发出。
+ 当图像生成工具调用已完成且最终图像可用时发出。
- `item_id: string`
@@ -86515,11 +86489,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.image_generation_call.completed"`
-### Response 图像生成调用正在生成事件
+### 响应图像生成调用生成事件
- `ResponseImageGenCallGeneratingEvent object { item_id, output_index, sequence_number, type }`
- 当图像生成工具调用正在主动生成图像时触发(中间状态)。
+ 当图像生成工具调用正在主动生成图像时发出(中间状态)。
- `item_id: string`
@@ -86539,11 +86513,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.image_generation_call.generating"`
-### 响应图像生成调用进行中事件
+### Response Image Gen Call In Progress Event
- `ResponseImageGenCallInProgressEvent object { item_id, output_index, sequence_number, type }`
- 当图像生成工具调用进行中时发出。
+ 当图像生成工具调用进行时触发。
- `item_id: string`
@@ -86567,7 +86541,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseImageGenCallPartialImageEvent object { item_id, output_index, partial_image_b64, 7 more }`
- 在图像生成流式传输过程中,当有部分图像可用时触发。
+ 在图像生成流式传输期间出现部分图像时发出。
- `item_id: string`
@@ -86579,11 +86553,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_image_b64: string`
- Base64 编码的部分图像数据,可用于渲染为图像。
+ Base64 编码的部分图像数据,适合渲染为图像。
- `partial_image_index: number`
- 部分图像的从 0 开始的索引(后端使用从 1 开始的索引,但此处为面向用户的从 0 开始)。
+ 部分图像的 0 基索引(后端使用 1 基索引,但供用户使用的是 0 基索引)。
- `sequence_number: number`
@@ -86611,11 +86585,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
所使用的图像尺寸。
-### 进行中响应事件
+### Response In Progress Event
- `ResponseInProgressEvent object { response, sequence_number, type }`
- 当响应正在进行时发出。
+ 在响应进行中时发出。
- `response: Response`
@@ -86627,7 +86601,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_at: number`
- 创建此 Response 时的 Unix 时间戳(以秒为单位)。
+ 此 Response 创建时的 Unix 时间戳(以秒为单位)。
- `error: ResponseError or null`
@@ -86683,87 +86657,89 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `incomplete_details: object { reason } or null`
- 有关响应未完成原因的详细信息。
+ 有关响应不完整的详细原因。
- - `reason: optional "max_output_tokens" or "content_filter"`
+ - `reason: optional "max_output_tokens" or "max_messages" or "content_filter"`
- 响应未完成的原因。
+ 响应不完整的原因。
- `"max_output_tokens"`
+ - `"max_messages"`
+
- `"content_filter"`
- `instructions: string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more or null`
插入到模型上下文中的系统(或开发者)消息。
- 当与 `previous_response_id`,配合使用时,前一次
- 响应的指令不会延续到下一次响应。这便于在新响应中
- 替换系统(或开发者)消息。
+ 当与 `previous_response_id`,配合使用时,上一个
+ response 中的 instructions 不会延续到下一个 response。这样可以轻松地
+ 在新的 response 中替换系统(或开发者)消息。
- `string`
- 发送给模型的文本输入,相当于使用
+ 发送给模型的文本输入,等同于
`developer` 角色的文本输入。
- `InputItemList = array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 发送给模型的一个或多个输入项的列表,包含
+ 发送给模型的一个或多个输入项列表,包含
不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` role. Messages with the
- `assistant` role are presumed to have been generated by the model in previous
- interactions.
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色给出的指令。带有
+ `assistant` 角色的消息被视为模型在之前的
+ 交互中生成。
- `content: string or ResponseInputMessageContentList`
- Text, image, or audio input to the model, used to generate a response.
- Can also contain previous assistant responses.
+ 发送给模型的文本、图像或音频输入,用于生成响应。
+ 也可以包含之前的助手响应。
- `TextInput = string`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputMessageContentList = array of ResponseInputContent`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -86775,25 +86751,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -86803,13 +86779,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -86819,33 +86795,33 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `assistant`, `system`, or
+ 消息输入的角色。其一为 接口 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -86858,9 +86834,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -86868,24 +86844,24 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: optional "message"`
- 消息输入的类型。始终为 `message`.
+ 消息输入的类型。始终为 接口 `message`.
- `"message"`
- `Message object { content, role, status, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` 角色的文本输入。
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色的文本输入。
- `content: ResponseInputMessageContentList`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `system`, or `developer`.
+ 消息输入的角色。其一为 接口 `user`, `system`,或 `developer`.
- `"user"`
@@ -86895,8 +86871,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -86916,7 +86892,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -86924,15 +86900,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -86948,7 +86924,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -86958,25 +86934,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -86988,7 +86964,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -86996,11 +86972,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -87054,15 +87030,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -87074,8 +87050,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -87091,9 +87067,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -87101,8 +87077,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -87114,7 +87090,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -87139,11 +87115,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -87161,7 +87137,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -87170,7 +87146,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -87182,7 +87158,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -87198,8 +87174,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -87223,7 +87199,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -87237,7 +87213,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -87263,7 +87239,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -87281,7 +87257,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -87300,7 +87276,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -87310,11 +87286,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -87334,15 +87310,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -87374,19 +87350,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -87410,8 +87386,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -87427,7 +87403,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -87443,7 +87419,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -87451,44 +87427,44 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCallOutput object { call_id, output, type, 3 more }`
- 一次 computer 工具调用的输出。
+ 计算机工具调用的输出。
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `id: optional string or null`
- computer 工具调用输出的 ID。
+ 计算机工具调用输出的 ID。
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 已被开发者确认的 API 所报告的安全检查结果。
+ 开发者已确认的 API 所报告的安全检查。
- `id: string`
@@ -87504,7 +87480,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值为 `in_progress`, `completed`, or `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -87515,7 +87491,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -87523,12 +87499,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -87538,11 +87514,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -87560,7 +87536,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -87574,7 +87550,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -87592,7 +87568,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -87604,14 +87580,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -87661,8 +87637,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -87676,7 +87652,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: string or array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的文本、图片或文件输出。
+ 函数工具调用的文本、图像或文件输出。
- `string`
@@ -87684,61 +87660,61 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的内容输出(文本、图片、文件)数组。
+ 函数工具调用的内容输出(文本、图像、文件)数组。
- `ResponseInputTextContent object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision)
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `detail: optional ImageDetail or null`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -87748,13 +87724,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -87768,23 +87744,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -87796,7 +87772,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string or null`
- 函数工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
+ 函数工具调用输出的唯一 ID。当此项通过 API 返回时填充。
- `call_id: optional string or null`
@@ -87836,7 +87812,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -87852,7 +87828,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目类型。始终为 `tool_search_call`.
+ 项的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
@@ -87920,37 +87896,37 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -87963,11 +87939,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -87987,7 +87963,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -88003,15 +87979,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -88025,7 +88001,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -88033,7 +88009,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -88045,7 +88021,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -88053,21 +88029,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -88093,18 +88069,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -88112,22 +88088,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -88137,23 +88113,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -88164,11 +88140,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -88186,21 +88162,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -88208,14 +88184,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -88247,32 +88223,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -88280,13 +88256,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -88294,9 +88270,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -88308,22 +88284,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -88332,7 +88308,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -88342,7 +88318,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -88372,29 +88348,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -88430,7 +88406,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -88440,11 +88416,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -88454,7 +88430,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -88462,7 +88438,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -88471,13 +88447,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -88486,7 +88462,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -88513,7 +88489,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -88524,7 +88500,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -88541,13 +88517,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -88563,7 +88539,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -88573,7 +88549,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -88597,7 +88573,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -88621,13 +88597,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -88651,7 +88627,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -88659,13 +88635,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -88685,7 +88661,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -88697,13 +88673,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -88717,11 +88693,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -88747,7 +88723,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -88765,7 +88741,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -88779,19 +88755,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -88811,19 +88787,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -88831,11 +88807,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -88881,7 +88857,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -88893,11 +88869,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -88911,7 +88887,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -88921,7 +88897,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -88931,23 +88907,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -88965,13 +88941,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目类型。始终为 `tool_search_output`.
+ 项的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `id: optional string or null`
- 此工具搜索输出的唯一 ID。
+ 该工具搜索输出的唯一 ID。
- `call_id: optional string or null`
@@ -88999,13 +88975,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `role: "developer"`
- 提供其他工具的角色。仅 `developer` 受支持。
+ 提供这些额外工具的角色。仅支持 `developer` 。
- `"developer"`
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 此项目提供的其他工具列表。
+ 在该条目中提供的额外工具列表。
- `Function object { name, parameters, strict, 5 more }`
@@ -89039,45 +89015,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -89085,7 +89061,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -89097,7 +89073,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -89105,21 +89081,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -89145,18 +89121,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -89164,22 +89140,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -89189,23 +89165,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -89216,11 +89192,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -89238,21 +89214,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -89260,14 +89236,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -89299,32 +89275,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -89332,13 +89308,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -89346,9 +89322,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -89360,22 +89336,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -89384,7 +89360,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -89394,7 +89370,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -89450,7 +89426,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -89460,11 +89436,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -89474,7 +89450,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -89482,7 +89458,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -89491,13 +89467,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -89506,7 +89482,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -89533,7 +89509,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -89544,7 +89520,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -89561,13 +89537,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -89583,7 +89559,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -89593,7 +89569,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -89619,11 +89595,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -89649,19 +89625,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -89681,19 +89657,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -89701,11 +89677,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -89751,7 +89727,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -89763,11 +89739,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -89781,7 +89757,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -89791,7 +89767,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -89801,23 +89777,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -89835,19 +89811,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目类型。始终为 `additional_tools`.
+ 项的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `id: optional string or null`
- 此其他工具项目的唯一 ID。
+ 该额外工具条目的唯一 ID。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -89860,7 +89836,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -89880,7 +89856,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -89890,20 +89866,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -89913,7 +89889,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Compaction object { encrypted_content, type, id }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -89921,17 +89897,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `id: optional string or null`
- 压缩条目的 ID。
+ 压缩项的 ID。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -89955,7 +89931,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -89978,7 +89954,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -89990,23 +89966,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -90024,13 +90000,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -90046,11 +90022,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -90064,11 +90040,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -90082,7 +90058,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -90092,7 +90068,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -90100,13 +90076,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -90120,7 +90096,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
@@ -90132,7 +90108,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最大挂钟时间(毫秒)。
+ 允许 shell 命令运行的 wall-clock 最长时间(毫秒)。
- `call_id: string`
@@ -90140,13 +90116,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
- `id: optional string or null`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -90182,7 +90158,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -90192,7 +90168,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ShellCallOutput object { call_id, output, type, 4 more }`
- shell 工具调用发出的流式输出项。
+ shell 工具调用发出的流式输出条目。
- `call_id: string`
@@ -90200,7 +90176,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: array of ResponseFunctionShellCallOutputContent`
- stdout 和 stderr 输出的捕获块及其关联结果。
+ 捕获的 stdout 和 stderr 输出块,以及它们关联的结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -90212,13 +90188,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -90226,27 +90202,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
- `stderr: string`
- shell 调用捕获的 stderr 输出。
+ 为该 shell 调用捕获的 stderr 输出。
- `stdout: string`
- shell 调用捕获的 stdout 输出。
+ 为该 shell 调用捕获的 stdout 输出。
- `type: "shell_call_output"`
- 条目的类型,恒为 `shell_call_output`.
+ item 的类型。始终为 `shell_call_output`.
- `"shell_call_output"`
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -90288,11 +90264,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 表示使用 diff 补丁创建、删除或更新文件的工具调用。
+ 表示通过 diff 补丁创建、删除或更新文件的工具调用。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
@@ -90304,7 +90280,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 创建文件时要应用的统一 diff 内容。
+ 创建文件时应用的 unified diff 内容。
- `path: string`
@@ -90336,7 +90312,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 要应用于现有文件的统一 diff 内容。
+ 应用于现有文件的 unified diff 内容。
- `path: string`
@@ -90350,7 +90326,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -90358,13 +90334,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
- `id: optional string or null`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -90392,15 +90368,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { call_id, status, type, 3 more }`
- apply patch 工具调用发出的流式输出。
+ 由 apply patch 工具调用发出的流式输出。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -90408,13 +90384,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
- `id: optional string or null`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -90470,7 +90446,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -90478,29 +90454,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -90508,31 +90484,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { approval_request_id, approve, type, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
- `id: optional string or null`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `reason: optional string or null`
@@ -90540,7 +90516,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -90548,11 +90524,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -90560,14 +90536,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -90607,7 +90583,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -90621,11 +90597,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 由你的代码生成的自定义工具调用输出,将被发送回模型。
+ 由你的代码生成的自定义工具调用的输出,将发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -90642,11 +90618,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -90660,7 +90636,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- 自定义工具调用输出在 OpenAI 平台中的唯一 ID。
+ 在 OpenAI 平台中该自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -90710,7 +90686,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -90738,11 +90714,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompactionTrigger object { type, id }`
- 压缩当前上下文。必须是最后一个输入项。
+ 压缩当前上下文。必须作为最后一个输入项。
- `type: "compaction_trigger"`
- 条目的类型,恒为 `compaction_trigger`.
+ item 的类型。始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -90756,11 +90732,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 要引用的条目 ID。
+ 被引用条目的 ID。
- `type: optional "item_reference" or null`
- 要引用的条目类型。始终为 `item_reference`.
+ 被引用条目的类型。始终为 `item_reference`.
- `"item_reference"`
@@ -90776,7 +90752,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -90784,7 +90760,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目类型。始终为 `program`.
+ 项的类型。始终为 `program`.
- `"program"`
@@ -90800,7 +90776,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -90812,14 +90788,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目类型。始终为 `program_output`.
+ 项的类型。始终为 `program_output`.
- `"program_output"`
- `metadata: Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
格式,以及通过 API 或控制台查询对象。
键为字符串,最长 64 个字符。值为字符串
@@ -90828,8 +90804,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: ResponsesModel`
用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI
- 提供了多种不同能力、性能
- 特性和定价的模型。请参阅 [模型指南](/docs/models)
+ 提供了众多功能、性能
+ 特性和价位各异的模型。请参阅 [模型指南](/docs/models)
以浏览和比较可用的模型。
- `string`
@@ -91052,12 +91028,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
由模型生成的内容项数组。
- - 该数组中项的数量和顺序 `output` 取决于
- 模型的响应。
- - 与直接访问该数组的 `output` 第一项并
- 假设它是一 `assistant` 个包含模型生成内容的
- 消息相比,你也可以考虑使用 `output_text` 属性(在
- 受支持的 SDK 中可用)。
+ - 该数组中项的长度和顺序取决于 `output` 模型的响应。
+ 与其访问。
+ - 数组中的第一项并 `output` 假设它是一个
+ 包含模型生成内容的 `assistant` 消息,不如使用
+ 属性(在受支持的 开发工具包 `output_text` 中可用)。
+ SDK。
- `ResponseOutputMessage object { id, content, role, 3 more }`
@@ -91065,8 +91041,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -91078,7 +91054,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -91103,11 +91079,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -91125,7 +91101,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -91134,7 +91110,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -91184,8 +91160,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -91210,15 +91186,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -91226,8 +91202,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -91271,7 +91247,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `name: optional string`
@@ -91284,7 +91260,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -91292,12 +91268,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -91307,11 +91283,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -91329,7 +91305,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -91343,7 +91319,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -91361,7 +91337,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -91373,14 +91349,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -91392,7 +91368,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -91408,8 +91384,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -91429,8 +91405,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `ComputerCallOutput object { id, call_id, output, 4 more }`
@@ -91440,16 +91416,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"completed"`
@@ -91461,13 +91437,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、已被
+ API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -91484,13 +91460,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -91503,7 +91479,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -91521,7 +91497,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -91531,20 +91507,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -91564,7 +91540,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -91572,7 +91548,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目的类型,恒为 `program`.
+ item 的类型。始终为 `program`.
- `"program"`
@@ -91588,7 +91564,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -91600,7 +91576,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目的类型,恒为 `program_output`.
+ item 的类型。始终为 `program_output`.
- `"program_output"`
@@ -91638,13 +91614,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目的类型,恒为 `tool_search_call`.
+ item 的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -91710,45 +91686,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -91756,7 +91732,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -91768,7 +91744,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -91776,21 +91752,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -91816,18 +91792,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -91835,22 +91811,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -91860,23 +91836,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -91887,11 +91863,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -91909,21 +91885,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -91931,14 +91907,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -91970,32 +91946,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -92003,13 +91979,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -92017,9 +91993,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -92031,22 +92007,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -92055,7 +92031,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -92065,7 +92041,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -92121,7 +92097,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -92131,11 +92107,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -92145,7 +92121,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -92153,7 +92129,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -92162,13 +92138,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -92177,7 +92153,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -92204,7 +92180,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -92215,7 +92191,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -92232,13 +92208,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -92254,7 +92230,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -92264,7 +92240,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -92290,11 +92266,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -92320,19 +92296,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -92352,19 +92328,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -92372,11 +92348,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -92422,7 +92398,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -92434,11 +92410,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -92452,7 +92428,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -92462,7 +92438,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -92472,23 +92448,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -92506,13 +92482,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目的类型,恒为 `tool_search_output`.
+ item 的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -92542,7 +92518,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -92576,45 +92552,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -92622,7 +92598,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -92634,7 +92610,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -92642,21 +92618,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -92682,18 +92658,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -92701,22 +92677,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -92726,23 +92702,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -92753,11 +92729,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -92775,21 +92751,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -92797,14 +92773,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -92836,32 +92812,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -92869,13 +92845,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -92883,9 +92859,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -92897,22 +92873,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -92921,7 +92897,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -92931,7 +92907,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -92987,7 +92963,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -92997,11 +92973,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -93011,7 +92987,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -93019,7 +92995,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -93028,13 +93004,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -93043,7 +93019,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -93070,7 +93046,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -93081,7 +93057,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -93098,13 +93074,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -93120,7 +93096,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -93130,7 +93106,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -93156,11 +93132,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -93186,19 +93162,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -93218,19 +93194,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -93238,11 +93214,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -93288,7 +93264,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -93300,11 +93276,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -93318,7 +93294,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -93328,7 +93304,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -93338,23 +93314,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -93372,13 +93348,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目的类型,恒为 `additional_tools`.
+ item 的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -93386,21 +93362,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的已加密内容。
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -93424,7 +93400,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -93447,7 +93423,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -93459,23 +93435,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -93493,13 +93469,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -93515,11 +93491,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -93533,11 +93509,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -93551,7 +93527,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -93561,7 +93537,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -93569,13 +93545,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -93589,17 +93565,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -93637,7 +93613,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -93647,7 +93623,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -93681,7 +93657,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。通过 API 返回该条目时填充此字段。
- `call_id: string`
@@ -93689,15 +93665,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -93705,13 +93681,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -93719,7 +93695,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -93733,11 +93709,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`, or `incomplete`.
+ shell 调用输出的状态。可选值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -93773,7 +93749,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -93781,15 +93757,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -93805,7 +93781,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的 diff 创建新文件。
- `"create_file"`
@@ -93819,7 +93795,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "delete_file"`
- 删除指定的文件。
+ 删除指定文件。
- `"delete_file"`
@@ -93837,13 +93813,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "update_file"`
- 使用提供的差异更新现有文件。
+ 使用提供的 diff 更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -93851,7 +93827,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -93881,19 +93857,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -93901,7 +93877,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -93935,7 +93911,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -93943,11 +93919,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -93955,14 +93931,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -93974,7 +93950,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -94012,7 +93988,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -94020,29 +93996,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -94050,29 +94026,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `id: string`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -94104,7 +94080,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -94138,7 +94114,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -94155,11 +94131,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -94167,8 +94143,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -94208,7 +94184,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `parallel_tool_calls: boolean`
@@ -94216,8 +94192,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `temperature: number or null`
- 使用的采样温度,介于 0 到 2 之间。较高的值(例如 0.8)会使输出更加随机,而较低的值(例如 0.2)会使输出更加聚焦和确定。
- 我们通常建议修改此参数或 `top_p` 但不要同时修改两者。
+ 使用的采样温度,介于 0 到 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加聚焦和确定性。
+ 我们通常建议调整此项或 `top_p` 但不要同时调整两者。
- `tool_choice: ToolChoiceOptions or ToolChoiceAllowed or ToolChoiceTypes or 6 more`
@@ -94227,9 +94203,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceOptions = "none" or "auto" or "required"`
- 控制模型调用哪个工具(如果有的话)。
+ 控制模型调用哪个工具(如果有)。
- `none` 表示模型不会调用任何工具,而是生成一条消息。
+ `none` 表示模型将不会调用任何工具,而是生成一条消息。
`auto` 表示模型可以在生成消息或调用一个或
多个工具之间进行选择。
@@ -94261,7 +94237,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of map[unknown]`
- 模型应允许调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -94282,11 +94258,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceTypes object { type }`
指示模型应使用内置工具来生成响应。
- [了解有关内置工具的更多信息](/docs/guides/tools).
+ [了解更多关于内置工具的信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
- 模型应使用的托管工具类型。了解更多关于
+ 模型应使用的 托管工具 类型。了解更多关于
[内置工具](/docs/guides/tools).
允许的值为:
@@ -94331,7 +94307,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceMcp object { server_label, type, name }`
- 使用此选项可以强制模型调用远程 MCP 服务器上的特定工具。
+ 使用此选项可强制模型调用远程 MCP 服务器上的特定工具。
- `server_label: string`
@@ -94349,7 +94325,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceCustom object { name, type }`
- 使用此选项可以强制模型调用特定的自定义工具。
+ 使用此选项可强制模型调用特定的自定义工具。
- `name: string`
@@ -94365,27 +94341,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "programmatic_tool_calling"`
- 要调用的工具。始终为 `programmatic_tool_calling`.
+ 要调用的工具。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ToolChoiceApplyPatch object { type }`
- 在执行工具调用时强制模型调用 apply_patch 工具。
+ 强制模型在执行工具调用时调用 apply_patch 工具。
- `type: "apply_patch"`
- 要调用的工具。始终为 `apply_patch`.
+ 要调用的工具。始终 `apply_patch`.
- `"apply_patch"`
- `ToolChoiceShell object { type }`
- 在需要工具调用时强制模型调用 shell 工具。
+ 在需要工具调用时,强制模型调用 shell 工具。
- `type: "shell"`
- 要调用的工具。始终为 `shell`.
+ 要调用的工具。始终 `shell`.
- `"shell"`
@@ -94396,18 +94372,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
我们支持以下类别的工具:
- - **内置工具**:由 OpenAI 提供的工具,用于扩展模型的
- 能力,例如 [网页搜索](/docs/guides/tools-web-search)
+ - **内置工具**:由 OpenAI 提供的工具,用于扩展
+ 模型的能力,例如 [网页搜索](/docs/guides/tools-web-search)
或 [文件搜索](/docs/guides/tools-file-search)。详细了解
[内置工具](/docs/guides/tools).
- - **MCP 工具**:通过自定义 MCP 服务器与第三方系统集成
- 或 Google Drive 和 SharePoint 等预定义连接器。详细了解
+ - **MCP 工具**: 通过自定义 MCP 服务器与第三方系统集成
+ 或使用 Google Drive 和 SharePoint 等预定义连接器。详细了解
[MCP 工具](/docs/guides/tools-connectors-mcp).
- - **函数调用(自定义工具)**:由你定义的函数,
+ - **函数调用(自定义工具)**: 由你定义的函数,
使模型能够使用强类型参数和输出调用你自己的代码。详细了解
。你也可以使用
- [function calling](/docs/guides/function-calling)。你还可以使用
- 自定义工具调用你自己的代码。
+ [function calling](/docs/guides/function-calling). 你也可以使用
+ 自定义工具来调用你自己的代码。
- `Function object { name, parameters, strict, 5 more }`
@@ -94441,45 +94417,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -94487,7 +94463,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -94499,7 +94475,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -94507,21 +94483,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -94547,18 +94523,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -94566,22 +94542,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -94591,23 +94567,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -94618,11 +94594,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -94640,21 +94616,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -94662,14 +94638,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -94701,32 +94677,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -94734,13 +94710,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -94748,9 +94724,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -94762,22 +94738,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -94786,7 +94762,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -94796,7 +94772,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -94852,7 +94828,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -94862,11 +94838,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -94876,7 +94852,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -94884,7 +94860,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -94893,13 +94869,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -94908,7 +94884,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -94935,7 +94911,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -94946,7 +94922,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -94963,13 +94939,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -94985,7 +94961,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -94995,7 +94971,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -95021,11 +94997,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -95051,19 +95027,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -95083,19 +95059,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -95103,11 +95079,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -95153,7 +95129,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -95165,11 +95141,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -95183,7 +95159,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -95193,7 +95169,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -95203,23 +95179,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -95237,12 +95213,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `top_p: number or null`
- 一种名为核采样的温度采样替代方案,
- 其中模型会考虑 top_p 概率质量排名前列的词元结果。
- 因此,0.1 表示仅考虑构成前 10% 概率质量的词元。
+ 一种温度采样的替代方法,称为核采样,
+ 模型会考虑概率质量排名前 top_p 的标记的结果。
+ 因此 0.1 表示仅考虑构成前 10% 概率质量的标记。
会被考虑。
- 我们通常建议修改此参数或 `temperature` 但不要同时修改两者。
+ 我们通常建议调整此项或 `temperature` 但不要同时调整两者。
- `background: optional boolean or null`
@@ -95251,44 +95227,44 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `completed_at: optional number or null`
- 此 Response 完成时的 Unix 时间戳(以秒为单位)。
- 仅当状态为 `completed`.
+ 此响应完成时的 Unix 时间戳(以秒为单位)。
+ 仅在状态为 `completed`.
- `conversation: optional object { id } or null`
- 此响应所属的对话。此响应的输入项和输出项已自动添加到此对话。
+ 此响应所属的对话。此次响应的输入项和输出项已自动添加到此对话中。
- `id: string`
- 与此响应关联的对话的唯一 ID。
+ 此响应关联的对话的唯一 ID。
- `max_output_tokens: optional number or null`
- 一次响应中可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
+ 响应可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
- `max_tool_calls: optional number or null`
- 响应中可以处理的内置工具调用总次数上限。该上限适用于所有内置工具调用,而非单个工具。模型任何进一步的工具调用尝试都将被忽略。
+ 一次响应中可处理的内置工具调用总次数上限。该上限适用于所有内置工具调用的总和,而非单个工具。模型后续任何再次调用工具的尝试都将被忽略。
- `moderation: optional object { input, output } or null`
- 响应输入和输出的审核结果,前提是请求了已审核的补全。
+ 响应输入与输出的内容审核结果,前提是请求了经过审核的补全。
- `input: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输入的审核结果。
+ 对响应输入的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -95296,7 +95272,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -95304,17 +95280,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -95326,25 +95302,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输出的审核结果。
+ 对响应输出的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -95352,7 +95328,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -95360,17 +95336,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -95382,21 +95358,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output_text: optional string or null`
- 仅限SDK的便捷属性,包含所有输出消息中聚合的文本输出
- 来自所有 `output_text` 数组中的 `output` 条目(如果有)。
+ SDK 独有的便捷属性,包含来自所有
+ 的聚合文本输出 `output_text` 数组中的 `output` 条目(如有)。
在 Python 和 JavaScript SDK 中受支持。
- `previous_response_id: optional string or null`
- 模型上一次响应的唯一 ID。使用它来
- 创建多轮对话。了解有关
- [对话状态](/docs/guides/conversation-state)。的更多信息。不能与 `conversation`.
+ 上一个模型响应的唯一 ID。使用它可以
+ 创建多轮对话。详细了解
+ [conversation state](/docs/guides/conversation-state)。不能与 `conversation`.
- `prompt: optional ResponsePrompt or null`
@@ -95409,19 +95385,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `variables: optional map[string or ResponseInputText or ResponseInputImage or ResponseInputFile] or null`
- 用于替换提示模板中变量的可选值映射,
- prompt。替换值可以是字符串,也可以是其他
- Response 输入类型,例如图像或文件。
+ 用于替换你
+ prompt。替换的值可以是字符串,也可以是其他
+ Response 输入类型,如图像或文件。
- `string`
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -95429,19 +95405,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `version: optional string or null`
- 提示模板的可选版本。
+ prompt 模板的可选版本。
- `prompt_cache_key: optional string or null`
- 由 OpenAI 用于缓存相似请求的响应,以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
+ 由OpenAI使用,为相似请求缓存响应以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
- `prompt_cache_options: optional object { mode, ttl }`
- 应用于该响应的提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。
+ 应用于该响应的 prompt 缓存选项。支持以下 `gpt-5.6` 及更高版本的模型。
- `mode: "implicit" or "explicit"`
- 是否启用了隐式提示缓存断点。
+ 是否启用了隐式 prompt 缓存断点。
- `"implicit"`
@@ -95449,24 +95425,24 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ttl: "30m"`
- 应用于每个缓存断点的最短生存时间。
+ 应用于每个缓存断点的最短生命周期。
- `"30m"`
- `prompt_cache_retention: optional "in_memory" or "24h" or null`
- 已弃用。请使用 `prompt_cache_options.ttl` 相反。
+ 已弃用。请使用 `prompt_cache_options.ttl` 改为。
- 提示词缓存的保留策略。设置为 `24h` 以启用扩展提示词缓存,使缓存前缀保持更长时间,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
- 此字段表示最长保留策略,而
+ 提示缓存的保留策略。设置为 `24h` 以启用扩展提示缓存,使缓存的前缀保持更长时间有效,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
+ 该字段表示最大保留策略,而
`prompt_cache_options.ttl` 表示最短缓存生命周期。这两个
- 字段彼此独立,不会相互影响。
- 对于 `gpt-5.5`, `gpt-5.5-pro`,及未来模型,仅 `24h` 受支持。
+ 字段是独立的,不会相互影响。
+ 对于 `gpt-5.5`, `gpt-5.5-pro`,以及未来的模型,仅 `24h` 。
对于同时支持两者的旧模型 `in_memory` 和 `24h`,默认值取决于你组织的数据保留策略:
- - 未启用 ZDR 的组织默认使用 `24h`.
- - 启用 ZDR 的组织默认使用 `in_memory` 当 `prompt_cache_retention` 未指定时。
+ - 未启用 ZDR 的组织默认为 `24h`.
+ - 启用 ZDR 的组织默认为 `in_memory` 当 `prompt_cache_retention` 未指定时。
- `"in_memory"`
@@ -95474,18 +95450,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `reasoning: optional Reasoning or null`
- 配置选项,适用于
+ 适用于
[推理模型](https://platform.openai.com/docs/guides/reasoning).
- `context: optional "auto" or "current_turn" or "all_turns" or null`
- 控制在后续轮次中呈现回模型的推理项。
- 如果省略或设置为 `auto`,则由模型确定上下文模式。
+ 控制在后续回合中哪些推理项会被回传给模型。
+ 如果省略或设置为 `auto`,则由模型决定上下文模式。
`gpt-5.6` 模型系列默认为 `all_turns`;早期模型默认为
`current_turn`.
- 在响应中返回时,这是该响应使用的有效推理上下文模式
- 。
+ 在响应中返回时,这是该响应所使用 的有效推理上下文模式
+ 用于该响应。
- `"auto"`
@@ -95495,13 +95471,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `effort: optional ReasoningEffort or null`
- 限制推理模型在推理上的投入程度。当前支持的值
- 包括 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
- 降低推理投入程度可以让响应更快,并减少响应中推理所用的 token 数。并非所有推理模型都支持每个
- 值。请参阅
- 推理指南
+ 限制推理模型在推理上的投入程度。目前支持
+ 的取值有 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
+ 降低推理投入程度可以让响应更快,并减少响应中用于推理的 token
+ 数量。并非所有推理模型都支持每个
+ 取值。有关各模型的支持情况,请参阅
[推理指南](https://platform.openai.com/docs/guides/reasoning)
- 以了解特定模型的支持情况。
+ 。
- `"none"`
@@ -95519,11 +95495,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `generate_summary: optional "auto" or "concise" or "detailed" or null`
- **已弃用:** 请使用 `summary` 相反。
+ **已弃用:** 请使用 `summary` 改为。
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `"auto"`
@@ -95535,7 +95511,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `string`
@@ -95543,7 +95519,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `"standard"`
@@ -95551,11 +95527,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `summary: optional "auto" or "concise" or "detailed" or null`
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `concise` 支持以下模型 `computer-use-preview` 以及之后的所有推理模型 `gpt-5`.
+ `concise` 支持用于 `computer-use-preview` 模型以及之后的 `gpt-5`.
- `"auto"`
@@ -95565,21 +95541,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `safety_identifier: optional string or null`
- 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用策略的应用程序用户。
- ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份识别信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用政策的应用用户。
+ ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `service_tier: optional ServiceTier or null`
指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
+ - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则该项目将使用 'default'。
- 如果设置为 'default',则该请求将使用所选模型的标准定价和性能进行处理。
- 如果设置为 '[flex](/docs/guides/flex-processing)',则该请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别选择启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 `service_tier=fast` 或 `service_tier=priority` 参数用于 Responses 或 Chat Completions。响应将显示 `service_tier=priority` ,无论你是否在请求中指定了 `service_tier=fast` 或 `priority` 。
- - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级返回的响应将显示 `service_tier=ultrafast`.
- - 如果未设置,默认行为是 'auto'。
+ - 若要在请求级别启用 [快速模式](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过它处理的响应将显示 `service_tier=ultrafast`.
+ - 未设置时,默认行为为 'auto'。
- 当设置 `service_tier` 参数时,响应正文将包含基于实际用于处理该请求的处理模式的 `service_tier` 值。此响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应体中将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。此响应中的值可能与该参数中设置的值不同。
- `"auto"`
@@ -95597,8 +95573,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional ResponseStatus`
- 响应生成的状态。取值之一为 `completed`, `failed`,
- `in_progress`, `cancelled`, `queued`, or `incomplete`.
+ 响应生成的状态。可选值为 `completed`, `failed`,
+ `in_progress`, `cancelled`, `queued`,或 `incomplete`.
- `"completed"`
@@ -95614,8 +95590,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: optional ResponseTextConfig`
- 用于配置模型文本响应的选项。可以是纯文本,也可以是结构化的 JSON 数据。详见:
- 文本输入与输出:
+ 模型文本响应的配置选项。可以是纯
+ 文本或结构化 JSON 数据。了解更多:
- [文本输入与输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
@@ -95624,79 +95600,79 @@ curl https://api.openai.com/v1/responses/resp_123 \
用于指定模型必须输出的格式的对象。
- 设置为 `{ "type": "json_schema" }` 时,将启用结构化输出,
- 功能,从而确保模型的输出与你提供的 JSON schema 相匹配。详见
+ 配置 `{ "type": "json_schema" }` 可启用结构化输出,
+ 从而确保模型匹配你提供的 JSON schema。更多信息请参阅
[结构化输出指南](/docs/guides/structured-outputs).
- 默认的格式为 `{ "type": "text" }` ,且不包含其他选项。
+ 默认格式为 `{ "type": "text" }` ,不包含任何额外选项。
- **不建议在 gpt-4o 及更新模型上使用:**
+ **不推荐用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
- 的模型,建议优先使用该格式。
+ 设置为 `{ "type": "json_object" }` 会启用旧版 JSON 模式,该模式
+ 可确保模型生成的消息是合法 JSON。对于支持 `json_schema`
+ 的模型,建议优先使用它。
- `ResponseFormatText object { type }`
- 默认的响应格式。用于生成文本响应。
+ 默认响应格式。用于生成文本响应。
- `type: "text"`
- 正在定义的响应格式的类型。始终为 `text`.
+ 正在定义的响应格式类型。始终为 `text`.
- `"text"`
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化的 JSON 响应。
+ JSON Schema 响应格式。用于生成结构化 JSON 响应。
详细了解 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
- 下划线和连字符,最大长度为 64。
+ 下划线和短横线,最大长度为 64。
- `schema: map[unknown]`
- 响应格式的 schema,以 JSON Schema 对象描述。
- 了解如何构建 JSON schema [此处](https://json-schema.org/).
+ 响应格式的架构,以 JSON Schema 对象形式描述。
+ 了解如何构建 JSON 架构 [此处](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式的类型。始终为 `json_schema`.
+ 正在定义的响应格式类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
响应格式用途的描述,供模型用于
- 确定如何按该格式进行响应。
+ 确定如何按该格式响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 一致性。
- 如果设置为 true,模型将始终遵循
- 字段中 `schema` 定义的精确 schema。仅支持 JSON Schema 的一个子集,当
- `strict` 是 `true`。要了解更多信息,请阅读 [Structured Outputs
+ 生成输出时是否启用严格的架构遵循。
+ 如果设置为 true,模型将始终遵循 字段中定义的
+ 确切架构。当 设置为 `schema` true 时,仅支持 JSON Schema 的一个子集
+ `strict` 是 `true`。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较早的生成 JSON 响应的方法。
- 使用 `json_schema` 对支持它的模型是推荐的做法。请注意
- 模型在没有系统或用户消息指示的情况下不会生成
- JSON。
+ JSON 对象响应格式。一种较旧的 JSON 响应生成方法。建议。
+ 对于支持 的模型,使用 `json_schema` 。请注意,模型不会在没有系统或用户消息指示
+ 的情况下生成 JSON
+ 。
- `type: "json_object"`
- 正在定义的响应格式的类型。始终为 `json_object`.
+ 正在定义的响应格式类型。始终为 `json_object`.
- `"json_object"`
- `verbosity: optional "low" or "medium" or "high" or null`
- 约束模型响应的详细程度。较低的值会产生
- 更简洁的响应,较高的值会产生更详细的响应。
+ 约束模型响应的详尽程度。较低的值将导致
+ 更简洁的响应,而较高的值将导致更冗长的响应。
当前支持的值包括 `low`, `medium`,和 `high`。默认值为
`medium`.
@@ -95708,20 +95684,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `top_logprobs: optional number or null`
- 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的最大最可能
- token 数量,每个 token 都附带对应的对数
+ 一个介于 0 到 20 之间的整数,指定在每个 token 位置返回的
+ 最可能 token 的最大数量,每个 token 都有一个关联的对数
概率。在某些情况下,返回的 token 数量可能少于
- 所请求的数量。
+ 请求的数量。
- `truncation: optional "auto" or "disabled" or null`
用于模型响应的截断策略。
- - `auto`:如果此 Response 的输入超过
- 模型的上下文窗口大小,模型将通过从对话开头丢弃条目来截断
- 响应以适配上下文窗口。
- - `disabled` (默认):如果输入大小将超出模型的上下文窗口
- 大小,请求将失败并返回 400 错误。
+ - `auto`:如果此 Response 的输入超出
+ 模型的上下文窗口大小,模型将通过从对话开头
+ 丢弃条目来截断响应以适配上下文窗口。
+ - `disabled` (默认):如果输入大小将超过模型的上下文窗口
+ 大小,请求将以 400 错误失败。
- `"auto"`
@@ -95730,7 +95706,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `usage: optional ResponseUsage`
表示 token 使用详情,包括输入 token、输出 token,
- 的输出 token 明细,以及所使用的 token 总数。
+ 输出 token 的细分,以及使用的总 token 数。
- `input_tokens: number`
@@ -95738,16 +95714,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_tokens_details: object { cache_write_tokens, cached_tokens }`
- 输入 token 的详细明细。
+ 输入 token 的详细细分。
- `cache_write_tokens: number`
- 已写入缓存的输入 token 数量。
+ 写入缓存的输入 token 的数量。
- `cached_tokens: number`
- 从缓存中检索到的 token 数量。
- [了解更多关于提示缓存的信息](/docs/guides/prompt-caching).
+ 从缓存中检索到的 token 的数量。
+ [有关 prompt caching 的更多信息](/docs/guides/prompt-caching).
- `output_tokens: number`
@@ -95755,25 +95731,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_tokens_details: object { reasoning_tokens }`
- 输出令牌的详细明细。
+ 输出 token 的详细明细。
- `reasoning_tokens: number`
- 推理令牌的数量。
+ 推理 token 的数量。
- `total_tokens: number`
- 使用的令牌总数。
-
- - `compute_units: optional number or null`
-
- 该请求的计算单元。在可用时当前为 null。
+ 使用的 token 总数。
- `user: optional string`
- 此字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
- 用于标识你的最终用户的稳定标识符。
- 通过更好地对相似请求进行分桶以提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 该字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
+ 你的最终用户的稳定标识符。
+ 通过更好地对相似请求进行分桶来提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `sequence_number: number`
@@ -95789,16 +95761,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseIncludable = "file_search_call.results" or "web_search_call.results" or "web_search_call.action.sources" or 5 more`
- 指定要在模型响应中包含的其他输出数据。目前支持的值包括:
+ 指定要包含在模型响应中的其他输出数据。目前支持的值包括:
- - `web_search_call.results`: 包含 网页搜索 工具调用的搜索结果。
- - `web_search_call.action.sources`:包含 网页搜索 工具调用的来源。
- - `code_interpreter_call.outputs`:在代码解释器工具调用条目中包含 Python 代码执行的输出。
- - `computer_call_output.output.image_url`:包含来自计算机调用输出的图片 URL。
- - `file_search_call.results`:包含 文件搜索 工具调用的搜索结果。
- - `message.input_image.image_url`:包含来自输入消息的图片 URL。
- - `message.output_text.logprobs`:在助手消息中包含 logprobs。
- - `reasoning.encrypted_content`:在推理条目的输出中包含加密版本的推理 token。这使得在使用 Responses API 以无状态方式处理多轮对话时能够使用推理条目(例如 `store` 参数设置为 `false`,时,或组织已加入零数据留存计划时)。
+ - `web_search_call.results`:包含 网页搜索 工具调用的搜索结果。
+ - `web_search_call.action.sources`: 包含网页搜索工具调用的来源。
+ - `code_interpreter_call.outputs`: 在代码解释器工具调用项中包含 Python 代码执行的输出。
+ - `computer_call_output.output.image_url`: 包含来自 computer call 输出的图片链接。
+ - `file_search_call.results`: 包含文件搜索工具调用的搜索结果。
+ - `message.input_image.image_url`: 包含来自输入消息的图片链接。
+ - `message.output_text.logprobs`: 在助手消息中包含 logprobs。
+ - `reasoning.encrypted_content`: 在推理项输出中包含加密版本的推理 token。这使得在使用Responses API无状态调用时(例如当 `store` 参数设置为 `false`,或组织加入了零数据保留计划时),可以在多轮对话中使用推理项。
- `"file_search_call.results"`
@@ -95820,11 +95792,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseIncompleteEvent object { response, sequence_number, type }`
- 当响应以不完整状态结束时发出的事件。
+ 当响应未完成时发出的事件。
- `response: Response`
- 不完整的响应。
+ 未完成的响应。
- `id: string`
@@ -95832,7 +95804,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_at: number`
- 创建此 Response 时的 Unix 时间戳(以秒为单位)。
+ 此 Response 创建时的 Unix 时间戳(以秒为单位)。
- `error: ResponseError or null`
@@ -95888,87 +95860,89 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `incomplete_details: object { reason } or null`
- 有关响应未完成原因的详细信息。
+ 有关响应不完整的详细原因。
- - `reason: optional "max_output_tokens" or "content_filter"`
+ - `reason: optional "max_output_tokens" or "max_messages" or "content_filter"`
- 响应未完成的原因。
+ 响应不完整的原因。
- `"max_output_tokens"`
+ - `"max_messages"`
+
- `"content_filter"`
- `instructions: string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more or null`
插入到模型上下文中的系统(或开发者)消息。
- 当与 `previous_response_id`,配合使用时,前一次
- 响应的指令不会延续到下一次响应。这便于在新响应中
- 替换系统(或开发者)消息。
+ 当与 `previous_response_id`,配合使用时,上一个
+ response 中的 instructions 不会延续到下一个 response。这样可以轻松地
+ 在新的 response 中替换系统(或开发者)消息。
- `string`
- 发送给模型的文本输入,相当于使用
+ 发送给模型的文本输入,等同于
`developer` 角色的文本输入。
- `InputItemList = array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 发送给模型的一个或多个输入项的列表,包含
+ 发送给模型的一个或多个输入项列表,包含
不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` role. Messages with the
- `assistant` role are presumed to have been generated by the model in previous
- interactions.
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色给出的指令。带有
+ `assistant` 角色的消息被视为模型在之前的
+ 交互中生成。
- `content: string or ResponseInputMessageContentList`
- Text, image, or audio input to the model, used to generate a response.
- Can also contain previous assistant responses.
+ 发送给模型的文本、图像或音频输入,用于生成响应。
+ 也可以包含之前的助手响应。
- `TextInput = string`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputMessageContentList = array of ResponseInputContent`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -95980,25 +95954,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -96008,13 +95982,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -96024,33 +95998,33 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `assistant`, `system`, or
+ 消息输入的角色。其一为 接口 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -96063,9 +96037,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -96073,24 +96047,24 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: optional "message"`
- 消息输入的类型。始终为 `message`.
+ 消息输入的类型。始终为 接口 `message`.
- `"message"`
- `Message object { content, role, status, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` 角色的文本输入。
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色的文本输入。
- `content: ResponseInputMessageContentList`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `system`, or `developer`.
+ 消息输入的角色。其一为 接口 `user`, `system`,或 `developer`.
- `"user"`
@@ -96100,8 +96074,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -96121,7 +96095,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -96129,15 +96103,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -96153,7 +96127,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -96163,25 +96137,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -96193,7 +96167,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -96201,11 +96175,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -96259,15 +96233,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -96279,8 +96253,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -96296,9 +96270,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -96306,8 +96280,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -96319,7 +96293,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -96344,11 +96318,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -96366,7 +96340,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -96375,7 +96349,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -96387,7 +96361,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -96403,8 +96377,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -96428,7 +96402,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -96442,7 +96416,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -96468,7 +96442,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -96486,7 +96460,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -96505,7 +96479,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -96515,11 +96489,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -96539,15 +96513,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -96579,19 +96553,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -96615,8 +96589,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -96632,7 +96606,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -96648,7 +96622,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -96656,44 +96630,44 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCallOutput object { call_id, output, type, 3 more }`
- 一次 computer 工具调用的输出。
+ 计算机工具调用的输出。
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `id: optional string or null`
- computer 工具调用输出的 ID。
+ 计算机工具调用输出的 ID。
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 已被开发者确认的 API 所报告的安全检查结果。
+ 开发者已确认的 API 所报告的安全检查。
- `id: string`
@@ -96709,7 +96683,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值为 `in_progress`, `completed`, or `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -96720,7 +96694,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -96728,12 +96702,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -96743,11 +96717,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -96765,7 +96739,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -96779,7 +96753,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -96797,7 +96771,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -96809,14 +96783,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -96866,8 +96840,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -96881,7 +96855,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: string or array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的文本、图片或文件输出。
+ 函数工具调用的文本、图像或文件输出。
- `string`
@@ -96889,61 +96863,61 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的内容输出(文本、图片、文件)数组。
+ 函数工具调用的内容输出(文本、图像、文件)数组。
- `ResponseInputTextContent object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision)
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `detail: optional ImageDetail or null`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -96953,13 +96927,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -96973,23 +96947,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -97001,7 +96975,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string or null`
- 函数工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
+ 函数工具调用输出的唯一 ID。当此项通过 API 返回时填充。
- `call_id: optional string or null`
@@ -97041,7 +97015,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -97057,7 +97031,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目类型。始终为 `tool_search_call`.
+ 项的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
@@ -97125,37 +97099,37 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -97168,11 +97142,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -97192,7 +97166,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -97208,15 +97182,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -97230,7 +97204,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -97238,7 +97212,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -97250,7 +97224,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -97258,21 +97232,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -97298,18 +97272,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -97317,22 +97291,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -97342,23 +97316,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -97369,11 +97343,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -97391,21 +97365,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -97413,14 +97387,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -97452,32 +97426,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -97485,13 +97459,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -97499,9 +97473,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -97513,22 +97487,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -97537,7 +97511,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -97547,7 +97521,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -97577,29 +97551,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -97635,7 +97609,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -97645,11 +97619,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -97659,7 +97633,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -97667,7 +97641,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -97676,13 +97650,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -97691,7 +97665,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -97718,7 +97692,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -97729,7 +97703,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -97746,13 +97720,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -97768,7 +97742,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -97778,7 +97752,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -97802,7 +97776,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -97826,13 +97800,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -97856,7 +97830,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -97864,13 +97838,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -97890,7 +97864,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -97902,13 +97876,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -97922,11 +97896,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -97952,7 +97926,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -97970,7 +97944,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -97984,19 +97958,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -98016,19 +97990,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -98036,11 +98010,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -98086,7 +98060,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -98098,11 +98072,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -98116,7 +98090,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -98126,7 +98100,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -98136,23 +98110,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -98170,13 +98144,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目类型。始终为 `tool_search_output`.
+ 项的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `id: optional string or null`
- 此工具搜索输出的唯一 ID。
+ 该工具搜索输出的唯一 ID。
- `call_id: optional string or null`
@@ -98204,13 +98178,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `role: "developer"`
- 提供其他工具的角色。仅 `developer` 受支持。
+ 提供这些额外工具的角色。仅支持 `developer` 。
- `"developer"`
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 此项目提供的其他工具列表。
+ 在该条目中提供的额外工具列表。
- `Function object { name, parameters, strict, 5 more }`
@@ -98244,45 +98218,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -98290,7 +98264,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -98302,7 +98276,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -98310,21 +98284,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -98350,18 +98324,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -98369,22 +98343,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -98394,23 +98368,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -98421,11 +98395,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -98443,21 +98417,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -98465,14 +98439,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -98504,32 +98478,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -98537,13 +98511,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -98551,9 +98525,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -98565,22 +98539,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -98589,7 +98563,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -98599,7 +98573,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -98655,7 +98629,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -98665,11 +98639,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -98679,7 +98653,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -98687,7 +98661,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -98696,13 +98670,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -98711,7 +98685,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -98738,7 +98712,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -98749,7 +98723,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -98766,13 +98740,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -98788,7 +98762,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -98798,7 +98772,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -98824,11 +98798,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -98854,19 +98828,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -98886,19 +98860,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -98906,11 +98880,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -98956,7 +98930,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -98968,11 +98942,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -98986,7 +98960,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -98996,7 +98970,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -99006,23 +98980,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -99040,19 +99014,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目类型。始终为 `additional_tools`.
+ 项的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `id: optional string or null`
- 此其他工具项目的唯一 ID。
+ 该额外工具条目的唯一 ID。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -99065,7 +99039,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -99085,7 +99059,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -99095,20 +99069,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -99118,7 +99092,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Compaction object { encrypted_content, type, id }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -99126,17 +99100,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `id: optional string or null`
- 压缩条目的 ID。
+ 压缩项的 ID。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -99160,7 +99134,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -99183,7 +99157,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -99195,23 +99169,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -99229,13 +99203,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -99251,11 +99225,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -99269,11 +99243,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -99287,7 +99261,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -99297,7 +99271,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -99305,13 +99279,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -99325,7 +99299,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
@@ -99337,7 +99311,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最大挂钟时间(毫秒)。
+ 允许 shell 命令运行的 wall-clock 最长时间(毫秒)。
- `call_id: string`
@@ -99345,13 +99319,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
- `id: optional string or null`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -99387,7 +99361,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -99397,7 +99371,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ShellCallOutput object { call_id, output, type, 4 more }`
- shell 工具调用发出的流式输出项。
+ shell 工具调用发出的流式输出条目。
- `call_id: string`
@@ -99405,7 +99379,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: array of ResponseFunctionShellCallOutputContent`
- stdout 和 stderr 输出的捕获块及其关联结果。
+ 捕获的 stdout 和 stderr 输出块,以及它们关联的结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -99417,13 +99391,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -99431,27 +99405,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
- `stderr: string`
- shell 调用捕获的 stderr 输出。
+ 为该 shell 调用捕获的 stderr 输出。
- `stdout: string`
- shell 调用捕获的 stdout 输出。
+ 为该 shell 调用捕获的 stdout 输出。
- `type: "shell_call_output"`
- 条目的类型,恒为 `shell_call_output`.
+ item 的类型。始终为 `shell_call_output`.
- `"shell_call_output"`
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -99493,11 +99467,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 表示使用 diff 补丁创建、删除或更新文件的工具调用。
+ 表示通过 diff 补丁创建、删除或更新文件的工具调用。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
@@ -99509,7 +99483,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 创建文件时要应用的统一 diff 内容。
+ 创建文件时应用的 unified diff 内容。
- `path: string`
@@ -99541,7 +99515,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 要应用于现有文件的统一 diff 内容。
+ 应用于现有文件的 unified diff 内容。
- `path: string`
@@ -99555,7 +99529,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -99563,13 +99537,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
- `id: optional string or null`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -99597,15 +99571,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { call_id, status, type, 3 more }`
- apply patch 工具调用发出的流式输出。
+ 由 apply patch 工具调用发出的流式输出。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -99613,13 +99587,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
- `id: optional string or null`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -99675,7 +99649,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -99683,29 +99657,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -99713,31 +99687,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { approval_request_id, approve, type, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
- `id: optional string or null`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `reason: optional string or null`
@@ -99745,7 +99719,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -99753,11 +99727,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -99765,14 +99739,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -99812,7 +99786,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -99826,11 +99800,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 由你的代码生成的自定义工具调用输出,将被发送回模型。
+ 由你的代码生成的自定义工具调用的输出,将发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -99847,11 +99821,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -99865,7 +99839,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- 自定义工具调用输出在 OpenAI 平台中的唯一 ID。
+ 在 OpenAI 平台中该自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -99915,7 +99889,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -99943,11 +99917,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompactionTrigger object { type, id }`
- 压缩当前上下文。必须是最后一个输入项。
+ 压缩当前上下文。必须作为最后一个输入项。
- `type: "compaction_trigger"`
- 条目的类型,恒为 `compaction_trigger`.
+ item 的类型。始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -99961,11 +99935,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 要引用的条目 ID。
+ 被引用条目的 ID。
- `type: optional "item_reference" or null`
- 要引用的条目类型。始终为 `item_reference`.
+ 被引用条目的类型。始终为 `item_reference`.
- `"item_reference"`
@@ -99981,7 +99955,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -99989,7 +99963,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目类型。始终为 `program`.
+ 项的类型。始终为 `program`.
- `"program"`
@@ -100005,7 +99979,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -100017,14 +99991,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目类型。始终为 `program_output`.
+ 项的类型。始终为 `program_output`.
- `"program_output"`
- `metadata: Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
格式,以及通过 API 或控制台查询对象。
键为字符串,最长 64 个字符。值为字符串
@@ -100033,8 +100007,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: ResponsesModel`
用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI
- 提供了多种不同能力、性能
- 特性和定价的模型。请参阅 [模型指南](/docs/models)
+ 提供了众多功能、性能
+ 特性和价位各异的模型。请参阅 [模型指南](/docs/models)
以浏览和比较可用的模型。
- `string`
@@ -100257,12 +100231,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
由模型生成的内容项数组。
- - 该数组中项的数量和顺序 `output` 取决于
- 模型的响应。
- - 与直接访问该数组的 `output` 第一项并
- 假设它是一 `assistant` 个包含模型生成内容的
- 消息相比,你也可以考虑使用 `output_text` 属性(在
- 受支持的 SDK 中可用)。
+ - 该数组中项的长度和顺序取决于 `output` 模型的响应。
+ 与其访问。
+ - 数组中的第一项并 `output` 假设它是一个
+ 包含模型生成内容的 `assistant` 消息,不如使用
+ 属性(在受支持的 开发工具包 `output_text` 中可用)。
+ SDK。
- `ResponseOutputMessage object { id, content, role, 3 more }`
@@ -100270,8 +100244,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -100283,7 +100257,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -100308,11 +100282,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -100330,7 +100304,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -100339,7 +100313,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -100389,8 +100363,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -100415,15 +100389,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -100431,8 +100405,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -100476,7 +100450,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `name: optional string`
@@ -100489,7 +100463,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -100497,12 +100471,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -100512,11 +100486,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -100534,7 +100508,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -100548,7 +100522,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -100566,7 +100540,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -100578,14 +100552,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -100597,7 +100571,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -100613,8 +100587,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -100634,8 +100608,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `ComputerCallOutput object { id, call_id, output, 4 more }`
@@ -100645,16 +100619,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"completed"`
@@ -100666,13 +100640,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、已被
+ API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -100689,13 +100663,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -100708,7 +100682,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -100726,7 +100700,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -100736,20 +100710,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -100769,7 +100743,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -100777,7 +100751,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目的类型,恒为 `program`.
+ item 的类型。始终为 `program`.
- `"program"`
@@ -100793,7 +100767,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -100805,7 +100779,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目的类型,恒为 `program_output`.
+ item 的类型。始终为 `program_output`.
- `"program_output"`
@@ -100843,13 +100817,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目的类型,恒为 `tool_search_call`.
+ item 的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -100915,45 +100889,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -100961,7 +100935,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -100973,7 +100947,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -100981,21 +100955,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -101021,18 +100995,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -101040,22 +101014,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -101065,23 +101039,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -101092,11 +101066,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -101114,21 +101088,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -101136,14 +101110,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -101175,32 +101149,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -101208,13 +101182,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -101222,9 +101196,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -101236,22 +101210,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -101260,7 +101234,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -101270,7 +101244,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -101326,7 +101300,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -101336,11 +101310,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -101350,7 +101324,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -101358,7 +101332,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -101367,13 +101341,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -101382,7 +101356,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -101409,7 +101383,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -101420,7 +101394,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -101437,13 +101411,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -101459,7 +101433,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -101469,7 +101443,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -101495,11 +101469,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -101525,19 +101499,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -101557,19 +101531,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -101577,11 +101551,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -101627,7 +101601,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -101639,11 +101613,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -101657,7 +101631,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -101667,7 +101641,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -101677,23 +101651,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -101711,13 +101685,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目的类型,恒为 `tool_search_output`.
+ item 的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -101747,7 +101721,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -101781,45 +101755,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -101827,7 +101801,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -101839,7 +101813,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -101847,21 +101821,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -101887,18 +101861,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -101906,22 +101880,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -101931,23 +101905,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -101958,11 +101932,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -101980,21 +101954,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -102002,14 +101976,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -102041,32 +102015,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -102074,13 +102048,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -102088,9 +102062,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -102102,22 +102076,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -102126,7 +102100,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -102136,7 +102110,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -102192,7 +102166,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -102202,11 +102176,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -102216,7 +102190,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -102224,7 +102198,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -102233,13 +102207,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -102248,7 +102222,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -102275,7 +102249,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -102286,7 +102260,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -102303,13 +102277,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -102325,7 +102299,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -102335,7 +102309,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -102361,11 +102335,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -102391,19 +102365,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -102423,19 +102397,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -102443,11 +102417,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -102493,7 +102467,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -102505,11 +102479,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -102523,7 +102497,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -102533,7 +102507,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -102543,23 +102517,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -102577,13 +102551,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目的类型,恒为 `additional_tools`.
+ item 的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -102591,21 +102565,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的已加密内容。
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -102629,7 +102603,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -102652,7 +102626,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -102664,23 +102638,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -102698,13 +102672,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -102720,11 +102694,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -102738,11 +102712,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -102756,7 +102730,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -102766,7 +102740,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -102774,13 +102748,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -102794,17 +102768,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -102842,7 +102816,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -102852,7 +102826,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -102886,7 +102860,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。通过 API 返回该条目时填充此字段。
- `call_id: string`
@@ -102894,15 +102868,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -102910,13 +102884,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -102924,7 +102898,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -102938,11 +102912,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`, or `incomplete`.
+ shell 调用输出的状态。可选值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -102978,7 +102952,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -102986,15 +102960,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -103010,7 +102984,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的 diff 创建新文件。
- `"create_file"`
@@ -103024,7 +102998,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "delete_file"`
- 删除指定的文件。
+ 删除指定文件。
- `"delete_file"`
@@ -103042,13 +103016,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "update_file"`
- 使用提供的差异更新现有文件。
+ 使用提供的 diff 更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -103056,7 +103030,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -103086,19 +103060,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -103106,7 +103080,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -103140,7 +103114,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -103148,11 +103122,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -103160,14 +103134,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -103179,7 +103153,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -103217,7 +103191,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -103225,29 +103199,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -103255,29 +103229,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `id: string`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -103309,7 +103283,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -103343,7 +103317,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -103360,11 +103334,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -103372,8 +103346,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -103413,7 +103387,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `parallel_tool_calls: boolean`
@@ -103421,8 +103395,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `temperature: number or null`
- 使用的采样温度,介于 0 到 2 之间。较高的值(例如 0.8)会使输出更加随机,而较低的值(例如 0.2)会使输出更加聚焦和确定。
- 我们通常建议修改此参数或 `top_p` 但不要同时修改两者。
+ 使用的采样温度,介于 0 到 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加聚焦和确定性。
+ 我们通常建议调整此项或 `top_p` 但不要同时调整两者。
- `tool_choice: ToolChoiceOptions or ToolChoiceAllowed or ToolChoiceTypes or 6 more`
@@ -103432,9 +103406,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceOptions = "none" or "auto" or "required"`
- 控制模型调用哪个工具(如果有的话)。
+ 控制模型调用哪个工具(如果有)。
- `none` 表示模型不会调用任何工具,而是生成一条消息。
+ `none` 表示模型将不会调用任何工具,而是生成一条消息。
`auto` 表示模型可以在生成消息或调用一个或
多个工具之间进行选择。
@@ -103466,7 +103440,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of map[unknown]`
- 模型应允许调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -103487,11 +103461,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceTypes object { type }`
指示模型应使用内置工具来生成响应。
- [了解有关内置工具的更多信息](/docs/guides/tools).
+ [了解更多关于内置工具的信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
- 模型应使用的托管工具类型。了解更多关于
+ 模型应使用的 托管工具 类型。了解更多关于
[内置工具](/docs/guides/tools).
允许的值为:
@@ -103536,7 +103510,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceMcp object { server_label, type, name }`
- 使用此选项可以强制模型调用远程 MCP 服务器上的特定工具。
+ 使用此选项可强制模型调用远程 MCP 服务器上的特定工具。
- `server_label: string`
@@ -103554,7 +103528,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceCustom object { name, type }`
- 使用此选项可以强制模型调用特定的自定义工具。
+ 使用此选项可强制模型调用特定的自定义工具。
- `name: string`
@@ -103570,27 +103544,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "programmatic_tool_calling"`
- 要调用的工具。始终为 `programmatic_tool_calling`.
+ 要调用的工具。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ToolChoiceApplyPatch object { type }`
- 在执行工具调用时强制模型调用 apply_patch 工具。
+ 强制模型在执行工具调用时调用 apply_patch 工具。
- `type: "apply_patch"`
- 要调用的工具。始终为 `apply_patch`.
+ 要调用的工具。始终 `apply_patch`.
- `"apply_patch"`
- `ToolChoiceShell object { type }`
- 在需要工具调用时强制模型调用 shell 工具。
+ 在需要工具调用时,强制模型调用 shell 工具。
- `type: "shell"`
- 要调用的工具。始终为 `shell`.
+ 要调用的工具。始终 `shell`.
- `"shell"`
@@ -103601,18 +103575,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
我们支持以下类别的工具:
- - **内置工具**:由 OpenAI 提供的工具,用于扩展模型的
- 能力,例如 [网页搜索](/docs/guides/tools-web-search)
+ - **内置工具**:由 OpenAI 提供的工具,用于扩展
+ 模型的能力,例如 [网页搜索](/docs/guides/tools-web-search)
或 [文件搜索](/docs/guides/tools-file-search)。详细了解
[内置工具](/docs/guides/tools).
- - **MCP 工具**:通过自定义 MCP 服务器与第三方系统集成
- 或 Google Drive 和 SharePoint 等预定义连接器。详细了解
+ - **MCP 工具**: 通过自定义 MCP 服务器与第三方系统集成
+ 或使用 Google Drive 和 SharePoint 等预定义连接器。详细了解
[MCP 工具](/docs/guides/tools-connectors-mcp).
- - **函数调用(自定义工具)**:由你定义的函数,
+ - **函数调用(自定义工具)**: 由你定义的函数,
使模型能够使用强类型参数和输出调用你自己的代码。详细了解
。你也可以使用
- [function calling](/docs/guides/function-calling)。你还可以使用
- 自定义工具调用你自己的代码。
+ [function calling](/docs/guides/function-calling). 你也可以使用
+ 自定义工具来调用你自己的代码。
- `Function object { name, parameters, strict, 5 more }`
@@ -103646,45 +103620,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -103692,7 +103666,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -103704,7 +103678,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -103712,21 +103686,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -103752,18 +103726,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -103771,22 +103745,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -103796,23 +103770,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -103823,11 +103797,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -103845,21 +103819,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -103867,14 +103841,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -103906,32 +103880,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -103939,13 +103913,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -103953,9 +103927,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -103967,22 +103941,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -103991,7 +103965,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -104001,7 +103975,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -104057,7 +104031,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -104067,11 +104041,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -104081,7 +104055,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -104089,7 +104063,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -104098,13 +104072,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -104113,7 +104087,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -104140,7 +104114,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -104151,7 +104125,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -104168,13 +104142,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -104190,7 +104164,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -104200,7 +104174,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -104226,11 +104200,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -104256,19 +104230,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -104288,19 +104262,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -104308,11 +104282,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -104358,7 +104332,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -104370,11 +104344,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -104388,7 +104362,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -104398,7 +104372,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -104408,23 +104382,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -104442,12 +104416,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `top_p: number or null`
- 一种名为核采样的温度采样替代方案,
- 其中模型会考虑 top_p 概率质量排名前列的词元结果。
- 因此,0.1 表示仅考虑构成前 10% 概率质量的词元。
+ 一种温度采样的替代方法,称为核采样,
+ 模型会考虑概率质量排名前 top_p 的标记的结果。
+ 因此 0.1 表示仅考虑构成前 10% 概率质量的标记。
会被考虑。
- 我们通常建议修改此参数或 `temperature` 但不要同时修改两者。
+ 我们通常建议调整此项或 `temperature` 但不要同时调整两者。
- `background: optional boolean or null`
@@ -104456,44 +104430,44 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `completed_at: optional number or null`
- 此 Response 完成时的 Unix 时间戳(以秒为单位)。
- 仅当状态为 `completed`.
+ 此响应完成时的 Unix 时间戳(以秒为单位)。
+ 仅在状态为 `completed`.
- `conversation: optional object { id } or null`
- 此响应所属的对话。此响应的输入项和输出项已自动添加到此对话。
+ 此响应所属的对话。此次响应的输入项和输出项已自动添加到此对话中。
- `id: string`
- 与此响应关联的对话的唯一 ID。
+ 此响应关联的对话的唯一 ID。
- `max_output_tokens: optional number or null`
- 一次响应中可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
+ 响应可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
- `max_tool_calls: optional number or null`
- 响应中可以处理的内置工具调用总次数上限。该上限适用于所有内置工具调用,而非单个工具。模型任何进一步的工具调用尝试都将被忽略。
+ 一次响应中可处理的内置工具调用总次数上限。该上限适用于所有内置工具调用的总和,而非单个工具。模型后续任何再次调用工具的尝试都将被忽略。
- `moderation: optional object { input, output } or null`
- 响应输入和输出的审核结果,前提是请求了已审核的补全。
+ 响应输入与输出的内容审核结果,前提是请求了经过审核的补全。
- `input: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输入的审核结果。
+ 对响应输入的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -104501,7 +104475,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -104509,17 +104483,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -104531,25 +104505,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输出的审核结果。
+ 对响应输出的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -104557,7 +104531,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -104565,17 +104539,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -104587,21 +104561,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output_text: optional string or null`
- 仅限SDK的便捷属性,包含所有输出消息中聚合的文本输出
- 来自所有 `output_text` 数组中的 `output` 条目(如果有)。
+ SDK 独有的便捷属性,包含来自所有
+ 的聚合文本输出 `output_text` 数组中的 `output` 条目(如有)。
在 Python 和 JavaScript SDK 中受支持。
- `previous_response_id: optional string or null`
- 模型上一次响应的唯一 ID。使用它来
- 创建多轮对话。了解有关
- [对话状态](/docs/guides/conversation-state)。的更多信息。不能与 `conversation`.
+ 上一个模型响应的唯一 ID。使用它可以
+ 创建多轮对话。详细了解
+ [conversation state](/docs/guides/conversation-state)。不能与 `conversation`.
- `prompt: optional ResponsePrompt or null`
@@ -104614,19 +104588,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `variables: optional map[string or ResponseInputText or ResponseInputImage or ResponseInputFile] or null`
- 用于替换提示模板中变量的可选值映射,
- prompt。替换值可以是字符串,也可以是其他
- Response 输入类型,例如图像或文件。
+ 用于替换你
+ prompt。替换的值可以是字符串,也可以是其他
+ Response 输入类型,如图像或文件。
- `string`
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -104634,19 +104608,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `version: optional string or null`
- 提示模板的可选版本。
+ prompt 模板的可选版本。
- `prompt_cache_key: optional string or null`
- 由 OpenAI 用于缓存相似请求的响应,以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
+ 由OpenAI使用,为相似请求缓存响应以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
- `prompt_cache_options: optional object { mode, ttl }`
- 应用于该响应的提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。
+ 应用于该响应的 prompt 缓存选项。支持以下 `gpt-5.6` 及更高版本的模型。
- `mode: "implicit" or "explicit"`
- 是否启用了隐式提示缓存断点。
+ 是否启用了隐式 prompt 缓存断点。
- `"implicit"`
@@ -104654,24 +104628,24 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ttl: "30m"`
- 应用于每个缓存断点的最短生存时间。
+ 应用于每个缓存断点的最短生命周期。
- `"30m"`
- `prompt_cache_retention: optional "in_memory" or "24h" or null`
- 已弃用。请使用 `prompt_cache_options.ttl` 相反。
+ 已弃用。请使用 `prompt_cache_options.ttl` 改为。
- 提示词缓存的保留策略。设置为 `24h` 以启用扩展提示词缓存,使缓存前缀保持更长时间,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
- 此字段表示最长保留策略,而
+ 提示缓存的保留策略。设置为 `24h` 以启用扩展提示缓存,使缓存的前缀保持更长时间有效,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
+ 该字段表示最大保留策略,而
`prompt_cache_options.ttl` 表示最短缓存生命周期。这两个
- 字段彼此独立,不会相互影响。
- 对于 `gpt-5.5`, `gpt-5.5-pro`,及未来模型,仅 `24h` 受支持。
+ 字段是独立的,不会相互影响。
+ 对于 `gpt-5.5`, `gpt-5.5-pro`,以及未来的模型,仅 `24h` 。
对于同时支持两者的旧模型 `in_memory` 和 `24h`,默认值取决于你组织的数据保留策略:
- - 未启用 ZDR 的组织默认使用 `24h`.
- - 启用 ZDR 的组织默认使用 `in_memory` 当 `prompt_cache_retention` 未指定时。
+ - 未启用 ZDR 的组织默认为 `24h`.
+ - 启用 ZDR 的组织默认为 `in_memory` 当 `prompt_cache_retention` 未指定时。
- `"in_memory"`
@@ -104679,18 +104653,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `reasoning: optional Reasoning or null`
- 配置选项,适用于
+ 适用于
[推理模型](https://platform.openai.com/docs/guides/reasoning).
- `context: optional "auto" or "current_turn" or "all_turns" or null`
- 控制在后续轮次中呈现回模型的推理项。
- 如果省略或设置为 `auto`,则由模型确定上下文模式。
+ 控制在后续回合中哪些推理项会被回传给模型。
+ 如果省略或设置为 `auto`,则由模型决定上下文模式。
`gpt-5.6` 模型系列默认为 `all_turns`;早期模型默认为
`current_turn`.
- 在响应中返回时,这是该响应使用的有效推理上下文模式
- 。
+ 在响应中返回时,这是该响应所使用 的有效推理上下文模式
+ 用于该响应。
- `"auto"`
@@ -104700,13 +104674,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `effort: optional ReasoningEffort or null`
- 限制推理模型在推理上的投入程度。当前支持的值
- 包括 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
- 降低推理投入程度可以让响应更快,并减少响应中推理所用的 token 数。并非所有推理模型都支持每个
- 值。请参阅
- 推理指南
+ 限制推理模型在推理上的投入程度。目前支持
+ 的取值有 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
+ 降低推理投入程度可以让响应更快,并减少响应中用于推理的 token
+ 数量。并非所有推理模型都支持每个
+ 取值。有关各模型的支持情况,请参阅
[推理指南](https://platform.openai.com/docs/guides/reasoning)
- 以了解特定模型的支持情况。
+ 。
- `"none"`
@@ -104724,11 +104698,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `generate_summary: optional "auto" or "concise" or "detailed" or null`
- **已弃用:** 请使用 `summary` 相反。
+ **已弃用:** 请使用 `summary` 改为。
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `"auto"`
@@ -104740,7 +104714,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `string`
@@ -104748,7 +104722,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `"standard"`
@@ -104756,11 +104730,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `summary: optional "auto" or "concise" or "detailed" or null`
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `concise` 支持以下模型 `computer-use-preview` 以及之后的所有推理模型 `gpt-5`.
+ `concise` 支持用于 `computer-use-preview` 模型以及之后的 `gpt-5`.
- `"auto"`
@@ -104770,21 +104744,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `safety_identifier: optional string or null`
- 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用策略的应用程序用户。
- ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份识别信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用政策的应用用户。
+ ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `service_tier: optional ServiceTier or null`
指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
+ - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则该项目将使用 'default'。
- 如果设置为 'default',则该请求将使用所选模型的标准定价和性能进行处理。
- 如果设置为 '[flex](/docs/guides/flex-processing)',则该请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别选择启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 `service_tier=fast` 或 `service_tier=priority` 参数用于 Responses 或 Chat Completions。响应将显示 `service_tier=priority` ,无论你是否在请求中指定了 `service_tier=fast` 或 `priority` 。
- - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级返回的响应将显示 `service_tier=ultrafast`.
- - 如果未设置,默认行为是 'auto'。
+ - 若要在请求级别启用 [快速模式](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过它处理的响应将显示 `service_tier=ultrafast`.
+ - 未设置时,默认行为为 'auto'。
- 当设置 `service_tier` 参数时,响应正文将包含基于实际用于处理该请求的处理模式的 `service_tier` 值。此响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应体中将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。此响应中的值可能与该参数中设置的值不同。
- `"auto"`
@@ -104802,8 +104776,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional ResponseStatus`
- 响应生成的状态。取值之一为 `completed`, `failed`,
- `in_progress`, `cancelled`, `queued`, or `incomplete`.
+ 响应生成的状态。可选值为 `completed`, `failed`,
+ `in_progress`, `cancelled`, `queued`,或 `incomplete`.
- `"completed"`
@@ -104819,8 +104793,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: optional ResponseTextConfig`
- 用于配置模型文本响应的选项。可以是纯文本,也可以是结构化的 JSON 数据。详见:
- 文本输入与输出:
+ 模型文本响应的配置选项。可以是纯
+ 文本或结构化 JSON 数据。了解更多:
- [文本输入与输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
@@ -104829,79 +104803,79 @@ curl https://api.openai.com/v1/responses/resp_123 \
用于指定模型必须输出的格式的对象。
- 设置为 `{ "type": "json_schema" }` 时,将启用结构化输出,
- 功能,从而确保模型的输出与你提供的 JSON schema 相匹配。详见
+ 配置 `{ "type": "json_schema" }` 可启用结构化输出,
+ 从而确保模型匹配你提供的 JSON schema。更多信息请参阅
[结构化输出指南](/docs/guides/structured-outputs).
- 默认的格式为 `{ "type": "text" }` ,且不包含其他选项。
+ 默认格式为 `{ "type": "text" }` ,不包含任何额外选项。
- **不建议在 gpt-4o 及更新模型上使用:**
+ **不推荐用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
- 的模型,建议优先使用该格式。
+ 设置为 `{ "type": "json_object" }` 会启用旧版 JSON 模式,该模式
+ 可确保模型生成的消息是合法 JSON。对于支持 `json_schema`
+ 的模型,建议优先使用它。
- `ResponseFormatText object { type }`
- 默认的响应格式。用于生成文本响应。
+ 默认响应格式。用于生成文本响应。
- `type: "text"`
- 正在定义的响应格式的类型。始终为 `text`.
+ 正在定义的响应格式类型。始终为 `text`.
- `"text"`
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化的 JSON 响应。
+ JSON Schema 响应格式。用于生成结构化 JSON 响应。
详细了解 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
- 下划线和连字符,最大长度为 64。
+ 下划线和短横线,最大长度为 64。
- `schema: map[unknown]`
- 响应格式的 schema,以 JSON Schema 对象描述。
- 了解如何构建 JSON schema [此处](https://json-schema.org/).
+ 响应格式的架构,以 JSON Schema 对象形式描述。
+ 了解如何构建 JSON 架构 [此处](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式的类型。始终为 `json_schema`.
+ 正在定义的响应格式类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
响应格式用途的描述,供模型用于
- 确定如何按该格式进行响应。
+ 确定如何按该格式响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 一致性。
- 如果设置为 true,模型将始终遵循
- 字段中 `schema` 定义的精确 schema。仅支持 JSON Schema 的一个子集,当
- `strict` 是 `true`。要了解更多信息,请阅读 [Structured Outputs
+ 生成输出时是否启用严格的架构遵循。
+ 如果设置为 true,模型将始终遵循 字段中定义的
+ 确切架构。当 设置为 `schema` true 时,仅支持 JSON Schema 的一个子集
+ `strict` 是 `true`。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较早的生成 JSON 响应的方法。
- 使用 `json_schema` 对支持它的模型是推荐的做法。请注意
- 模型在没有系统或用户消息指示的情况下不会生成
- JSON。
+ JSON 对象响应格式。一种较旧的 JSON 响应生成方法。建议。
+ 对于支持 的模型,使用 `json_schema` 。请注意,模型不会在没有系统或用户消息指示
+ 的情况下生成 JSON
+ 。
- `type: "json_object"`
- 正在定义的响应格式的类型。始终为 `json_object`.
+ 正在定义的响应格式类型。始终为 `json_object`.
- `"json_object"`
- `verbosity: optional "low" or "medium" or "high" or null`
- 约束模型响应的详细程度。较低的值会产生
- 更简洁的响应,较高的值会产生更详细的响应。
+ 约束模型响应的详尽程度。较低的值将导致
+ 更简洁的响应,而较高的值将导致更冗长的响应。
当前支持的值包括 `low`, `medium`,和 `high`。默认值为
`medium`.
@@ -104913,20 +104887,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `top_logprobs: optional number or null`
- 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的最大最可能
- token 数量,每个 token 都附带对应的对数
+ 一个介于 0 到 20 之间的整数,指定在每个 token 位置返回的
+ 最可能 token 的最大数量,每个 token 都有一个关联的对数
概率。在某些情况下,返回的 token 数量可能少于
- 所请求的数量。
+ 请求的数量。
- `truncation: optional "auto" or "disabled" or null`
用于模型响应的截断策略。
- - `auto`:如果此 Response 的输入超过
- 模型的上下文窗口大小,模型将通过从对话开头丢弃条目来截断
- 响应以适配上下文窗口。
- - `disabled` (默认):如果输入大小将超出模型的上下文窗口
- 大小,请求将失败并返回 400 错误。
+ - `auto`:如果此 Response 的输入超出
+ 模型的上下文窗口大小,模型将通过从对话开头
+ 丢弃条目来截断响应以适配上下文窗口。
+ - `disabled` (默认):如果输入大小将超过模型的上下文窗口
+ 大小,请求将以 400 错误失败。
- `"auto"`
@@ -104935,7 +104909,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `usage: optional ResponseUsage`
表示 token 使用详情,包括输入 token、输出 token,
- 的输出 token 明细,以及所使用的 token 总数。
+ 输出 token 的细分,以及使用的总 token 数。
- `input_tokens: number`
@@ -104943,16 +104917,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_tokens_details: object { cache_write_tokens, cached_tokens }`
- 输入 token 的详细明细。
+ 输入 token 的详细细分。
- `cache_write_tokens: number`
- 已写入缓存的输入 token 数量。
+ 写入缓存的输入 token 的数量。
- `cached_tokens: number`
- 从缓存中检索到的 token 数量。
- [了解更多关于提示缓存的信息](/docs/guides/prompt-caching).
+ 从缓存中检索到的 token 的数量。
+ [有关 prompt caching 的更多信息](/docs/guides/prompt-caching).
- `output_tokens: number`
@@ -104960,25 +104934,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_tokens_details: object { reasoning_tokens }`
- 输出令牌的详细明细。
+ 输出 token 的详细明细。
- `reasoning_tokens: number`
- 推理令牌的数量。
+ 推理 token 的数量。
- `total_tokens: number`
- 使用的令牌总数。
-
- - `compute_units: optional number or null`
-
- 该请求的计算单元。在可用时当前为 null。
+ 使用的 token 总数。
- `user: optional string`
- 此字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
- 用于标识你的最终用户的稳定标识符。
- 通过更好地对相似请求进行分桶以提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 该字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
+ 你的最终用户的稳定标识符。
+ 通过更好地对相似请求进行分桶来提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `sequence_number: number`
@@ -105004,7 +104974,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `format: "mp3" or "wav"`
- 音频数据的格式。当前支持的格式包括 `mp3` 和
+ 音频数据的格式。当前支持的格式为 `mp3` 和
`wav`.
- `"mp3"`
@@ -105013,47 +104983,47 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_audio"`
- The type of the input item. Always `input_audio`.
+ 输入项的类型。始终为 `input_audio`.
- `"input_audio"`
-### Response 输入内容
+### Response Input Content
- `ResponseInputContent = ResponseInputText or ResponseInputImage or ResponseInputFile`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -105065,25 +105035,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -105093,13 +105063,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -105109,31 +105079,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
-### Response 输入文件
+### Response Input File
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -105141,13 +105111,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -105157,31 +105127,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
-### Response 输入文件内容
+### Response Input File Content
- `ResponseInputFileContent object { type, detail, file_data, 4 more }`
@@ -105189,13 +105159,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -105209,35 +105179,35 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
-### Response 输入图像
+### Response Input Image
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -105249,43 +105219,43 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
-### Response 输入图像内容
+### Response Input Image Content
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision)
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `detail: optional ImageDetail or null`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -105297,60 +105267,60 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
-### Response 输入消息内容列表
+### Response Input Message Content List
- `ResponseInputMessageContentList = array of ResponseInputContent`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -105362,25 +105332,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -105390,13 +105360,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -105406,31 +105376,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
-### Response 输入消息项
+### Response Input Message Item
- `ResponseInputMessageItem object { id, content, role, 2 more }`
@@ -105440,40 +105410,40 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `content: ResponseInputMessageContentList`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -105485,25 +105455,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -105513,13 +105483,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -105529,33 +105499,33 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `system`, or `developer`.
+ 消息输入的角色。其一为 接口 `user`, `system`,或 `developer`.
- `"user"`
@@ -105571,8 +105541,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -105584,25 +105554,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -105610,25 +105580,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputTextContent object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -105648,15 +105618,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseMcpCallArgumentsDeltaEvent object { delta, item_id, output_index, 2 more }`
- 当 MCP 工具调用的参数存在 delta(部分更新)时发出。
+ 在 MCP 工具调用的参数存在增量(部分更新)时发出。
- `delta: string`
- 一个 JSON 字符串,包含 MCP 工具调用参数的部分更新。
+ 一个 JSON 字符串,包含对 MCP 工具调用参数的部分更新。
- `item_id: string`
- 正在处理的 MCP 工具调用项的唯一标识符。
+ 正在处理的 MCP 工具调用条目的唯一标识符。
- `output_index: number`
@@ -105672,19 +105642,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.mcp_call_arguments.delta"`
-### Response Mcp 调用参数完成事件
+### Response Mcp Call Arguments Done 事件
- `ResponseMcpCallArgumentsDoneEvent object { arguments, item_id, output_index, 2 more }`
- 当 MCP 工具调用的参数被最终确定时发出。
+ 在 MCP 工具调用的参数确定后发出。
- `arguments: string`
- 一个 JSON 字符串,包含 MCP 工具调用的最终确定参数。
+ 包含 MCP 工具调用最终参数的 JSON 字符串。
- `item_id: string`
- 正在处理的 MCP 工具调用项的唯一标识符。
+ 正在处理的 MCP 工具调用条目的唯一标识符。
- `output_index: number`
@@ -105704,7 +105674,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseMcpCallCompletedEvent object { item_id, output_index, sequence_number, type }`
- 当 MCP 工具调用已成功完成时触发。
+ 当 MCP 工具调用成功完成时触发。
- `item_id: string`
@@ -105724,15 +105694,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.mcp_call.completed"`
-### Response Mcp Call Failed Event
+### Response Mcp 调用失败事件
- `ResponseMcpCallFailedEvent object { item_id, output_index, sequence_number, type }`
- 当 MCP 工具调用失败时触发。
+ 当 MCP 工具调用失败时发出。
- `item_id: string`
- 失败的 MCP 工具调用项的 ID。
+ 失败 MCP 工具调用项的 ID。
- `output_index: number`
@@ -105748,15 +105718,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.mcp_call.failed"`
-### Response Mcp Call In Progress 事件
+### Response Mcp 调用进行中事件
- `ResponseMcpCallInProgressEvent object { item_id, output_index, sequence_number, type }`
- 在 MCP 工具调用进行中时发出。
+ 在 MCP 工具调用进行中时发出。
- `item_id: string`
- 正在处理的 MCP 工具调用项的唯一标识符。
+ 正在处理的 MCP 工具调用条目的唯一标识符。
- `output_index: number`
@@ -105768,7 +105738,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "response.mcp_call.in_progress"`
- 事件的类型。始终为 'response.mcp_call.in_progress'。
+ 事件的类型,恒为 'response.mcp_call.in_progress'。
- `"response.mcp_call.in_progress"`
@@ -105776,11 +105746,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseMcpListToolsCompletedEvent object { item_id, output_index, sequence_number, type }`
- 在成功检索到可用的 MCP 工具列表时发出。
+ 在可用 MCP 工具列表成功检索到时触发。
- `item_id: string`
- 产生此输出的 MCP 工具调用项的 ID。
+ 生成此输出的 MCP 工具调用项的 ID。
- `output_index: number`
@@ -105796,15 +105766,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.mcp_list_tools.completed"`
-### Response Mcp List Tools Failed 事件
+### Response Mcp List Tools Failed Event
- `ResponseMcpListToolsFailedEvent object { item_id, output_index, sequence_number, type }`
- 在尝试列出可用的 MCP 工具失败时发出。
+ 当尝试列出可用的 MCP 工具失败时发出。
- `item_id: string`
- 失败的 MCP 工具调用项的 ID。
+ 失败 MCP 工具调用项的 ID。
- `output_index: number`
@@ -105824,7 +105794,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseMcpListToolsInProgressEvent object { item_id, output_index, sequence_number, type }`
- 系统在检索可用 MCP 工具列表的过程中发出。
+ 在系统正在检索可用 MCP 工具列表的过程中发出。
- `item_id: string`
@@ -105844,11 +105814,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.mcp_list_tools.in_progress"`
-### Response 输出音频
+### 响应输出音频
- `ResponseOutputAudio object { data, transcript, type }`
- 模型的音频输出。
+ 来自模型的音频输出。
- `data: string`
@@ -105856,7 +105826,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `transcript: string`
- 来自模型的音频数据的文字稿。
+ 来自模型的音频数据的转录文本。
- `type: "output_audio"`
@@ -105864,7 +105834,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"output_audio"`
-### 响应输出项
+### Response 输出项
- `ResponseOutputItem = ResponseOutputMessage or object { id, queries, status, 2 more } or object { arguments, call_id, name, 5 more } or 25 more`
@@ -105876,7 +105846,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -105884,15 +105854,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -105908,7 +105878,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -105918,25 +105888,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -105948,7 +105918,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -105956,11 +105926,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -106014,15 +105984,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -106034,8 +106004,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -106051,9 +106021,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -106061,8 +106031,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -106074,7 +106044,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -106099,11 +106069,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -106121,7 +106091,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -106130,7 +106100,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -106180,8 +106150,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -106206,39 +106176,39 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -106250,25 +106220,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -106278,13 +106248,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -106294,34 +106264,34 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -106365,7 +106335,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `name: optional string`
@@ -106378,7 +106348,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -106386,12 +106356,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -106401,11 +106371,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -106423,7 +106393,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -106437,7 +106407,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -106455,7 +106425,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -106467,14 +106437,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -106486,7 +106456,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -106502,8 +106472,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -106527,7 +106497,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -106541,7 +106511,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -106567,7 +106537,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -106585,7 +106555,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -106604,7 +106574,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -106614,11 +106584,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -106638,15 +106608,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -106678,19 +106648,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -106714,8 +106684,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -106731,7 +106701,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -106747,7 +106717,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -106761,31 +106731,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"completed"`
@@ -106797,13 +106767,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、已被
+ API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -106820,13 +106790,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -106839,7 +106809,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -106859,7 +106829,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -106869,20 +106839,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -106902,7 +106872,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -106910,7 +106880,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目的类型,恒为 `program`.
+ item 的类型。始终为 `program`.
- `"program"`
@@ -106926,7 +106896,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -106938,7 +106908,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目的类型,恒为 `program_output`.
+ item 的类型。始终为 `program_output`.
- `"program_output"`
@@ -106976,13 +106946,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目的类型,恒为 `tool_search_call`.
+ item 的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -107048,37 +107018,37 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -107091,11 +107061,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -107115,7 +107085,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -107131,15 +107101,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -107153,7 +107123,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -107161,7 +107131,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -107173,7 +107143,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -107181,21 +107151,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -107221,18 +107191,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -107240,22 +107210,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -107265,23 +107235,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -107292,11 +107262,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -107314,21 +107284,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -107336,14 +107306,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -107375,32 +107345,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -107408,13 +107378,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -107422,9 +107392,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -107436,22 +107406,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -107460,7 +107430,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -107470,7 +107440,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -107500,29 +107470,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -107558,7 +107528,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -107568,11 +107538,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -107582,7 +107552,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -107590,7 +107560,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -107599,13 +107569,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -107614,7 +107584,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -107641,7 +107611,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -107652,7 +107622,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -107669,13 +107639,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -107691,7 +107661,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -107701,7 +107671,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -107725,7 +107695,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -107749,13 +107719,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -107779,7 +107749,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -107787,13 +107757,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -107813,7 +107783,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -107825,13 +107795,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -107845,11 +107815,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -107875,7 +107845,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -107893,7 +107863,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -107907,19 +107877,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -107939,19 +107909,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -107959,11 +107929,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -108009,7 +107979,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -108021,11 +107991,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -108039,7 +108009,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -108049,7 +108019,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -108059,23 +108029,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -108093,13 +108063,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目的类型,恒为 `tool_search_output`.
+ item 的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -108129,7 +108099,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -108163,45 +108133,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -108209,7 +108179,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -108221,7 +108191,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -108229,21 +108199,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -108269,18 +108239,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -108288,22 +108258,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -108313,23 +108283,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -108340,11 +108310,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -108362,21 +108332,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -108384,14 +108354,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -108423,32 +108393,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -108456,13 +108426,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -108470,9 +108440,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -108484,22 +108454,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -108508,7 +108478,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -108518,7 +108488,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -108574,7 +108544,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -108584,11 +108554,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -108598,7 +108568,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -108606,7 +108576,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -108615,13 +108585,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -108630,7 +108600,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -108657,7 +108627,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -108668,7 +108638,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -108685,13 +108655,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -108707,7 +108677,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -108717,7 +108687,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -108743,11 +108713,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -108773,19 +108743,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -108805,19 +108775,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -108825,11 +108795,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -108875,7 +108845,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -108887,11 +108857,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -108905,7 +108875,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -108915,7 +108885,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -108925,23 +108895,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -108959,13 +108929,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目的类型,恒为 `additional_tools`.
+ item 的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -108973,21 +108943,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的已加密内容。
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -109011,7 +108981,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -109034,7 +109004,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -109046,23 +109016,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -109080,13 +109050,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -109102,11 +109072,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -109120,11 +109090,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -109138,7 +109108,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -109148,7 +109118,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -109156,13 +109126,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -109176,17 +109146,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -109224,7 +109194,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -109234,7 +109204,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -109268,7 +109238,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。通过 API 返回该条目时填充此字段。
- `call_id: string`
@@ -109276,15 +109246,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -109292,13 +109262,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -109306,7 +109276,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -109320,11 +109290,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`, or `incomplete`.
+ shell 调用输出的状态。可选值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -109360,7 +109330,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -109368,15 +109338,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -109392,7 +109362,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的 diff 创建新文件。
- `"create_file"`
@@ -109406,7 +109376,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "delete_file"`
- 删除指定的文件。
+ 删除指定文件。
- `"delete_file"`
@@ -109424,13 +109394,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "update_file"`
- 使用提供的差异更新现有文件。
+ 使用提供的 diff 更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -109438,7 +109408,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -109468,19 +109438,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -109488,7 +109458,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -109522,7 +109492,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -109530,11 +109500,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -109542,14 +109512,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -109589,7 +109559,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -109627,7 +109597,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -109635,29 +109605,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -109665,29 +109635,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `id: string`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -109719,7 +109689,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -109753,7 +109723,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -109770,11 +109740,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -109782,8 +109752,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -109823,20 +109793,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
-### 响应输出项添加事件
+### Response 输出项添加事件
- `ResponseOutputItemAddedEvent object { item, output_index, sequence_number, type }`
- 当新增一个输出项时触发。
+ 在添加新的输出项时触发。
- `item: ResponseOutputItem`
被添加的输出项。对于推理项, `encrypted_content`
- 在项进行中时可能不完整。可使用相应
- 事件中的推理项 `response.output_item.done` 在将其作为输入传递给后续请求时使用。
- 后续请求的输入。
+ 在项进行中时可能不完整。请使用推理项
+ 来自相应的 `response.output_item.done` 事件中,在将其作为输入
+ 传递给后续请求时。
- `ResponseOutputMessage object { id, content, role, 3 more }`
@@ -109844,7 +109814,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -109852,15 +109822,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -109876,7 +109846,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -109886,25 +109856,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -109916,7 +109886,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -109924,11 +109894,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -109982,15 +109952,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -110002,8 +109972,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -110019,9 +109989,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -110029,8 +109999,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -110042,7 +110012,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -110067,11 +110037,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -110089,7 +110059,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -110098,7 +110068,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -110148,8 +110118,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -110174,39 +110144,39 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -110218,25 +110188,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -110246,13 +110216,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -110262,34 +110232,34 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -110333,7 +110303,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `name: optional string`
@@ -110346,7 +110316,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -110354,12 +110324,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -110369,11 +110339,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -110391,7 +110361,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -110405,7 +110375,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -110423,7 +110393,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -110435,14 +110405,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -110454,7 +110424,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -110470,8 +110440,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -110495,7 +110465,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -110509,7 +110479,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -110535,7 +110505,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -110553,7 +110523,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -110572,7 +110542,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -110582,11 +110552,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -110606,15 +110576,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -110646,19 +110616,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -110682,8 +110652,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -110699,7 +110669,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -110715,7 +110685,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -110729,31 +110699,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"completed"`
@@ -110765,13 +110735,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、已被
+ API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -110788,13 +110758,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -110807,7 +110777,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -110827,7 +110797,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -110837,20 +110807,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -110870,7 +110840,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -110878,7 +110848,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目的类型,恒为 `program`.
+ item 的类型。始终为 `program`.
- `"program"`
@@ -110894,7 +110864,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -110906,7 +110876,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目的类型,恒为 `program_output`.
+ item 的类型。始终为 `program_output`.
- `"program_output"`
@@ -110944,13 +110914,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目的类型,恒为 `tool_search_call`.
+ item 的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -111016,37 +110986,37 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -111059,11 +111029,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -111083,7 +111053,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -111099,15 +111069,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -111121,7 +111091,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -111129,7 +111099,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -111141,7 +111111,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -111149,21 +111119,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -111189,18 +111159,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -111208,22 +111178,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -111233,23 +111203,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -111260,11 +111230,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -111282,21 +111252,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -111304,14 +111274,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -111343,32 +111313,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -111376,13 +111346,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -111390,9 +111360,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -111404,22 +111374,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -111428,7 +111398,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -111438,7 +111408,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -111468,29 +111438,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -111526,7 +111496,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -111536,11 +111506,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -111550,7 +111520,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -111558,7 +111528,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -111567,13 +111537,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -111582,7 +111552,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -111609,7 +111579,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -111620,7 +111590,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -111637,13 +111607,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -111659,7 +111629,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -111669,7 +111639,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -111693,7 +111663,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -111717,13 +111687,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -111747,7 +111717,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -111755,13 +111725,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -111781,7 +111751,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -111793,13 +111763,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -111813,11 +111783,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -111843,7 +111813,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -111861,7 +111831,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -111875,19 +111845,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -111907,19 +111877,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -111927,11 +111897,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -111977,7 +111947,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -111989,11 +111959,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -112007,7 +111977,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -112017,7 +111987,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -112027,23 +111997,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -112061,13 +112031,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目的类型,恒为 `tool_search_output`.
+ item 的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -112097,7 +112067,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -112131,45 +112101,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -112177,7 +112147,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -112189,7 +112159,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -112197,21 +112167,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -112237,18 +112207,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -112256,22 +112226,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -112281,23 +112251,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -112308,11 +112278,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -112330,21 +112300,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -112352,14 +112322,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -112391,32 +112361,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -112424,13 +112394,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -112438,9 +112408,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -112452,22 +112422,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -112476,7 +112446,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -112486,7 +112456,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -112542,7 +112512,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -112552,11 +112522,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -112566,7 +112536,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -112574,7 +112544,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -112583,13 +112553,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -112598,7 +112568,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -112625,7 +112595,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -112636,7 +112606,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -112653,13 +112623,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -112675,7 +112645,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -112685,7 +112655,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -112711,11 +112681,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -112741,19 +112711,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -112773,19 +112743,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -112793,11 +112763,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -112843,7 +112813,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -112855,11 +112825,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -112873,7 +112843,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -112883,7 +112853,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -112893,23 +112863,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -112927,13 +112897,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目的类型,恒为 `additional_tools`.
+ item 的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -112941,21 +112911,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的已加密内容。
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -112979,7 +112949,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -113002,7 +112972,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -113014,23 +112984,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -113048,13 +113018,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -113070,11 +113040,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -113088,11 +113058,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -113106,7 +113076,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -113116,7 +113086,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -113124,13 +113094,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -113144,17 +113114,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -113192,7 +113162,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -113202,7 +113172,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -113236,7 +113206,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。通过 API 返回该条目时填充此字段。
- `call_id: string`
@@ -113244,15 +113214,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -113260,13 +113230,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -113274,7 +113244,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -113288,11 +113258,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`, or `incomplete`.
+ shell 调用输出的状态。可选值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -113328,7 +113298,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -113336,15 +113306,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -113360,7 +113330,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的 diff 创建新文件。
- `"create_file"`
@@ -113374,7 +113344,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "delete_file"`
- 删除指定的文件。
+ 删除指定文件。
- `"delete_file"`
@@ -113392,13 +113362,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "update_file"`
- 使用提供的差异更新现有文件。
+ 使用提供的 diff 更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -113406,7 +113376,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -113436,19 +113406,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -113456,7 +113426,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -113490,7 +113460,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -113498,11 +113468,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -113510,14 +113480,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -113557,7 +113527,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -113595,7 +113565,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -113603,29 +113573,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -113633,29 +113603,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `id: string`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -113687,7 +113657,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -113721,7 +113691,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -113738,11 +113708,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -113750,8 +113720,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -113791,7 +113761,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `output_index: number`
@@ -113807,11 +113777,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.output_item.added"`
-### 响应输出项完成事件
+### Response 输出项完成事件
- `ResponseOutputItemDoneEvent object { item, output_index, sequence_number, type }`
- 当某个输出项被标记为完成时触发。
+ 在某个输出项被标记为完成时发出。
- `item: ResponseOutputItem`
@@ -113823,7 +113793,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -113831,15 +113801,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -113855,7 +113825,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -113865,25 +113835,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -113895,7 +113865,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -113903,11 +113873,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -113961,15 +113931,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -113981,8 +113951,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -113998,9 +113968,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -114008,8 +113978,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -114021,7 +113991,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -114046,11 +114016,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -114068,7 +114038,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -114077,7 +114047,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -114127,8 +114097,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -114153,39 +114123,39 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -114197,25 +114167,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -114225,13 +114195,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -114241,34 +114211,34 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -114312,7 +114282,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `name: optional string`
@@ -114325,7 +114295,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -114333,12 +114303,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -114348,11 +114318,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -114370,7 +114340,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -114384,7 +114354,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -114402,7 +114372,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -114414,14 +114384,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -114433,7 +114403,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -114449,8 +114419,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -114474,7 +114444,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -114488,7 +114458,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -114514,7 +114484,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -114532,7 +114502,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -114551,7 +114521,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -114561,11 +114531,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -114585,15 +114555,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -114625,19 +114595,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -114661,8 +114631,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -114678,7 +114648,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -114694,7 +114664,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -114708,31 +114678,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"completed"`
@@ -114744,13 +114714,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、已被
+ API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -114767,13 +114737,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -114786,7 +114756,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -114806,7 +114776,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -114816,20 +114786,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -114849,7 +114819,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -114857,7 +114827,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目的类型,恒为 `program`.
+ item 的类型。始终为 `program`.
- `"program"`
@@ -114873,7 +114843,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -114885,7 +114855,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目的类型,恒为 `program_output`.
+ item 的类型。始终为 `program_output`.
- `"program_output"`
@@ -114923,13 +114893,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目的类型,恒为 `tool_search_call`.
+ item 的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -114995,37 +114965,37 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -115038,11 +115008,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -115062,7 +115032,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -115078,15 +115048,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -115100,7 +115070,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -115108,7 +115078,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -115120,7 +115090,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -115128,21 +115098,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -115168,18 +115138,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -115187,22 +115157,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -115212,23 +115182,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -115239,11 +115209,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -115261,21 +115231,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -115283,14 +115253,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -115322,32 +115292,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -115355,13 +115325,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -115369,9 +115339,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -115383,22 +115353,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -115407,7 +115377,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -115417,7 +115387,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -115447,29 +115417,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -115505,7 +115475,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -115515,11 +115485,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -115529,7 +115499,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -115537,7 +115507,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -115546,13 +115516,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -115561,7 +115531,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -115588,7 +115558,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -115599,7 +115569,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -115616,13 +115586,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -115638,7 +115608,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -115648,7 +115618,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -115672,7 +115642,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -115696,13 +115666,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -115726,7 +115696,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -115734,13 +115704,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -115760,7 +115730,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -115772,13 +115742,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -115792,11 +115762,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -115822,7 +115792,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -115840,7 +115810,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -115854,19 +115824,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -115886,19 +115856,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -115906,11 +115876,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -115956,7 +115926,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -115968,11 +115938,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -115986,7 +115956,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -115996,7 +115966,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -116006,23 +115976,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -116040,13 +116010,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目的类型,恒为 `tool_search_output`.
+ item 的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -116076,7 +116046,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -116110,45 +116080,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -116156,7 +116126,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -116168,7 +116138,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -116176,21 +116146,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -116216,18 +116186,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -116235,22 +116205,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -116260,23 +116230,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -116287,11 +116257,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -116309,21 +116279,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -116331,14 +116301,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -116370,32 +116340,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -116403,13 +116373,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -116417,9 +116387,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -116431,22 +116401,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -116455,7 +116425,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -116465,7 +116435,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -116521,7 +116491,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -116531,11 +116501,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -116545,7 +116515,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -116553,7 +116523,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -116562,13 +116532,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -116577,7 +116547,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -116604,7 +116574,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -116615,7 +116585,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -116632,13 +116602,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -116654,7 +116624,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -116664,7 +116634,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -116690,11 +116660,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -116720,19 +116690,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -116752,19 +116722,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -116772,11 +116742,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -116822,7 +116792,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -116834,11 +116804,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -116852,7 +116822,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -116862,7 +116832,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -116872,23 +116842,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -116906,13 +116876,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目的类型,恒为 `additional_tools`.
+ item 的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -116920,21 +116890,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的已加密内容。
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -116958,7 +116928,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -116981,7 +116951,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -116993,23 +116963,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -117027,13 +116997,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -117049,11 +117019,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -117067,11 +117037,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -117085,7 +117055,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -117095,7 +117065,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -117103,13 +117073,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -117123,17 +117093,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -117171,7 +117141,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -117181,7 +117151,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -117215,7 +117185,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。通过 API 返回该条目时填充此字段。
- `call_id: string`
@@ -117223,15 +117193,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -117239,13 +117209,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -117253,7 +117223,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -117267,11 +117237,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`, or `incomplete`.
+ shell 调用输出的状态。可选值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -117307,7 +117277,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -117315,15 +117285,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -117339,7 +117309,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的 diff 创建新文件。
- `"create_file"`
@@ -117353,7 +117323,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "delete_file"`
- 删除指定的文件。
+ 删除指定文件。
- `"delete_file"`
@@ -117371,13 +117341,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "update_file"`
- 使用提供的差异更新现有文件。
+ 使用提供的 diff 更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -117385,7 +117355,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -117415,19 +117385,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -117435,7 +117405,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -117469,7 +117439,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -117477,11 +117447,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -117489,14 +117459,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -117536,7 +117506,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -117574,7 +117544,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -117582,29 +117552,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -117612,29 +117582,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `id: string`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -117666,7 +117636,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -117700,7 +117670,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -117717,11 +117687,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -117729,8 +117699,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -117770,7 +117740,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `output_index: number`
@@ -117786,7 +117756,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.output_item.done"`
-### Response Output Message
+### Response 输出消息
- `ResponseOutputMessage object { id, content, role, 3 more }`
@@ -117794,7 +117764,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -117802,15 +117772,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -117826,7 +117796,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -117836,25 +117806,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -117866,7 +117836,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -117874,11 +117844,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -117932,15 +117902,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -117952,8 +117922,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -117969,43 +117939,43 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
- `"final_answer"`
-### Response Output Refusal
+### Response 输出拒绝
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
-### Response Output Text
+### Response 输出文本
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -118021,7 +117991,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -118031,25 +118001,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -118061,7 +118031,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -118069,11 +118039,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -118125,19 +118095,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"output_text"`
-### Response Output Text Annotation Added Event
+### Response 输出文本注释添加事件
- `ResponseOutputTextAnnotationAddedEvent object { annotation, annotation_index, content_index, 4 more }`
- 当向输出文本内容添加批注时发出。
+ 当向输出文本内容添加注解时触发。
- `annotation: object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type } or null`
- 应用于一段输出文本的批注。
+ 应用于一段输出文本的注解。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -118153,7 +118123,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -118163,25 +118133,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -118193,7 +118163,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -118201,11 +118171,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -118233,15 +118203,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotation_index: number`
- 内容片段中批注的索引。
+ 内容部分中该注解的索引。
- `content_index: number`
- 输出项中内容片段的索引。
+ 输出项中内容部分的索引。
- `item_id: string`
- 正在添加批注的项的唯一标识符。
+ 正在添加注解的项的唯一标识符。
- `output_index: number`
@@ -118270,43 +118240,43 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `variables: optional map[string or ResponseInputText or ResponseInputImage or ResponseInputFile] or null`
- 用于替换提示模板中变量的可选值映射,
- prompt。替换值可以是字符串,也可以是其他
- Response 输入类型,例如图像或文件。
+ 用于替换你
+ prompt。替换的值可以是字符串,也可以是其他
+ Response 输入类型,如图像或文件。
- `string`
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -118318,25 +118288,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -118346,13 +118316,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -118362,43 +118332,43 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `version: optional string or null`
- 提示模板的可选版本。
+ prompt 模板的可选版本。
### Response Queued Event
- `ResponseQueuedEvent object { response, sequence_number, type }`
- 当响应被排队等待处理时发出。
+ 当一个响应被加入队列并等待处理时触发。
- `response: Response`
- 被排队的完整响应对象。
+ 已加入队列的完整响应对象。
- `id: string`
@@ -118406,7 +118376,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_at: number`
- 创建此 Response 时的 Unix 时间戳(以秒为单位)。
+ 此 Response 创建时的 Unix 时间戳(以秒为单位)。
- `error: ResponseError or null`
@@ -118462,87 +118432,89 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `incomplete_details: object { reason } or null`
- 有关响应未完成原因的详细信息。
+ 有关响应不完整的详细原因。
- - `reason: optional "max_output_tokens" or "content_filter"`
+ - `reason: optional "max_output_tokens" or "max_messages" or "content_filter"`
- 响应未完成的原因。
+ 响应不完整的原因。
- `"max_output_tokens"`
+ - `"max_messages"`
+
- `"content_filter"`
- `instructions: string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more or null`
插入到模型上下文中的系统(或开发者)消息。
- 当与 `previous_response_id`,配合使用时,前一次
- 响应的指令不会延续到下一次响应。这便于在新响应中
- 替换系统(或开发者)消息。
+ 当与 `previous_response_id`,配合使用时,上一个
+ response 中的 instructions 不会延续到下一个 response。这样可以轻松地
+ 在新的 response 中替换系统(或开发者)消息。
- `string`
- 发送给模型的文本输入,相当于使用
+ 发送给模型的文本输入,等同于
`developer` 角色的文本输入。
- `InputItemList = array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 发送给模型的一个或多个输入项的列表,包含
+ 发送给模型的一个或多个输入项列表,包含
不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` role. Messages with the
- `assistant` role are presumed to have been generated by the model in previous
- interactions.
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色给出的指令。带有
+ `assistant` 角色的消息被视为模型在之前的
+ 交互中生成。
- `content: string or ResponseInputMessageContentList`
- Text, image, or audio input to the model, used to generate a response.
- Can also contain previous assistant responses.
+ 发送给模型的文本、图像或音频输入,用于生成响应。
+ 也可以包含之前的助手响应。
- `TextInput = string`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputMessageContentList = array of ResponseInputContent`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -118554,25 +118526,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -118582,13 +118554,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -118598,33 +118570,33 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `assistant`, `system`, or
+ 消息输入的角色。其一为 接口 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -118637,9 +118609,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -118647,24 +118619,24 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: optional "message"`
- 消息输入的类型。始终为 `message`.
+ 消息输入的类型。始终为 接口 `message`.
- `"message"`
- `Message object { content, role, status, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` 角色的文本输入。
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色的文本输入。
- `content: ResponseInputMessageContentList`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `system`, or `developer`.
+ 消息输入的角色。其一为 接口 `user`, `system`,或 `developer`.
- `"user"`
@@ -118674,8 +118646,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -118695,7 +118667,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -118703,15 +118675,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -118727,7 +118699,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -118737,25 +118709,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -118767,7 +118739,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -118775,11 +118747,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -118833,15 +118805,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -118853,8 +118825,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -118870,9 +118842,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -118880,8 +118852,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -118893,7 +118865,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -118918,11 +118890,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -118940,7 +118912,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -118949,7 +118921,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -118961,7 +118933,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -118977,8 +118949,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -119002,7 +118974,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -119016,7 +118988,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -119042,7 +119014,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -119060,7 +119032,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -119079,7 +119051,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -119089,11 +119061,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -119113,15 +119085,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -119153,19 +119125,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -119189,8 +119161,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -119206,7 +119178,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -119222,7 +119194,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -119230,44 +119202,44 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCallOutput object { call_id, output, type, 3 more }`
- 一次 computer 工具调用的输出。
+ 计算机工具调用的输出。
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `id: optional string or null`
- computer 工具调用输出的 ID。
+ 计算机工具调用输出的 ID。
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 已被开发者确认的 API 所报告的安全检查结果。
+ 开发者已确认的 API 所报告的安全检查。
- `id: string`
@@ -119283,7 +119255,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值为 `in_progress`, `completed`, or `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -119294,7 +119266,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -119302,12 +119274,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -119317,11 +119289,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -119339,7 +119311,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -119353,7 +119325,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -119371,7 +119343,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -119383,14 +119355,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -119440,8 +119412,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -119455,7 +119427,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: string or array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的文本、图片或文件输出。
+ 函数工具调用的文本、图像或文件输出。
- `string`
@@ -119463,61 +119435,61 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的内容输出(文本、图片、文件)数组。
+ 函数工具调用的内容输出(文本、图像、文件)数组。
- `ResponseInputTextContent object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision)
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `detail: optional ImageDetail or null`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -119527,13 +119499,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -119547,23 +119519,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -119575,7 +119547,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string or null`
- 函数工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
+ 函数工具调用输出的唯一 ID。当此项通过 API 返回时填充。
- `call_id: optional string or null`
@@ -119615,7 +119587,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -119631,7 +119603,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目类型。始终为 `tool_search_call`.
+ 项的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
@@ -119699,37 +119671,37 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -119742,11 +119714,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -119766,7 +119738,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -119782,15 +119754,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -119804,7 +119776,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -119812,7 +119784,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -119824,7 +119796,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -119832,21 +119804,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -119872,18 +119844,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -119891,22 +119863,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -119916,23 +119888,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -119943,11 +119915,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -119965,21 +119937,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -119987,14 +119959,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -120026,32 +119998,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -120059,13 +120031,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -120073,9 +120045,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -120087,22 +120059,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -120111,7 +120083,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -120121,7 +120093,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -120151,29 +120123,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -120209,7 +120181,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -120219,11 +120191,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -120233,7 +120205,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -120241,7 +120213,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -120250,13 +120222,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -120265,7 +120237,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -120292,7 +120264,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -120303,7 +120275,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -120320,13 +120292,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -120342,7 +120314,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -120352,7 +120324,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -120376,7 +120348,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -120400,13 +120372,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -120430,7 +120402,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -120438,13 +120410,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -120464,7 +120436,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -120476,13 +120448,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -120496,11 +120468,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -120526,7 +120498,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -120544,7 +120516,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -120558,19 +120530,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -120590,19 +120562,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -120610,11 +120582,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -120660,7 +120632,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -120672,11 +120644,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -120690,7 +120662,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -120700,7 +120672,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -120710,23 +120682,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -120744,13 +120716,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目类型。始终为 `tool_search_output`.
+ 项的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `id: optional string or null`
- 此工具搜索输出的唯一 ID。
+ 该工具搜索输出的唯一 ID。
- `call_id: optional string or null`
@@ -120778,13 +120750,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `role: "developer"`
- 提供其他工具的角色。仅 `developer` 受支持。
+ 提供这些额外工具的角色。仅支持 `developer` 。
- `"developer"`
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 此项目提供的其他工具列表。
+ 在该条目中提供的额外工具列表。
- `Function object { name, parameters, strict, 5 more }`
@@ -120818,45 +120790,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -120864,7 +120836,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -120876,7 +120848,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -120884,21 +120856,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -120924,18 +120896,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -120943,22 +120915,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -120968,23 +120940,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -120995,11 +120967,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -121017,21 +120989,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -121039,14 +121011,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -121078,32 +121050,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -121111,13 +121083,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -121125,9 +121097,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -121139,22 +121111,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -121163,7 +121135,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -121173,7 +121145,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -121229,7 +121201,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -121239,11 +121211,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -121253,7 +121225,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -121261,7 +121233,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -121270,13 +121242,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -121285,7 +121257,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -121312,7 +121284,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -121323,7 +121295,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -121340,13 +121312,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -121362,7 +121334,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -121372,7 +121344,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -121398,11 +121370,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -121428,19 +121400,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -121460,19 +121432,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -121480,11 +121452,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -121530,7 +121502,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -121542,11 +121514,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -121560,7 +121532,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -121570,7 +121542,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -121580,23 +121552,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -121614,19 +121586,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目类型。始终为 `additional_tools`.
+ 项的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `id: optional string or null`
- 此其他工具项目的唯一 ID。
+ 该额外工具条目的唯一 ID。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -121639,7 +121611,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -121659,7 +121631,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -121669,20 +121641,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -121692,7 +121664,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Compaction object { encrypted_content, type, id }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -121700,17 +121672,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `id: optional string or null`
- 压缩条目的 ID。
+ 压缩项的 ID。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -121734,7 +121706,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -121757,7 +121729,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -121769,23 +121741,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -121803,13 +121775,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -121825,11 +121797,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -121843,11 +121815,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -121861,7 +121833,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -121871,7 +121843,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -121879,13 +121851,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -121899,7 +121871,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
@@ -121911,7 +121883,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最大挂钟时间(毫秒)。
+ 允许 shell 命令运行的 wall-clock 最长时间(毫秒)。
- `call_id: string`
@@ -121919,13 +121891,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
- `id: optional string or null`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -121961,7 +121933,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -121971,7 +121943,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ShellCallOutput object { call_id, output, type, 4 more }`
- shell 工具调用发出的流式输出项。
+ shell 工具调用发出的流式输出条目。
- `call_id: string`
@@ -121979,7 +121951,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: array of ResponseFunctionShellCallOutputContent`
- stdout 和 stderr 输出的捕获块及其关联结果。
+ 捕获的 stdout 和 stderr 输出块,以及它们关联的结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -121991,13 +121963,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -122005,27 +121977,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
- `stderr: string`
- shell 调用捕获的 stderr 输出。
+ 为该 shell 调用捕获的 stderr 输出。
- `stdout: string`
- shell 调用捕获的 stdout 输出。
+ 为该 shell 调用捕获的 stdout 输出。
- `type: "shell_call_output"`
- 条目的类型,恒为 `shell_call_output`.
+ item 的类型。始终为 `shell_call_output`.
- `"shell_call_output"`
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -122067,11 +122039,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 表示使用 diff 补丁创建、删除或更新文件的工具调用。
+ 表示通过 diff 补丁创建、删除或更新文件的工具调用。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
@@ -122083,7 +122055,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 创建文件时要应用的统一 diff 内容。
+ 创建文件时应用的 unified diff 内容。
- `path: string`
@@ -122115,7 +122087,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 要应用于现有文件的统一 diff 内容。
+ 应用于现有文件的 unified diff 内容。
- `path: string`
@@ -122129,7 +122101,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -122137,13 +122109,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
- `id: optional string or null`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -122171,15 +122143,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { call_id, status, type, 3 more }`
- apply patch 工具调用发出的流式输出。
+ 由 apply patch 工具调用发出的流式输出。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -122187,13 +122159,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
- `id: optional string or null`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -122249,7 +122221,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -122257,29 +122229,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -122287,31 +122259,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { approval_request_id, approve, type, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
- `id: optional string or null`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `reason: optional string or null`
@@ -122319,7 +122291,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -122327,11 +122299,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -122339,14 +122311,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -122386,7 +122358,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -122400,11 +122372,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 由你的代码生成的自定义工具调用输出,将被发送回模型。
+ 由你的代码生成的自定义工具调用的输出,将发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -122421,11 +122393,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -122439,7 +122411,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- 自定义工具调用输出在 OpenAI 平台中的唯一 ID。
+ 在 OpenAI 平台中该自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -122489,7 +122461,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -122517,11 +122489,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompactionTrigger object { type, id }`
- 压缩当前上下文。必须是最后一个输入项。
+ 压缩当前上下文。必须作为最后一个输入项。
- `type: "compaction_trigger"`
- 条目的类型,恒为 `compaction_trigger`.
+ item 的类型。始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -122535,11 +122507,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 要引用的条目 ID。
+ 被引用条目的 ID。
- `type: optional "item_reference" or null`
- 要引用的条目类型。始终为 `item_reference`.
+ 被引用条目的类型。始终为 `item_reference`.
- `"item_reference"`
@@ -122555,7 +122527,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -122563,7 +122535,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目类型。始终为 `program`.
+ 项的类型。始终为 `program`.
- `"program"`
@@ -122579,7 +122551,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -122591,14 +122563,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目类型。始终为 `program_output`.
+ 项的类型。始终为 `program_output`.
- `"program_output"`
- `metadata: Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
格式,以及通过 API 或控制台查询对象。
键为字符串,最长 64 个字符。值为字符串
@@ -122607,8 +122579,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: ResponsesModel`
用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI
- 提供了多种不同能力、性能
- 特性和定价的模型。请参阅 [模型指南](/docs/models)
+ 提供了众多功能、性能
+ 特性和价位各异的模型。请参阅 [模型指南](/docs/models)
以浏览和比较可用的模型。
- `string`
@@ -122831,12 +122803,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
由模型生成的内容项数组。
- - 该数组中项的数量和顺序 `output` 取决于
- 模型的响应。
- - 与直接访问该数组的 `output` 第一项并
- 假设它是一 `assistant` 个包含模型生成内容的
- 消息相比,你也可以考虑使用 `output_text` 属性(在
- 受支持的 SDK 中可用)。
+ - 该数组中项的长度和顺序取决于 `output` 模型的响应。
+ 与其访问。
+ - 数组中的第一项并 `output` 假设它是一个
+ 包含模型生成内容的 `assistant` 消息,不如使用
+ 属性(在受支持的 开发工具包 `output_text` 中可用)。
+ SDK。
- `ResponseOutputMessage object { id, content, role, 3 more }`
@@ -122844,8 +122816,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -122857,7 +122829,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -122882,11 +122854,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -122904,7 +122876,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -122913,7 +122885,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -122963,8 +122935,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -122989,15 +122961,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -123005,8 +122977,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -123050,7 +123022,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `name: optional string`
@@ -123063,7 +123035,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -123071,12 +123043,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -123086,11 +123058,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -123108,7 +123080,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -123122,7 +123094,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -123140,7 +123112,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -123152,14 +123124,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -123171,7 +123143,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -123187,8 +123159,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -123208,8 +123180,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `ComputerCallOutput object { id, call_id, output, 4 more }`
@@ -123219,16 +123191,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"completed"`
@@ -123240,13 +123212,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、已被
+ API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -123263,13 +123235,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -123282,7 +123254,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -123300,7 +123272,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -123310,20 +123282,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -123343,7 +123315,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -123351,7 +123323,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目的类型,恒为 `program`.
+ item 的类型。始终为 `program`.
- `"program"`
@@ -123367,7 +123339,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -123379,7 +123351,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目的类型,恒为 `program_output`.
+ item 的类型。始终为 `program_output`.
- `"program_output"`
@@ -123417,13 +123389,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目的类型,恒为 `tool_search_call`.
+ item 的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -123489,45 +123461,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -123535,7 +123507,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -123547,7 +123519,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -123555,21 +123527,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -123595,18 +123567,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -123614,22 +123586,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -123639,23 +123611,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -123666,11 +123638,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -123688,21 +123660,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -123710,14 +123682,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -123749,32 +123721,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -123782,13 +123754,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -123796,9 +123768,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -123810,22 +123782,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -123834,7 +123806,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -123844,7 +123816,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -123900,7 +123872,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -123910,11 +123882,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -123924,7 +123896,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -123932,7 +123904,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -123941,13 +123913,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -123956,7 +123928,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -123983,7 +123955,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -123994,7 +123966,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -124011,13 +123983,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -124033,7 +124005,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -124043,7 +124015,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -124069,11 +124041,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -124099,19 +124071,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -124131,19 +124103,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -124151,11 +124123,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -124201,7 +124173,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -124213,11 +124185,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -124231,7 +124203,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -124241,7 +124213,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -124251,23 +124223,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -124285,13 +124257,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目的类型,恒为 `tool_search_output`.
+ item 的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -124321,7 +124293,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -124355,45 +124327,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -124401,7 +124373,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -124413,7 +124385,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -124421,21 +124393,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -124461,18 +124433,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -124480,22 +124452,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -124505,23 +124477,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -124532,11 +124504,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -124554,21 +124526,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -124576,14 +124548,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -124615,32 +124587,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -124648,13 +124620,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -124662,9 +124634,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -124676,22 +124648,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -124700,7 +124672,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -124710,7 +124682,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -124766,7 +124738,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -124776,11 +124748,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -124790,7 +124762,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -124798,7 +124770,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -124807,13 +124779,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -124822,7 +124794,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -124849,7 +124821,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -124860,7 +124832,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -124877,13 +124849,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -124899,7 +124871,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -124909,7 +124881,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -124935,11 +124907,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -124965,19 +124937,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -124997,19 +124969,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -125017,11 +124989,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -125067,7 +125039,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -125079,11 +125051,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -125097,7 +125069,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -125107,7 +125079,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -125117,23 +125089,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -125151,13 +125123,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目的类型,恒为 `additional_tools`.
+ item 的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -125165,21 +125137,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的已加密内容。
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -125203,7 +125175,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -125226,7 +125198,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -125238,23 +125210,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -125272,13 +125244,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -125294,11 +125266,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -125312,11 +125284,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -125330,7 +125302,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -125340,7 +125312,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -125348,13 +125320,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -125368,17 +125340,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -125416,7 +125388,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -125426,7 +125398,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -125460,7 +125432,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。通过 API 返回该条目时填充此字段。
- `call_id: string`
@@ -125468,15 +125440,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -125484,13 +125456,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -125498,7 +125470,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -125512,11 +125484,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`, or `incomplete`.
+ shell 调用输出的状态。可选值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -125552,7 +125524,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -125560,15 +125532,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -125584,7 +125556,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的 diff 创建新文件。
- `"create_file"`
@@ -125598,7 +125570,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "delete_file"`
- 删除指定的文件。
+ 删除指定文件。
- `"delete_file"`
@@ -125616,13 +125588,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "update_file"`
- 使用提供的差异更新现有文件。
+ 使用提供的 diff 更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -125630,7 +125602,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -125660,19 +125632,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -125680,7 +125652,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -125714,7 +125686,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -125722,11 +125694,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -125734,14 +125706,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -125753,7 +125725,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -125791,7 +125763,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -125799,29 +125771,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -125829,29 +125801,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `id: string`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -125883,7 +125855,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -125917,7 +125889,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -125934,11 +125906,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -125946,8 +125918,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -125987,7 +125959,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `parallel_tool_calls: boolean`
@@ -125995,8 +125967,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `temperature: number or null`
- 使用的采样温度,介于 0 到 2 之间。较高的值(例如 0.8)会使输出更加随机,而较低的值(例如 0.2)会使输出更加聚焦和确定。
- 我们通常建议修改此参数或 `top_p` 但不要同时修改两者。
+ 使用的采样温度,介于 0 到 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加聚焦和确定性。
+ 我们通常建议调整此项或 `top_p` 但不要同时调整两者。
- `tool_choice: ToolChoiceOptions or ToolChoiceAllowed or ToolChoiceTypes or 6 more`
@@ -126006,9 +125978,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceOptions = "none" or "auto" or "required"`
- 控制模型调用哪个工具(如果有的话)。
+ 控制模型调用哪个工具(如果有)。
- `none` 表示模型不会调用任何工具,而是生成一条消息。
+ `none` 表示模型将不会调用任何工具,而是生成一条消息。
`auto` 表示模型可以在生成消息或调用一个或
多个工具之间进行选择。
@@ -126040,7 +126012,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of map[unknown]`
- 模型应允许调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -126061,11 +126033,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceTypes object { type }`
指示模型应使用内置工具来生成响应。
- [了解有关内置工具的更多信息](/docs/guides/tools).
+ [了解更多关于内置工具的信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
- 模型应使用的托管工具类型。了解更多关于
+ 模型应使用的 托管工具 类型。了解更多关于
[内置工具](/docs/guides/tools).
允许的值为:
@@ -126110,7 +126082,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceMcp object { server_label, type, name }`
- 使用此选项可以强制模型调用远程 MCP 服务器上的特定工具。
+ 使用此选项可强制模型调用远程 MCP 服务器上的特定工具。
- `server_label: string`
@@ -126128,7 +126100,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceCustom object { name, type }`
- 使用此选项可以强制模型调用特定的自定义工具。
+ 使用此选项可强制模型调用特定的自定义工具。
- `name: string`
@@ -126144,27 +126116,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "programmatic_tool_calling"`
- 要调用的工具。始终为 `programmatic_tool_calling`.
+ 要调用的工具。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ToolChoiceApplyPatch object { type }`
- 在执行工具调用时强制模型调用 apply_patch 工具。
+ 强制模型在执行工具调用时调用 apply_patch 工具。
- `type: "apply_patch"`
- 要调用的工具。始终为 `apply_patch`.
+ 要调用的工具。始终 `apply_patch`.
- `"apply_patch"`
- `ToolChoiceShell object { type }`
- 在需要工具调用时强制模型调用 shell 工具。
+ 在需要工具调用时,强制模型调用 shell 工具。
- `type: "shell"`
- 要调用的工具。始终为 `shell`.
+ 要调用的工具。始终 `shell`.
- `"shell"`
@@ -126175,18 +126147,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
我们支持以下类别的工具:
- - **内置工具**:由 OpenAI 提供的工具,用于扩展模型的
- 能力,例如 [网页搜索](/docs/guides/tools-web-search)
+ - **内置工具**:由 OpenAI 提供的工具,用于扩展
+ 模型的能力,例如 [网页搜索](/docs/guides/tools-web-search)
或 [文件搜索](/docs/guides/tools-file-search)。详细了解
[内置工具](/docs/guides/tools).
- - **MCP 工具**:通过自定义 MCP 服务器与第三方系统集成
- 或 Google Drive 和 SharePoint 等预定义连接器。详细了解
+ - **MCP 工具**: 通过自定义 MCP 服务器与第三方系统集成
+ 或使用 Google Drive 和 SharePoint 等预定义连接器。详细了解
[MCP 工具](/docs/guides/tools-connectors-mcp).
- - **函数调用(自定义工具)**:由你定义的函数,
+ - **函数调用(自定义工具)**: 由你定义的函数,
使模型能够使用强类型参数和输出调用你自己的代码。详细了解
。你也可以使用
- [function calling](/docs/guides/function-calling)。你还可以使用
- 自定义工具调用你自己的代码。
+ [function calling](/docs/guides/function-calling). 你也可以使用
+ 自定义工具来调用你自己的代码。
- `Function object { name, parameters, strict, 5 more }`
@@ -126220,45 +126192,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -126266,7 +126238,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -126278,7 +126250,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -126286,21 +126258,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -126326,18 +126298,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -126345,22 +126317,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -126370,23 +126342,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -126397,11 +126369,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -126419,21 +126391,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -126441,14 +126413,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -126480,32 +126452,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -126513,13 +126485,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -126527,9 +126499,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -126541,22 +126513,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -126565,7 +126537,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -126575,7 +126547,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -126631,7 +126603,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -126641,11 +126613,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -126655,7 +126627,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -126663,7 +126635,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -126672,13 +126644,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -126687,7 +126659,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -126714,7 +126686,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -126725,7 +126697,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -126742,13 +126714,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -126764,7 +126736,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -126774,7 +126746,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -126800,11 +126772,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -126830,19 +126802,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -126862,19 +126834,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -126882,11 +126854,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -126932,7 +126904,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -126944,11 +126916,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -126962,7 +126934,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -126972,7 +126944,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -126982,23 +126954,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -127016,12 +126988,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `top_p: number or null`
- 一种名为核采样的温度采样替代方案,
- 其中模型会考虑 top_p 概率质量排名前列的词元结果。
- 因此,0.1 表示仅考虑构成前 10% 概率质量的词元。
+ 一种温度采样的替代方法,称为核采样,
+ 模型会考虑概率质量排名前 top_p 的标记的结果。
+ 因此 0.1 表示仅考虑构成前 10% 概率质量的标记。
会被考虑。
- 我们通常建议修改此参数或 `temperature` 但不要同时修改两者。
+ 我们通常建议调整此项或 `temperature` 但不要同时调整两者。
- `background: optional boolean or null`
@@ -127030,44 +127002,44 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `completed_at: optional number or null`
- 此 Response 完成时的 Unix 时间戳(以秒为单位)。
- 仅当状态为 `completed`.
+ 此响应完成时的 Unix 时间戳(以秒为单位)。
+ 仅在状态为 `completed`.
- `conversation: optional object { id } or null`
- 此响应所属的对话。此响应的输入项和输出项已自动添加到此对话。
+ 此响应所属的对话。此次响应的输入项和输出项已自动添加到此对话中。
- `id: string`
- 与此响应关联的对话的唯一 ID。
+ 此响应关联的对话的唯一 ID。
- `max_output_tokens: optional number or null`
- 一次响应中可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
+ 响应可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
- `max_tool_calls: optional number or null`
- 响应中可以处理的内置工具调用总次数上限。该上限适用于所有内置工具调用,而非单个工具。模型任何进一步的工具调用尝试都将被忽略。
+ 一次响应中可处理的内置工具调用总次数上限。该上限适用于所有内置工具调用的总和,而非单个工具。模型后续任何再次调用工具的尝试都将被忽略。
- `moderation: optional object { input, output } or null`
- 响应输入和输出的审核结果,前提是请求了已审核的补全。
+ 响应输入与输出的内容审核结果,前提是请求了经过审核的补全。
- `input: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输入的审核结果。
+ 对响应输入的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -127075,7 +127047,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -127083,17 +127055,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -127105,25 +127077,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输出的审核结果。
+ 对响应输出的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -127131,7 +127103,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -127139,17 +127111,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -127161,21 +127133,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output_text: optional string or null`
- 仅限SDK的便捷属性,包含所有输出消息中聚合的文本输出
- 来自所有 `output_text` 数组中的 `output` 条目(如果有)。
+ SDK 独有的便捷属性,包含来自所有
+ 的聚合文本输出 `output_text` 数组中的 `output` 条目(如有)。
在 Python 和 JavaScript SDK 中受支持。
- `previous_response_id: optional string or null`
- 模型上一次响应的唯一 ID。使用它来
- 创建多轮对话。了解有关
- [对话状态](/docs/guides/conversation-state)。的更多信息。不能与 `conversation`.
+ 上一个模型响应的唯一 ID。使用它可以
+ 创建多轮对话。详细了解
+ [conversation state](/docs/guides/conversation-state)。不能与 `conversation`.
- `prompt: optional ResponsePrompt or null`
@@ -127188,19 +127160,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `variables: optional map[string or ResponseInputText or ResponseInputImage or ResponseInputFile] or null`
- 用于替换提示模板中变量的可选值映射,
- prompt。替换值可以是字符串,也可以是其他
- Response 输入类型,例如图像或文件。
+ 用于替换你
+ prompt。替换的值可以是字符串,也可以是其他
+ Response 输入类型,如图像或文件。
- `string`
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -127208,19 +127180,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `version: optional string or null`
- 提示模板的可选版本。
+ prompt 模板的可选版本。
- `prompt_cache_key: optional string or null`
- 由 OpenAI 用于缓存相似请求的响应,以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
+ 由OpenAI使用,为相似请求缓存响应以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
- `prompt_cache_options: optional object { mode, ttl }`
- 应用于该响应的提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。
+ 应用于该响应的 prompt 缓存选项。支持以下 `gpt-5.6` 及更高版本的模型。
- `mode: "implicit" or "explicit"`
- 是否启用了隐式提示缓存断点。
+ 是否启用了隐式 prompt 缓存断点。
- `"implicit"`
@@ -127228,24 +127200,24 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ttl: "30m"`
- 应用于每个缓存断点的最短生存时间。
+ 应用于每个缓存断点的最短生命周期。
- `"30m"`
- `prompt_cache_retention: optional "in_memory" or "24h" or null`
- 已弃用。请使用 `prompt_cache_options.ttl` 相反。
+ 已弃用。请使用 `prompt_cache_options.ttl` 改为。
- 提示词缓存的保留策略。设置为 `24h` 以启用扩展提示词缓存,使缓存前缀保持更长时间,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
- 此字段表示最长保留策略,而
+ 提示缓存的保留策略。设置为 `24h` 以启用扩展提示缓存,使缓存的前缀保持更长时间有效,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
+ 该字段表示最大保留策略,而
`prompt_cache_options.ttl` 表示最短缓存生命周期。这两个
- 字段彼此独立,不会相互影响。
- 对于 `gpt-5.5`, `gpt-5.5-pro`,及未来模型,仅 `24h` 受支持。
+ 字段是独立的,不会相互影响。
+ 对于 `gpt-5.5`, `gpt-5.5-pro`,以及未来的模型,仅 `24h` 。
对于同时支持两者的旧模型 `in_memory` 和 `24h`,默认值取决于你组织的数据保留策略:
- - 未启用 ZDR 的组织默认使用 `24h`.
- - 启用 ZDR 的组织默认使用 `in_memory` 当 `prompt_cache_retention` 未指定时。
+ - 未启用 ZDR 的组织默认为 `24h`.
+ - 启用 ZDR 的组织默认为 `in_memory` 当 `prompt_cache_retention` 未指定时。
- `"in_memory"`
@@ -127253,18 +127225,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `reasoning: optional Reasoning or null`
- 配置选项,适用于
+ 适用于
[推理模型](https://platform.openai.com/docs/guides/reasoning).
- `context: optional "auto" or "current_turn" or "all_turns" or null`
- 控制在后续轮次中呈现回模型的推理项。
- 如果省略或设置为 `auto`,则由模型确定上下文模式。
+ 控制在后续回合中哪些推理项会被回传给模型。
+ 如果省略或设置为 `auto`,则由模型决定上下文模式。
`gpt-5.6` 模型系列默认为 `all_turns`;早期模型默认为
`current_turn`.
- 在响应中返回时,这是该响应使用的有效推理上下文模式
- 。
+ 在响应中返回时,这是该响应所使用 的有效推理上下文模式
+ 用于该响应。
- `"auto"`
@@ -127274,13 +127246,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `effort: optional ReasoningEffort or null`
- 限制推理模型在推理上的投入程度。当前支持的值
- 包括 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
- 降低推理投入程度可以让响应更快,并减少响应中推理所用的 token 数。并非所有推理模型都支持每个
- 值。请参阅
- 推理指南
+ 限制推理模型在推理上的投入程度。目前支持
+ 的取值有 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
+ 降低推理投入程度可以让响应更快,并减少响应中用于推理的 token
+ 数量。并非所有推理模型都支持每个
+ 取值。有关各模型的支持情况,请参阅
[推理指南](https://platform.openai.com/docs/guides/reasoning)
- 以了解特定模型的支持情况。
+ 。
- `"none"`
@@ -127298,11 +127270,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `generate_summary: optional "auto" or "concise" or "detailed" or null`
- **已弃用:** 请使用 `summary` 相反。
+ **已弃用:** 请使用 `summary` 改为。
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `"auto"`
@@ -127314,7 +127286,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `string`
@@ -127322,7 +127294,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `"standard"`
@@ -127330,11 +127302,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `summary: optional "auto" or "concise" or "detailed" or null`
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `concise` 支持以下模型 `computer-use-preview` 以及之后的所有推理模型 `gpt-5`.
+ `concise` 支持用于 `computer-use-preview` 模型以及之后的 `gpt-5`.
- `"auto"`
@@ -127344,21 +127316,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `safety_identifier: optional string or null`
- 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用策略的应用程序用户。
- ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份识别信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用政策的应用用户。
+ ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `service_tier: optional ServiceTier or null`
指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
+ - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则该项目将使用 'default'。
- 如果设置为 'default',则该请求将使用所选模型的标准定价和性能进行处理。
- 如果设置为 '[flex](/docs/guides/flex-processing)',则该请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别选择启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 `service_tier=fast` 或 `service_tier=priority` 参数用于 Responses 或 Chat Completions。响应将显示 `service_tier=priority` ,无论你是否在请求中指定了 `service_tier=fast` 或 `priority` 。
- - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级返回的响应将显示 `service_tier=ultrafast`.
- - 如果未设置,默认行为是 'auto'。
+ - 若要在请求级别启用 [快速模式](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过它处理的响应将显示 `service_tier=ultrafast`.
+ - 未设置时,默认行为为 'auto'。
- 当设置 `service_tier` 参数时,响应正文将包含基于实际用于处理该请求的处理模式的 `service_tier` 值。此响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应体中将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。此响应中的值可能与该参数中设置的值不同。
- `"auto"`
@@ -127376,8 +127348,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional ResponseStatus`
- 响应生成的状态。取值之一为 `completed`, `failed`,
- `in_progress`, `cancelled`, `queued`, or `incomplete`.
+ 响应生成的状态。可选值为 `completed`, `failed`,
+ `in_progress`, `cancelled`, `queued`,或 `incomplete`.
- `"completed"`
@@ -127393,8 +127365,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: optional ResponseTextConfig`
- 用于配置模型文本响应的选项。可以是纯文本,也可以是结构化的 JSON 数据。详见:
- 文本输入与输出:
+ 模型文本响应的配置选项。可以是纯
+ 文本或结构化 JSON 数据。了解更多:
- [文本输入与输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
@@ -127403,79 +127375,79 @@ curl https://api.openai.com/v1/responses/resp_123 \
用于指定模型必须输出的格式的对象。
- 设置为 `{ "type": "json_schema" }` 时,将启用结构化输出,
- 功能,从而确保模型的输出与你提供的 JSON schema 相匹配。详见
+ 配置 `{ "type": "json_schema" }` 可启用结构化输出,
+ 从而确保模型匹配你提供的 JSON schema。更多信息请参阅
[结构化输出指南](/docs/guides/structured-outputs).
- 默认的格式为 `{ "type": "text" }` ,且不包含其他选项。
+ 默认格式为 `{ "type": "text" }` ,不包含任何额外选项。
- **不建议在 gpt-4o 及更新模型上使用:**
+ **不推荐用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
- 的模型,建议优先使用该格式。
+ 设置为 `{ "type": "json_object" }` 会启用旧版 JSON 模式,该模式
+ 可确保模型生成的消息是合法 JSON。对于支持 `json_schema`
+ 的模型,建议优先使用它。
- `ResponseFormatText object { type }`
- 默认的响应格式。用于生成文本响应。
+ 默认响应格式。用于生成文本响应。
- `type: "text"`
- 正在定义的响应格式的类型。始终为 `text`.
+ 正在定义的响应格式类型。始终为 `text`.
- `"text"`
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化的 JSON 响应。
+ JSON Schema 响应格式。用于生成结构化 JSON 响应。
详细了解 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
- 下划线和连字符,最大长度为 64。
+ 下划线和短横线,最大长度为 64。
- `schema: map[unknown]`
- 响应格式的 schema,以 JSON Schema 对象描述。
- 了解如何构建 JSON schema [此处](https://json-schema.org/).
+ 响应格式的架构,以 JSON Schema 对象形式描述。
+ 了解如何构建 JSON 架构 [此处](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式的类型。始终为 `json_schema`.
+ 正在定义的响应格式类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
响应格式用途的描述,供模型用于
- 确定如何按该格式进行响应。
+ 确定如何按该格式响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 一致性。
- 如果设置为 true,模型将始终遵循
- 字段中 `schema` 定义的精确 schema。仅支持 JSON Schema 的一个子集,当
- `strict` 是 `true`。要了解更多信息,请阅读 [Structured Outputs
+ 生成输出时是否启用严格的架构遵循。
+ 如果设置为 true,模型将始终遵循 字段中定义的
+ 确切架构。当 设置为 `schema` true 时,仅支持 JSON Schema 的一个子集
+ `strict` 是 `true`。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较早的生成 JSON 响应的方法。
- 使用 `json_schema` 对支持它的模型是推荐的做法。请注意
- 模型在没有系统或用户消息指示的情况下不会生成
- JSON。
+ JSON 对象响应格式。一种较旧的 JSON 响应生成方法。建议。
+ 对于支持 的模型,使用 `json_schema` 。请注意,模型不会在没有系统或用户消息指示
+ 的情况下生成 JSON
+ 。
- `type: "json_object"`
- 正在定义的响应格式的类型。始终为 `json_object`.
+ 正在定义的响应格式类型。始终为 `json_object`.
- `"json_object"`
- `verbosity: optional "low" or "medium" or "high" or null`
- 约束模型响应的详细程度。较低的值会产生
- 更简洁的响应,较高的值会产生更详细的响应。
+ 约束模型响应的详尽程度。较低的值将导致
+ 更简洁的响应,而较高的值将导致更冗长的响应。
当前支持的值包括 `low`, `medium`,和 `high`。默认值为
`medium`.
@@ -127487,20 +127459,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `top_logprobs: optional number or null`
- 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的最大最可能
- token 数量,每个 token 都附带对应的对数
+ 一个介于 0 到 20 之间的整数,指定在每个 token 位置返回的
+ 最可能 token 的最大数量,每个 token 都有一个关联的对数
概率。在某些情况下,返回的 token 数量可能少于
- 所请求的数量。
+ 请求的数量。
- `truncation: optional "auto" or "disabled" or null`
用于模型响应的截断策略。
- - `auto`:如果此 Response 的输入超过
- 模型的上下文窗口大小,模型将通过从对话开头丢弃条目来截断
- 响应以适配上下文窗口。
- - `disabled` (默认):如果输入大小将超出模型的上下文窗口
- 大小,请求将失败并返回 400 错误。
+ - `auto`:如果此 Response 的输入超出
+ 模型的上下文窗口大小,模型将通过从对话开头
+ 丢弃条目来截断响应以适配上下文窗口。
+ - `disabled` (默认):如果输入大小将超过模型的上下文窗口
+ 大小,请求将以 400 错误失败。
- `"auto"`
@@ -127509,7 +127481,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `usage: optional ResponseUsage`
表示 token 使用详情,包括输入 token、输出 token,
- 的输出 token 明细,以及所使用的 token 总数。
+ 输出 token 的细分,以及使用的总 token 数。
- `input_tokens: number`
@@ -127517,16 +127489,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_tokens_details: object { cache_write_tokens, cached_tokens }`
- 输入 token 的详细明细。
+ 输入 token 的详细细分。
- `cache_write_tokens: number`
- 已写入缓存的输入 token 数量。
+ 写入缓存的输入 token 的数量。
- `cached_tokens: number`
- 从缓存中检索到的 token 数量。
- [了解更多关于提示缓存的信息](/docs/guides/prompt-caching).
+ 从缓存中检索到的 token 的数量。
+ [有关 prompt caching 的更多信息](/docs/guides/prompt-caching).
- `output_tokens: number`
@@ -127534,25 +127506,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_tokens_details: object { reasoning_tokens }`
- 输出令牌的详细明细。
+ 输出 token 的详细明细。
- `reasoning_tokens: number`
- 推理令牌的数量。
+ 推理 token 的数量。
- `total_tokens: number`
- 使用的令牌总数。
-
- - `compute_units: optional number or null`
-
- 该请求的计算单元。在可用时当前为 null。
+ 使用的 token 总数。
- `user: optional string`
- 此字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
- 用于标识你的最终用户的稳定标识符。
- 通过更好地对相似请求进行分桶以提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 该字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
+ 你的最终用户的稳定标识符。
+ 通过更好地对相似请求进行分桶来提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `sequence_number: number`
@@ -127560,35 +127528,35 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "response.queued"`
- 事件的类型。始终为 response.queued。
+ 事件的类型。始终为 'response.queued'。
- `"response.queued"`
-### 响应推理摘要部分添加事件
+### Response 推理摘要部分已添加事件
- `ResponseReasoningSummaryPartAddedEvent object { item_id, output_index, part, 3 more }`
- 当新的推理摘要部分被添加时触发。
+ 当新增推理摘要分块时触发。
- `item_id: string`
- 与此摘要部分相关联的项目的 ID。
+ 与此摘要分块关联的项的 ID。
- `output_index: number`
- 与此摘要部分相关联的输出项目的索引。
+ 与此摘要分块关联的输出项的索引。
- `part: object { text, type }`
- 被添加的摘要部分。
+ 已添加的摘要分块。
- `text: string`
- 摘要部分的文本。
+ 摘要分块的文本。
- `type: "summary_text"`
- 摘要部分的类型。始终为 `summary_text`.
+ 摘要分块的类型。始终为 `summary_text`.
- `"summary_text"`
@@ -127598,7 +127566,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `summary_index: number`
- 推理摘要内此摘要部分的索引。
+ 该摘要分块在推理摘要中的索引。
- `type: "response.reasoning_summary_part.added"`
@@ -127606,31 +127574,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.reasoning_summary_part.added"`
-### Response Reasoning Summary Part Done Event
+### 响应推理摘要部分完成事件
- `ResponseReasoningSummaryPartDoneEvent object { item_id, output_index, part, 4 more }`
- 在推理摘要部分完成时发出。
+ 当某个推理摘要分块完成时发出。
- `item_id: string`
- 与此摘要部分相关联的项目的 ID。
+ 与此摘要分块关联的项的 ID。
- `output_index: number`
- 与此摘要部分相关联的输出项目的索引。
+ 与此摘要分块关联的输出项的索引。
- `part: object { text, type }`
- 已完成的摘要部分。
+ 已完成的摘要分块。
- `text: string`
- 摘要部分的文本。
+ 摘要分块的文本。
- `type: "summary_text"`
- 摘要部分的类型。始终为 `summary_text`.
+ 摘要分块的类型。始终为 `summary_text`.
- `"summary_text"`
@@ -127640,7 +127608,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `summary_index: number`
- 推理摘要内此摘要部分的索引。
+ 该摘要分块在推理摘要中的索引。
- `type: "response.reasoning_summary_part.done"`
@@ -127650,20 +127618,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "incomplete"`
- 摘要部分的完成状态。在该部分正常完成时省略,
- 在生成被中断时设置为 `incomplete` 。
+ 该摘要分块的完成状态。当该分块已完成时省略。
+ 正常工作并设置为 `incomplete` 当生成被中断时。
- `"incomplete"`
-### Response 推理摘要文本增量事件
+### 响应推理摘要文本增量事件
- `ResponseReasoningSummaryTextDeltaEvent object { delta, item_id, output_index, 3 more }`
- 当有增量被添加到推理摘要文本时触发。
+ 当向推理摘要文本添加增量时触发。
- `delta: string`
- 已添加到摘要的文本增量。
+ 添加到摘要的文本增量。
- `item_id: string`
@@ -127679,7 +127647,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `summary_index: number`
- 推理摘要内此摘要部分的索引。
+ 该摘要分块在推理摘要中的索引。
- `type: "response.reasoning_summary_text.delta"`
@@ -127695,11 +127663,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 此摘要文本所关联条目的 ID。
+ 与此摘要文本关联的项的 ID。
- `output_index: number`
- 此摘要文本所关联输出项的索引。
+ 与此摘要文本关联的输出项的索引。
- `sequence_number: number`
@@ -127707,7 +127675,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `summary_index: number`
- 推理摘要内此摘要部分的索引。
+ 该摘要分块在推理摘要中的索引。
- `text: string`
@@ -127719,27 +127687,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.reasoning_summary_text.done"`
-### 响应推理文本增量事件
+### Response Reasoning Text Delta Event
- `ResponseReasoningTextDeltaEvent object { content_index, delta, item_id, 3 more }`
- 在向推理文本添加增量时发出。
+ 当向推理文本添加增量时触发。
- `content_index: number`
- 与此增量关联的推理内容部分的索引。
+ 此增量关联的推理内容部分的索引。
- `delta: string`
- 已添加到推理内容的文本增量。
+ 添加到推理内容中的文本增量。
- `item_id: string`
- 与此推理文本增量关联的项的 ID。
+ 此推理文本增量所属项的 ID。
- `output_index: number`
- 与此推理文本增量关联的输出项的索引。
+ 此推理文本增量所属输出项的索引。
- `sequence_number: number`
@@ -127759,15 +127727,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `content_index: number`
- 推理内容片段的索引。
+ 推理内容部分的索引。
- `item_id: string`
- 与此推理文本关联的条目 ID。
+ 此推理文本所关联的项的 ID。
- `output_index: number`
- 与此推理文本关联的输出条目索引。
+ 此推理文本所关联的输出项的索引。
- `sequence_number: number`
@@ -127783,7 +127751,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.reasoning_text.done"`
-### Response Refusal Delta Event
+### 响应拒绝增量事件
- `ResponseRefusalDeltaEvent object { content_index, delta, item_id, 3 more }`
@@ -127791,19 +127759,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `content_index: number`
- 拒绝文本所添加到的内容部分的索引。
+ 拒绝文本所添加到内容分块的索引。
- `delta: string`
- 所添加的拒绝文本。
+ 被添加的拒绝文本。
- `item_id: string`
- 拒绝文本所添加到的输出项的 ID。
+ 拒绝文本所添加到输出项的 ID。
- `output_index: number`
- 拒绝文本所添加到的输出项的索引。
+ 拒绝文本所添加到输出项的索引。
- `sequence_number: number`
@@ -127815,27 +127783,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.refusal.delta"`
-### Response Refusal Done Event
+### Response 拒绝完成事件
- `ResponseRefusalDoneEvent object { content_index, item_id, output_index, 3 more }`
- 在拒绝文本最终确定时发出。
+ 当拒绝文本完成时发出。
- `content_index: number`
- 拒绝文本最终确定时所对应的内容分片的索引。
+ 拒绝文本完成时所处内容片段的索引。
- `item_id: string`
- 拒绝文本最终确定时所对应的输出项的 ID。
+ 拒绝文本完成时所处输出项的 ID。
- `output_index: number`
- 拒绝文本最终确定时所对应的输出项的索引。
+ 拒绝文本完成时所处输出项的索引。
- `refusal: string`
- 已最终确定的拒绝文本。
+ 已完成的拒绝文本。
- `sequence_number: number`
@@ -127847,23 +127815,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.refusal.done"`
-### Response Shell Call Command Added Event
+### 已添加 Response Shell 调用命令事件
- `ResponseShellCallCommandAddedEvent object { command, command_index, output_index, 2 more }`
- 指示已将 shell 命令添加到工具调用的流式事件。
+ 一个流式事件,表示一条 shell 命令已被添加到工具调用中。
- `command: string`
- 已添加的 shell 命令。
+ 被添加的 shell 命令。
- `command_index: number`
- 已添加的 shell 命令的索引。
+ 被添加的 shell 命令的索引。
- `output_index: number`
- 已更新的输出项的索引。
+ 被更新的输出项的索引。
- `sequence_number: number`
@@ -127871,11 +127839,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "response.shell_call_command.added"`
- 事件的类型,always `response.shell_call_command.added`.
+ 事件的类型,始终为 `response.shell_call_command.added`.
- `"response.shell_call_command.added"`
-### Response Shell Call Command Delta Event
+### 响应 Shell 调用命令增量事件
- `ResponseShellCallCommandDeltaEvent object { command_index, delta, output_index, 3 more }`
@@ -127883,15 +127851,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `command_index: number`
- 被更新的 shell 命令的索引。
+ 已更新的 shell 命令的索引。
- `delta: string`
- 被追加的 shell 命令增量内容。
+ 已追加的 shell 命令增量。
- `output_index: number`
- 已更新的输出项的索引。
+ 被更新的输出项的索引。
- `sequence_number: number`
@@ -127899,7 +127867,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "response.shell_call_command.delta"`
- 事件的类型,always `response.shell_call_command.delta`.
+ 事件的类型,始终为 `response.shell_call_command.delta`.
- `"response.shell_call_command.delta"`
@@ -127907,11 +127875,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
为填充事件负载而添加的混淆字符串。
-### 响应 Shell 调用命令完成事件
+### Response Shell Call Command Done Event
- `ResponseShellCallCommandDoneEvent object { command, command_index, output_index, 2 more }`
- 指示 shell 命令已完成的流事件。
+ 指示 shell 命令已完成的流式事件。
- `command: string`
@@ -127923,7 +127891,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_index: number`
- 已更新的输出项的索引。
+ 被更新的输出项的索引。
- `sequence_number: number`
@@ -127931,15 +127899,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "response.shell_call_command.done"`
- 事件的类型,always `response.shell_call_command.done`.
+ 事件的类型,始终为 `response.shell_call_command.done`.
- `"response.shell_call_command.done"`
-### Response Shell 调用输出内容增量事件
+### 响应 Shell 调用输出内容增量事件
- `ResponseShellCallOutputContentDeltaEvent object { command_index, delta, item_id, 3 more }`
- 表示 shell 调用输出被增量添加的流事件。
+ 指示 shell 调用输出被增量添加的流式事件。
- `command_index: number`
@@ -127963,7 +127931,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_index: number`
- 已更新的输出项的索引。
+ 被更新的输出项的索引。
- `sequence_number: number`
@@ -127971,7 +127939,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "response.shell_call_output_content.delta"`
- 事件的类型,always `response.shell_call_output_content.delta`.
+ 事件的类型,始终为 `response.shell_call_output_content.delta`.
- `"response.shell_call_output_content.delta"`
@@ -127991,11 +127959,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: array of object { outcome, stderr, stdout, created_by }`
- 为 shell 命令发出的输出内容。
+ shell 命令发出的输出内容。
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -128003,13 +127971,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -128017,7 +127985,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -128031,11 +127999,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `output_index: number`
- 已更新的输出项的索引。
+ 被更新的输出项的索引。
- `sequence_number: number`
@@ -128043,16 +128011,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "response.shell_call_output_content.done"`
- 事件的类型,always `response.shell_call_output_content.done`.
+ 事件的类型,始终为 `response.shell_call_output_content.done`.
- `"response.shell_call_output_content.done"`
-### Response Status
+### 响应状态
- `ResponseStatus = "completed" or "failed" or "in_progress" or 3 more`
- 响应生成的状态。取值之一为 `completed`, `failed`,
- `in_progress`, `cancelled`, `queued`, or `incomplete`.
+ 响应生成的状态。可选值为 `completed`, `failed`,
+ `in_progress`, `cancelled`, `queued`,或 `incomplete`.
- `"completed"`
@@ -128066,23 +128034,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"incomplete"`
-### Response Stream Event
+### 响应流事件
- `ResponseStreamEvent = ResponseAudioDeltaEvent or ResponseAudioDoneEvent or ResponseAudioTranscriptDeltaEvent or 55 more`
- 在流式传输响应时发出的事件。
+ 在响应流式传输期间发出的事件。
- `ResponseAudioDeltaEvent object { delta, sequence_number, type }`
- 当出现部分音频响应时发出。
+ 当存在部分音频响应时发出。
- `delta: string`
- 一段 Base64 编码的响应音频字节。
+ Base64 编码的响应音频字节块。
- `sequence_number: number`
- 该流式响应片段的序列号。
+ 流响应中此块的序列号。
- `type: "response.audio.delta"`
@@ -128092,11 +128060,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseAudioDoneEvent object { sequence_number, type }`
- 当音频响应完成时发出。
+ 音频响应完成时触发。
- `sequence_number: number`
- 增量事件的序列号。
+ 增量数据的序列号。
- `type: "response.audio.done"`
@@ -128124,7 +128092,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseAudioTranscriptDoneEvent object { sequence_number, type }`
- 当完整音频转写完成时发出。
+ 在完整音频转录完成时发出。
- `sequence_number: number`
@@ -128138,23 +128106,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseCodeInterpreterCallCodeDeltaEvent object { delta, item_id, output_index, 2 more }`
- 当代码解释器流式传输出部分代码片段时发出。
+ 当代码解释器流式输出部分代码片段时触发。
- `delta: string`
- 代码解释器正在流式传输的部分代码片段。
+ 由代码解释器流式输出的部分代码片段。
- `item_id: string`
- 代码解释器工具调用条目的唯一标识符。
+ 代码解释器工具调用项的唯一标识符。
- `output_index: number`
- 响应中正在流式传输代码的输出条目的索引。
+ 响应中正在流式输出代码的输出项的索引。
- `sequence_number: number`
- 该事件的序列号,用于对流式传输事件进行排序。
+ 此事件的序列号,用于对流式事件进行排序。
- `type: "response.code_interpreter_call_code.delta"`
@@ -128164,7 +128132,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseCodeInterpreterCallCodeDoneEvent object { code, item_id, output_index, 2 more }`
- 当代码解释器最终确定代码片段时发出。
+ 当代码解释器最终确定代码片段时触发。
- `code: string`
@@ -128172,15 +128140,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 代码解释器工具调用条目的唯一标识符。
+ 代码解释器工具调用项的唯一标识符。
- `output_index: number`
- 响应中输出项的索引,该输出项的代码已最终确定。
+ 响应中已最终确定代码的输出项的索引。
- `sequence_number: number`
- 该事件的序列号,用于对流式传输事件进行排序。
+ 此事件的序列号,用于对流式事件进行排序。
- `type: "response.code_interpreter_call_code.done"`
@@ -128194,7 +128162,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 代码解释器工具调用条目的唯一标识符。
+ 代码解释器工具调用项的唯一标识符。
- `output_index: number`
@@ -128202,7 +128170,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `sequence_number: number`
- 该事件的序列号,用于对流式传输事件进行排序。
+ 此事件的序列号,用于对流式事件进行排序。
- `type: "response.code_interpreter_call.completed"`
@@ -128216,15 +128184,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 代码解释器工具调用条目的唯一标识符。
+ 代码解释器工具调用项的唯一标识符。
- `output_index: number`
- 响应中正在执行代码解释器调用的输出项的索引。
+ 响应中代码解释器调用正在进行的输出项索引。
- `sequence_number: number`
- 该事件的序列号,用于对流式传输事件进行排序。
+ 此事件的序列号,用于对流式事件进行排序。
- `type: "response.code_interpreter_call.in_progress"`
@@ -128238,15 +128206,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 代码解释器工具调用条目的唯一标识符。
+ 代码解释器工具调用项的唯一标识符。
- `output_index: number`
- 响应中代码解释器正在解释代码的输出项索引。
+ 响应中代码解释器正在解释代码的输出项的索引。
- `sequence_number: number`
- 该事件的序列号,用于对流式传输事件进行排序。
+ 此事件的序列号,用于对流式事件进行排序。
- `type: "response.code_interpreter_call.interpreting"`
@@ -128268,7 +128236,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_at: number`
- 创建此 Response 时的 Unix 时间戳(以秒为单位)。
+ 此 Response 创建时的 Unix 时间戳(以秒为单位)。
- `error: ResponseError or null`
@@ -128324,87 +128292,89 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `incomplete_details: object { reason } or null`
- 有关响应未完成原因的详细信息。
+ 有关响应不完整的详细原因。
- - `reason: optional "max_output_tokens" or "content_filter"`
+ - `reason: optional "max_output_tokens" or "max_messages" or "content_filter"`
- 响应未完成的原因。
+ 响应不完整的原因。
- `"max_output_tokens"`
+ - `"max_messages"`
+
- `"content_filter"`
- `instructions: string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more or null`
插入到模型上下文中的系统(或开发者)消息。
- 当与 `previous_response_id`,配合使用时,前一次
- 响应的指令不会延续到下一次响应。这便于在新响应中
- 替换系统(或开发者)消息。
+ 当与 `previous_response_id`,配合使用时,上一个
+ response 中的 instructions 不会延续到下一个 response。这样可以轻松地
+ 在新的 response 中替换系统(或开发者)消息。
- `string`
- 发送给模型的文本输入,相当于使用
+ 发送给模型的文本输入,等同于
`developer` 角色的文本输入。
- `InputItemList = array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 发送给模型的一个或多个输入项的列表,包含
+ 发送给模型的一个或多个输入项列表,包含
不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` role. Messages with the
- `assistant` role are presumed to have been generated by the model in previous
- interactions.
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色给出的指令。带有
+ `assistant` 角色的消息被视为模型在之前的
+ 交互中生成。
- `content: string or ResponseInputMessageContentList`
- Text, image, or audio input to the model, used to generate a response.
- Can also contain previous assistant responses.
+ 发送给模型的文本、图像或音频输入,用于生成响应。
+ 也可以包含之前的助手响应。
- `TextInput = string`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputMessageContentList = array of ResponseInputContent`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -128416,25 +128386,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -128444,13 +128414,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -128460,33 +128430,33 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `assistant`, `system`, or
+ 消息输入的角色。其一为 接口 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -128499,9 +128469,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -128509,24 +128479,24 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: optional "message"`
- 消息输入的类型。始终为 `message`.
+ 消息输入的类型。始终为 接口 `message`.
- `"message"`
- `Message object { content, role, status, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` 角色的文本输入。
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色的文本输入。
- `content: ResponseInputMessageContentList`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `system`, or `developer`.
+ 消息输入的角色。其一为 接口 `user`, `system`,或 `developer`.
- `"user"`
@@ -128536,8 +128506,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -128557,7 +128527,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -128565,15 +128535,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -128589,7 +128559,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -128599,25 +128569,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -128629,7 +128599,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -128637,11 +128607,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -128695,15 +128665,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -128715,8 +128685,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -128732,9 +128702,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -128742,8 +128712,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -128755,7 +128725,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -128780,11 +128750,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -128802,7 +128772,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -128811,7 +128781,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -128823,7 +128793,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -128839,8 +128809,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -128864,7 +128834,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -128878,7 +128848,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -128904,7 +128874,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -128922,7 +128892,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -128941,7 +128911,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -128951,11 +128921,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -128975,15 +128945,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -129015,19 +128985,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -129051,8 +129021,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -129068,7 +129038,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -129084,7 +129054,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -129092,44 +129062,44 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCallOutput object { call_id, output, type, 3 more }`
- 一次 computer 工具调用的输出。
+ 计算机工具调用的输出。
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `id: optional string or null`
- computer 工具调用输出的 ID。
+ 计算机工具调用输出的 ID。
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 已被开发者确认的 API 所报告的安全检查结果。
+ 开发者已确认的 API 所报告的安全检查。
- `id: string`
@@ -129145,7 +129115,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值为 `in_progress`, `completed`, or `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -129156,7 +129126,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -129164,12 +129134,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -129179,11 +129149,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -129201,7 +129171,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -129215,7 +129185,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -129233,7 +129203,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -129245,14 +129215,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -129302,8 +129272,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -129317,7 +129287,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: string or array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的文本、图片或文件输出。
+ 函数工具调用的文本、图像或文件输出。
- `string`
@@ -129325,61 +129295,61 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的内容输出(文本、图片、文件)数组。
+ 函数工具调用的内容输出(文本、图像、文件)数组。
- `ResponseInputTextContent object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision)
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `detail: optional ImageDetail or null`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -129389,13 +129359,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -129409,23 +129379,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -129437,7 +129407,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string or null`
- 函数工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
+ 函数工具调用输出的唯一 ID。当此项通过 API 返回时填充。
- `call_id: optional string or null`
@@ -129477,7 +129447,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -129493,7 +129463,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目类型。始终为 `tool_search_call`.
+ 项的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
@@ -129561,37 +129531,37 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -129604,11 +129574,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -129628,7 +129598,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -129644,15 +129614,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -129666,7 +129636,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -129674,7 +129644,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -129686,7 +129656,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -129694,21 +129664,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -129734,18 +129704,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -129753,22 +129723,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -129778,23 +129748,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -129805,11 +129775,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -129827,21 +129797,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -129849,14 +129819,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -129888,32 +129858,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -129921,13 +129891,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -129935,9 +129905,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -129949,22 +129919,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -129973,7 +129943,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -129983,7 +129953,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -130013,29 +129983,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -130071,7 +130041,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -130081,11 +130051,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -130095,7 +130065,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -130103,7 +130073,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -130112,13 +130082,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -130127,7 +130097,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -130154,7 +130124,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -130165,7 +130135,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -130182,13 +130152,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -130204,7 +130174,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -130214,7 +130184,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -130238,7 +130208,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -130262,13 +130232,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -130292,7 +130262,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -130300,13 +130270,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -130326,7 +130296,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -130338,13 +130308,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -130358,11 +130328,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -130388,7 +130358,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -130406,7 +130376,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -130420,19 +130390,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -130452,19 +130422,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -130472,11 +130442,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -130522,7 +130492,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -130534,11 +130504,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -130552,7 +130522,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -130562,7 +130532,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -130572,23 +130542,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -130606,13 +130576,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目类型。始终为 `tool_search_output`.
+ 项的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `id: optional string or null`
- 此工具搜索输出的唯一 ID。
+ 该工具搜索输出的唯一 ID。
- `call_id: optional string or null`
@@ -130640,13 +130610,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `role: "developer"`
- 提供其他工具的角色。仅 `developer` 受支持。
+ 提供这些额外工具的角色。仅支持 `developer` 。
- `"developer"`
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 此项目提供的其他工具列表。
+ 在该条目中提供的额外工具列表。
- `Function object { name, parameters, strict, 5 more }`
@@ -130680,45 +130650,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -130726,7 +130696,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -130738,7 +130708,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -130746,21 +130716,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -130786,18 +130756,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -130805,22 +130775,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -130830,23 +130800,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -130857,11 +130827,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -130879,21 +130849,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -130901,14 +130871,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -130940,32 +130910,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -130973,13 +130943,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -130987,9 +130957,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -131001,22 +130971,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -131025,7 +130995,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -131035,7 +131005,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -131091,7 +131061,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -131101,11 +131071,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -131115,7 +131085,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -131123,7 +131093,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -131132,13 +131102,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -131147,7 +131117,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -131174,7 +131144,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -131185,7 +131155,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -131202,13 +131172,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -131224,7 +131194,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -131234,7 +131204,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -131260,11 +131230,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -131290,19 +131260,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -131322,19 +131292,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -131342,11 +131312,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -131392,7 +131362,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -131404,11 +131374,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -131422,7 +131392,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -131432,7 +131402,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -131442,23 +131412,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -131476,19 +131446,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目类型。始终为 `additional_tools`.
+ 项的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `id: optional string or null`
- 此其他工具项目的唯一 ID。
+ 该额外工具条目的唯一 ID。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -131501,7 +131471,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -131521,7 +131491,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -131531,20 +131501,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -131554,7 +131524,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Compaction object { encrypted_content, type, id }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -131562,17 +131532,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `id: optional string or null`
- 压缩条目的 ID。
+ 压缩项的 ID。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -131596,7 +131566,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -131619,7 +131589,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -131631,23 +131601,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -131665,13 +131635,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -131687,11 +131657,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -131705,11 +131675,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -131723,7 +131693,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -131733,7 +131703,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -131741,13 +131711,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -131761,7 +131731,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
@@ -131773,7 +131743,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最大挂钟时间(毫秒)。
+ 允许 shell 命令运行的 wall-clock 最长时间(毫秒)。
- `call_id: string`
@@ -131781,13 +131751,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
- `id: optional string or null`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -131823,7 +131793,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -131833,7 +131803,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ShellCallOutput object { call_id, output, type, 4 more }`
- shell 工具调用发出的流式输出项。
+ shell 工具调用发出的流式输出条目。
- `call_id: string`
@@ -131841,7 +131811,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: array of ResponseFunctionShellCallOutputContent`
- stdout 和 stderr 输出的捕获块及其关联结果。
+ 捕获的 stdout 和 stderr 输出块,以及它们关联的结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -131853,13 +131823,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -131867,27 +131837,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
- `stderr: string`
- shell 调用捕获的 stderr 输出。
+ 为该 shell 调用捕获的 stderr 输出。
- `stdout: string`
- shell 调用捕获的 stdout 输出。
+ 为该 shell 调用捕获的 stdout 输出。
- `type: "shell_call_output"`
- 条目的类型,恒为 `shell_call_output`.
+ item 的类型。始终为 `shell_call_output`.
- `"shell_call_output"`
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -131929,11 +131899,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 表示使用 diff 补丁创建、删除或更新文件的工具调用。
+ 表示通过 diff 补丁创建、删除或更新文件的工具调用。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
@@ -131945,7 +131915,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 创建文件时要应用的统一 diff 内容。
+ 创建文件时应用的 unified diff 内容。
- `path: string`
@@ -131977,7 +131947,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 要应用于现有文件的统一 diff 内容。
+ 应用于现有文件的 unified diff 内容。
- `path: string`
@@ -131991,7 +131961,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -131999,13 +131969,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
- `id: optional string or null`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -132033,15 +132003,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { call_id, status, type, 3 more }`
- apply patch 工具调用发出的流式输出。
+ 由 apply patch 工具调用发出的流式输出。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -132049,13 +132019,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
- `id: optional string or null`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -132111,7 +132081,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -132119,29 +132089,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -132149,31 +132119,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { approval_request_id, approve, type, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
- `id: optional string or null`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `reason: optional string or null`
@@ -132181,7 +132151,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -132189,11 +132159,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -132201,14 +132171,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -132248,7 +132218,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -132262,11 +132232,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 由你的代码生成的自定义工具调用输出,将被发送回模型。
+ 由你的代码生成的自定义工具调用的输出,将发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -132283,11 +132253,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -132301,7 +132271,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- 自定义工具调用输出在 OpenAI 平台中的唯一 ID。
+ 在 OpenAI 平台中该自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -132351,7 +132321,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -132379,11 +132349,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompactionTrigger object { type, id }`
- 压缩当前上下文。必须是最后一个输入项。
+ 压缩当前上下文。必须作为最后一个输入项。
- `type: "compaction_trigger"`
- 条目的类型,恒为 `compaction_trigger`.
+ item 的类型。始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -132397,11 +132367,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 要引用的条目 ID。
+ 被引用条目的 ID。
- `type: optional "item_reference" or null`
- 要引用的条目类型。始终为 `item_reference`.
+ 被引用条目的类型。始终为 `item_reference`.
- `"item_reference"`
@@ -132417,7 +132387,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -132425,7 +132395,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目类型。始终为 `program`.
+ 项的类型。始终为 `program`.
- `"program"`
@@ -132441,7 +132411,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -132453,14 +132423,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目类型。始终为 `program_output`.
+ 项的类型。始终为 `program_output`.
- `"program_output"`
- `metadata: Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
格式,以及通过 API 或控制台查询对象。
键为字符串,最长 64 个字符。值为字符串
@@ -132469,8 +132439,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: ResponsesModel`
用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI
- 提供了多种不同能力、性能
- 特性和定价的模型。请参阅 [模型指南](/docs/models)
+ 提供了众多功能、性能
+ 特性和价位各异的模型。请参阅 [模型指南](/docs/models)
以浏览和比较可用的模型。
- `string`
@@ -132693,12 +132663,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
由模型生成的内容项数组。
- - 该数组中项的数量和顺序 `output` 取决于
- 模型的响应。
- - 与直接访问该数组的 `output` 第一项并
- 假设它是一 `assistant` 个包含模型生成内容的
- 消息相比,你也可以考虑使用 `output_text` 属性(在
- 受支持的 SDK 中可用)。
+ - 该数组中项的长度和顺序取决于 `output` 模型的响应。
+ 与其访问。
+ - 数组中的第一项并 `output` 假设它是一个
+ 包含模型生成内容的 `assistant` 消息,不如使用
+ 属性(在受支持的 开发工具包 `output_text` 中可用)。
+ SDK。
- `ResponseOutputMessage object { id, content, role, 3 more }`
@@ -132706,8 +132676,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -132719,7 +132689,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -132744,11 +132714,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -132766,7 +132736,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -132775,7 +132745,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -132825,8 +132795,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -132851,15 +132821,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -132867,8 +132837,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -132912,7 +132882,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `name: optional string`
@@ -132925,7 +132895,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -132933,12 +132903,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -132948,11 +132918,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -132970,7 +132940,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -132984,7 +132954,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -133002,7 +132972,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -133014,14 +132984,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -133033,7 +133003,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -133049,8 +133019,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -133070,8 +133040,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `ComputerCallOutput object { id, call_id, output, 4 more }`
@@ -133081,16 +133051,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"completed"`
@@ -133102,13 +133072,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、已被
+ API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -133125,13 +133095,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -133144,7 +133114,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -133162,7 +133132,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -133172,20 +133142,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -133205,7 +133175,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -133213,7 +133183,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目的类型,恒为 `program`.
+ item 的类型。始终为 `program`.
- `"program"`
@@ -133229,7 +133199,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -133241,7 +133211,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目的类型,恒为 `program_output`.
+ item 的类型。始终为 `program_output`.
- `"program_output"`
@@ -133279,13 +133249,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目的类型,恒为 `tool_search_call`.
+ item 的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -133351,45 +133321,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -133397,7 +133367,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -133409,7 +133379,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -133417,21 +133387,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -133457,18 +133427,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -133476,22 +133446,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -133501,23 +133471,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -133528,11 +133498,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -133550,21 +133520,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -133572,14 +133542,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -133611,32 +133581,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -133644,13 +133614,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -133658,9 +133628,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -133672,22 +133642,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -133696,7 +133666,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -133706,7 +133676,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -133762,7 +133732,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -133772,11 +133742,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -133786,7 +133756,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -133794,7 +133764,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -133803,13 +133773,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -133818,7 +133788,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -133845,7 +133815,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -133856,7 +133826,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -133873,13 +133843,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -133895,7 +133865,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -133905,7 +133875,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -133931,11 +133901,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -133961,19 +133931,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -133993,19 +133963,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -134013,11 +133983,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -134063,7 +134033,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -134075,11 +134045,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -134093,7 +134063,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -134103,7 +134073,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -134113,23 +134083,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -134147,13 +134117,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目的类型,恒为 `tool_search_output`.
+ item 的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -134183,7 +134153,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -134217,45 +134187,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -134263,7 +134233,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -134275,7 +134245,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -134283,21 +134253,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -134323,18 +134293,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -134342,22 +134312,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -134367,23 +134337,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -134394,11 +134364,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -134416,21 +134386,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -134438,14 +134408,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -134477,32 +134447,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -134510,13 +134480,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -134524,9 +134494,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -134538,22 +134508,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -134562,7 +134532,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -134572,7 +134542,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -134628,7 +134598,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -134638,11 +134608,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -134652,7 +134622,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -134660,7 +134630,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -134669,13 +134639,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -134684,7 +134654,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -134711,7 +134681,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -134722,7 +134692,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -134739,13 +134709,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -134761,7 +134731,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -134771,7 +134741,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -134797,11 +134767,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -134827,19 +134797,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -134859,19 +134829,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -134879,11 +134849,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -134929,7 +134899,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -134941,11 +134911,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -134959,7 +134929,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -134969,7 +134939,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -134979,23 +134949,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -135013,13 +134983,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目的类型,恒为 `additional_tools`.
+ item 的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -135027,21 +134997,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的已加密内容。
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -135065,7 +135035,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -135088,7 +135058,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -135100,23 +135070,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -135134,13 +135104,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -135156,11 +135126,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -135174,11 +135144,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -135192,7 +135162,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -135202,7 +135172,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -135210,13 +135180,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -135230,17 +135200,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -135278,7 +135248,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -135288,7 +135258,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -135322,7 +135292,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。通过 API 返回该条目时填充此字段。
- `call_id: string`
@@ -135330,15 +135300,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -135346,13 +135316,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -135360,7 +135330,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -135374,11 +135344,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`, or `incomplete`.
+ shell 调用输出的状态。可选值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -135414,7 +135384,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -135422,15 +135392,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -135446,7 +135416,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的 diff 创建新文件。
- `"create_file"`
@@ -135460,7 +135430,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "delete_file"`
- 删除指定的文件。
+ 删除指定文件。
- `"delete_file"`
@@ -135478,13 +135448,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "update_file"`
- 使用提供的差异更新现有文件。
+ 使用提供的 diff 更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -135492,7 +135462,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -135522,19 +135492,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -135542,7 +135512,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -135576,7 +135546,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -135584,11 +135554,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -135596,14 +135566,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -135615,7 +135585,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -135653,7 +135623,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -135661,29 +135631,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -135691,29 +135661,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `id: string`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -135745,7 +135715,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -135779,7 +135749,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -135796,11 +135766,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -135808,8 +135778,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -135849,7 +135819,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `parallel_tool_calls: boolean`
@@ -135857,8 +135827,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `temperature: number or null`
- 使用的采样温度,介于 0 到 2 之间。较高的值(例如 0.8)会使输出更加随机,而较低的值(例如 0.2)会使输出更加聚焦和确定。
- 我们通常建议修改此参数或 `top_p` 但不要同时修改两者。
+ 使用的采样温度,介于 0 到 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加聚焦和确定性。
+ 我们通常建议调整此项或 `top_p` 但不要同时调整两者。
- `tool_choice: ToolChoiceOptions or ToolChoiceAllowed or ToolChoiceTypes or 6 more`
@@ -135868,9 +135838,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceOptions = "none" or "auto" or "required"`
- 控制模型调用哪个工具(如果有的话)。
+ 控制模型调用哪个工具(如果有)。
- `none` 表示模型不会调用任何工具,而是生成一条消息。
+ `none` 表示模型将不会调用任何工具,而是生成一条消息。
`auto` 表示模型可以在生成消息或调用一个或
多个工具之间进行选择。
@@ -135902,7 +135872,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of map[unknown]`
- 模型应允许调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -135923,11 +135893,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceTypes object { type }`
指示模型应使用内置工具来生成响应。
- [了解有关内置工具的更多信息](/docs/guides/tools).
+ [了解更多关于内置工具的信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
- 模型应使用的托管工具类型。了解更多关于
+ 模型应使用的 托管工具 类型。了解更多关于
[内置工具](/docs/guides/tools).
允许的值为:
@@ -135972,7 +135942,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceMcp object { server_label, type, name }`
- 使用此选项可以强制模型调用远程 MCP 服务器上的特定工具。
+ 使用此选项可强制模型调用远程 MCP 服务器上的特定工具。
- `server_label: string`
@@ -135990,7 +135960,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceCustom object { name, type }`
- 使用此选项可以强制模型调用特定的自定义工具。
+ 使用此选项可强制模型调用特定的自定义工具。
- `name: string`
@@ -136006,27 +135976,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "programmatic_tool_calling"`
- 要调用的工具。始终为 `programmatic_tool_calling`.
+ 要调用的工具。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ToolChoiceApplyPatch object { type }`
- 在执行工具调用时强制模型调用 apply_patch 工具。
+ 强制模型在执行工具调用时调用 apply_patch 工具。
- `type: "apply_patch"`
- 要调用的工具。始终为 `apply_patch`.
+ 要调用的工具。始终 `apply_patch`.
- `"apply_patch"`
- `ToolChoiceShell object { type }`
- 在需要工具调用时强制模型调用 shell 工具。
+ 在需要工具调用时,强制模型调用 shell 工具。
- `type: "shell"`
- 要调用的工具。始终为 `shell`.
+ 要调用的工具。始终 `shell`.
- `"shell"`
@@ -136037,18 +136007,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
我们支持以下类别的工具:
- - **内置工具**:由 OpenAI 提供的工具,用于扩展模型的
- 能力,例如 [网页搜索](/docs/guides/tools-web-search)
+ - **内置工具**:由 OpenAI 提供的工具,用于扩展
+ 模型的能力,例如 [网页搜索](/docs/guides/tools-web-search)
或 [文件搜索](/docs/guides/tools-file-search)。详细了解
[内置工具](/docs/guides/tools).
- - **MCP 工具**:通过自定义 MCP 服务器与第三方系统集成
- 或 Google Drive 和 SharePoint 等预定义连接器。详细了解
+ - **MCP 工具**: 通过自定义 MCP 服务器与第三方系统集成
+ 或使用 Google Drive 和 SharePoint 等预定义连接器。详细了解
[MCP 工具](/docs/guides/tools-connectors-mcp).
- - **函数调用(自定义工具)**:由你定义的函数,
+ - **函数调用(自定义工具)**: 由你定义的函数,
使模型能够使用强类型参数和输出调用你自己的代码。详细了解
。你也可以使用
- [function calling](/docs/guides/function-calling)。你还可以使用
- 自定义工具调用你自己的代码。
+ [function calling](/docs/guides/function-calling). 你也可以使用
+ 自定义工具来调用你自己的代码。
- `Function object { name, parameters, strict, 5 more }`
@@ -136082,45 +136052,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -136128,7 +136098,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -136140,7 +136110,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -136148,21 +136118,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -136188,18 +136158,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -136207,22 +136177,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -136232,23 +136202,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -136259,11 +136229,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -136281,21 +136251,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -136303,14 +136273,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -136342,32 +136312,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -136375,13 +136345,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -136389,9 +136359,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -136403,22 +136373,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -136427,7 +136397,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -136437,7 +136407,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -136493,7 +136463,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -136503,11 +136473,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -136517,7 +136487,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -136525,7 +136495,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -136534,13 +136504,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -136549,7 +136519,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -136576,7 +136546,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -136587,7 +136557,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -136604,13 +136574,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -136626,7 +136596,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -136636,7 +136606,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -136662,11 +136632,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -136692,19 +136662,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -136724,19 +136694,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -136744,11 +136714,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -136794,7 +136764,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -136806,11 +136776,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -136824,7 +136794,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -136834,7 +136804,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -136844,23 +136814,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -136878,12 +136848,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `top_p: number or null`
- 一种名为核采样的温度采样替代方案,
- 其中模型会考虑 top_p 概率质量排名前列的词元结果。
- 因此,0.1 表示仅考虑构成前 10% 概率质量的词元。
+ 一种温度采样的替代方法,称为核采样,
+ 模型会考虑概率质量排名前 top_p 的标记的结果。
+ 因此 0.1 表示仅考虑构成前 10% 概率质量的标记。
会被考虑。
- 我们通常建议修改此参数或 `temperature` 但不要同时修改两者。
+ 我们通常建议调整此项或 `temperature` 但不要同时调整两者。
- `background: optional boolean or null`
@@ -136892,44 +136862,44 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `completed_at: optional number or null`
- 此 Response 完成时的 Unix 时间戳(以秒为单位)。
- 仅当状态为 `completed`.
+ 此响应完成时的 Unix 时间戳(以秒为单位)。
+ 仅在状态为 `completed`.
- `conversation: optional object { id } or null`
- 此响应所属的对话。此响应的输入项和输出项已自动添加到此对话。
+ 此响应所属的对话。此次响应的输入项和输出项已自动添加到此对话中。
- `id: string`
- 与此响应关联的对话的唯一 ID。
+ 此响应关联的对话的唯一 ID。
- `max_output_tokens: optional number or null`
- 一次响应中可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
+ 响应可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
- `max_tool_calls: optional number or null`
- 响应中可以处理的内置工具调用总次数上限。该上限适用于所有内置工具调用,而非单个工具。模型任何进一步的工具调用尝试都将被忽略。
+ 一次响应中可处理的内置工具调用总次数上限。该上限适用于所有内置工具调用的总和,而非单个工具。模型后续任何再次调用工具的尝试都将被忽略。
- `moderation: optional object { input, output } or null`
- 响应输入和输出的审核结果,前提是请求了已审核的补全。
+ 响应输入与输出的内容审核结果,前提是请求了经过审核的补全。
- `input: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输入的审核结果。
+ 对响应输入的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -136937,7 +136907,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -136945,17 +136915,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -136967,25 +136937,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输出的审核结果。
+ 对响应输出的内容审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
- 为响应输入或输出生成的审核结果。
+ 为响应输入或输出生成的内容审核结果。
- `categories: map[boolean]`
- 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
+ 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则值为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的评分所反映的输入模态。
- `"text"`
@@ -136993,7 +136963,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `category_scores: map[number]`
- 从审核类别到分数的字典。
+ 从内容审核类别到评分的字典。
- `flagged: boolean`
@@ -137001,17 +136971,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: string`
- 生成该结果的审核模型。
+ 生成此结果的内容审核模型。
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果,该值始终为 `moderation_result` 。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在对响应输入或输出进行审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -137023,21 +136993,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "error"`
- 对象类型,对于成功的审核结果,该值始终为 `error` ,用于审核失败的情况。
+ 对象类型,对于成功的审核结果始终为 `error` ,适用于内容审核失败的情况。
- `"error"`
- `output_text: optional string or null`
- 仅限SDK的便捷属性,包含所有输出消息中聚合的文本输出
- 来自所有 `output_text` 数组中的 `output` 条目(如果有)。
+ SDK 独有的便捷属性,包含来自所有
+ 的聚合文本输出 `output_text` 数组中的 `output` 条目(如有)。
在 Python 和 JavaScript SDK 中受支持。
- `previous_response_id: optional string or null`
- 模型上一次响应的唯一 ID。使用它来
- 创建多轮对话。了解有关
- [对话状态](/docs/guides/conversation-state)。的更多信息。不能与 `conversation`.
+ 上一个模型响应的唯一 ID。使用它可以
+ 创建多轮对话。详细了解
+ [conversation state](/docs/guides/conversation-state)。不能与 `conversation`.
- `prompt: optional ResponsePrompt or null`
@@ -137050,19 +137020,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `variables: optional map[string or ResponseInputText or ResponseInputImage or ResponseInputFile] or null`
- 用于替换提示模板中变量的可选值映射,
- prompt。替换值可以是字符串,也可以是其他
- Response 输入类型,例如图像或文件。
+ 用于替换你
+ prompt。替换的值可以是字符串,也可以是其他
+ Response 输入类型,如图像或文件。
- `string`
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -137070,19 +137040,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `version: optional string or null`
- 提示模板的可选版本。
+ prompt 模板的可选版本。
- `prompt_cache_key: optional string or null`
- 由 OpenAI 用于缓存相似请求的响应,以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
+ 由OpenAI使用,为相似请求缓存响应以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
- `prompt_cache_options: optional object { mode, ttl }`
- 应用于该响应的提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。
+ 应用于该响应的 prompt 缓存选项。支持以下 `gpt-5.6` 及更高版本的模型。
- `mode: "implicit" or "explicit"`
- 是否启用了隐式提示缓存断点。
+ 是否启用了隐式 prompt 缓存断点。
- `"implicit"`
@@ -137090,24 +137060,24 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ttl: "30m"`
- 应用于每个缓存断点的最短生存时间。
+ 应用于每个缓存断点的最短生命周期。
- `"30m"`
- `prompt_cache_retention: optional "in_memory" or "24h" or null`
- 已弃用。请使用 `prompt_cache_options.ttl` 相反。
+ 已弃用。请使用 `prompt_cache_options.ttl` 改为。
- 提示词缓存的保留策略。设置为 `24h` 以启用扩展提示词缓存,使缓存前缀保持更长时间,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
- 此字段表示最长保留策略,而
+ 提示缓存的保留策略。设置为 `24h` 以启用扩展提示缓存,使缓存的前缀保持更长时间有效,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
+ 该字段表示最大保留策略,而
`prompt_cache_options.ttl` 表示最短缓存生命周期。这两个
- 字段彼此独立,不会相互影响。
- 对于 `gpt-5.5`, `gpt-5.5-pro`,及未来模型,仅 `24h` 受支持。
+ 字段是独立的,不会相互影响。
+ 对于 `gpt-5.5`, `gpt-5.5-pro`,以及未来的模型,仅 `24h` 。
对于同时支持两者的旧模型 `in_memory` 和 `24h`,默认值取决于你组织的数据保留策略:
- - 未启用 ZDR 的组织默认使用 `24h`.
- - 启用 ZDR 的组织默认使用 `in_memory` 当 `prompt_cache_retention` 未指定时。
+ - 未启用 ZDR 的组织默认为 `24h`.
+ - 启用 ZDR 的组织默认为 `in_memory` 当 `prompt_cache_retention` 未指定时。
- `"in_memory"`
@@ -137115,18 +137085,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `reasoning: optional Reasoning or null`
- 配置选项,适用于
+ 适用于
[推理模型](https://platform.openai.com/docs/guides/reasoning).
- `context: optional "auto" or "current_turn" or "all_turns" or null`
- 控制在后续轮次中呈现回模型的推理项。
- 如果省略或设置为 `auto`,则由模型确定上下文模式。
+ 控制在后续回合中哪些推理项会被回传给模型。
+ 如果省略或设置为 `auto`,则由模型决定上下文模式。
`gpt-5.6` 模型系列默认为 `all_turns`;早期模型默认为
`current_turn`.
- 在响应中返回时,这是该响应使用的有效推理上下文模式
- 。
+ 在响应中返回时,这是该响应所使用 的有效推理上下文模式
+ 用于该响应。
- `"auto"`
@@ -137136,13 +137106,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `effort: optional ReasoningEffort or null`
- 限制推理模型在推理上的投入程度。当前支持的值
- 包括 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
- 降低推理投入程度可以让响应更快,并减少响应中推理所用的 token 数。并非所有推理模型都支持每个
- 值。请参阅
- 推理指南
+ 限制推理模型在推理上的投入程度。目前支持
+ 的取值有 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
+ 降低推理投入程度可以让响应更快,并减少响应中用于推理的 token
+ 数量。并非所有推理模型都支持每个
+ 取值。有关各模型的支持情况,请参阅
[推理指南](https://platform.openai.com/docs/guides/reasoning)
- 以了解特定模型的支持情况。
+ 。
- `"none"`
@@ -137160,11 +137130,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `generate_summary: optional "auto" or "concise" or "detailed" or null`
- **已弃用:** 请使用 `summary` 相反。
+ **已弃用:** 请使用 `summary` 改为。
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `"auto"`
@@ -137176,7 +137146,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `string`
@@ -137184,7 +137154,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `"standard"`
@@ -137192,11 +137162,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `summary: optional "auto" or "concise" or "detailed" or null`
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `concise` 支持以下模型 `computer-use-preview` 以及之后的所有推理模型 `gpt-5`.
+ `concise` 支持用于 `computer-use-preview` 模型以及之后的 `gpt-5`.
- `"auto"`
@@ -137206,21 +137176,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `safety_identifier: optional string or null`
- 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用策略的应用程序用户。
- ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份识别信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用政策的应用用户。
+ ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `service_tier: optional ServiceTier or null`
指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
+ - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则该项目将使用 'default'。
- 如果设置为 'default',则该请求将使用所选模型的标准定价和性能进行处理。
- 如果设置为 '[flex](/docs/guides/flex-processing)',则该请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别选择启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 `service_tier=fast` 或 `service_tier=priority` 参数用于 Responses 或 Chat Completions。响应将显示 `service_tier=priority` ,无论你是否在请求中指定了 `service_tier=fast` 或 `priority` 。
- - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级返回的响应将显示 `service_tier=ultrafast`.
- - 如果未设置,默认行为是 'auto'。
+ - 若要在请求级别启用 [快速模式](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过它处理的响应将显示 `service_tier=ultrafast`.
+ - 未设置时,默认行为为 'auto'。
- 当设置 `service_tier` 参数时,响应正文将包含基于实际用于处理该请求的处理模式的 `service_tier` 值。此响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应体中将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。此响应中的值可能与该参数中设置的值不同。
- `"auto"`
@@ -137238,8 +137208,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional ResponseStatus`
- 响应生成的状态。取值之一为 `completed`, `failed`,
- `in_progress`, `cancelled`, `queued`, or `incomplete`.
+ 响应生成的状态。可选值为 `completed`, `failed`,
+ `in_progress`, `cancelled`, `queued`,或 `incomplete`.
- `"completed"`
@@ -137255,8 +137225,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: optional ResponseTextConfig`
- 用于配置模型文本响应的选项。可以是纯文本,也可以是结构化的 JSON 数据。详见:
- 文本输入与输出:
+ 模型文本响应的配置选项。可以是纯
+ 文本或结构化 JSON 数据。了解更多:
- [文本输入与输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
@@ -137265,79 +137235,79 @@ curl https://api.openai.com/v1/responses/resp_123 \
用于指定模型必须输出的格式的对象。
- 设置为 `{ "type": "json_schema" }` 时,将启用结构化输出,
- 功能,从而确保模型的输出与你提供的 JSON schema 相匹配。详见
+ 配置 `{ "type": "json_schema" }` 可启用结构化输出,
+ 从而确保模型匹配你提供的 JSON schema。更多信息请参阅
[结构化输出指南](/docs/guides/structured-outputs).
- 默认的格式为 `{ "type": "text" }` ,且不包含其他选项。
+ 默认格式为 `{ "type": "text" }` ,不包含任何额外选项。
- **不建议在 gpt-4o 及更新模型上使用:**
+ **不推荐用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
- 的模型,建议优先使用该格式。
+ 设置为 `{ "type": "json_object" }` 会启用旧版 JSON 模式,该模式
+ 可确保模型生成的消息是合法 JSON。对于支持 `json_schema`
+ 的模型,建议优先使用它。
- `ResponseFormatText object { type }`
- 默认的响应格式。用于生成文本响应。
+ 默认响应格式。用于生成文本响应。
- `type: "text"`
- 正在定义的响应格式的类型。始终为 `text`.
+ 正在定义的响应格式类型。始终为 `text`.
- `"text"`
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化的 JSON 响应。
+ JSON Schema 响应格式。用于生成结构化 JSON 响应。
详细了解 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
- 下划线和连字符,最大长度为 64。
+ 下划线和短横线,最大长度为 64。
- `schema: map[unknown]`
- 响应格式的 schema,以 JSON Schema 对象描述。
- 了解如何构建 JSON schema [此处](https://json-schema.org/).
+ 响应格式的架构,以 JSON Schema 对象形式描述。
+ 了解如何构建 JSON 架构 [此处](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式的类型。始终为 `json_schema`.
+ 正在定义的响应格式类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
响应格式用途的描述,供模型用于
- 确定如何按该格式进行响应。
+ 确定如何按该格式响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 一致性。
- 如果设置为 true,模型将始终遵循
- 字段中 `schema` 定义的精确 schema。仅支持 JSON Schema 的一个子集,当
- `strict` 是 `true`。要了解更多信息,请阅读 [Structured Outputs
+ 生成输出时是否启用严格的架构遵循。
+ 如果设置为 true,模型将始终遵循 字段中定义的
+ 确切架构。当 设置为 `schema` true 时,仅支持 JSON Schema 的一个子集
+ `strict` 是 `true`。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较早的生成 JSON 响应的方法。
- 使用 `json_schema` 对支持它的模型是推荐的做法。请注意
- 模型在没有系统或用户消息指示的情况下不会生成
- JSON。
+ JSON 对象响应格式。一种较旧的 JSON 响应生成方法。建议。
+ 对于支持 的模型,使用 `json_schema` 。请注意,模型不会在没有系统或用户消息指示
+ 的情况下生成 JSON
+ 。
- `type: "json_object"`
- 正在定义的响应格式的类型。始终为 `json_object`.
+ 正在定义的响应格式类型。始终为 `json_object`.
- `"json_object"`
- `verbosity: optional "low" or "medium" or "high" or null`
- 约束模型响应的详细程度。较低的值会产生
- 更简洁的响应,较高的值会产生更详细的响应。
+ 约束模型响应的详尽程度。较低的值将导致
+ 更简洁的响应,而较高的值将导致更冗长的响应。
当前支持的值包括 `low`, `medium`,和 `high`。默认值为
`medium`.
@@ -137349,20 +137319,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `top_logprobs: optional number or null`
- 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的最大最可能
- token 数量,每个 token 都附带对应的对数
+ 一个介于 0 到 20 之间的整数,指定在每个 token 位置返回的
+ 最可能 token 的最大数量,每个 token 都有一个关联的对数
概率。在某些情况下,返回的 token 数量可能少于
- 所请求的数量。
+ 请求的数量。
- `truncation: optional "auto" or "disabled" or null`
用于模型响应的截断策略。
- - `auto`:如果此 Response 的输入超过
- 模型的上下文窗口大小,模型将通过从对话开头丢弃条目来截断
- 响应以适配上下文窗口。
- - `disabled` (默认):如果输入大小将超出模型的上下文窗口
- 大小,请求将失败并返回 400 错误。
+ - `auto`:如果此 Response 的输入超出
+ 模型的上下文窗口大小,模型将通过从对话开头
+ 丢弃条目来截断响应以适配上下文窗口。
+ - `disabled` (默认):如果输入大小将超过模型的上下文窗口
+ 大小,请求将以 400 错误失败。
- `"auto"`
@@ -137371,7 +137341,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `usage: optional ResponseUsage`
表示 token 使用详情,包括输入 token、输出 token,
- 的输出 token 明细,以及所使用的 token 总数。
+ 输出 token 的细分,以及使用的总 token 数。
- `input_tokens: number`
@@ -137379,16 +137349,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_tokens_details: object { cache_write_tokens, cached_tokens }`
- 输入 token 的详细明细。
+ 输入 token 的详细细分。
- `cache_write_tokens: number`
- 已写入缓存的输入 token 数量。
+ 写入缓存的输入 token 的数量。
- `cached_tokens: number`
- 从缓存中检索到的 token 数量。
- [了解更多关于提示缓存的信息](/docs/guides/prompt-caching).
+ 从缓存中检索到的 token 的数量。
+ [有关 prompt caching 的更多信息](/docs/guides/prompt-caching).
- `output_tokens: number`
@@ -137396,25 +137366,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_tokens_details: object { reasoning_tokens }`
- 输出令牌的详细明细。
+ 输出 token 的详细明细。
- `reasoning_tokens: number`
- 推理令牌的数量。
+ 推理 token 的数量。
- `total_tokens: number`
- 使用的令牌总数。
-
- - `compute_units: optional number or null`
-
- 该请求的计算单元。在可用时当前为 null。
+ 使用的 token 总数。
- `user: optional string`
- 此字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
- 用于标识你的最终用户的稳定标识符。
- 通过更好地对相似请求进行分桶以提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 该字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
+ 你的最终用户的稳定标识符。
+ 通过更好地对相似请求进行分桶来提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `sequence_number: number`
@@ -137428,31 +137394,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseContentPartAddedEvent object { content_index, item_id, output_index, 3 more }`
- 在新增内容部分时触发。
+ 当新增一个内容分块时发出。
- `content_index: number`
- 被新增内容部分的索引。
+ 被添加的内容分块的索引。
- `item_id: string`
- 内容部分所添加到的输出项的 ID。
+ 内容分块所添加到的输出项的 ID。
- `output_index: number`
- 内容部分所添加到的输出项的索引。
+ 内容分块所添加到的输出项的索引。
- `part: ResponseOutputText or ResponseOutputRefusal or object { text, type }`
- 被新增的内容部分。
+ 被添加的内容分块。
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `ReasoningText object { text, type }`
@@ -137460,7 +137426,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -137480,7 +137446,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseContentPartDoneEvent object { content_index, item_id, output_index, 3 more }`
- 当某个内容部分完成时触发。
+ 在内容部分完成时发出。
- `content_index: number`
@@ -137488,11 +137454,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 内容部分所添加到的输出项的 ID。
+ 内容分块所添加到的输出项的 ID。
- `output_index: number`
- 内容部分所添加到的输出项的索引。
+ 内容分块所添加到的输出项的索引。
- `part: ResponseOutputText or ResponseOutputRefusal or object { text, type }`
@@ -137500,11 +137466,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `ReasoningText object { text, type }`
@@ -137512,7 +137478,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -137532,11 +137498,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseCreatedEvent object { response, sequence_number, type }`
- 在创建响应时发出的事件。
+ 在创建 response 时发出的事件。
- `response: Response`
- 已创建的响应。
+ The response that was created.
- `sequence_number: number`
@@ -137550,7 +137516,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseErrorEvent object { code, message, param, 2 more }`
- 发生错误时触发。
+ 在发生错误时触发。
- `code: string or null`
@@ -137576,15 +137542,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseFileSearchCallCompletedEvent object { item_id, output_index, sequence_number, type }`
- 在文件搜索调用完成(找到结果)时发出。
+ 在文件搜索调用完成时触发(已找到结果)。
- `item_id: string`
- 发起文件搜索调用的输出项的 ID。
+ 发起文件搜索调用的输出项 ID。
- `output_index: number`
- 发起文件搜索调用的输出项的索引。
+ 发起文件搜索调用的输出项索引。
- `sequence_number: number`
@@ -137598,15 +137564,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseFileSearchCallInProgressEvent object { item_id, output_index, sequence_number, type }`
- 在发起 文件搜索 调用时发出。
+ 在发起文件搜索调用时发出。
- `item_id: string`
- 发起文件搜索调用的输出项的 ID。
+ 发起文件搜索调用的输出项 ID。
- `output_index: number`
- 发起文件搜索调用的输出项的索引。
+ 发起文件搜索调用的输出项索引。
- `sequence_number: number`
@@ -137620,15 +137586,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseFileSearchCallSearchingEvent object { item_id, output_index, sequence_number, type }`
- 在文件搜索正在执行检索时发出。
+ 当 文件搜索 正在搜索时发出。
- `item_id: string`
- 发起文件搜索调用的输出项的 ID。
+ 发起文件搜索调用的输出项 ID。
- `output_index: number`
- 文件搜索调用正在搜索的输出项的索引。
+ 文件搜索 调用正在搜索的输出项的索引。
- `sequence_number: number`
@@ -137642,7 +137608,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseFunctionCallArgumentsDeltaEvent object { delta, item_id, output_index, 2 more }`
- 当存在部分函数调用参数的增量时发出。
+ 当存在部分函数调用参数增量时发出。
- `delta: string`
@@ -137650,11 +137616,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 添加函数调用参数增量的输出项的 ID。
+ 被添加函数调用参数增量的输出项的 ID。
- `output_index: number`
- 添加函数调用参数增量的输出项的索引。
+ 被添加函数调用参数增量的输出项的索引。
- `sequence_number: number`
@@ -137668,7 +137634,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseFunctionCallArgumentsDoneEvent object { arguments, item_id, name, 3 more }`
- 在函数调用参数被最终确定时发出。
+ 在函数调用参数确定时发出。
- `arguments: string`
@@ -137696,19 +137662,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseShellCallCommandAddedEvent object { command, command_index, output_index, 2 more }`
- 指示已将 shell 命令添加到工具调用的流式事件。
+ 一个流式事件,表示一条 shell 命令已被添加到工具调用中。
- `command: string`
- 已添加的 shell 命令。
+ 被添加的 shell 命令。
- `command_index: number`
- 已添加的 shell 命令的索引。
+ 被添加的 shell 命令的索引。
- `output_index: number`
- 已更新的输出项的索引。
+ 被更新的输出项的索引。
- `sequence_number: number`
@@ -137716,7 +137682,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "response.shell_call_command.added"`
- 事件的类型,always `response.shell_call_command.added`.
+ 事件的类型,始终为 `response.shell_call_command.added`.
- `"response.shell_call_command.added"`
@@ -137726,15 +137692,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `command_index: number`
- 被更新的 shell 命令的索引。
+ 已更新的 shell 命令的索引。
- `delta: string`
- 被追加的 shell 命令增量内容。
+ 已追加的 shell 命令增量。
- `output_index: number`
- 已更新的输出项的索引。
+ 被更新的输出项的索引。
- `sequence_number: number`
@@ -137742,7 +137708,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "response.shell_call_command.delta"`
- 事件的类型,always `response.shell_call_command.delta`.
+ 事件的类型,始终为 `response.shell_call_command.delta`.
- `"response.shell_call_command.delta"`
@@ -137752,7 +137718,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseShellCallCommandDoneEvent object { command, command_index, output_index, 2 more }`
- 指示 shell 命令已完成的流事件。
+ 指示 shell 命令已完成的流式事件。
- `command: string`
@@ -137764,7 +137730,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_index: number`
- 已更新的输出项的索引。
+ 被更新的输出项的索引。
- `sequence_number: number`
@@ -137772,13 +137738,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "response.shell_call_command.done"`
- 事件的类型,always `response.shell_call_command.done`.
+ 事件的类型,始终为 `response.shell_call_command.done`.
- `"response.shell_call_command.done"`
- `ResponseShellCallOutputContentDeltaEvent object { command_index, delta, item_id, 3 more }`
- 表示 shell 调用输出被增量添加的流事件。
+ 指示 shell 调用输出被增量添加的流式事件。
- `command_index: number`
@@ -137802,7 +137768,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_index: number`
- 已更新的输出项的索引。
+ 被更新的输出项的索引。
- `sequence_number: number`
@@ -137810,7 +137776,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "response.shell_call_output_content.delta"`
- 事件的类型,always `response.shell_call_output_content.delta`.
+ 事件的类型,始终为 `response.shell_call_output_content.delta`.
- `"response.shell_call_output_content.delta"`
@@ -137828,11 +137794,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: array of object { outcome, stderr, stdout, created_by }`
- 为 shell 命令发出的输出内容。
+ shell 命令发出的输出内容。
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -137840,13 +137806,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -137854,7 +137820,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -137868,11 +137834,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `output_index: number`
- 已更新的输出项的索引。
+ 被更新的输出项的索引。
- `sequence_number: number`
@@ -137880,13 +137846,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "response.shell_call_output_content.done"`
- 事件的类型,always `response.shell_call_output_content.done`.
+ 事件的类型,始终为 `response.shell_call_output_content.done`.
- `"response.shell_call_output_content.done"`
- `ResponseInProgressEvent object { response, sequence_number, type }`
- 当响应正在进行时发出。
+ 在响应进行中时发出。
- `response: Response`
@@ -137904,11 +137870,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseFailedEvent object { response, sequence_number, type }`
- 当 response 失败时发出的事件。
+ 当响应失败时发出的事件。
- `response: Response`
- 失败的 response。
+ 失败的响应。
- `sequence_number: number`
@@ -137922,11 +137888,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseIncompleteEvent object { response, sequence_number, type }`
- 当响应以不完整状态结束时发出的事件。
+ 当响应未完成时发出的事件。
- `response: Response`
- 不完整的响应。
+ 未完成的响应。
- `sequence_number: number`
@@ -137940,14 +137906,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputItemAddedEvent object { item, output_index, sequence_number, type }`
- 当新增一个输出项时触发。
+ 在添加新的输出项时触发。
- `item: ResponseOutputItem`
被添加的输出项。对于推理项, `encrypted_content`
- 在项进行中时可能不完整。可使用相应
- 事件中的推理项 `response.output_item.done` 在将其作为输入传递给后续请求时使用。
- 后续请求的输入。
+ 在项进行中时可能不完整。请使用推理项
+ 来自相应的 `response.output_item.done` 事件中,在将其作为输入
+ 传递给后续请求时。
- `ResponseOutputMessage object { id, content, role, 3 more }`
@@ -137955,33 +137921,33 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `FunctionCallOutput object { id, output, status, 6 more }`
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `ComputerCallOutput object { id, call_id, output, 4 more }`
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `Program object { id, call_id, code, 2 more }`
@@ -137996,11 +137962,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `CodeInterpreterCall object { id, code, container_id, 3 more }`
@@ -138008,7 +137974,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `LocalShellCallOutput object { id, output, type, status }`
@@ -138028,11 +137994,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `McpListTools object { id, server_label, tools, 2 more }`
@@ -138040,11 +138006,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `CustomToolCall object { call_id, input, name, 4 more }`
@@ -138068,7 +138034,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputItemDoneEvent object { item, output_index, sequence_number, type }`
- 当某个输出项被标记为完成时触发。
+ 在某个输出项被标记为完成时发出。
- `item: ResponseOutputItem`
@@ -138090,27 +138056,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseReasoningSummaryPartAddedEvent object { item_id, output_index, part, 3 more }`
- 当新的推理摘要部分被添加时触发。
+ 当新增推理摘要分块时触发。
- `item_id: string`
- 与此摘要部分相关联的项目的 ID。
+ 与此摘要分块关联的项的 ID。
- `output_index: number`
- 与此摘要部分相关联的输出项目的索引。
+ 与此摘要分块关联的输出项的索引。
- `part: object { text, type }`
- 被添加的摘要部分。
+ 已添加的摘要分块。
- `text: string`
- 摘要部分的文本。
+ 摘要分块的文本。
- `type: "summary_text"`
- 摘要部分的类型。始终为 `summary_text`.
+ 摘要分块的类型。始终为 `summary_text`.
- `"summary_text"`
@@ -138120,7 +138086,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `summary_index: number`
- 推理摘要内此摘要部分的索引。
+ 该摘要分块在推理摘要中的索引。
- `type: "response.reasoning_summary_part.added"`
@@ -138130,27 +138096,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseReasoningSummaryPartDoneEvent object { item_id, output_index, part, 4 more }`
- 在推理摘要部分完成时发出。
+ 当某个推理摘要分块完成时发出。
- `item_id: string`
- 与此摘要部分相关联的项目的 ID。
+ 与此摘要分块关联的项的 ID。
- `output_index: number`
- 与此摘要部分相关联的输出项目的索引。
+ 与此摘要分块关联的输出项的索引。
- `part: object { text, type }`
- 已完成的摘要部分。
+ 已完成的摘要分块。
- `text: string`
- 摘要部分的文本。
+ 摘要分块的文本。
- `type: "summary_text"`
- 摘要部分的类型。始终为 `summary_text`.
+ 摘要分块的类型。始终为 `summary_text`.
- `"summary_text"`
@@ -138160,7 +138126,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `summary_index: number`
- 推理摘要内此摘要部分的索引。
+ 该摘要分块在推理摘要中的索引。
- `type: "response.reasoning_summary_part.done"`
@@ -138170,18 +138136,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "incomplete"`
- 摘要部分的完成状态。在该部分正常完成时省略,
- 在生成被中断时设置为 `incomplete` 。
+ 该摘要分块的完成状态。当该分块已完成时省略。
+ 正常工作并设置为 `incomplete` 当生成被中断时。
- `"incomplete"`
- `ResponseReasoningSummaryTextDeltaEvent object { delta, item_id, output_index, 3 more }`
- 当有增量被添加到推理摘要文本时触发。
+ 当向推理摘要文本添加增量时触发。
- `delta: string`
- 已添加到摘要的文本增量。
+ 添加到摘要的文本增量。
- `item_id: string`
@@ -138197,7 +138163,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `summary_index: number`
- 推理摘要内此摘要部分的索引。
+ 该摘要分块在推理摘要中的索引。
- `type: "response.reasoning_summary_text.delta"`
@@ -138211,11 +138177,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 此摘要文本所关联条目的 ID。
+ 与此摘要文本关联的项的 ID。
- `output_index: number`
- 此摘要文本所关联输出项的索引。
+ 与此摘要文本关联的输出项的索引。
- `sequence_number: number`
@@ -138223,7 +138189,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `summary_index: number`
- 推理摘要内此摘要部分的索引。
+ 该摘要分块在推理摘要中的索引。
- `text: string`
@@ -138237,23 +138203,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseReasoningTextDeltaEvent object { content_index, delta, item_id, 3 more }`
- 在向推理文本添加增量时发出。
+ 当向推理文本添加增量时触发。
- `content_index: number`
- 与此增量关联的推理内容部分的索引。
+ 此增量关联的推理内容部分的索引。
- `delta: string`
- 已添加到推理内容的文本增量。
+ 添加到推理内容中的文本增量。
- `item_id: string`
- 与此推理文本增量关联的项的 ID。
+ 此推理文本增量所属项的 ID。
- `output_index: number`
- 与此推理文本增量关联的输出项的索引。
+ 此推理文本增量所属输出项的索引。
- `sequence_number: number`
@@ -138271,15 +138237,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `content_index: number`
- 推理内容片段的索引。
+ 推理内容部分的索引。
- `item_id: string`
- 与此推理文本关联的条目 ID。
+ 此推理文本所关联的项的 ID。
- `output_index: number`
- 与此推理文本关联的输出条目索引。
+ 此推理文本所关联的输出项的索引。
- `sequence_number: number`
@@ -138301,19 +138267,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `content_index: number`
- 拒绝文本所添加到的内容部分的索引。
+ 拒绝文本所添加到内容分块的索引。
- `delta: string`
- 所添加的拒绝文本。
+ 被添加的拒绝文本。
- `item_id: string`
- 拒绝文本所添加到的输出项的 ID。
+ 拒绝文本所添加到输出项的 ID。
- `output_index: number`
- 拒绝文本所添加到的输出项的索引。
+ 拒绝文本所添加到输出项的索引。
- `sequence_number: number`
@@ -138327,23 +138293,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseRefusalDoneEvent object { content_index, item_id, output_index, 3 more }`
- 在拒绝文本最终确定时发出。
+ 当拒绝文本完成时发出。
- `content_index: number`
- 拒绝文本最终确定时所对应的内容分片的索引。
+ 拒绝文本完成时所处内容片段的索引。
- `item_id: string`
- 拒绝文本最终确定时所对应的输出项的 ID。
+ 拒绝文本完成时所处输出项的 ID。
- `output_index: number`
- 拒绝文本最终确定时所对应的输出项的索引。
+ 拒绝文本完成时所处输出项的索引。
- `refusal: string`
- 已最终确定的拒绝文本。
+ 已完成的拒绝文本。
- `sequence_number: number`
@@ -138357,11 +138323,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseTextDeltaEvent object { content_index, delta, item_id, 4 more }`
- 当有额外的文本增量时发出。
+ 在出现额外文本增量时发出。
- `content_index: number`
- 文本增量所添加到的内容部分的索引。
+ 添加文本增量的内容部分的索引。
- `delta: string`
@@ -138369,7 +138335,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 文本增量所添加到的输出项的 ID。
+ 已添加文本增量的输出项的 ID。
- `logprobs: array of object { token, logprob, top_logprobs }`
@@ -138397,7 +138363,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_index: number`
- 文本增量所添加到的输出项的索引。
+ 已添加文本增量的输出项的索引。
- `sequence_number: number`
@@ -138411,15 +138377,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseTextDoneEvent object { content_index, item_id, logprobs, 4 more }`
- 当文本内容最终确定时发出。
+ 在文本内容完成时发出。
- `content_index: number`
- 文本内容最终确定的内容部分的索引。
+ 已完成文本内容的内容部分的索引。
- `item_id: string`
- 文本内容最终确定的输出项的 ID。
+ 已完成文本内容的输出项的 ID。
- `logprobs: array of object { token, logprob, top_logprobs }`
@@ -138447,7 +138413,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_index: number`
- 文本内容最终确定的输出项的索引。
+ 已完成文本内容的输出项的索引。
- `sequence_number: number`
@@ -138455,7 +138421,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 最终确定的文本内容。
+ 已完成的文本内容。
- `type: "response.output_text.done"`
@@ -138465,19 +138431,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseWebSearchCallCompletedEvent object { item_id, output_index, sequence_number, type }`
- 当一次网页搜索调用完成时发出。
+ 在 网页搜索 调用完成时发出。
- `item_id: string`
- 与网页搜索调用关联的输出项的唯一 ID。
+ 与 网页搜索 调用关联的输出项的唯一 ID。
- `output_index: number`
- 网页搜索调用所关联的输出项的索引。
+ 与 网页搜索 调用关联的输出项的索引。
- `sequence_number: number`
- 正在处理的网页搜索调用的序号。
+ 正在处理的 网页搜索 调用的序列号。
- `type: "response.web_search_call.completed"`
@@ -138487,19 +138453,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseWebSearchCallInProgressEvent object { item_id, output_index, sequence_number, type }`
- 当一次网页搜索调用被发起时发出。
+ 在 网页搜索 调用发起时发出。
- `item_id: string`
- 与网页搜索调用关联的输出项的唯一 ID。
+ 与 网页搜索 调用关联的输出项的唯一 ID。
- `output_index: number`
- 网页搜索调用所关联的输出项的索引。
+ 与 网页搜索 调用关联的输出项的索引。
- `sequence_number: number`
- 正在处理的网页搜索调用的序号。
+ 正在处理的 网页搜索 调用的序列号。
- `type: "response.web_search_call.in_progress"`
@@ -138509,19 +138475,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseWebSearchCallSearchingEvent object { item_id, output_index, sequence_number, type }`
- 在网页搜索调用执行时发出。
+ 当 网页搜索 调用正在执行时发出。
- `item_id: string`
- 与网页搜索调用关联的输出项的唯一 ID。
+ 与 网页搜索 调用关联的输出项的唯一 ID。
- `output_index: number`
- 网页搜索调用所关联的输出项的索引。
+ 与 网页搜索 调用关联的输出项的索引。
- `sequence_number: number`
- 正在处理的网页搜索调用的序号。
+ 正在处理的 网页搜索 调用的序列号。
- `type: "response.web_search_call.searching"`
@@ -138531,7 +138497,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseImageGenCallCompletedEvent object { item_id, output_index, sequence_number, type }`
- 当一个图像生成工具调用已完成且最终图像可用时发出。
+ 当图像生成工具调用已完成且最终图像可用时发出。
- `item_id: string`
@@ -138553,7 +138519,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseImageGenCallGeneratingEvent object { item_id, output_index, sequence_number, type }`
- 当图像生成工具调用正在主动生成图像时触发(中间状态)。
+ 当图像生成工具调用正在主动生成图像时发出(中间状态)。
- `item_id: string`
@@ -138575,7 +138541,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseImageGenCallInProgressEvent object { item_id, output_index, sequence_number, type }`
- 当图像生成工具调用进行中时发出。
+ 当图像生成工具调用进行时触发。
- `item_id: string`
@@ -138597,7 +138563,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseImageGenCallPartialImageEvent object { item_id, output_index, partial_image_b64, 7 more }`
- 在图像生成流式传输过程中,当有部分图像可用时触发。
+ 在图像生成流式传输期间出现部分图像时发出。
- `item_id: string`
@@ -138609,11 +138575,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_image_b64: string`
- Base64 编码的部分图像数据,可用于渲染为图像。
+ Base64 编码的部分图像数据,适合渲染为图像。
- `partial_image_index: number`
- 部分图像的从 0 开始的索引(后端使用从 1 开始的索引,但此处为面向用户的从 0 开始)。
+ 部分图像的 0 基索引(后端使用 1 基索引,但供用户使用的是 0 基索引)。
- `sequence_number: number`
@@ -138643,15 +138609,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseMcpCallArgumentsDeltaEvent object { delta, item_id, output_index, 2 more }`
- 当 MCP 工具调用的参数存在 delta(部分更新)时发出。
+ 在 MCP 工具调用的参数存在增量(部分更新)时发出。
- `delta: string`
- 一个 JSON 字符串,包含 MCP 工具调用参数的部分更新。
+ 一个 JSON 字符串,包含对 MCP 工具调用参数的部分更新。
- `item_id: string`
- 正在处理的 MCP 工具调用项的唯一标识符。
+ 正在处理的 MCP 工具调用条目的唯一标识符。
- `output_index: number`
@@ -138669,15 +138635,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseMcpCallArgumentsDoneEvent object { arguments, item_id, output_index, 2 more }`
- 当 MCP 工具调用的参数被最终确定时发出。
+ 在 MCP 工具调用的参数确定后发出。
- `arguments: string`
- 一个 JSON 字符串,包含 MCP 工具调用的最终确定参数。
+ 包含 MCP 工具调用最终参数的 JSON 字符串。
- `item_id: string`
- 正在处理的 MCP 工具调用项的唯一标识符。
+ 正在处理的 MCP 工具调用条目的唯一标识符。
- `output_index: number`
@@ -138695,7 +138661,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseMcpCallCompletedEvent object { item_id, output_index, sequence_number, type }`
- 当 MCP 工具调用已成功完成时触发。
+ 当 MCP 工具调用成功完成时触发。
- `item_id: string`
@@ -138717,11 +138683,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseMcpCallFailedEvent object { item_id, output_index, sequence_number, type }`
- 当 MCP 工具调用失败时触发。
+ 当 MCP 工具调用失败时发出。
- `item_id: string`
- 失败的 MCP 工具调用项的 ID。
+ 失败 MCP 工具调用项的 ID。
- `output_index: number`
@@ -138739,11 +138705,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseMcpCallInProgressEvent object { item_id, output_index, sequence_number, type }`
- 在 MCP 工具调用进行中时发出。
+ 在 MCP 工具调用进行中时发出。
- `item_id: string`
- 正在处理的 MCP 工具调用项的唯一标识符。
+ 正在处理的 MCP 工具调用条目的唯一标识符。
- `output_index: number`
@@ -138755,17 +138721,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "response.mcp_call.in_progress"`
- 事件的类型。始终为 'response.mcp_call.in_progress'。
+ 事件的类型,恒为 'response.mcp_call.in_progress'。
- `"response.mcp_call.in_progress"`
- `ResponseMcpListToolsCompletedEvent object { item_id, output_index, sequence_number, type }`
- 在成功检索到可用的 MCP 工具列表时发出。
+ 在可用 MCP 工具列表成功检索到时触发。
- `item_id: string`
- 产生此输出的 MCP 工具调用项的 ID。
+ 生成此输出的 MCP 工具调用项的 ID。
- `output_index: number`
@@ -138783,11 +138749,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseMcpListToolsFailedEvent object { item_id, output_index, sequence_number, type }`
- 在尝试列出可用的 MCP 工具失败时发出。
+ 当尝试列出可用的 MCP 工具失败时发出。
- `item_id: string`
- 失败的 MCP 工具调用项的 ID。
+ 失败 MCP 工具调用项的 ID。
- `output_index: number`
@@ -138805,7 +138771,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseMcpListToolsInProgressEvent object { item_id, output_index, sequence_number, type }`
- 系统在检索可用 MCP 工具列表的过程中发出。
+ 在系统正在检索可用 MCP 工具列表的过程中发出。
- `item_id: string`
@@ -138827,15 +138793,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputTextAnnotationAddedEvent object { annotation, annotation_index, content_index, 4 more }`
- 当向输出文本内容添加批注时发出。
+ 当向输出文本内容添加注解时触发。
- `annotation: object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type } or null`
- 应用于一段输出文本的批注。
+ 应用于一段输出文本的注解。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -138851,7 +138817,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -138861,25 +138827,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -138891,7 +138857,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -138899,11 +138865,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -138931,15 +138897,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotation_index: number`
- 内容片段中批注的索引。
+ 内容部分中该注解的索引。
- `content_index: number`
- 输出项中内容片段的索引。
+ 输出项中内容部分的索引。
- `item_id: string`
- 正在添加批注的项的唯一标识符。
+ 正在添加注解的项的唯一标识符。
- `output_index: number`
@@ -138957,11 +138923,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseQueuedEvent object { response, sequence_number, type }`
- 当响应被排队等待处理时发出。
+ 当一个响应被加入队列并等待处理时触发。
- `response: Response`
- 被排队的完整响应对象。
+ 已加入队列的完整响应对象。
- `sequence_number: number`
@@ -138969,7 +138935,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "response.queued"`
- 事件的类型。始终为 response.queued。
+ 事件的类型。始终为 'response.queued'。
- `"response.queued"`
@@ -138983,11 +138949,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 与此事件关联的 API 项的唯一标识符。
+ 与此事件关联的 API 条目的唯一标识符。
- `output_index: number`
- 此增量所应用的输出索引。
+ 此增量所适用的输出索引。
- `sequence_number: number`
@@ -139009,11 +138975,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 与此事件关联的 API 项的唯一标识符。
+ 与此事件关联的 API 条目的唯一标识符。
- `output_index: number`
- 此事件适用的输出索引。
+ 此事件所适用的输出索引。
- `sequence_number: number`
@@ -139025,12 +138991,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.custom_tool_call_input.done"`
-### 响应文本配置
+### Response Text Config
- `ResponseTextConfig object { format, verbosity }`
- 用于配置模型文本响应的选项。可以是纯文本,也可以是结构化的 JSON 数据。详见:
- 文本输入与输出:
+ 模型文本响应的配置选项。可以是纯
+ 文本或结构化 JSON 数据。了解更多:
- [文本输入与输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
@@ -139039,79 +139005,79 @@ curl https://api.openai.com/v1/responses/resp_123 \
用于指定模型必须输出的格式的对象。
- 设置为 `{ "type": "json_schema" }` 时,将启用结构化输出,
- 功能,从而确保模型的输出与你提供的 JSON schema 相匹配。详见
+ 配置 `{ "type": "json_schema" }` 可启用结构化输出,
+ 从而确保模型匹配你提供的 JSON schema。更多信息请参阅
[结构化输出指南](/docs/guides/structured-outputs).
- 默认的格式为 `{ "type": "text" }` ,且不包含其他选项。
+ 默认格式为 `{ "type": "text" }` ,不包含任何额外选项。
- **不建议在 gpt-4o 及更新模型上使用:**
+ **不推荐用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
- 的模型,建议优先使用该格式。
+ 设置为 `{ "type": "json_object" }` 会启用旧版 JSON 模式,该模式
+ 可确保模型生成的消息是合法 JSON。对于支持 `json_schema`
+ 的模型,建议优先使用它。
- `ResponseFormatText object { type }`
- 默认的响应格式。用于生成文本响应。
+ 默认响应格式。用于生成文本响应。
- `type: "text"`
- 正在定义的响应格式的类型。始终为 `text`.
+ 正在定义的响应格式类型。始终为 `text`.
- `"text"`
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化的 JSON 响应。
+ JSON Schema 响应格式。用于生成结构化 JSON 响应。
详细了解 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
- 下划线和连字符,最大长度为 64。
+ 下划线和短横线,最大长度为 64。
- `schema: map[unknown]`
- 响应格式的 schema,以 JSON Schema 对象描述。
- 了解如何构建 JSON schema [此处](https://json-schema.org/).
+ 响应格式的架构,以 JSON Schema 对象形式描述。
+ 了解如何构建 JSON 架构 [此处](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式的类型。始终为 `json_schema`.
+ 正在定义的响应格式类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
响应格式用途的描述,供模型用于
- 确定如何按该格式进行响应。
+ 确定如何按该格式响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 一致性。
- 如果设置为 true,模型将始终遵循
- 字段中 `schema` 定义的精确 schema。仅支持 JSON Schema 的一个子集,当
- `strict` 是 `true`。要了解更多信息,请阅读 [Structured Outputs
+ 生成输出时是否启用严格的架构遵循。
+ 如果设置为 true,模型将始终遵循 字段中定义的
+ 确切架构。当 设置为 `schema` true 时,仅支持 JSON Schema 的一个子集
+ `strict` 是 `true`。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较早的生成 JSON 响应的方法。
- 使用 `json_schema` 对支持它的模型是推荐的做法。请注意
- 模型在没有系统或用户消息指示的情况下不会生成
- JSON。
+ JSON 对象响应格式。一种较旧的 JSON 响应生成方法。建议。
+ 对于支持 的模型,使用 `json_schema` 。请注意,模型不会在没有系统或用户消息指示
+ 的情况下生成 JSON
+ 。
- `type: "json_object"`
- 正在定义的响应格式的类型。始终为 `json_object`.
+ 正在定义的响应格式类型。始终为 `json_object`.
- `"json_object"`
- `verbosity: optional "low" or "medium" or "high" or null`
- 约束模型响应的详细程度。较低的值会产生
- 更简洁的响应,较高的值会产生更详细的响应。
+ 约束模型响应的详尽程度。较低的值将导致
+ 更简洁的响应,而较高的值将导致更冗长的响应。
当前支持的值包括 `low`, `medium`,和 `high`。默认值为
`medium`.
@@ -139121,15 +139087,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"high"`
-### 响应文本增量事件
+### Response Text Delta Event
- `ResponseTextDeltaEvent object { content_index, delta, item_id, 4 more }`
- 当有额外的文本增量时发出。
+ 在出现额外文本增量时发出。
- `content_index: number`
- 文本增量所添加到的内容部分的索引。
+ 添加文本增量的内容部分的索引。
- `delta: string`
@@ -139137,7 +139103,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `item_id: string`
- 文本增量所添加到的输出项的 ID。
+ 已添加文本增量的输出项的 ID。
- `logprobs: array of object { token, logprob, top_logprobs }`
@@ -139165,7 +139131,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_index: number`
- 文本增量所添加到的输出项的索引。
+ 已添加文本增量的输出项的索引。
- `sequence_number: number`
@@ -139177,19 +139143,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.output_text.delta"`
-### 响应文本完成事件
+### Response Text Done Event
- `ResponseTextDoneEvent object { content_index, item_id, logprobs, 4 more }`
- 当文本内容最终确定时发出。
+ 在文本内容完成时发出。
- `content_index: number`
- 文本内容最终确定的内容部分的索引。
+ 已完成文本内容的内容部分的索引。
- `item_id: string`
- 文本内容最终确定的输出项的 ID。
+ 已完成文本内容的输出项的 ID。
- `logprobs: array of object { token, logprob, top_logprobs }`
@@ -139217,7 +139183,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_index: number`
- 文本内容最终确定的输出项的索引。
+ 已完成文本内容的输出项的索引。
- `sequence_number: number`
@@ -139225,7 +139191,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 最终确定的文本内容。
+ 已完成的文本内容。
- `type: "response.output_text.done"`
@@ -139233,12 +139199,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.output_text.done"`
-### 响应使用情况
+### Response Usage
-- `ResponseUsage object { input_tokens, input_tokens_details, output_tokens, 3 more }`
+- `ResponseUsage object { input_tokens, input_tokens_details, output_tokens, 2 more }`
表示 token 使用详情,包括输入 token、输出 token,
- 的输出 token 明细,以及所使用的 token 总数。
+ 输出 token 的细分,以及使用的总 token 数。
- `input_tokens: number`
@@ -139246,16 +139212,16 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_tokens_details: object { cache_write_tokens, cached_tokens }`
- 输入 token 的详细明细。
+ 输入 token 的详细细分。
- `cache_write_tokens: number`
- 已写入缓存的输入 token 数量。
+ 写入缓存的输入 token 的数量。
- `cached_tokens: number`
- 从缓存中检索到的 token 数量。
- [了解更多关于提示缓存的信息](/docs/guides/prompt-caching).
+ 从缓存中检索到的 token 的数量。
+ [有关 prompt caching 的更多信息](/docs/guides/prompt-caching).
- `output_tokens: number`
@@ -139263,37 +139229,33 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_tokens_details: object { reasoning_tokens }`
- 输出令牌的详细明细。
+ 输出 token 的详细明细。
- `reasoning_tokens: number`
- 推理令牌的数量。
+ 推理 token 的数量。
- `total_tokens: number`
- 使用的令牌总数。
-
- - `compute_units: optional number or null`
-
- 该请求的计算单元。在可用时当前为 null。
+ 使用的 token 总数。
-### 响应网页搜索调用完成事件
+### Response Web Search Call Completed Event
- `ResponseWebSearchCallCompletedEvent object { item_id, output_index, sequence_number, type }`
- 当一次网页搜索调用完成时发出。
+ 在 网页搜索 调用完成时发出。
- `item_id: string`
- 与网页搜索调用关联的输出项的唯一 ID。
+ 与 网页搜索 调用关联的输出项的唯一 ID。
- `output_index: number`
- 网页搜索调用所关联的输出项的索引。
+ 与 网页搜索 调用关联的输出项的索引。
- `sequence_number: number`
- 正在处理的网页搜索调用的序号。
+ 正在处理的 网页搜索 调用的序列号。
- `type: "response.web_search_call.completed"`
@@ -139301,23 +139263,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.web_search_call.completed"`
-### 响应网页搜索调用进行中事件
+### Response Web Search Call In Progress Event
- `ResponseWebSearchCallInProgressEvent object { item_id, output_index, sequence_number, type }`
- 当一次网页搜索调用被发起时发出。
+ 在 网页搜索 调用发起时发出。
- `item_id: string`
- 与网页搜索调用关联的输出项的唯一 ID。
+ 与 网页搜索 调用关联的输出项的唯一 ID。
- `output_index: number`
- 网页搜索调用所关联的输出项的索引。
+ 与 网页搜索 调用关联的输出项的索引。
- `sequence_number: number`
- 正在处理的网页搜索调用的序号。
+ 正在处理的 网页搜索 调用的序列号。
- `type: "response.web_search_call.in_progress"`
@@ -139325,23 +139287,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.web_search_call.in_progress"`
-### 响应网页搜索调用搜索中事件
+### Response Web Search Call Searching Event
- `ResponseWebSearchCallSearchingEvent object { item_id, output_index, sequence_number, type }`
- 在网页搜索调用执行时发出。
+ 当 网页搜索 调用正在执行时发出。
- `item_id: string`
- 与网页搜索调用关联的输出项的唯一 ID。
+ 与 网页搜索 调用关联的输出项的唯一 ID。
- `output_index: number`
- 网页搜索调用所关联的输出项的索引。
+ 与 网页搜索 调用关联的输出项的索引。
- `sequence_number: number`
- 正在处理的网页搜索调用的序号。
+ 正在处理的 网页搜索 调用的序列号。
- `type: "response.web_search_call.searching"`
@@ -139349,13 +139311,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"response.web_search_call.searching"`
-### Responses 客户端事件
+### Responses Client Event
- `ResponsesClientEvent object { type, background, context_management, 30 more }`
- `type: "response.create"`
- 客户端事件的类型。始终为 `response.create`.
+ 客户端事件的类型。始终 `response.create`.
- `"response.create"`
@@ -139366,7 +139328,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `context_management: optional array of object { type, compact_threshold } or null`
- 此请求的上下文管理配置。
+ 本次请求的上下文管理配置。
- `type: string`
@@ -139374,12 +139336,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `compact_threshold: optional number or null`
- 应触发此条目压缩的 token 阈值。
+ 触发该条目压缩的 token 阈值。
- `conversation: optional string or ResponseConversationParam or null`
- 此响应所属的对话。该对话中的条目会被添加到 `input_items` 此响应请求之前。
- 此响应的输入条目和输出条目会在该响应完成后自动添加到此对话中。
+ 本次响应所属的对话。该对话中的条目会前置拼接到 `input_items` 本次响应请求的输入中。
+ 本次响应的输入条目和输出条目会在响应完成后自动追加到该对话中。
- `ConversationID = string`
@@ -139387,7 +139349,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseConversationParam object { id }`
- 此响应所属的对话。
+ 本次响应所属的对话。
- `id: string`
@@ -139395,15 +139357,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `include: optional array of ResponseIncludable or null`
- 指定要在模型响应中包含的其他输出数据。目前支持的值包括:
+ 指定要包含在模型响应中的其他输出数据。目前支持的值包括:
- - `web_search_call.action.sources`:包含 网页搜索 工具调用的来源。
- - `code_interpreter_call.outputs`:在代码解释器工具调用条目中包含 Python 代码执行的输出。
- - `computer_call_output.output.image_url`:包含来自计算机调用输出的图片 URL。
- - `file_search_call.results`:包含 文件搜索 工具调用的搜索结果。
- - `message.input_image.image_url`:包含来自输入消息的图片 URL。
- - `message.output_text.logprobs`:在助手消息中包含 logprobs。
- - `reasoning.encrypted_content`:在推理条目的输出中包含加密版本的推理 token。这使得在使用 Responses API 以无状态方式处理多轮对话时能够使用推理条目(例如 `store` 参数设置为 `false`,时,或组织已加入零数据留存计划时)。
+ - `web_search_call.action.sources`: 包含网页搜索工具调用的来源。
+ - `code_interpreter_call.outputs`: 在代码解释器工具调用项中包含 Python 代码执行的输出。
+ - `computer_call_output.output.image_url`: 包含来自 computer call 输出的图片链接。
+ - `file_search_call.results`: 包含文件搜索工具调用的搜索结果。
+ - `message.input_image.image_url`: 包含来自输入消息的图片链接。
+ - `message.output_text.logprobs`: 在助手消息中包含 logprobs。
+ - `reasoning.encrypted_content`: 在推理项输出中包含加密版本的推理 token。这使得在使用Responses API无状态调用时(例如当 `store` 参数设置为 `false`,或组织加入了零数据保留计划时),可以在多轮对话中使用推理项。
- `"file_search_call.results"`
@@ -139423,9 +139385,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input: optional string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 提供给模型的文本、图片或文件输入,用于生成响应。
+ 模型的文本、图片或文件输入,用于生成响应。
- 了解详情:
+ 了解更多:
- [文本输入与输出](/docs/guides/text)
- [图像输入](/docs/guides/images)
@@ -139435,67 +139397,67 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `TextInput = string`
- 发送给模型的文本输入,相当于使用
+ 发送给模型的文本输入,等同于
`user` 角色的文本输入。
- `InputItemList = array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 发送给模型的一个或多个输入项的列表,包含
+ 发送给模型的一个或多个输入项列表,包含
不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` role. Messages with the
- `assistant` role are presumed to have been generated by the model in previous
- interactions.
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色给出的指令。带有
+ `assistant` 角色的消息被视为模型在之前的
+ 交互中生成。
- `content: string or ResponseInputMessageContentList`
- Text, image, or audio input to the model, used to generate a response.
- Can also contain previous assistant responses.
+ 发送给模型的文本、图像或音频输入,用于生成响应。
+ 也可以包含之前的助手响应。
- `TextInput = string`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputMessageContentList = array of ResponseInputContent`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -139507,25 +139469,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -139535,13 +139497,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -139551,33 +139513,33 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `assistant`, `system`, or
+ 消息输入的角色。其一为 接口 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -139590,9 +139552,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -139600,24 +139562,24 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: optional "message"`
- 消息输入的类型。始终为 `message`.
+ 消息输入的类型。始终为 接口 `message`.
- `"message"`
- `Message object { content, role, status, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` 角色的文本输入。
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色的文本输入。
- `content: ResponseInputMessageContentList`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `system`, or `developer`.
+ 消息输入的角色。其一为 接口 `user`, `system`,或 `developer`.
- `"user"`
@@ -139627,8 +139589,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -139648,7 +139610,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -139656,15 +139618,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -139680,7 +139642,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -139690,25 +139652,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -139720,7 +139682,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -139728,11 +139690,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -139786,15 +139748,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -139806,8 +139768,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -139823,9 +139785,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -139833,8 +139795,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -139846,7 +139808,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -139871,11 +139833,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -139893,7 +139855,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -139902,7 +139864,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -139914,7 +139876,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -139930,8 +139892,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -139955,7 +139917,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -139969,7 +139931,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -139995,7 +139957,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -140013,7 +139975,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -140032,7 +139994,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -140042,11 +140004,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -140066,15 +140028,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -140106,19 +140068,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -140142,8 +140104,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -140159,7 +140121,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -140175,7 +140137,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -140183,44 +140145,44 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCallOutput object { call_id, output, type, 3 more }`
- 一次 computer 工具调用的输出。
+ 计算机工具调用的输出。
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `id: optional string or null`
- computer 工具调用输出的 ID。
+ 计算机工具调用输出的 ID。
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 已被开发者确认的 API 所报告的安全检查结果。
+ 开发者已确认的 API 所报告的安全检查。
- `id: string`
@@ -140236,7 +140198,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值为 `in_progress`, `completed`, or `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -140247,7 +140209,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -140255,12 +140217,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -140270,11 +140232,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -140292,7 +140254,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -140306,7 +140268,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -140324,7 +140286,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -140336,14 +140298,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -140393,8 +140355,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -140408,7 +140370,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: string or array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的文本、图片或文件输出。
+ 函数工具调用的文本、图像或文件输出。
- `string`
@@ -140416,61 +140378,61 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的内容输出(文本、图片、文件)数组。
+ 函数工具调用的内容输出(文本、图像、文件)数组。
- `ResponseInputTextContent object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision)
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `detail: optional ImageDetail or null`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -140480,13 +140442,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -140500,23 +140462,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -140528,7 +140490,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string or null`
- 函数工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
+ 函数工具调用输出的唯一 ID。当此项通过 API 返回时填充。
- `call_id: optional string or null`
@@ -140568,7 +140530,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -140584,7 +140546,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目类型。始终为 `tool_search_call`.
+ 项的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
@@ -140652,37 +140614,37 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -140695,11 +140657,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -140719,7 +140681,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -140735,15 +140697,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -140757,7 +140719,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -140765,7 +140727,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -140777,7 +140739,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -140785,21 +140747,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -140825,18 +140787,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -140844,22 +140806,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -140869,23 +140831,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -140896,11 +140858,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -140918,21 +140880,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -140940,14 +140902,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -140979,32 +140941,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -141012,13 +140974,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -141026,9 +140988,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -141040,22 +141002,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -141064,7 +141026,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -141074,7 +141036,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -141104,29 +141066,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -141162,7 +141124,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -141172,11 +141134,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -141186,7 +141148,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -141194,7 +141156,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -141203,13 +141165,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -141218,7 +141180,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -141245,7 +141207,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -141256,7 +141218,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -141273,13 +141235,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -141295,7 +141257,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -141305,7 +141267,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -141329,7 +141291,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -141353,13 +141315,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -141383,7 +141345,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -141391,13 +141353,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -141417,7 +141379,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -141429,13 +141391,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -141449,11 +141411,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -141479,7 +141441,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -141497,7 +141459,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -141511,19 +141473,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -141543,19 +141505,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -141563,11 +141525,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -141613,7 +141575,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -141625,11 +141587,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -141643,7 +141605,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -141653,7 +141615,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -141663,23 +141625,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -141697,13 +141659,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目类型。始终为 `tool_search_output`.
+ 项的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `id: optional string or null`
- 此工具搜索输出的唯一 ID。
+ 该工具搜索输出的唯一 ID。
- `call_id: optional string or null`
@@ -141731,13 +141693,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `role: "developer"`
- 提供其他工具的角色。仅 `developer` 受支持。
+ 提供这些额外工具的角色。仅支持 `developer` 。
- `"developer"`
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 此项目提供的其他工具列表。
+ 在该条目中提供的额外工具列表。
- `Function object { name, parameters, strict, 5 more }`
@@ -141771,45 +141733,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -141817,7 +141779,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -141829,7 +141791,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -141837,21 +141799,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -141877,18 +141839,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -141896,22 +141858,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -141921,23 +141883,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -141948,11 +141910,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -141970,21 +141932,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -141992,14 +141954,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -142031,32 +141993,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -142064,13 +142026,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -142078,9 +142040,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -142092,22 +142054,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -142116,7 +142078,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -142126,7 +142088,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -142182,7 +142144,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -142192,11 +142154,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -142206,7 +142168,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -142214,7 +142176,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -142223,13 +142185,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -142238,7 +142200,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -142265,7 +142227,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -142276,7 +142238,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -142293,13 +142255,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -142315,7 +142277,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -142325,7 +142287,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -142351,11 +142313,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -142381,19 +142343,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -142413,19 +142375,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -142433,11 +142395,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -142483,7 +142445,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -142495,11 +142457,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -142513,7 +142475,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -142523,7 +142485,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -142533,23 +142495,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -142567,19 +142529,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目类型。始终为 `additional_tools`.
+ 项的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `id: optional string or null`
- 此其他工具项目的唯一 ID。
+ 该额外工具条目的唯一 ID。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -142592,7 +142554,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -142612,7 +142574,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -142622,20 +142584,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -142645,7 +142607,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Compaction object { encrypted_content, type, id }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -142653,17 +142615,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `id: optional string or null`
- 压缩条目的 ID。
+ 压缩项的 ID。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -142687,7 +142649,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -142710,7 +142672,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -142722,23 +142684,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -142756,13 +142718,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -142778,11 +142740,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -142796,11 +142758,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -142814,7 +142776,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -142824,7 +142786,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -142832,13 +142794,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -142852,7 +142814,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
@@ -142864,7 +142826,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最大挂钟时间(毫秒)。
+ 允许 shell 命令运行的 wall-clock 最长时间(毫秒)。
- `call_id: string`
@@ -142872,13 +142834,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
- `id: optional string or null`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -142914,7 +142876,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -142924,7 +142886,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ShellCallOutput object { call_id, output, type, 4 more }`
- shell 工具调用发出的流式输出项。
+ shell 工具调用发出的流式输出条目。
- `call_id: string`
@@ -142932,7 +142894,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: array of ResponseFunctionShellCallOutputContent`
- stdout 和 stderr 输出的捕获块及其关联结果。
+ 捕获的 stdout 和 stderr 输出块,以及它们关联的结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -142944,13 +142906,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -142958,27 +142920,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
- `stderr: string`
- shell 调用捕获的 stderr 输出。
+ 为该 shell 调用捕获的 stderr 输出。
- `stdout: string`
- shell 调用捕获的 stdout 输出。
+ 为该 shell 调用捕获的 stdout 输出。
- `type: "shell_call_output"`
- 条目的类型,恒为 `shell_call_output`.
+ item 的类型。始终为 `shell_call_output`.
- `"shell_call_output"`
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -143020,11 +142982,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 表示使用 diff 补丁创建、删除或更新文件的工具调用。
+ 表示通过 diff 补丁创建、删除或更新文件的工具调用。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
@@ -143036,7 +142998,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 创建文件时要应用的统一 diff 内容。
+ 创建文件时应用的 unified diff 内容。
- `path: string`
@@ -143068,7 +143030,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `diff: string`
- 要应用于现有文件的统一 diff 内容。
+ 应用于现有文件的 unified diff 内容。
- `path: string`
@@ -143082,7 +143044,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -143090,13 +143052,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
- `id: optional string or null`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -143124,15 +143086,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { call_id, status, type, 3 more }`
- apply patch 工具调用发出的流式输出。
+ 由 apply patch 工具调用发出的流式输出。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -143140,13 +143102,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
- `id: optional string or null`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -143202,7 +143164,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -143210,29 +143172,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -143240,31 +143202,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { approval_request_id, approve, type, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
- `id: optional string or null`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `reason: optional string or null`
@@ -143272,7 +143234,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -143280,11 +143242,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -143292,14 +143254,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -143339,7 +143301,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -143353,11 +143315,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 由你的代码生成的自定义工具调用输出,将被发送回模型。
+ 由你的代码生成的自定义工具调用的输出,将发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -143374,11 +143336,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -143392,7 +143354,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- 自定义工具调用输出在 OpenAI 平台中的唯一 ID。
+ 在 OpenAI 平台中该自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -143442,7 +143404,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -143470,11 +143432,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompactionTrigger object { type, id }`
- 压缩当前上下文。必须是最后一个输入项。
+ 压缩当前上下文。必须作为最后一个输入项。
- `type: "compaction_trigger"`
- 条目的类型,恒为 `compaction_trigger`.
+ item 的类型。始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -143488,11 +143450,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 要引用的条目 ID。
+ 被引用条目的 ID。
- `type: optional "item_reference" or null`
- 要引用的条目类型。始终为 `item_reference`.
+ 被引用条目的类型。始终为 `item_reference`.
- `"item_reference"`
@@ -143508,7 +143470,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -143516,7 +143478,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目类型。始终为 `program`.
+ 项的类型。始终为 `program`.
- `"program"`
@@ -143532,7 +143494,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -143544,7 +143506,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目类型。始终为 `program_output`.
+ 项的类型。始终为 `program_output`.
- `"program_output"`
@@ -143552,22 +143514,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
插入到模型上下文中的系统(或开发者)消息。
- 当与 `previous_response_id`,配合使用时,前一次
- 响应的指令不会延续到下一次响应。这便于在新响应中
- 替换系统(或开发者)消息。
+ 当与 `previous_response_id`,配合使用时,上一个
+ response 中的 instructions 不会延续到下一个 response。这样可以轻松地
+ 在新的 response 中替换系统(或开发者)消息。
- `max_output_tokens: optional number or null`
- 一次响应中可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
+ 响应可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
- `max_tool_calls: optional number or null`
- 响应中可以处理的内置工具调用总次数上限。该上限适用于所有内置工具调用,而非单个工具。模型任何进一步的工具调用尝试都将被忽略。
+ 一次响应中可处理的内置工具调用总次数上限。该上限适用于所有内置工具调用的总和,而非单个工具。模型后续任何再次调用工具的尝试都将被忽略。
- `metadata: optional Metadata or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
格式,以及通过 API 或控制台查询对象。
键为字符串,最长 64 个字符。值为字符串
@@ -143576,8 +143538,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `model: optional ResponsesModel`
用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI
- 提供了多种不同能力、性能
- 特性和定价的模型。请参阅 [模型指南](/docs/models)
+ 提供了众多功能、性能
+ 特性和价位各异的模型。请参阅 [模型指南](/docs/models)
以浏览和比较可用的模型。
- `string`
@@ -143792,19 +143754,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `moderation: optional object { model, policy } or null`
- 用于对此响应的输入和输出运行审核的配置。
+ 用于对此次响应输入和输出运行审核的配置。
- `model: string`
- 用于受审核补全的审核模型,例如 'omni-moderation-latest'。
+ 用于审核补全的审核模型,例如 'omni-moderation-latest'。
- `policy: optional object { input, output } or null`
- 应用于受审核响应输入和输出的策略。
+ 应用于审核响应输入和输出的策略。
- `input: optional object { mode } or null`
- 用于响应输入的审核策略。
+ 响应输入的审核策略。
- `mode: "score" or "block"`
@@ -143814,7 +143776,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output: optional object { mode } or null`
- 用于响应输出的审核策略。
+ 响应输出的审核策略。
- `mode: "score" or "block"`
@@ -143828,9 +143790,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `previous_response_id: optional string or null`
- 模型上一次响应的唯一 ID。使用它来
- 创建多轮对话。了解有关
- [对话状态](/docs/guides/conversation-state)。的更多信息。不能与 `conversation`.
+ 上一个模型响应的唯一 ID。使用它可以
+ 创建多轮对话。详细了解
+ [conversation state](/docs/guides/conversation-state)。不能与 `conversation`.
- `prompt: optional ResponsePrompt or null`
@@ -143843,19 +143805,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `variables: optional map[string or ResponseInputText or ResponseInputImage or ResponseInputFile] or null`
- 用于替换提示模板中变量的可选值映射,
- prompt。替换值可以是字符串,也可以是其他
- Response 输入类型,例如图像或文件。
+ 用于替换你
+ prompt。替换的值可以是字符串,也可以是其他
+ Response 输入类型,如图像或文件。
- `string`
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -143863,19 +143825,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `version: optional string or null`
- 提示模板的可选版本。
+ prompt 模板的可选版本。
- `prompt_cache_key: optional string or null`
- 由 OpenAI 用于缓存相似请求的响应,以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
+ 由OpenAI使用,为相似请求缓存响应以优化你的缓存命中率。取代 `user` 字段。 [详细了解](/docs/guides/prompt-caching).
- `prompt_cache_options: optional object { mode, ttl }`
- 提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。默认情况下,OpenAI 会自动选择一个隐式缓存断点。你可以使用 `prompt_cache_breakpoint`。为内容块添加显式断点。每个请求最多可以写入四个断点。对于缓存匹配,OpenAI 会考虑对话中最近的最多 80 个断点,且不受内容块回溯长度的限制。将 `mode` 设置为 `explicit` 可禁用隐式断点。 `ttl` 默认为 `30m`,这是当前唯一支持的值。请参阅 [提示缓存指南](/docs/guides/prompt-caching) 了解当前详细信息。
+ 提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。默认情况下,OpenAI 会自动选择一个隐式缓存断点。你可以通过 `prompt_cache_breakpoint`.每个请求最多可以写入四个断点。对于缓存匹配,OpenAI 会考虑对话中最多最新的 80 个断点,且没有内容块回溯限制。将 `mode` 设置为 `explicit` 可禁用隐式断点。 `ttl` 默认为 `30m`,目前这是唯一支持的值。请参阅 [提示缓存指南](/docs/guides/prompt-caching) 了解最新详情。
- `mode: optional "implicit" or "explicit"`
- 控制 OpenAI 是否自动创建隐式缓存断点。默认为 `implicit`。当 `implicit`,时,OpenAI 会创建一个隐式断点,并在请求中写入最多最近的三个显式断点。当 `explicit`,OpenAI 不会创建隐式断点,最多写入最近的四个显式断点。如果没有显式断点,则该请求不会使用提示缓存。
+ 控制 OpenAI 是否自动创建隐式缓存断点。默认为 `implicit`。当为 `implicit`,时,OpenAI 会创建一个隐式断点,并在请求中写入最多最新的三个显式断点。当为 `explicit`,OpenAI 不会创建隐式断点,并最多写入最新的四个显式断点。如果没有显式断点,则该请求不使用提示缓存。
- `"implicit"`
@@ -143883,24 +143845,24 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ttl: optional "30m"`
- 应用于该请求写入的每个隐式和显式缓存断点的最短生命周期。默认为 `30m`,目前这是唯一受支持的值。后端可能会将缓存条目保留更长时间。
+ 应用于该请求所写入的每个隐式和显式缓存断点的最短生命周期。默认为 `30m`,目前这是唯一受支持的值。后端可能会将缓存条目保留更长时间。
- `"30m"`
- `prompt_cache_retention: optional "in_memory" or "24h" or null`
- 已弃用。请使用 `prompt_cache_options.ttl` 相反。
+ 已弃用。请使用 `prompt_cache_options.ttl` 改为。
- 提示词缓存的保留策略。设置为 `24h` 以启用扩展提示词缓存,使缓存前缀保持更长时间,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
- 此字段表示最长保留策略,而
+ 提示缓存的保留策略。设置为 `24h` 以启用扩展提示缓存,使缓存的前缀保持更长时间有效,最长可达 24 小时。 [详细了解](/docs/guides/prompt-caching#prompt-cache-retention).
+ 该字段表示最大保留策略,而
`prompt_cache_options.ttl` 表示最短缓存生命周期。这两个
- 字段彼此独立,不会相互影响。
- 对于 `gpt-5.5`, `gpt-5.5-pro`,及未来模型,仅 `24h` 受支持。
+ 字段是独立的,不会相互影响。
+ 对于 `gpt-5.5`, `gpt-5.5-pro`,以及未来的模型,仅 `24h` 。
对于同时支持两者的旧模型 `in_memory` 和 `24h`,默认值取决于你组织的数据保留策略:
- - 未启用 ZDR 的组织默认使用 `24h`.
- - 启用 ZDR 的组织默认使用 `in_memory` 当 `prompt_cache_retention` 未指定时。
+ - 未启用 ZDR 的组织默认为 `24h`.
+ - 启用 ZDR 的组织默认为 `in_memory` 当 `prompt_cache_retention` 未指定时。
- `"in_memory"`
@@ -143908,18 +143870,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `reasoning: optional Reasoning or null`
- 配置选项,适用于
+ 适用于
[推理模型](https://platform.openai.com/docs/guides/reasoning).
- `context: optional "auto" or "current_turn" or "all_turns" or null`
- 控制在后续轮次中呈现回模型的推理项。
- 如果省略或设置为 `auto`,则由模型确定上下文模式。
+ 控制在后续回合中哪些推理项会被回传给模型。
+ 如果省略或设置为 `auto`,则由模型决定上下文模式。
`gpt-5.6` 模型系列默认为 `all_turns`;早期模型默认为
`current_turn`.
- 在响应中返回时,这是该响应使用的有效推理上下文模式
- 。
+ 在响应中返回时,这是该响应所使用 的有效推理上下文模式
+ 用于该响应。
- `"auto"`
@@ -143929,13 +143891,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `effort: optional ReasoningEffort or null`
- 限制推理模型在推理上的投入程度。当前支持的值
- 包括 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
- 降低推理投入程度可以让响应更快,并减少响应中推理所用的 token 数。并非所有推理模型都支持每个
- 值。请参阅
- 推理指南
+ 限制推理模型在推理上的投入程度。目前支持
+ 的取值有 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
+ 降低推理投入程度可以让响应更快,并减少响应中用于推理的 token
+ 数量。并非所有推理模型都支持每个
+ 取值。有关各模型的支持情况,请参阅
[推理指南](https://platform.openai.com/docs/guides/reasoning)
- 以了解特定模型的支持情况。
+ 。
- `"none"`
@@ -143953,11 +143915,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `generate_summary: optional "auto" or "concise" or "detailed" or null`
- **已弃用:** 请使用 `summary` 相反。
+ **已弃用:** 请使用 `summary` 改为。
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `"auto"`
@@ -143969,7 +143931,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `string`
@@ -143977,7 +143939,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `"standard"`
@@ -143985,11 +143947,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `summary: optional "auto" or "concise" or "detailed" or null`
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `concise` 支持以下模型 `computer-use-preview` 以及之后的所有推理模型 `gpt-5`.
+ `concise` 支持用于 `computer-use-preview` 模型以及之后的 `gpt-5`.
- `"auto"`
@@ -143999,21 +143961,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `safety_identifier: optional string or null`
- 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用策略的应用程序用户。
- ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份识别信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用政策的应用用户。
+ ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份信息。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
- `service_tier: optional ServiceTier or null`
指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
+ - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则该项目将使用 'default'。
- 如果设置为 'default',则该请求将使用所选模型的标准定价和性能进行处理。
- 如果设置为 '[flex](/docs/guides/flex-processing)',则该请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别选择启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 `service_tier=fast` 或 `service_tier=priority` 参数用于 Responses 或 Chat Completions。响应将显示 `service_tier=priority` ,无论你是否在请求中指定了 `service_tier=fast` 或 `priority` 。
- - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级返回的响应将显示 `service_tier=ultrafast`.
- - 如果未设置,默认行为是 'auto'。
+ - 若要在请求级别启用 [快速模式](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过它处理的响应将显示 `service_tier=ultrafast`.
+ - 未设置时,默认行为为 'auto'。
- 当设置 `service_tier` 参数时,响应正文将包含基于实际用于处理该请求的处理模式的 `service_tier` 值。此响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应体中将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。此响应中的值可能与该参数中设置的值不同。
- `"auto"`
@@ -144036,44 +143998,44 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `stream: optional boolean or null`
- 如果设置为 true,模型响应数据将流式传输到客户端
- ,使用 [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
+ 如果设置为 true,则模型响应数据将在生成时通过
+ 流式传输到客户端,使用 [服务端发送事件](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
参见下方 [流式传输部分](/docs/api-reference/responses-streaming)
- 了解更多信息。
+ 以了解更多信息。
- `stream_id: optional string`
- 此响应所使用的 WebSocket 通道。请求若使用相同的
- `stream_id` 则会按 FIFO 顺序处理,且响应的事件会回显该
+ 此响应的 WebSocket 通道。带有相同
+ `stream_id` 的请求按 FIFO 顺序处理,且该响应的事件会回显
相同的 `stream_id`.
`stream_id` 控制路由; `previous_response_id` 控制
- 对话谱系,以便新通道可以从在另一条通道上创建的响应分叉
- 出来。
+ 会话血缘,因此可以从在另一条通道上创建的响应派生出一条新通道。
+ 该响应由另一条通道上创建的响应派生出一条新通道。
- `stream_options: optional object { include_obfuscation } or null`
- 用于流式响应选项。仅当你设置了 `stream: true`.
+ 流式响应选项。仅当设置了 `stream: true`.
- `include_obfuscation: optional boolean`
- 为 true 时,将启用流混淆。流混淆会向流式增量事件上的
- 字段添加 `obfuscation` 随机字符
- 将载荷大小归一化,作为对某些侧信道攻击的缓解措施。
- 默认会包含这些混淆字段,但会为数据流带来少量
- 开销。你可以将 `include_obfuscation` 设置为
- 设为 false 以优化带宽,前提是你信任应用与
- OpenAI API 之间的网络链路。
+ 为 true 时,将启用流混淆。流混淆会向流式 delta 事件中的某个
+ 字段添加随机字符,以 `obfuscation` 字段进行混淆。
+ 将负载大小归一化,作为对某些侧信道攻击的缓解措施。
+ 默认情况下会包含这些混淆字段,但会在数据流中增加少量
+ 开销。你可以设置 `include_obfuscation` 设置为
+ 如果你信任你的应用与
+ OpenAI API 之间的网络链路,可以设为 false 以优化带宽。
- `temperature: optional number or null`
- 使用的采样温度,介于 0 到 2 之间。较高的值(例如 0.8)会使输出更加随机,而较低的值(例如 0.2)会使输出更加聚焦和确定。
- 我们通常建议修改此参数或 `top_p` 但不要同时修改两者。
+ 使用的采样温度,介于 0 到 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加聚焦和确定性。
+ 我们通常建议调整此项或 `top_p` 但不要同时调整两者。
- `text: optional ResponseTextConfig`
- 用于配置模型文本响应的选项。可以是纯文本,也可以是结构化的 JSON 数据。详见:
- 文本输入与输出:
+ 模型文本响应的配置选项。可以是纯
+ 文本或结构化 JSON 数据。了解更多:
- [文本输入与输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
@@ -144082,79 +144044,79 @@ curl https://api.openai.com/v1/responses/resp_123 \
用于指定模型必须输出的格式的对象。
- 设置为 `{ "type": "json_schema" }` 时,将启用结构化输出,
- 功能,从而确保模型的输出与你提供的 JSON schema 相匹配。详见
+ 配置 `{ "type": "json_schema" }` 可启用结构化输出,
+ 从而确保模型匹配你提供的 JSON schema。更多信息请参阅
[结构化输出指南](/docs/guides/structured-outputs).
- 默认的格式为 `{ "type": "text" }` ,且不包含其他选项。
+ 默认格式为 `{ "type": "text" }` ,不包含任何额外选项。
- **不建议在 gpt-4o 及更新模型上使用:**
+ **不推荐用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
- 的模型,建议优先使用该格式。
+ 设置为 `{ "type": "json_object" }` 会启用旧版 JSON 模式,该模式
+ 可确保模型生成的消息是合法 JSON。对于支持 `json_schema`
+ 的模型,建议优先使用它。
- `ResponseFormatText object { type }`
- 默认的响应格式。用于生成文本响应。
+ 默认响应格式。用于生成文本响应。
- `type: "text"`
- 正在定义的响应格式的类型。始终为 `text`.
+ 正在定义的响应格式类型。始终为 `text`.
- `"text"`
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化的 JSON 响应。
+ JSON Schema 响应格式。用于生成结构化 JSON 响应。
详细了解 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
- 下划线和连字符,最大长度为 64。
+ 下划线和短横线,最大长度为 64。
- `schema: map[unknown]`
- 响应格式的 schema,以 JSON Schema 对象描述。
- 了解如何构建 JSON schema [此处](https://json-schema.org/).
+ 响应格式的架构,以 JSON Schema 对象形式描述。
+ 了解如何构建 JSON 架构 [此处](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式的类型。始终为 `json_schema`.
+ 正在定义的响应格式类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
响应格式用途的描述,供模型用于
- 确定如何按该格式进行响应。
+ 确定如何按该格式响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 一致性。
- 如果设置为 true,模型将始终遵循
- 字段中 `schema` 定义的精确 schema。仅支持 JSON Schema 的一个子集,当
- `strict` 是 `true`。要了解更多信息,请阅读 [Structured Outputs
+ 生成输出时是否启用严格的架构遵循。
+ 如果设置为 true,模型将始终遵循 字段中定义的
+ 确切架构。当 设置为 `schema` true 时,仅支持 JSON Schema 的一个子集
+ `strict` 是 `true`。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较早的生成 JSON 响应的方法。
- 使用 `json_schema` 对支持它的模型是推荐的做法。请注意
- 模型在没有系统或用户消息指示的情况下不会生成
- JSON。
+ JSON 对象响应格式。一种较旧的 JSON 响应生成方法。建议。
+ 对于支持 的模型,使用 `json_schema` 。请注意,模型不会在没有系统或用户消息指示
+ 的情况下生成 JSON
+ 。
- `type: "json_object"`
- 正在定义的响应格式的类型。始终为 `json_object`.
+ 正在定义的响应格式类型。始终为 `json_object`.
- `"json_object"`
- `verbosity: optional "low" or "medium" or "high" or null`
- 约束模型响应的详细程度。较低的值会产生
- 更简洁的响应,较高的值会产生更详细的响应。
+ 约束模型响应的详尽程度。较低的值将导致
+ 更简洁的响应,而较高的值将导致更冗长的响应。
当前支持的值包括 `low`, `medium`,和 `high`。默认值为
`medium`.
@@ -144172,9 +144134,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceOptions = "none" or "auto" or "required"`
- 控制模型调用哪个工具(如果有的话)。
+ 控制模型调用哪个工具(如果有)。
- `none` 表示模型不会调用任何工具,而是生成一条消息。
+ `none` 表示模型将不会调用任何工具,而是生成一条消息。
`auto` 表示模型可以在生成消息或调用一个或
多个工具之间进行选择。
@@ -144206,7 +144168,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of map[unknown]`
- 模型应允许调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -144227,11 +144189,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceTypes object { type }`
指示模型应使用内置工具来生成响应。
- [了解有关内置工具的更多信息](/docs/guides/tools).
+ [了解更多关于内置工具的信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
- 模型应使用的托管工具类型。了解更多关于
+ 模型应使用的 托管工具 类型。了解更多关于
[内置工具](/docs/guides/tools).
允许的值为:
@@ -144276,7 +144238,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceMcp object { server_label, type, name }`
- 使用此选项可以强制模型调用远程 MCP 服务器上的特定工具。
+ 使用此选项可强制模型调用远程 MCP 服务器上的特定工具。
- `server_label: string`
@@ -144294,7 +144256,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceCustom object { name, type }`
- 使用此选项可以强制模型调用特定的自定义工具。
+ 使用此选项可强制模型调用特定的自定义工具。
- `name: string`
@@ -144310,27 +144272,27 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "programmatic_tool_calling"`
- 要调用的工具。始终为 `programmatic_tool_calling`.
+ 要调用的工具。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ToolChoiceApplyPatch object { type }`
- 在执行工具调用时强制模型调用 apply_patch 工具。
+ 强制模型在执行工具调用时调用 apply_patch 工具。
- `type: "apply_patch"`
- 要调用的工具。始终为 `apply_patch`.
+ 要调用的工具。始终 `apply_patch`.
- `"apply_patch"`
- `ToolChoiceShell object { type }`
- 在需要工具调用时强制模型调用 shell 工具。
+ 在需要工具调用时,强制模型调用 shell 工具。
- `type: "shell"`
- 要调用的工具。始终为 `shell`.
+ 要调用的工具。始终 `shell`.
- `"shell"`
@@ -144341,18 +144303,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
我们支持以下类别的工具:
- - **内置工具**:由 OpenAI 提供的工具,用于扩展模型的
- 能力,例如 [网页搜索](/docs/guides/tools-web-search)
+ - **内置工具**:由 OpenAI 提供的工具,用于扩展
+ 模型的能力,例如 [网页搜索](/docs/guides/tools-web-search)
或 [文件搜索](/docs/guides/tools-file-search)。详细了解
[内置工具](/docs/guides/tools).
- - **MCP 工具**:通过自定义 MCP 服务器与第三方系统集成
- 或 Google Drive 和 SharePoint 等预定义连接器。详细了解
+ - **MCP 工具**: 通过自定义 MCP 服务器与第三方系统集成
+ 或使用 Google Drive 和 SharePoint 等预定义连接器。详细了解
[MCP 工具](/docs/guides/tools-connectors-mcp).
- - **函数调用(自定义工具)**:由你定义的函数,
+ - **函数调用(自定义工具)**: 由你定义的函数,
使模型能够使用强类型参数和输出调用你自己的代码。详细了解
。你也可以使用
- [function calling](/docs/guides/function-calling)。你还可以使用
- 自定义工具调用你自己的代码。
+ [function calling](/docs/guides/function-calling). 你也可以使用
+ 自定义工具来调用你自己的代码。
- `Function object { name, parameters, strict, 5 more }`
@@ -144386,45 +144348,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -144432,7 +144394,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -144444,7 +144406,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -144452,21 +144414,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -144492,18 +144454,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -144511,22 +144473,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -144536,23 +144498,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -144563,11 +144525,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -144585,21 +144547,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -144607,14 +144569,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -144646,32 +144608,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -144679,13 +144641,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -144693,9 +144655,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -144707,22 +144669,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -144731,7 +144693,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -144741,7 +144703,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -144797,7 +144759,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -144807,11 +144769,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -144821,7 +144783,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -144829,7 +144791,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -144838,13 +144800,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -144853,7 +144815,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -144880,7 +144842,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -144891,7 +144853,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -144908,13 +144870,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -144930,7 +144892,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -144940,7 +144902,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -144966,11 +144928,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -144996,19 +144958,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -145028,19 +144990,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -145048,11 +145010,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -145098,7 +145060,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -145110,11 +145072,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -145128,7 +145090,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -145138,7 +145100,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -145148,23 +145110,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -145182,29 +145144,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `top_logprobs: optional number or null`
- 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的最大最可能
- token 数量,每个 token 都附带对应的对数
+ 一个介于 0 到 20 之间的整数,指定在每个 token 位置返回的
+ 最可能 token 的最大数量,每个 token 都有一个关联的对数
概率。在某些情况下,返回的 token 数量可能少于
- 所请求的数量。
+ 请求的数量。
- `top_p: optional number or null`
- 一种名为核采样的温度采样替代方案,
- 其中模型会考虑 top_p 概率质量排名前列的词元结果。
- 因此,0.1 表示仅考虑构成前 10% 概率质量的词元。
+ 一种温度采样的替代方法,称为核采样,
+ 模型会考虑概率质量排名前 top_p 的标记的结果。
+ 因此 0.1 表示仅考虑构成前 10% 概率质量的标记。
会被考虑。
- 我们通常建议修改此参数或 `temperature` 但不要同时修改两者。
+ 我们通常建议调整此项或 `temperature` 但不要同时调整两者。
- `truncation: optional "auto" or "disabled" or null`
用于模型响应的截断策略。
- - `auto`:如果此 Response 的输入超过
- 模型的上下文窗口大小,模型将通过从对话开头丢弃条目来截断
- 响应以适配上下文窗口。
- - `disabled` (默认):如果输入大小将超出模型的上下文窗口
- 大小,请求将失败并返回 400 错误。
+ - `auto`:如果此 Response 的输入超出
+ 模型的上下文窗口大小,模型将通过从对话开头
+ 丢弃条目来截断响应以适配上下文窗口。
+ - `disabled` (默认):如果输入大小将超过模型的上下文窗口
+ 大小,请求将以 400 错误失败。
- `"auto"`
@@ -145212,9 +145174,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user: optional string`
- 此字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
- 用于标识你的最终用户的稳定标识符。
- 通过更好地对相似请求进行分桶以提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
+ 该字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化效果。
+ 你的最终用户的稳定标识符。
+ 通过更好地对相似请求进行分桶来提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [详细了解](/docs/guides/safety-best-practices#safety-identifiers).
### Responses 服务端事件
@@ -145224,22 +145186,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseAudioWsDelta = ResponseAudioDeltaEvent`
- 当出现部分音频响应时发出。
+ 当存在部分音频响应时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseAudioWsDone = ResponseAudioDoneEvent`
- 当音频响应完成时发出。
+ 音频响应完成时触发。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseAudioTranscriptWsDelta = ResponseAudioTranscriptDeltaEvent`
@@ -145248,38 +145210,38 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseAudioTranscriptWsDone = ResponseAudioTranscriptDoneEvent`
- 当完整音频转写完成时发出。
+ 在完整音频转录完成时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseCodeInterpreterCallCodeWsDelta = ResponseCodeInterpreterCallCodeDeltaEvent`
- 当代码解释器流式传输出部分代码片段时发出。
+ 当代码解释器流式输出部分代码片段时触发。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseCodeInterpreterCallCodeWsDone = ResponseCodeInterpreterCallCodeDoneEvent`
- 当代码解释器最终确定代码片段时发出。
+ 当代码解释器最终确定代码片段时触发。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseCodeInterpreterCallWsCompleted = ResponseCodeInterpreterCallCompletedEvent`
@@ -145288,8 +145250,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseCodeInterpreterCallInWsProgress = ResponseCodeInterpreterCallInProgressEvent`
@@ -145298,8 +145260,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseCodeInterpreterCallWsInterpreting = ResponseCodeInterpreterCallInterpretingEvent`
@@ -145308,8 +145270,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseWsCompleted = ResponseCompletedEvent`
@@ -145318,98 +145280,98 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseContentPartWsAdded = ResponseContentPartAddedEvent`
- 在新增内容部分时触发。
+ 当新增一个内容分块时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseContentPartWsDone = ResponseContentPartDoneEvent`
- 当某个内容部分完成时触发。
+ 在内容部分完成时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseWsCreated = ResponseCreatedEvent`
- 在创建响应时发出的事件。
+ 在创建 response 时发出的事件。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseFileSearchCallWsCompleted = ResponseFileSearchCallCompletedEvent`
- 在文件搜索调用完成(找到结果)时发出。
+ 在文件搜索调用完成时触发(已找到结果)。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseFileSearchCallInWsProgress = ResponseFileSearchCallInProgressEvent`
- 在发起 文件搜索 调用时发出。
+ 在发起文件搜索调用时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseFileSearchCallWsSearching = ResponseFileSearchCallSearchingEvent`
- 在文件搜索正在执行检索时发出。
+ 当 文件搜索 正在搜索时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseFunctionCallArgumentsWsDelta = ResponseFunctionCallArgumentsDeltaEvent`
- 当存在部分函数调用参数的增量时发出。
+ 当存在部分函数调用参数增量时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseFunctionCallArgumentsWsDone = ResponseFunctionCallArgumentsDoneEvent`
- 在函数调用参数被最终确定时发出。
+ 在函数调用参数确定时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseShellCallCommandWsAdded = ResponseShellCallCommandAddedEvent`
- 指示已将 shell 命令添加到工具调用的流式事件。
+ 一个流式事件,表示一条 shell 命令已被添加到工具调用中。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseShellCallCommandWsDelta = ResponseShellCallCommandDeltaEvent`
@@ -145418,28 +145380,28 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseShellCallCommandWsDone = ResponseShellCallCommandDoneEvent`
- 指示 shell 命令已完成的流事件。
+ 指示 shell 命令已完成的流式事件。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseShellCallOutputContentWsDelta = ResponseShellCallOutputContentDeltaEvent`
- 表示 shell 调用输出被增量添加的流事件。
+ 指示 shell 调用输出被增量添加的流式事件。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseShellCallOutputContentWsDone = ResponseShellCallOutputContentDoneEvent`
@@ -145448,88 +145410,88 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseInWsProgress = ResponseInProgressEvent`
- 当响应正在进行时发出。
+ 在响应进行中时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseWsFailed = ResponseFailedEvent`
- 当 response 失败时发出的事件。
+ 当响应失败时发出的事件。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseWsIncomplete = ResponseIncompleteEvent`
- 当响应以不完整状态结束时发出的事件。
+ 当响应未完成时发出的事件。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseOutputItemWsAdded = ResponseOutputItemAddedEvent`
- 当新增一个输出项时触发。
+ 在添加新的输出项时触发。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseOutputItemWsDone = ResponseOutputItemDoneEvent`
- 当某个输出项被标记为完成时触发。
+ 在某个输出项被标记为完成时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseReasoningSummaryPartWsAdded = ResponseReasoningSummaryPartAddedEvent`
- 当新的推理摘要部分被添加时触发。
+ 当新增推理摘要分块时触发。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseReasoningSummaryPartWsDone = ResponseReasoningSummaryPartDoneEvent`
- 在推理摘要部分完成时发出。
+ 当某个推理摘要分块完成时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseReasoningSummaryTextWsDelta = ResponseReasoningSummaryTextDeltaEvent`
- 当有增量被添加到推理摘要文本时触发。
+ 当向推理摘要文本添加增量时触发。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseReasoningSummaryTextWsDone = ResponseReasoningSummaryTextDoneEvent`
@@ -145538,18 +145500,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseReasoningTextWsDelta = ResponseReasoningTextDeltaEvent`
- 在向推理文本添加增量时发出。
+ 当向推理文本添加增量时触发。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseReasoningTextWsDone = ResponseReasoningTextDoneEvent`
@@ -145558,8 +145520,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseRefusalWsDelta = ResponseRefusalDeltaEvent`
@@ -145568,208 +145530,208 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseRefusalWsDone = ResponseRefusalDoneEvent`
- 在拒绝文本最终确定时发出。
+ 当拒绝文本完成时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseTextWsDelta = ResponseTextDeltaEvent`
- 当有额外的文本增量时发出。
+ 在出现额外文本增量时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseTextWsDone = ResponseTextDoneEvent`
- 当文本内容最终确定时发出。
+ 在文本内容完成时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseWebSearchCallWsCompleted = ResponseWebSearchCallCompletedEvent`
- 当一次网页搜索调用完成时发出。
+ 在 网页搜索 调用完成时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseWebSearchCallInWsProgress = ResponseWebSearchCallInProgressEvent`
- 当一次网页搜索调用被发起时发出。
+ 在 网页搜索 调用发起时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseWebSearchCallWsSearching = ResponseWebSearchCallSearchingEvent`
- 在网页搜索调用执行时发出。
+ 当 网页搜索 调用正在执行时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseImageGenCallWsCompleted = ResponseImageGenCallCompletedEvent`
- 当一个图像生成工具调用已完成且最终图像可用时发出。
+ 当图像生成工具调用已完成且最终图像可用时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseImageGenCallWsGenerating = ResponseImageGenCallGeneratingEvent`
- 当图像生成工具调用正在主动生成图像时触发(中间状态)。
+ 当图像生成工具调用正在主动生成图像时发出(中间状态)。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseImageGenCallInWsProgress = ResponseImageGenCallInProgressEvent`
- 当图像生成工具调用进行中时发出。
+ 当图像生成工具调用进行时触发。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseImageGenCallPartialWsImage = ResponseImageGenCallPartialImageEvent`
- 在图像生成流式传输过程中,当有部分图像可用时触发。
+ 在图像生成流式传输期间出现部分图像时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseMcpCallArgumentsWsDelta = ResponseMcpCallArgumentsDeltaEvent`
- 当 MCP 工具调用的参数存在 delta(部分更新)时发出。
+ 在 MCP 工具调用的参数存在增量(部分更新)时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseMcpCallArgumentsWsDone = ResponseMcpCallArgumentsDoneEvent`
- 当 MCP 工具调用的参数被最终确定时发出。
+ 在 MCP 工具调用的参数确定后发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseMcpCallWsCompleted = ResponseMcpCallCompletedEvent`
- 当 MCP 工具调用已成功完成时触发。
+ 当 MCP 工具调用成功完成时触发。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseMcpCallWsFailed = ResponseMcpCallFailedEvent`
- 当 MCP 工具调用失败时触发。
+ 当 MCP 工具调用失败时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseMcpCallInWsProgress = ResponseMcpCallInProgressEvent`
- 在 MCP 工具调用进行中时发出。
+ 在 MCP 工具调用进行中时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseMcpListToolsWsCompleted = ResponseMcpListToolsCompletedEvent`
- 在成功检索到可用的 MCP 工具列表时发出。
+ 在可用 MCP 工具列表成功检索到时触发。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseMcpListToolsWsFailed = ResponseMcpListToolsFailedEvent`
- 在尝试列出可用的 MCP 工具失败时发出。
+ 当尝试列出可用的 MCP 工具失败时发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseMcpListToolsInWsProgress = ResponseMcpListToolsInProgressEvent`
- 系统在检索可用 MCP 工具列表的过程中发出。
+ 在系统正在检索可用 MCP 工具列表的过程中发出。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseOutputTextAnnotationWsAdded = ResponseOutputTextAnnotationAddedEvent`
- 当向输出文本内容添加批注时发出。
+ 当向输出文本内容添加注解时触发。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseWsQueued = ResponseQueuedEvent`
- 当响应被排队等待处理时发出。
+ 当一个响应被加入队列并等待处理时触发。
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseCustomToolCallInputWsDelta = ResponseCustomToolCallInputDeltaEvent`
@@ -145778,8 +145740,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseCustomToolCallInputWsDone = ResponseCustomToolCallInputDoneEvent`
@@ -145788,17 +145750,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `stream_id: optional string`
- 发出此事件的 WebSocket 通道。该字段在以下情况下存在
- 当原始 `response.create` 事件提供了
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段
+ 原始事件 `response.create` 提供了
`stream_id`.
- `ResponseWsError object { error, type, sequence_number, 2 more }`
- 在处理 Responses WebSocket 请求过程中发生错误时发出。
+ 在处理 Responses WebSocket 请求时发生错误时发出。
- `error: object { code, message, param, 2 more }`
- 有关错误的详细信息。
+ 有关该错误的详细信息。
- `code: string or null`
@@ -145806,19 +145768,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `message: string`
- 已发出的、人类可读的错误消息。
+ 已发出的、可供人类阅读的错误消息。
- `param: string or null`
- 与此错误关联的参数名称(若有)。
+ 与该错误关联的参数名称(如果有)。
- `type: string`
- 发出的错误类型。
+ 已发出的错误类型。
- `headers: optional map[string]`
- 与此错误一同发出的响应头(若有)。
+ 与该错误一同发出的响应头(如果有)。
- `type: "error"`
@@ -145828,7 +145790,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `sequence_number: optional number`
- 响应流发出的错误的序号。
+ 响应流所发出错误的序列号。
- `status: optional number`
@@ -145836,23 +145798,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `stream_id: optional string`
- 发出该事件的 WebSocket 通道。当以下情况时会出现此字段:
- 原始 `response.create` 事件提供了 `stream_id`.
+ 发出此事件的 WebSocket 通道。在以下情况下会出现此字段:
+ 原始事件 `response.create` 提供了 `stream_id`.
-### 服务等级
+### Service Tier
- `ServiceTier = "auto" or "default" or "flex" or 4 more`
指定用于处理该请求的处理类型。
- - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则项目将使用 'default'。
+ - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另行配置,否则该项目将使用 'default'。
- 如果设置为 'default',则该请求将使用所选模型的标准定价和性能进行处理。
- 如果设置为 '[flex](/docs/guides/flex-processing)',则该请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别选择启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 `service_tier=fast` 或 `service_tier=priority` 参数用于 Responses 或 Chat Completions。响应将显示 `service_tier=priority` ,无论你是否在请求中指定了 `service_tier=fast` 或 `priority` 。
- - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级返回的响应将显示 `service_tier=ultrafast`.
- - 如果未设置,默认行为是 'auto'。
+ - 若要在请求级别启用 [快速模式](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过它处理的响应将显示 `service_tier=ultrafast`.
+ - 未设置时,默认行为为 'auto'。
- 当设置 `service_tier` 参数时,响应正文将包含基于实际用于处理该请求的处理模式的 `service_tier` 值。此响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应体中将根据实际用于处理该请求的处理模式包含对应的 `service_tier` 值。此响应中的值可能与该参数中设置的值不同。
- `"auto"`
@@ -145874,7 +145836,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -145886,7 +145848,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
可选的技能版本。使用正整数或 'latest'。省略则使用默认值。
-### 工具选择可用
+### 允许的工具选择
- `ToolChoiceAllowed object { mode, tools, type }`
@@ -145907,7 +145869,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of map[unknown]`
- 模型应允许调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -145929,11 +145891,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceApplyPatch object { type }`
- 在执行工具调用时强制模型调用 apply_patch 工具。
+ 强制模型在执行工具调用时调用 apply_patch 工具。
- `type: "apply_patch"`
- 要调用的工具。始终为 `apply_patch`.
+ 要调用的工具。始终 `apply_patch`.
- `"apply_patch"`
@@ -145941,7 +145903,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceCustom object { name, type }`
- 使用此选项可以强制模型调用特定的自定义工具。
+ 使用此选项可强制模型调用特定的自定义工具。
- `name: string`
@@ -145973,7 +145935,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceMcp object { server_label, type, name }`
- 使用此选项可以强制模型调用远程 MCP 服务器上的特定工具。
+ 使用此选项可强制模型调用远程 MCP 服务器上的特定工具。
- `server_label: string`
@@ -145989,13 +145951,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
要在服务器上调用的工具的名称。
-### 工具选择选项
+### 工具选择 Options
- `ToolChoiceOptions = "none" or "auto" or "required"`
- 控制模型调用哪个工具(如果有的话)。
+ 控制模型调用哪个工具(如果有)。
- `none` 表示模型不会调用任何工具,而是生成一条消息。
+ `none` 表示模型将不会调用任何工具,而是生成一条消息。
`auto` 表示模型可以在生成消息或调用一个或
多个工具之间进行选择。
@@ -146012,11 +145974,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceShell object { type }`
- 在需要工具调用时强制模型调用 shell 工具。
+ 在需要工具调用时,强制模型调用 shell 工具。
- `type: "shell"`
- 要调用的工具。始终为 `shell`.
+ 要调用的工具。始终 `shell`.
- `"shell"`
@@ -146025,11 +145987,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ToolChoiceTypes object { type }`
指示模型应使用内置工具来生成响应。
- [了解有关内置工具的更多信息](/docs/guides/tools).
+ [了解更多关于内置工具的信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
- 模型应使用的托管工具类型。了解更多关于
+ 模型应使用的 托管工具 类型。了解更多关于
[内置工具](/docs/guides/tools).
允许的值为:
@@ -146058,9 +146020,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `"code_interpreter"`
-# 输入项
+# Input Items
-## 列出输入项
+## List input items
**get** `/responses/{response_id}/input_items`
@@ -146074,12 +146036,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `after: optional string`
- 分页时用于列出其后各项的项 ID。
+ 用于在分页中列出其后条目的条目 ID。
- `include: optional array of ResponseIncludable`
- 要在响应中包含的其他字段。详见上方 `include`
- 参数的 Response 创建部分以了解更多信息。
+ 响应中要包含的其他字段。更多信息请参阅上面的 Response 创建 `include`
+ 参数。
- `"file_search_call.results"`
@@ -146099,29 +146061,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `limit: optional number`
- 返回对象数量的上限。Limit 的取值范围介于
- 1 到 100 之间,默认值为 20。
+ 返回对象数量的上限。范围介于
+ 1 到 100 之间,默认为 20。
- `order: optional "asc" or "desc"`
- 输入项的返回顺序。默认值为 `desc`.
+ 返回输入条目的顺序。默认为 `desc`.
- - `asc`: 按升序返回输入项。
- - `desc`: 按降序返回输入项。
+ - `asc`: 按升序返回输入条目。
+ - `desc`: 按降序返回输入条目。
- `"asc"`
- `"desc"`
-### 返回
+### 返回值
- `ResponseItemList object { data, first_id, has_more, 2 more }`
- Response 项的列表。
+ Response 条目列表。
- `data: array of ResponseInputMessageItem or ResponseOutputMessage or object { id, queries, status, 2 more } or 26 more`
- 用于生成此响应的项列表。
+ 用于生成此 response 的条目列表。
- `ResponseInputMessageItem object { id, content, role, 2 more }`
@@ -146131,40 +146093,40 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `content: ResponseInputMessageContentList`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -146176,25 +146138,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -146204,13 +146166,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -146220,33 +146182,33 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `system`, or `developer`.
+ 消息输入的角色。其一为 接口 `user`, `system`,或 `developer`.
- `"user"`
@@ -146262,8 +146224,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -146277,7 +146239,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -146285,15 +146247,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -146309,7 +146271,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -146319,25 +146281,25 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -146349,7 +146311,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -146357,11 +146319,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -146415,15 +146377,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -146435,8 +146397,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -146452,9 +146414,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -146462,8 +146424,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -146475,7 +146437,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -146500,11 +146462,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -146522,7 +146484,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -146531,7 +146493,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -146543,7 +146505,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -146559,8 +146521,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -146584,7 +146546,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -146598,7 +146560,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -146624,7 +146586,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -146642,7 +146604,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -146661,7 +146623,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -146671,11 +146633,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -146695,15 +146657,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -146735,19 +146697,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -146771,8 +146733,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -146788,7 +146750,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -146804,7 +146766,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -146818,31 +146780,31 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"completed"`
@@ -146854,13 +146816,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、已被
+ API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -146877,12 +146839,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -146890,12 +146852,12 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -146905,11 +146867,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -146927,7 +146889,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -146941,7 +146903,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -146959,7 +146921,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -146971,7 +146933,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
@@ -146995,8 +146957,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -147032,7 +146994,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `namespace: optional string`
@@ -147055,15 +147017,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -147071,8 +147033,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -147116,7 +147078,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `name: optional string`
@@ -147160,13 +147122,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_call"`
- 条目的类型,恒为 `tool_search_call`.
+ item 的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -147232,37 +147194,37 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -147275,11 +147237,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -147299,7 +147261,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -147315,15 +147277,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -147337,7 +147299,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -147345,7 +147307,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -147357,7 +147319,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -147365,21 +147327,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -147405,18 +147367,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -147424,22 +147386,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -147449,23 +147411,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -147476,11 +147438,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -147498,21 +147460,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -147520,14 +147482,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -147559,32 +147521,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -147592,13 +147554,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -147606,9 +147568,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -147620,22 +147582,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -147644,7 +147606,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -147654,7 +147616,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -147684,29 +147646,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -147742,7 +147704,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -147752,11 +147714,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -147766,7 +147728,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -147774,7 +147736,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -147783,13 +147745,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -147798,7 +147760,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -147825,7 +147787,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -147836,7 +147798,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -147853,13 +147815,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -147875,7 +147837,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -147885,7 +147847,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -147909,7 +147871,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -147933,13 +147895,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -147963,7 +147925,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -147971,13 +147933,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -147997,7 +147959,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -148009,13 +147971,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -148029,11 +147991,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -148059,7 +148021,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -148077,7 +148039,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -148091,19 +148053,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -148123,19 +148085,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -148143,11 +148105,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -148193,7 +148155,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -148205,11 +148167,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -148223,7 +148185,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -148233,7 +148195,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -148243,23 +148205,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -148277,13 +148239,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "tool_search_output"`
- 条目的类型,恒为 `tool_search_output`.
+ item 的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -148313,7 +148275,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -148347,45 +148309,45 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -148393,7 +148355,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -148405,7 +148367,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -148413,21 +148375,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -148453,18 +148415,18 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -148472,22 +148434,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -148497,23 +148459,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -148524,11 +148486,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -148546,21 +148508,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -148568,14 +148530,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -148607,32 +148569,32 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -148640,13 +148602,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -148654,9 +148616,9 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -148668,22 +148630,22 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -148692,7 +148654,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -148702,7 +148664,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -148758,7 +148720,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -148768,11 +148730,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -148782,7 +148744,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -148790,7 +148752,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -148799,13 +148761,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -148814,7 +148776,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -148841,7 +148803,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -148852,7 +148814,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -148869,13 +148831,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -148891,7 +148853,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -148901,7 +148863,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -148927,11 +148889,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -148957,19 +148919,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -148989,19 +148951,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -149009,11 +148971,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -149059,7 +149021,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -149071,11 +149033,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -149089,7 +149051,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -149099,7 +149061,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -149109,23 +149071,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -149143,15 +149105,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "additional_tools"`
- 条目的类型,恒为 `additional_tools`.
+ item 的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -149164,7 +149126,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -149184,7 +149146,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -149194,20 +149156,20 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -149227,7 +149189,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -149235,7 +149197,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program"`
- 条目的类型,恒为 `program`.
+ item 的类型。始终为 `program`.
- `"program"`
@@ -149251,7 +149213,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -149263,13 +149225,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "program_output"`
- 条目的类型,恒为 `program_output`.
+ item 的类型。始终为 `program_output`.
- `"program_output"`
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -149277,21 +149239,21 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的已加密内容。
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -149315,7 +149277,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -149338,7 +149300,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -149350,23 +149312,23 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -149384,13 +149346,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -149406,11 +149368,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -149424,11 +149386,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -149442,7 +149404,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -149452,7 +149414,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -149460,13 +149422,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -149480,17 +149442,17 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -149528,7 +149490,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -149538,7 +149500,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -149572,7 +149534,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。通过 API 返回该条目时填充此字段。
- `call_id: string`
@@ -149580,15 +149542,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -149596,13 +149558,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -149610,7 +149572,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -149624,11 +149586,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`, or `incomplete`.
+ shell 调用输出的状态。可选值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -149664,7 +149626,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -149672,15 +149634,15 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -149696,7 +149658,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的 diff 创建新文件。
- `"create_file"`
@@ -149710,7 +149672,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "delete_file"`
- 删除指定的文件。
+ 删除指定文件。
- `"delete_file"`
@@ -149728,13 +149690,13 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "update_file"`
- 使用提供的差异更新现有文件。
+ 使用提供的 diff 更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -149742,7 +149704,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -149772,19 +149734,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -149792,7 +149754,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -149850,7 +149812,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -149858,29 +149820,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -149888,29 +149850,29 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `id: string`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -149920,7 +149882,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -149928,11 +149890,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -149940,14 +149902,14 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -149987,7 +149949,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -150003,7 +149965,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `id: string`
- 自定义工具调用项的唯一 ID。
+ 自定义工具调用条目的唯一 ID。
- `call_id: string`
@@ -150019,8 +149981,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -150056,7 +150018,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `namespace: optional string`
@@ -150070,7 +150032,7 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -150087,11 +150049,11 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -150099,8 +150061,8 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -150140,19 +150102,19 @@ curl https://api.openai.com/v1/responses/resp_123 \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `first_id: string`
- 列表中第一项的 ID。
+ 列表中第一个条目的 ID。
- `has_more: boolean`
- 是否还有更多项可用。
+ 是否还有更多可用条目。
- `last_id: string`
- 列表中最后一项的 ID。
+ 列表中最后一个条目的 ID。
- `object: "list"`
@@ -150167,7 +150129,7 @@ curl https://api.openai.com/v1/responses/$RESPONSE_ID/input_items \
-H "Authorization: Bearer $OPENAI_API_KEY"
```
-#### 响应
+#### Response
```json
{
@@ -150203,7 +150165,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
-H "Authorization: Bearer $OPENAI_API_KEY"
```
-#### 响应
+#### Response
```json
{
@@ -150229,15 +150191,15 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
## Domain Types
-### 响应项目列表
+### 响应项列表
- `ResponseItemList object { data, first_id, has_more, 2 more }`
- Response 项的列表。
+ Response 条目列表。
- `data: array of ResponseInputMessageItem or ResponseOutputMessage or object { id, queries, status, 2 more } or 26 more`
- 用于生成此响应的项列表。
+ 用于生成此 response 的条目列表。
- `ResponseInputMessageItem object { id, content, role, 2 more }`
@@ -150247,40 +150209,40 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `content: ResponseInputMessageContentList`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -150292,25 +150254,25 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -150320,13 +150282,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -150336,33 +150298,33 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `system`, or `developer`.
+ 消息输入的角色。其一为 接口 `user`, `system`,或 `developer`.
- `"user"`
@@ -150378,8 +150340,8 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -150393,7 +150355,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -150401,15 +150363,15 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -150425,7 +150387,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -150435,25 +150397,25 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -150465,7 +150427,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -150473,11 +150435,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -150531,15 +150493,15 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -150551,8 +150513,8 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -150568,9 +150530,9 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -150578,8 +150540,8 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -150591,7 +150553,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -150616,11 +150578,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -150638,7 +150600,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -150647,7 +150609,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -150659,7 +150621,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -150675,8 +150637,8 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -150700,7 +150662,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -150714,7 +150676,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -150740,7 +150702,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -150758,7 +150720,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -150777,7 +150739,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -150787,11 +150749,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -150811,15 +150773,15 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -150851,19 +150813,19 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -150887,8 +150849,8 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -150904,7 +150866,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -150920,7 +150882,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -150934,31 +150896,31 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"completed"`
@@ -150970,13 +150932,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、已被
+ API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -150993,12 +150955,12 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -151006,12 +150968,12 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -151021,11 +150983,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -151043,7 +151005,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -151057,7 +151019,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -151075,7 +151037,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -151087,7 +151049,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
@@ -151111,8 +151073,8 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -151148,7 +151110,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `namespace: optional string`
@@ -151171,15 +151133,15 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -151187,8 +151149,8 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -151232,7 +151194,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `name: optional string`
@@ -151276,13 +151238,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "tool_search_call"`
- 条目的类型,恒为 `tool_search_call`.
+ item 的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -151348,37 +151310,37 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -151391,11 +151353,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -151415,7 +151377,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -151431,15 +151393,15 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -151453,7 +151415,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -151461,7 +151423,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -151473,7 +151435,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -151481,21 +151443,21 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -151521,18 +151483,18 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -151540,22 +151502,22 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -151565,23 +151527,23 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -151592,11 +151554,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -151614,21 +151576,21 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -151636,14 +151598,14 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -151675,32 +151637,32 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -151708,13 +151670,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -151722,9 +151684,9 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -151736,22 +151698,22 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -151760,7 +151722,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -151770,7 +151732,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -151800,29 +151762,29 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -151858,7 +151820,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -151868,11 +151830,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -151882,7 +151844,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -151890,7 +151852,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -151899,13 +151861,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -151914,7 +151876,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -151941,7 +151903,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -151952,7 +151914,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -151969,13 +151931,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -151991,7 +151953,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -152001,7 +151963,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -152025,7 +151987,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -152049,13 +152011,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -152079,7 +152041,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -152087,13 +152049,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -152113,7 +152075,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -152125,13 +152087,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -152145,11 +152107,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -152175,7 +152137,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -152193,7 +152155,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -152207,19 +152169,19 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -152239,19 +152201,19 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -152259,11 +152221,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -152309,7 +152271,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -152321,11 +152283,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -152339,7 +152301,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -152349,7 +152311,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -152359,23 +152321,23 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -152393,13 +152355,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "tool_search_output"`
- 条目的类型,恒为 `tool_search_output`.
+ item 的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -152429,7 +152391,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -152463,45 +152425,45 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -152509,7 +152471,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -152521,7 +152483,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -152529,21 +152491,21 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -152569,18 +152531,18 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -152588,22 +152550,22 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -152613,23 +152575,23 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -152640,11 +152602,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -152662,21 +152624,21 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -152684,14 +152646,14 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -152723,32 +152685,32 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -152756,13 +152718,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -152770,9 +152732,9 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -152784,22 +152746,22 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -152808,7 +152770,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -152818,7 +152780,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -152874,7 +152836,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -152884,11 +152846,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -152898,7 +152860,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -152906,7 +152868,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -152915,13 +152877,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -152930,7 +152892,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -152957,7 +152919,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -152968,7 +152930,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -152985,13 +152947,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -153007,7 +152969,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -153017,7 +152979,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -153043,11 +153005,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -153073,19 +153035,19 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -153105,19 +153067,19 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -153125,11 +153087,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -153175,7 +153137,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -153187,11 +153149,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -153205,7 +153167,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -153215,7 +153177,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -153225,23 +153187,23 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -153259,15 +153221,15 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "additional_tools"`
- 条目的类型,恒为 `additional_tools`.
+ item 的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -153280,7 +153242,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -153300,7 +153262,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -153310,20 +153272,20 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -153343,7 +153305,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -153351,7 +153313,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "program"`
- 条目的类型,恒为 `program`.
+ item 的类型。始终为 `program`.
- `"program"`
@@ -153367,7 +153329,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -153379,13 +153341,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "program_output"`
- 条目的类型,恒为 `program_output`.
+ item 的类型。始终为 `program_output`.
- `"program_output"`
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -153393,21 +153355,21 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的已加密内容。
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -153431,7 +153393,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -153454,7 +153416,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -153466,23 +153428,23 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -153500,13 +153462,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -153522,11 +153484,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -153540,11 +153502,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -153558,7 +153520,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -153568,7 +153530,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -153576,13 +153538,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -153596,17 +153558,17 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `id: string`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -153644,7 +153606,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -153654,7 +153616,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -153688,7 +153650,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。通过 API 返回该条目时填充此字段。
- `call_id: string`
@@ -153696,15 +153658,15 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
@@ -153712,13 +153674,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -153726,7 +153688,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
@@ -153740,11 +153702,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`, or `incomplete`.
+ shell 调用输出的状态。可选值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -153780,7 +153742,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -153788,15 +153750,15 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `id: string`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -153812,7 +153774,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的 diff 创建新文件。
- `"create_file"`
@@ -153826,7 +153788,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "delete_file"`
- 删除指定的文件。
+ 删除指定文件。
- `"delete_file"`
@@ -153844,13 +153806,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "update_file"`
- 使用提供的差异更新现有文件。
+ 使用提供的 diff 更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -153858,7 +153820,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -153888,19 +153850,19 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用所发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -153908,7 +153870,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -153966,7 +153928,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -153974,29 +153936,29 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -154004,29 +153966,29 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `id: string`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -154036,7 +153998,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -154044,11 +154006,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -154056,14 +154018,14 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -154103,7 +154065,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -154119,7 +154081,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `id: string`
- 自定义工具调用项的唯一 ID。
+ 自定义工具调用条目的唯一 ID。
- `call_id: string`
@@ -154135,8 +154097,8 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -154172,7 +154134,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `namespace: optional string`
@@ -154186,7 +154148,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -154203,11 +154165,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -154215,8 +154177,8 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -154256,19 +154218,19 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `first_id: string`
- 列表中第一项的 ID。
+ 列表中第一个条目的 ID。
- `has_more: boolean`
- 是否还有更多项可用。
+ 是否还有更多可用条目。
- `last_id: string`
- 列表中最后一项的 ID。
+ 列表中最后一个条目的 ID。
- `object: "list"`
@@ -154276,22 +154238,22 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `"list"`
-# 输入令牌
+# 输入 Tokens
-## 获取输入令牌计数
+## 获取输入 token 计数
**post** `/responses/input_tokens`
返回请求的输入 token 计数。
-返回一个对象,其中包含 `object` 设置为 `response.input_tokens` 以及一个 `input_tokens` 计数。
+返回一个对象,其中 `object` 设置为 `response.input_tokens` 和一个 `input_tokens` 计数。
-### 请求体参数
+### 正文参数
- `conversation: optional string or ResponseConversationParam or null`
- 此响应所属的对话。该对话中的条目会被添加到 `input_items` 此响应请求之前。
- 此响应的输入条目和输出条目会在该响应完成后自动添加到此对话中。
+ 本次响应所属的对话。该对话中的条目会前置拼接到 `input_items` 本次响应请求的输入中。
+ 本次响应的输入条目和输出条目会在响应完成后自动追加到该对话中。
- `ConversationID = string`
@@ -154299,7 +154261,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ResponseConversationParam object { id }`
- 此响应所属的对话。
+ 本次响应所属的对话。
- `id: string`
@@ -154307,69 +154269,69 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `input: optional string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more or null`
- 提供给模型的文本、图像或文件输入,用于生成响应
+ 模型的文本、图像或文件输入,用于生成响应
- `string`
- 发送给模型的文本输入,相当于使用 `user` 角色的文本输入。
+ 发送给模型的文本输入,等同于 `user` 角色的文本输入。
- `array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 包含一个或多个输入条目的列表,用于模型,包含不同的内容类型。
+ 包含一项或多项输入项的列表,可包含不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` role. Messages with the
- `assistant` role are presumed to have been generated by the model in previous
- interactions.
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色给出的指令。带有
+ `assistant` 角色的消息被视为模型在之前的
+ 交互中生成。
- `content: string or ResponseInputMessageContentList`
- Text, image, or audio input to the model, used to generate a response.
- Can also contain previous assistant responses.
+ 发送给模型的文本、图像或音频输入,用于生成响应。
+ 也可以包含之前的助手响应。
- `TextInput = string`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputMessageContentList = array of ResponseInputContent`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -154381,25 +154343,25 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -154409,13 +154371,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -154425,33 +154387,33 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `assistant`, `system`, or
+ 消息输入的角色。其一为 接口 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -154464,9 +154426,9 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -154474,24 +154436,24 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: optional "message"`
- 消息输入的类型。始终为 `message`.
+ 消息输入的类型。始终为 接口 `message`.
- `"message"`
- `Message object { content, role, status, type }`
- 发送给模型的消息输入,其角色表示指令的优先级
- 层级。使用 `developer` 或 `system` 角色给出的指令具有
- precedence over instructions given with the `user` 角色的文本输入。
+ 发送给模型的消息输入,其角色指示指令遵循
+ 层级关系。使用 `developer` 或 `system` 角色给出的指令优先级高于
+ 优先于通过 `user` 角色的文本输入。
- `content: ResponseInputMessageContentList`
- A list of one or many input items to the model, containing different content
- types.
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色。可选值为 `user`, `system`, or `developer`.
+ 消息输入的角色。其一为 接口 `user`, `system`,或 `developer`.
- `"user"`
@@ -154501,8 +154463,8 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。可选值为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。其一为 接口 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -154522,7 +154484,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `id: string`
- 该输出消息的唯一 ID。
+ 输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
@@ -154530,15 +154492,15 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型生成的一段文本输出。
+ 模型生成的一条文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 该文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
- 对某个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -154554,7 +154516,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "file_citation"`
- 文件引用的类型。始终 `file_citation`.
+ 文件引用的类型。始终为 `file_citation`.
- `"file_citation"`
@@ -154564,25 +154526,25 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `end_index: number`
- 消息中该 URL 引用最后一个字符的索引。
+ 消息中 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中该 URL 引用第一个字符的索引。
+ 消息中 URL 引用第一个字符的索引。
- `title: string`
- 该网页资源的标题。
+ 网页资源的标题。
- `type: "url_citation"`
- URL 引用的类型。始终 `url_citation`.
+ URL 引用的类型。始终为 `url_citation`.
- `"url_citation"`
- `url: string`
- 该网页资源的 URL。
+ 网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
@@ -154594,7 +154556,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `end_index: number`
- 消息中该容器文件引用最后一个字符的索引。
+ 消息中容器文件引用最后一个字符的索引。
- `file_id: string`
@@ -154602,11 +154564,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `filename: string`
- 被引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用内容的起始字符索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -154660,15 +154622,15 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝内容。
+ 模型的拒绝回复。
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝内容的类型。始终为 `refusal`.
+ 拒绝回复的类型。始终为 `refusal`.
- `"refusal"`
@@ -154680,8 +154642,8 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`, or
- `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -154697,9 +154659,9 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终答案(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段信息于所有助手消息中——省略它可能会降低性能。不会用于用户消息。
+ 将 assistant 消息标记 `assistant` 为中间评论(接口(`commentary`)或最终答案(接口(`final_answer`).
+ )。对于 接口 `gpt-5.3-codex` 及更高版本的模型,发送后续请求时,请在所有 assistant 消息上保留并重新发送 接口
+ 字段——省略它可能会降低性能。不适用于 user 消息。
- `"commentary"`
@@ -154707,8 +154669,8 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -154720,7 +154682,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -154745,11 +154707,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 组键值对。可用于
- 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板
- 查询对象。键为字符串,最大
- 长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于以结构化
+ 格式存储对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。
+ 值为字符串,最长
+ 512 个字符,或布尔值或数字。
- `string`
@@ -154767,7 +154729,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性分数,取值介于 0 和 1 之间。
- `text: optional string`
@@ -154776,7 +154738,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
对计算机使用工具的工具调用。请参阅
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -154788,7 +154750,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用待处理的安全检查。
- `id: string`
@@ -154804,8 +154766,8 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -154829,7 +154791,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `button: "left" or "right" or "wheel" or 2 more`
- 指示点击时按下了哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`, or `forward`.
+ 表示点击时按下了哪个鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -154843,7 +154805,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "click"`
- 指定事件类型。对于点击操作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
@@ -154869,7 +154831,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "double_click"`
- 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
@@ -154887,7 +154849,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `path: array of object { x, y }`
- 表示拖动操作路径的坐标数组。坐标将以对象数组的形式出现,例如
+ 表示拖动操作路径的坐标数组。坐标将以对象数组的形式呈现,例如
```
[
@@ -154906,7 +154868,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "drag"`
- 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -154916,11 +154878,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -154940,15 +154902,15 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
@@ -154980,19 +154942,19 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `x: number`
- 发生滚动位置的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动位置的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -155016,8 +154978,8 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `actions: optional ComputerActionList`
- 批量操作的扁平化形式, `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 展平后的批量操作,针对 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作特定字段。
- `Click object { button, type, x, 2 more }`
@@ -155033,7 +154995,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -155049,7 +155011,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -155057,44 +155019,44 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ComputerCallOutput object { call_id, output, type, 3 more }`
- 一次 computer 工具调用的输出。
+ 计算机工具调用的输出。
- `call_id: string`
- 产生该输出的 computer 工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,该属性
- 始终为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终设置为
+ computer_screenshot `computer_screenshot`.
- `"computer_screenshot"`
- `file_id: optional string`
- 包含截图的已上传文件的标识符。
+ 包含截图的上传文件的标识符。
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `id: optional string or null`
- computer 工具调用输出的 ID。
+ 计算机工具调用输出的 ID。
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 已被开发者确认的 API 所报告的安全检查结果。
+ 开发者已确认的 API 所报告的安全检查。
- `id: string`
@@ -155110,7 +155072,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值为 `in_progress`, `completed`, or `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。在通过 API 返回输入条目时填充。
- `"in_progress"`
@@ -155121,7 +155083,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `WebSearchCall object { id, action, status, type }`
网页搜索工具调用的结果。参见
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
@@ -155129,12 +155091,12 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行具体操作的对象。
+ 描述本次 网页搜索调用中具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" — 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -155144,11 +155106,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `queries: optional array of string`
- 搜索查询列表。
+ 搜索查询内容。
- `query: optional string`
- 搜索查询。
+ 搜索查询内容。
- `sources: optional array of object { type, url }`
@@ -155166,7 +155128,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `OpenPage object { type, url }`
- 动作类型 "open_page" - 打开搜索结果中的某个特定 URL。
+ 操作类型 "open_page" - 从搜索结果中打开指定 URL。
- `type: "open_page"`
@@ -155180,7 +155142,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `FindInPage object { pattern, type, url }`
- 动作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
@@ -155198,7 +155160,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -155210,14 +155172,14 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [函数调用指南](/docs/guides/function-calling) 了解更多信息。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -155267,8 +155229,8 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -155282,7 +155244,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `output: string or array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的文本、图片或文件输出。
+ 函数工具调用的文本、图像或文件输出。
- `string`
@@ -155290,61 +155252,61 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的内容输出(文本、图片、文件)数组。
+ 函数工具调用的内容输出(文本、图像、文件)数组。
- `ResponseInputTextContent object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `text: string`
- The text input to the model.
+ 发送给模型的文本输入。
- `type: "input_text"`
- The type of the input item. Always `input_text`.
+ 输入项的类型。始终为 `input_text`.
- `"input_text"`
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision)
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
- `type: "input_image"`
- The type of the input item. Always `input_image`.
+ 输入项的类型。始终为 `input_image`.
- `"input_image"`
- `detail: optional ImageDetail or null`
- The detail level of the image to be sent to the model. One of `high`, `low`, `auto`, or `original`. Defaults to `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片的 URL。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -155354,13 +155316,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "input_file"`
- The type of the input item. Always `input_file`.
+ 输入项的类型。始终为 `input_file`.
- `"input_file"`
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的使用量。使用 `low` 以获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 API `auto` 让系统选择细节等级;对于 GPT-5.6 及更高模型,接口, `auto` 使用高质量渲染,这可能会增加输入 token 的使用量。使用 接口 `low` 进行低成本渲染,或 接口 `high` 以更高质量渲染文件。默认为 接口 `auto`.
- `"auto"`
@@ -155374,23 +155336,23 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `file_id: optional string or null`
- The ID of the file to be sent to the model.
+ 发送给模型的文件的 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- Marks the exact end of a reusable prompt prefix. The breakpoint inherits its TTL from the request's `prompt_cache_options.ttl`; the boundary is not rounded to a token block.
+ 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
- `mode: "explicit"`
- The breakpoint mode. Always `explicit`.
+ 断点模式。始终为 `explicit`.
- `"explicit"`
@@ -155402,7 +155364,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `id: optional string or null`
- 函数工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
+ 函数工具调用输出的唯一 ID。当此项通过 API 返回时填充。
- `call_id: optional string or null`
@@ -155442,7 +155404,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -155458,7 +155420,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "tool_search_call"`
- 条目类型。始终为 `tool_search_call`.
+ 项的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
@@ -155526,37 +155488,37 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `key: string`
@@ -155569,11 +155531,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `eq`:等于
- `ne`:不等于
- `gt`:大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -155593,7 +155555,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性 key 进行比较的值,支持字符串、数字或布尔类型。
- `string`
@@ -155609,15 +155571,15 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `unknown`
@@ -155631,7 +155593,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -155639,7 +155601,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -155651,7 +155613,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -155659,21 +155621,21 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -155699,18 +155661,18 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -155718,22 +155680,22 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -155743,23 +155705,23 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -155770,11 +155732,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -155792,21 +155754,21 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -155814,14 +155776,14 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -155853,32 +155815,32 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -155886,13 +155848,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -155900,9 +155862,9 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -155914,22 +155876,22 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -155938,7 +155900,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -155948,7 +155910,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -155978,29 +155940,29 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当 type 为时允许的域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域发起出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 针对白名单域的可选域范围密钥。
+ 针对允许列表中域的可选域作用域密钥。
- `domain: string`
- 与密钥关联的域。
+ 与该密钥关联的域。
- `name: string`
- 要注入到该域的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
- 要注入到该域的密钥值。
+ 为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -156036,7 +155998,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -156046,11 +156008,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -156060,7 +156022,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -156068,7 +156030,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -156077,13 +156039,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -156092,7 +156054,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -156119,7 +156081,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -156130,7 +156092,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -156147,13 +156109,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -156169,7 +156131,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -156179,7 +156141,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -156203,7 +156165,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -156227,13 +156189,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 所引用技能的 ID。
+ 被引用技能的 ID。
- `type: "skill_reference"`
@@ -156257,7 +156219,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -156265,13 +156227,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能来源的类型,必须为 `base64`.
- `"base64"`
@@ -156291,7 +156253,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -156303,13 +156265,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `path: string`
- 包含该技能的目录的路径。
+ 指向包含该技能的目录的路径。
- `ContainerReference object { container_id, type }`
- `container_id: string`
- 所引用的容器的 ID。
+ 被引用的容器的 ID。
- `type: "container_reference"`
@@ -156323,11 +156285,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -156353,7 +156315,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Text object { type }`
- 无约束的任意形式文本。
+ 无约束的任意文本。
- `type: "text"`
@@ -156371,7 +156333,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值之一为 `lark` 或 `regex`.
+ 语法定义的语法格式之一为 `lark` 或 `regex`.
- `"lark"`
@@ -156385,19 +156347,19 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -156417,19 +156379,19 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -156437,11 +156399,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -156487,7 +156449,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -156499,11 +156461,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -156517,7 +156479,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -156527,7 +156489,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -156537,23 +156499,23 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -156571,13 +156533,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "tool_search_output"`
- 条目类型。始终为 `tool_search_output`.
+ 项的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `id: optional string or null`
- 此工具搜索输出的唯一 ID。
+ 该工具搜索输出的唯一 ID。
- `call_id: optional string or null`
@@ -156605,13 +156567,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `role: "developer"`
- 提供其他工具的角色。仅 `developer` 受支持。
+ 提供这些额外工具的角色。仅支持 `developer` 。
- `"developer"`
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 此项目提供的其他工具列表。
+ 在该条目中提供的额外工具列表。
- `Function object { name, parameters, strict, 5 more }`
@@ -156645,45 +156607,45 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -156691,7 +156653,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -156703,7 +156665,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -156711,21 +156673,21 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -156751,18 +156713,18 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -156770,22 +156732,22 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -156795,23 +156757,23 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -156822,11 +156784,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -156844,21 +156806,21 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -156866,14 +156828,14 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -156905,32 +156867,32 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -156938,13 +156900,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -156952,9 +156914,9 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -156966,22 +156928,22 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -156990,7 +156952,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -157000,7 +156962,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -157056,7 +157018,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -157066,11 +157028,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -157080,7 +157042,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -157088,7 +157050,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -157097,13 +157059,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -157112,7 +157074,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -157139,7 +157101,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -157150,7 +157112,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -157167,13 +157129,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -157189,7 +157151,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -157199,7 +157161,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -157225,11 +157187,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -157255,19 +157217,19 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -157287,19 +157249,19 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -157307,11 +157269,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -157357,7 +157319,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -157369,11 +157331,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -157387,7 +157349,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -157397,7 +157359,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -157407,23 +157369,23 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -157441,19 +157403,19 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "additional_tools"`
- 条目类型。始终为 `additional_tools`.
+ 项的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `id: optional string or null`
- 此其他工具项目的唯一 ID。
+ 该额外工具条目的唯一 ID。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链的描述。请务必将这些项目包含在你的 `input` 到 Responses API
- 用于在手动管理上下文时后续轮次的对话
+ 描述推理模型在生成回复时使用的思维链过程
+ 时所用的描述。请务必将这些条目包含在你的 `input` 到 Responses API
+ 用于在手动管理上下文
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -157466,7 +157428,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `text: string`
- 模型到目前为止推理输出的摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -157486,7 +157448,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -157496,20 +157458,20 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `encrypted_content: optional string or null`
- 推理条目的加密内容。默认情况下会填充该字段,
- 用于由返回的推理条目 `POST /v1/responses` 和 WebSocket
- `response.create` 请求。
+ 推理项的加密内容。默认情况下会填充此项,
+ 适用于由 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理项。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 中的 `response.output_item.done` 事件
- 在后续请求中使用。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。尤其是在
- 重要场景:在以下情况下尤为重要 `store` 是 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请使用已完成的推理项及其
+ `encrypted_content` 来自 `response.output_item.done` 事件,并在
+ 后续请求中使用。该 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在
+ 在以下情况下很重要 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`, or
- `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态。可选值包括 `in_progress`, `completed`,或
+ `incomplete`。或 接口。在通过 接口 返回条目时填充。
- `"in_progress"`
@@ -157519,7 +157481,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Compaction object { encrypted_content, type, id }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -157527,17 +157489,17 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "compaction"`
- 条目的类型,恒为 `compaction`.
+ item 的类型。始终为 `compaction`.
- `"compaction"`
- `id: optional string or null`
- 压缩条目的 ID。
+ 压缩项的 ID。
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 由模型发起的图像生成请求。
- `id: string`
@@ -157561,7 +157523,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "image_generation_call"`
- 图像生成调用的类型,恒为 `image_generation_call`.
+ 图像生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -157584,7 +157546,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果无可用输出,可以为 null。
+ 如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -157596,23 +157558,23 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "logs"`
- 输出的类型。Always `logs`.
+ 输出的类型。始终为 `logs`.
- `"logs"`
- `Image object { type, url }`
- 代码解释器的图片输出。
+ 来自代码解释器的图像输出。
- `type: "image"`
- 输出的类型。Always `image`.
+ 输出的类型。始终为 `image`.
- `"image"`
- `url: string`
- 代码解释器图片输出的 URL。
+ 来自代码解释器的图像输出的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -157630,13 +157592,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "code_interpreter_call"`
- 代码解释器工具调用的类型。Always `code_interpreter_call`.
+ 代码解释器工具调用的类型。始终为 `code_interpreter_call`.
- `"code_interpreter_call"`
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -157652,11 +157614,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `env: map[string]`
- 要为命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
- 本地 shell 操作的类型。Always `exec`.
+ 本地 shell 操作的类型。始终为 `exec`.
- `"exec"`
@@ -157670,11 +157632,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -157688,7 +157650,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "local_shell_call"`
- 本地 shell 调用的类型。Always `local_shell_call`.
+ 本地 shell 调用的类型。始终为 `local_shell_call`.
- `"local_shell_call"`
@@ -157698,7 +157660,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `id: string`
- 模型生成的本地 shell 工具调用的唯一 ID。
+ 由模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -157706,13 +157668,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "local_shell_call_output"`
- 本地 shell 工具调用输出的类型。Always `local_shell_call_output`.
+ 本地 shell 工具调用输出的类型。始终为 `local_shell_call_output`.
- `"local_shell_call_output"`
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值之一为 `in_progress`, `completed`, or `incomplete`.
+ 该项的状态。可选值包括 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -157726,7 +157688,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行工具调用的 shell 命令和限制。
+ 用于描述如何运行该工具调用的 shell 命令及其限制。
- `commands: array of string`
@@ -157738,7 +157700,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最大挂钟时间(毫秒)。
+ 允许 shell 命令运行的 wall-clock 最长时间(毫秒)。
- `call_id: string`
@@ -157746,13 +157708,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "shell_call"`
- 条目的类型,恒为 `shell_call`.
+ item 的类型。始终为 `shell_call`.
- `"shell_call"`
- `id: optional string or null`
- shell 工具调用的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -157788,7 +157750,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态,取值之一 `in_progress`, `completed`, or `incomplete`.
+ shell 调用的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -157798,7 +157760,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ShellCallOutput object { call_id, output, type, 4 more }`
- shell 工具调用发出的流式输出项。
+ shell 工具调用发出的流式输出条目。
- `call_id: string`
@@ -157806,7 +157768,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `output: array of ResponseFunctionShellCallOutputContent`
- stdout 和 stderr 输出的捕获块及其关联结果。
+ 捕获的 stdout 和 stderr 输出块,以及它们关联的结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -157818,13 +157780,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "timeout"`
- 结果类型,恒为 `timeout`.
+ 结果类型,始终为 `timeout`.
- `"timeout"`
- `Exit object { exit_code, type }`
- 表示 shell 命令已完成并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -157832,27 +157794,27 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "exit"`
- 结果类型,恒为 `exit`.
+ 结果类型,始终为 `exit`.
- `"exit"`
- `stderr: string`
- shell 调用捕获的 stderr 输出。
+ 为该 shell 调用捕获的 stderr 输出。
- `stdout: string`
- shell 调用捕获的 stdout 输出。
+ 为该 shell 调用捕获的 stdout 输出。
- `type: "shell_call_output"`
- 条目的类型,恒为 `shell_call_output`.
+ item 的类型。始终为 `shell_call_output`.
- `"shell_call_output"`
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。当该项通过 API 返回时填充。
+ shell 工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -157894,11 +157856,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 表示使用 diff 补丁创建、删除或更新文件的工具调用。
+ 表示通过 diff 补丁创建、删除或更新文件的工具调用。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
@@ -157910,7 +157872,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `diff: string`
- 创建文件时要应用的统一 diff 内容。
+ 创建文件时应用的 unified diff 内容。
- `path: string`
@@ -157942,7 +157904,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `diff: string`
- 要应用于现有文件的统一 diff 内容。
+ 应用于现有文件的 unified diff 内容。
- `path: string`
@@ -157956,7 +157918,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。其一为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -157964,13 +157926,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "apply_patch_call"`
- 条目的类型,恒为 `apply_patch_call`.
+ item 的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
- `id: optional string or null`
- apply patch 工具调用的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -157998,15 +157960,15 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ApplyPatchCallOutput object { call_id, status, type, 3 more }`
- apply patch 工具调用发出的流式输出。
+ 由 apply patch 工具调用发出的流式输出。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。其一为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -158014,13 +157976,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "apply_patch_call_output"`
- 条目的类型,恒为 `apply_patch_call_output`.
+ item 的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
- `id: optional string or null`
- apply patch 工具调用输出的唯一 ID。通过 API 返回此条目时填充。
+ apply patch 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -158076,7 +158038,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `annotations: optional unknown or null`
- 有关该工具的附加注解。
+ 关于该工具的附加标注。
- `description: optional string or null`
@@ -158084,29 +158046,29 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "mcp_list_tools"`
- 条目的类型,恒为 `mcp_list_tools`.
+ item 的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具时返回的错误信息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工批准工具调用。
+ 请求人工审批某个工具调用。
- `id: string`
- 批准请求的唯一 ID。
+ 审批请求的唯一 ID。
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
- 要运行的工具的名称。
+ 要运行工具的名称。
- `server_label: string`
@@ -158114,31 +158076,31 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "mcp_approval_request"`
- 条目的类型,恒为 `mcp_approval_request`.
+ item 的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
- `McpApprovalResponse object { approval_request_id, approve, type, 2 more }`
- 对 MCP 批准请求的响应。
+ 对 MCP 审批请求的响应。
- `approval_request_id: string`
- 正在回复的批准请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 条目的类型,恒为 `mcp_approval_response`.
+ item 的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
- `id: optional string or null`
- 批准响应的唯一 ID
+ 审批响应的唯一 ID。
- `reason: optional string or null`
@@ -158146,7 +158108,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对某个工具的调用。
- `id: string`
@@ -158154,11 +158116,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `arguments: string`
- 传递给该工具的参数。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行的工具名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -158166,14 +158128,14 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "mcp_call"`
- 条目的类型,恒为 `mcp_call`.
+ item 的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中传入此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -158213,7 +158175,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`, or `failed`.
+ 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -158227,11 +158189,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 由你的代码生成的自定义工具调用输出,将被发送回模型。
+ 由你的代码生成的自定义工具调用的输出,将发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -158248,11 +158210,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- A text input to the model.
+ 发送给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- An image input to the model. Learn about [image inputs](/docs/guides/vision).
+ 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -158266,7 +158228,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `id: optional string`
- 自定义工具调用输出在 OpenAI 平台中的唯一 ID。
+ 在 OpenAI 平台中该自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -158316,7 +158278,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `id: optional string`
- OpenAI 平台中此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -158344,11 +158306,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `CompactionTrigger object { type, id }`
- 压缩当前上下文。必须是最后一个输入项。
+ 压缩当前上下文。必须作为最后一个输入项。
- `type: "compaction_trigger"`
- 条目的类型,恒为 `compaction_trigger`.
+ item 的类型。始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -158362,11 +158324,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `id: string`
- 要引用的条目 ID。
+ 被引用条目的 ID。
- `type: optional "item_reference" or null`
- 要引用的条目类型。始终为 `item_reference`.
+ 被引用条目的类型。始终为 `item_reference`.
- `"item_reference"`
@@ -158382,7 +158344,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
@@ -158390,7 +158352,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "program"`
- 条目类型。始终为 `program`.
+ 项的类型。始终为 `program`.
- `"program"`
@@ -158406,7 +158368,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `result: string`
- 由程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -158418,18 +158380,18 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "program_output"`
- 条目类型。始终为 `program_output`.
+ 项的类型。始终为 `program_output`.
- `"program_output"`
- `instructions: optional string or null`
- 插入到模型上下文中的系统(或开发者)消息。
- 与 `previous_response_id`,配合使用时,上一次响应中的指令不会延续到下一次响应。这样可以方便地在新响应中替换系统(或开发者)消息。
+ 插入模型上下文中的系统(或开发者)消息。
+ 与 `previous_response_id`,一起使用时,上一次响应的指令不会延续到下一次响应。这样就能方便地在新响应中替换系统(或开发者)消息。
- `model: optional string or null`
- 用于生成响应的模型 ID,例如 `gpt-4o` 或 `o3`. OpenAI 提供一系列具有不同能力、性能特征和价格点的模型。请参阅 [模型指南](/docs/models) 以浏览和比较可用的模型。
+ 用于生成响应的模型 ID,例如 `gpt-4o` 或 `o3`. OpenAI 提供多种不同能力、性能特征和价格的模型。请参阅 [模型指南](/docs/models) 以浏览和比较可用的模型。
- `parallel_tool_calls: optional boolean or null`
@@ -158437,13 +158399,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `personality: optional string or "friendly" or "pragmatic"`
- 应用于本次请求的模型自有风格预设。省略此参数将使用模型的默认风格。支持的值可能会随时间扩展。值的长度不得超过 64 个字符。
+ 应用于本次请求的模型自带样式预设。省略此参数将使用模型的默认样式。支持的值可能会随时间增加。值的长度不得超过 64 个字符。
- `string`
- `"friendly" or "pragmatic"`
- 应用于本次请求的模型自有风格预设。省略此参数将使用模型的默认风格。支持的值可能会随时间扩展。值的长度不得超过 64 个字符。
+ 应用于本次请求的模型自带样式预设。省略此参数将使用模型的默认样式。支持的值可能会随时间增加。值的长度不得超过 64 个字符。
- `"friendly"`
@@ -158451,21 +158413,21 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `previous_response_id: optional string or null`
- 上一次模型响应的唯一 ID。使用此 ID 可以创建多轮对话。详细了解 [对话状态](/docs/guides/conversation-state)。的更多信息。不能与 `conversation`.
+ 上一次模型响应的唯一 ID。使用它可以创建多轮对话。详细了解 [conversation state](/docs/guides/conversation-state)。不能与 `conversation`.
- `reasoning: optional Reasoning or null`
- **仅适用于 gpt-5 和 o-series 模型** 配置选项,适用于 [推理模型](https://platform.openai.com/docs/guides/reasoning).
+ **仅适用于 gpt-5 和 o-series 模型** 适用于 [推理模型](https://platform.openai.com/docs/guides/reasoning).
- `context: optional "auto" or "current_turn" or "all_turns" or null`
- 控制在后续轮次中呈现回模型的推理项。
- 如果省略或设置为 `auto`,则由模型确定上下文模式。
+ 控制在后续回合中哪些推理项会被回传给模型。
+ 如果省略或设置为 `auto`,则由模型决定上下文模式。
`gpt-5.6` 模型系列默认为 `all_turns`;早期模型默认为
`current_turn`.
- 在响应中返回时,这是该响应使用的有效推理上下文模式
- 。
+ 在响应中返回时,这是该响应所使用 的有效推理上下文模式
+ 用于该响应。
- `"auto"`
@@ -158475,13 +158437,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `effort: optional ReasoningEffort or null`
- 限制推理模型在推理上的投入程度。当前支持的值
- 包括 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
- 降低推理投入程度可以让响应更快,并减少响应中推理所用的 token 数。并非所有推理模型都支持每个
- 值。请参阅
- 推理指南
+ 限制推理模型在推理上的投入程度。目前支持
+ 的取值有 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
+ 降低推理投入程度可以让响应更快,并减少响应中用于推理的 token
+ 数量。并非所有推理模型都支持每个
+ 取值。有关各模型的支持情况,请参阅
[推理指南](https://platform.openai.com/docs/guides/reasoning)
- 以了解特定模型的支持情况。
+ 。
- `"none"`
@@ -158499,11 +158461,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `generate_summary: optional "auto" or "concise" or "detailed" or null`
- **已弃用:** 请使用 `summary` 相反。
+ **已弃用:** 请使用 `summary` 改为。
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `"auto"`
@@ -158515,7 +158477,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `string`
@@ -158523,7 +158485,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 在响应中返回时,这是该响应的有效执行模式。
- `"standard"`
@@ -158531,11 +158493,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `summary: optional "auto" or "concise" or "detailed" or null`
- 模型执行的推理摘要。这可用于调试和理解模型的推理过程。取值之一
- 可用于调试和理解模型的推理过程。
- 取值为 `auto`, `concise`, or `detailed`.
+ 模型执行的推理摘要。这可用于
+ 调试以及了解模型的推理过程。
+ 取值为 `auto`, `concise`,或 `detailed`.
- `concise` 支持以下模型 `computer-use-preview` 以及之后的所有推理模型 `gpt-5`.
+ `concise` 支持用于 `computer-use-preview` 模型以及之后的 `gpt-5`.
- `"auto"`
@@ -158545,8 +158507,8 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `text: optional object { format, verbosity } or null`
- 用于配置模型文本响应的选项。可以是纯文本,也可以是结构化的 JSON 数据。详见:
- 文本输入与输出:
+ 模型文本响应的配置选项。可以是纯
+ 文本或结构化 JSON 数据。了解更多:
- [文本输入与输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
@@ -158555,79 +158517,79 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
用于指定模型必须输出的格式的对象。
- 设置为 `{ "type": "json_schema" }` 时,将启用结构化输出,
- 功能,从而确保模型的输出与你提供的 JSON schema 相匹配。详见
+ 配置 `{ "type": "json_schema" }` 可启用结构化输出,
+ 从而确保模型匹配你提供的 JSON schema。更多信息请参阅
[结构化输出指南](/docs/guides/structured-outputs).
- 默认的格式为 `{ "type": "text" }` ,且不包含其他选项。
+ 默认格式为 `{ "type": "text" }` ,不包含任何额外选项。
- **不建议在 gpt-4o 及更新模型上使用:**
+ **不推荐用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
- 的模型,建议优先使用该格式。
+ 设置为 `{ "type": "json_object" }` 会启用旧版 JSON 模式,该模式
+ 可确保模型生成的消息是合法 JSON。对于支持 `json_schema`
+ 的模型,建议优先使用它。
- `ResponseFormatText object { type }`
- 默认的响应格式。用于生成文本响应。
+ 默认响应格式。用于生成文本响应。
- `type: "text"`
- 正在定义的响应格式的类型。始终为 `text`.
+ 正在定义的响应格式类型。始终为 `text`.
- `"text"`
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化的 JSON 响应。
+ JSON Schema 响应格式。用于生成结构化 JSON 响应。
详细了解 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
- 下划线和连字符,最大长度为 64。
+ 下划线和短横线,最大长度为 64。
- `schema: map[unknown]`
- 响应格式的 schema,以 JSON Schema 对象描述。
- 了解如何构建 JSON schema [此处](https://json-schema.org/).
+ 响应格式的架构,以 JSON Schema 对象形式描述。
+ 了解如何构建 JSON 架构 [此处](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式的类型。始终为 `json_schema`.
+ 正在定义的响应格式类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
响应格式用途的描述,供模型用于
- 确定如何按该格式进行响应。
+ 确定如何按该格式响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 一致性。
- 如果设置为 true,模型将始终遵循
- 字段中 `schema` 定义的精确 schema。仅支持 JSON Schema 的一个子集,当
- `strict` 是 `true`。要了解更多信息,请阅读 [Structured Outputs
+ 生成输出时是否启用严格的架构遵循。
+ 如果设置为 true,模型将始终遵循 字段中定义的
+ 确切架构。当 设置为 `schema` true 时,仅支持 JSON Schema 的一个子集
+ `strict` 是 `true`。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较早的生成 JSON 响应的方法。
- 使用 `json_schema` 对支持它的模型是推荐的做法。请注意
- 模型在没有系统或用户消息指示的情况下不会生成
- JSON。
+ JSON 对象响应格式。一种较旧的 JSON 响应生成方法。建议。
+ 对于支持 的模型,使用 `json_schema` 。请注意,模型不会在没有系统或用户消息指示
+ 的情况下生成 JSON
+ 。
- `type: "json_object"`
- 正在定义的响应格式的类型。始终为 `json_object`.
+ 正在定义的响应格式类型。始终为 `json_object`.
- `"json_object"`
- `verbosity: optional "low" or "medium" or "high" or null`
- 约束模型响应的详细程度。较低的值会产生
- 更简洁的响应,较高的值会产生更详细的响应。
+ 约束模型响应的详尽程度。较低的值将导致
+ 更简洁的响应,而较高的值将导致更冗长的响应。
当前支持的值包括 `low`, `medium`,和 `high`。默认值为
`medium`.
@@ -158639,13 +158601,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `tool_choice: optional ToolChoiceOptions or ToolChoiceAllowed or ToolChoiceTypes or 6 more or null`
- 控制模型应使用的工具(若有)。
+ 控制模型应使用的工具(如果有)。
- `ToolChoiceOptions = "none" or "auto" or "required"`
- 控制模型调用哪个工具(如果有的话)。
+ 控制模型调用哪个工具(如果有)。
- `none` 表示模型不会调用任何工具,而是生成一条消息。
+ `none` 表示模型将不会调用任何工具,而是生成一条消息。
`auto` 表示模型可以在生成消息或调用一个或
多个工具之间进行选择。
@@ -158677,7 +158639,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `tools: array of map[unknown]`
- 模型应允许调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -158698,11 +158660,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ToolChoiceTypes object { type }`
指示模型应使用内置工具来生成响应。
- [了解有关内置工具的更多信息](/docs/guides/tools).
+ [了解更多关于内置工具的信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
- 模型应使用的托管工具类型。了解更多关于
+ 模型应使用的 托管工具 类型。了解更多关于
[内置工具](/docs/guides/tools).
允许的值为:
@@ -158747,7 +158709,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ToolChoiceMcp object { server_label, type, name }`
- 使用此选项可以强制模型调用远程 MCP 服务器上的特定工具。
+ 使用此选项可强制模型调用远程 MCP 服务器上的特定工具。
- `server_label: string`
@@ -158765,7 +158727,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ToolChoiceCustom object { name, type }`
- 使用此选项可以强制模型调用特定的自定义工具。
+ 使用此选项可强制模型调用特定的自定义工具。
- `name: string`
@@ -158781,33 +158743,33 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "programmatic_tool_calling"`
- 要调用的工具。始终为 `programmatic_tool_calling`.
+ 要调用的工具。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ToolChoiceApplyPatch object { type }`
- 在执行工具调用时强制模型调用 apply_patch 工具。
+ 强制模型在执行工具调用时调用 apply_patch 工具。
- `type: "apply_patch"`
- 要调用的工具。始终为 `apply_patch`.
+ 要调用的工具。始终 `apply_patch`.
- `"apply_patch"`
- `ToolChoiceShell object { type }`
- 在需要工具调用时强制模型调用 shell 工具。
+ 在需要工具调用时,强制模型调用 shell 工具。
- `type: "shell"`
- 要调用的工具。始终为 `shell`.
+ 要调用的工具。始终 `shell`.
- `"shell"`
- `tools: optional array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more or null`
- 模型在生成响应时可以调用的工具数组。你可以通过设置以下项来指定要使用的工具: `tool_choice` 参数来指定要使用的工具。
+ 模型在生成响应时可以调用的工具数组。你可以通过设置 `tool_choice` 参数来指定要使用的工具。
- `Function object { name, parameters, strict, 5 more }`
@@ -158841,45 +158803,45 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过工具搜索加载。
+ 此函数是否被延迟并通过 tool search 加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 函数的描述。由模型用来判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数以字符串形式输出时所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。了解更多关于 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库的 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将某个指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
+ 用于将指定属性键与给定值使用定义的比较运算进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用以下方式组合多个过滤器 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数值应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应在 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -158887,7 +158849,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于调节倒数排名融合中语义嵌入匹配与稀疏关键词匹配权重的权重值。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -158899,7 +158861,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `ranker: optional "auto" or "default-2024-11-15"`
- 用于 文件搜索 的排序器。
+ 用于文件搜索的排序器。
- `"auto"`
@@ -158907,21 +158869,21 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `score_threshold: optional number`
- 文件搜索 的分数阈值,介于 0 到 1 之间。越接近 1 的数值越倾向于只返回最相关的结果,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数值会尝试仅返回最相关的结果,但可能会返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer tool 的类型。始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -158947,18 +158909,18 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "computer_use_preview"`
- 计算机使用工具的类型,始终为 `computer_use_preview`.
+ 计算机使用工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。详细了解
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型,取值之一为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型,为以下之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -158966,22 +158928,22 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。若省略,默认值为 true。当值为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,将不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤器。
- `allowed_domains: optional array of string or null`
- 搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -158991,23 +158953,23 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的近似位置。
+ 用户的大致位置。
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
@@ -159018,11 +158980,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP)服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器让模型访问更多工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 该 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -159040,21 +159002,21 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 允许的工具名称组成的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -159062,14 +159024,14 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合
- 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
- 必须处理 OAuth 授权流程并在此提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP 服务器 URL
+ 或服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并将令牌提供在此处。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供以下之一
- `server_url`, `connector_id`, or `tunnel_id` 中的某一项。了解更多
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些标识符。其中一个
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -159101,32 +159063,32 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `defer_loading: optional boolean`
- 该 MCP 工具是否被延迟,并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务端的可选 HTTP 头。用于身份验证
+ 发送到 MCP server 的可选 HTTP 头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务端的哪些工具需要审批。
+ 指定 MCP server 的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务端的哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的过滤对象
- 用于需要审批的工具。
+ 指定 MCP server 的哪些工具需要审批。可以是
+ `always`, `never`,或与工具关联的筛选对象
+ ,这些工具需要审批。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -159134,13 +159096,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 标注,它就会匹配此过滤条件。
- `tool_names: optional array of string`
@@ -159148,9 +159110,9 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值为 `always` 或
- `never`. 当设置为 `always`,所有工具都需要审批。当设置为
- 设置为 `never`,所有工具都不需要审批。
+ 为所有工具指定单个审批策略。可选值为 `always` 或
+ `never`. 当设置为 `always`,时,所有工具都需要审批。当设置为
+ 时, `never`,所有工具都不需要审批。
- `"always"`
@@ -159162,22 +159124,22 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`, or
- `tunnel_id` 中的一个。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 其中之一必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供
- `server_url`, `connector_id`, or `tunnel_id` 中的一个。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词回应的工具。
+ 运行 Python 代码以帮助生成针对提示的响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
代码解释器容器。可以是容器 ID,也可以是指定
- 可供你的代码使用的已上传文件 ID 以及一个
+ 可供代码使用的已上传文件 ID 以及一个
可选的 `memory_limit` 设置的对象。
- `string`
@@ -159186,7 +159148,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定用于运行代码的文件 ID。
- `type: "auto"`
@@ -159196,7 +159158,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -159252,7 +159214,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图像还是编辑已有图像。默认值: `auto`.
- `"generate"`
@@ -159262,11 +159224,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。为 `transparent`,
- `opaque`, or `auto`。之一。透明背景适用于
- 支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持目前处于预览阶段。当使用
- `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图像的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
+ `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -159276,7 +159238,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`. Defaults to `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -159284,7 +159246,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复的可选遮罩。包含 `image_url`
+ 用于修复(inpainting)的可选遮罩。包含 `image_url`
(string,可选)和 `file_id` (string,可选)。
- `file_id: optional string`
@@ -159293,13 +159255,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `image_url: optional string`
- 经过 Base64 编码的遮罩图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `string`
@@ -159308,7 +159270,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
要使用的图像生成模型。可选值为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
- `gpt-image-2-2026-04-21`, or `chatgpt-image-latest`。默认值:
+ `gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
- `"gpt-image-1"`
@@ -159335,7 +159297,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`, or
+ 生成图像的输出格式。可选值为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -159346,7 +159308,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
+ 在流式模式下生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -159363,13 +159325,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` is supported for models that allow automatic sizing. For `dall-e-2`, use one of `256x256`, `512x512`, or `1024x1024`. For `dall-e-3`, use one of `1024x1024`, `1792x1024`, or `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -159385,7 +159347,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "local_shell"`
- 本地 shell 工具的类型。始终为 `local_shell`.
+ 本地 shell 工具的类型,始终为 `local_shell`.
- `"local_shell"`
@@ -159395,7 +159357,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `type: "shell"`
- shell 工具的类型。始终为 `shell`.
+ shell 工具的类型,始终为 `shell`.
- `"shell"`
@@ -159421,11 +159383,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -159451,19 +159413,19 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入同一共享命名空间下。
- `description: string`
- 向模型展示的命名空间描述。
+ 展示给模型的命名空间描述。
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 工具调用中使用的命名空间名称(例如 `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的函数/自定义工具。
+ 该命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -159483,19 +159445,19 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 此函数是否应延迟加载并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 一个 JSON Schema,用于描述此函数工具的字符串输出中编码的 JSON 值。这不描述 content-array 类型的输出。
+ 用于描述该函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -159503,11 +159465,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `name: string`
- 自定义工具的名称,用于在工具调用中标识它。
+ 自定义工具的名称,用于在工具调用中标识该工具。
- `type: "custom"`
- 自定义工具的类型,始终为 `custom`.
+ 自定义工具的类型。通常为 `custom`.
- `"custom"`
@@ -159553,7 +159515,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -159565,11 +159527,11 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具在网页上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会在网页中搜索可用于回复的相关结果。了解更多关于 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型,取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型,为以下之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -159583,7 +159545,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级指导量。取值之一: `low`, `medium`, or `high`. `medium` 为默认值。
+ 搜索所使用的上下文窗口空间的高层级指导。为以下之一 `low`, `medium`,或 `high`. `medium` 是默认值。
- `"low"`
@@ -159593,7 +159555,7 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户的位置。
+ 用户所在的位置。
- `type: "approximate"`
@@ -159603,23 +159565,23 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如: `San Francisco`.
+ 用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如: `US`.
+ 由两个字母组成的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 例如。 `US`.
- `region: optional string or null`
- 用户所在地区的自由文本输入,例如: `California`.
+ 用户所在地区的自由文本输入,例如 `California`.
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如: `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用统一差异格式创建、删除或更新文件。
+ 允许助手使用 unified diff 创建、删除或更新文件。
- `type: "apply_patch"`
@@ -159637,13 +159599,13 @@ curl https://api.openai.com/v1/responses/resp_abc123/input_items \
- `truncation: optional "auto" or "disabled"`
- 用于模型响应的截断策略。- `auto`: 如果此响应的输入超出模型的上下文窗口大小,模型将通过丢弃对话开头的条目来截断响应,以适配上下文窗口。- `disabled` (默认):如果输入大小将超出模型的上下文窗口大小,请求将失败并返回 400 错误。
+ 用于模型响应的截断策略。- `auto`:如果此响应的输入超出模型的上下文窗口大小,模型将通过从对话开头丢弃条目来截断响应,以适应上下文窗口。- `disabled` (默认):如果输入大小将超出模型的上下文窗口大小,请求将失败并返回 400 错误。
- `"auto"`
- `"disabled"`
-### 返回
+### 返回值
- `input_tokens: number`
@@ -159659,7 +159621,7 @@ curl https://api.openai.com/v1/responses/input_tokens \
-H "Authorization: Bearer $OPENAI_API_KEY"
```
-#### 响应
+#### Response
```json
{
@@ -159680,7 +159642,7 @@ curl -X POST https://api.openai.com/v1/responses/input_tokens \
}'
```
-#### 响应
+#### Response
```json
{
@@ -159691,7 +159653,7 @@ curl -X POST https://api.openai.com/v1/responses/input_tokens \
## Domain Types
-### Input Token Count Response
+### 输入 Token 计数响应
- `InputTokenCountResponse object { input_tokens, object }`
diff --git a/docs/zh/api/reference/resources/responses/methods/cancel.md b/docs/zh/api/reference/resources/responses/methods/cancel.md
index 8b25e4c..1365ad1 100644
--- a/docs/zh/api/reference/resources/responses/methods/cancel.md
+++ b/docs/zh/api/reference/resources/responses/methods/cancel.md
@@ -1,18 +1,18 @@
-> 如需完整文档索引,请参阅 [llms.txt](/llms.txt)。可通过在页面 URL 末尾附加 `.md` 来获取文档页面的 Markdown 版本。
+> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。可通过在页面 URL 末尾添加 `.md` 来获取文档页面的 Markdown 版本。
## 取消响应
**post** `/responses/{response_id}/cancel`
-取消具有给定 ID 的模型响应。只能取消使用
-该 `background` 参数设置为 `true` 创建的响应。
-[了解详情](/docs/guides/background).
+取消具有指定 ID 的模型响应。仅当使用
+该 `background` 参数设置为 `true` 创建的响应才能被取消。
+[了解更多](/docs/guides/background).
### 路径参数
- `response_id: string`
-### 返回
+### 返回值
- `Response object { id, created_at, error, 32 more }`
@@ -26,7 +26,7 @@
- `error: ResponseError or null`
- 当模型未能生成 Response 时返回的错误对象。
+ 当模型生成 Response 失败时返回的错误对象。
- `code: "server_error" or "rate_limit_exceeded" or "invalid_prompt" or 17 more`
@@ -78,41 +78,43 @@
- `incomplete_details: object { reason } or null`
- 关于响应不完整的详细信息。
+ 关于响应为何未完成的详细信息。
- - `reason: optional "max_output_tokens" or "content_filter"`
+ - `reason: optional "max_output_tokens" or "max_messages" or "content_filter"`
- 响应不完整的原因。
+ 响应未完成的原因。
- `"max_output_tokens"`
+ - `"max_messages"`
+
- `"content_filter"`
- `instructions: string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more or null`
插入到模型上下文中的系统(或开发者)消息。
- 当与 previous_response_id 一起使用时, `previous_response_id`,上一个 response 中的指令将不会延续到下一个 response。这使得在新的 response 中替换系统(或开发者)消息变得简单。
- 上一个 response 中的指令将不会延续到下一个 response。这使得在新的 response 中替换系统(或开发者)消息变得简单。
- 上一个 response 中的指令将不会延续到下一个 response。这使得在新的 response 中替换系统(或开发者)消息变得简单。
+ 当与 `previous_response_id`,一起使用时,上一个
+ 响应中的指令不会延续到下一个响应。这样可以方便地在新响应中替换系统(或开发者)消息。
+ to swap out system (or developer) messages in new responses.
- `string`
- 模型的文本输入,等同于 role 为 "user" 的文本输入。
- `developer` role 为 "user" 的文本输入。
+ 模型的文本输入,等同于带有
+ `developer` role 的文本输入。
- `InputItemList = array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 一个由一个或多个输入项组成的列表,传递给模型,包含不同内容类型。
- 包含不同内容类型的输入项。
+ 包含不同内容类型的一个或多个输入项的列表,传递给模型。
+ 不同内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 具有角色(指示指令遵循层级)的模型消息输入。使用 "system" 或 "developer" 角色给出的指令优先级高于 "user" 消息,但低于 "assistant" 消息。
- 使用 "system" 或 "developer" 角色给出的指令优先级高于 "user" 消息。 `developer` 或 `system` role 优先级高于
- 优先级高于通过 `user` 角色给出的指令。带有
- `assistant` 角色的消息被假定为在先前
- 交互中由模型生成。
+ 带有角色(表示指令遵循层级)的模型消息输入。使用
+ 层级。使用 `developer` 或 `system` role 提供的
+ 优先于通过 `user` 角色给出的指令。带有
+ `assistant` 角色的消息被视为模型在之前的
+ 交互中生成。
- `content: string or ResponseInputMessageContentList`
@@ -144,7 +146,7 @@
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用提示前缀的精确断点。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会四舍五入到 token 块。
- `mode: "explicit"`
@@ -154,11 +156,11 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
+ 发送到模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- 发送给模型的图像的详细级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
+ 发送到模型的图像详细程度。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -176,15 +178,15 @@
- `file_id: optional string or null`
- 要发送给模型的文件。
+ 发送到模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完整 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片链接。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用提示前缀的精确断点。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会四舍五入到 token 块。
- `mode: "explicit"`
@@ -194,7 +196,7 @@
- `ResponseInputFile object { type, detail, file_data, 4 more }`
- 发送给模型的文件输入。
+ 传递给模型的文件输入。
- `type: "input_file"`
@@ -204,7 +206,7 @@
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会增加输入 token 使用量。使用 `low` 可降低渲染成本,或 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 `auto` 可让系统选择细节等级;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会提高输入 token 用量。使用 `low` 可降低渲染成本,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
- `"auto"`
@@ -214,23 +216,23 @@
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- 要发送给模型的文件。
+ 发送到模型的文件的 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用提示前缀的精确断点。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会四舍五入到 token 块。
- `mode: "explicit"`
@@ -240,7 +242,7 @@
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色,可选值为 `user`, `assistant`, `system`,或
+ 消息输入的角色。可选值之一 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -253,9 +255,9 @@
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终回答(`final_answer`).
- 对于类似 `gpt-5.3-codex` 及更高的模型,在发送后续请求时,请保留并重新发送
- 阶段于所有助手消息上——丢弃它可能会降低性能。不用于用户消息。
+ 将 `assistant` 消息标记为中间评论(`commentary`)或最终答案(`final_answer`).
+ 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,保留并重新发送
+ 阶段的所有助手消息——遗漏该字段可能导致性能下降。不用于用户消息。
- `"commentary"`
@@ -263,15 +265,15 @@
- `type: optional "message"`
- 消息输入的类型,始终为 `message`.
+ 消息输入的类型。始终为 `message`.
- `"message"`
- `Message object { content, role, status, type }`
- 具有角色(指示指令遵循层级)的模型消息输入。使用 "system" 或 "developer" 角色给出的指令优先级高于 "user" 消息,但低于 "assistant" 消息。
- 使用 "system" 或 "developer" 角色给出的指令优先级高于 "user" 消息。 `developer` 或 `system` role 优先级高于
- 优先级高于通过 `user` role 为 "user" 的文本输入。
+ 带有角色(表示指令遵循层级)的模型消息输入。使用
+ 层级。使用 `developer` 或 `system` role 提供的
+ 优先于通过 `user` role 的文本输入。
- `content: ResponseInputMessageContentList`
@@ -280,7 +282,7 @@
- `role: "user" or "system" or "developer"`
- 消息输入的角色,可选值为 `user`, `system`,或 `developer`.
+ 消息输入的角色。可选值之一 `user`, `system`,或 `developer`.
- `"user"`
@@ -290,7 +292,7 @@
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态,可选值为 `in_progress`, `completed`,或
+ 条目的状态。可选值之一 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -311,31 +313,31 @@
- `id: string`
- 输出消息的唯一 ID。
+ 该输出消息的唯一 ID。
- `content: array of ResponseOutputText or ResponseOutputRefusal`
- 输出消息的内容。
+ 该输出消息的内容。
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 来自模型的一段文本输出。
+ 模型输出的文本。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 文本输出的注解。
+ 该文本输出的注解。
- `FileCitation object { file_id, filename, index, type }`
- 对一个文件的引用。
+ 对文件的引用。
- `file_id: string`
- 文件的 ID。
+ 该文件的 ID。
- `filename: string`
- 被引用文件的文件名。
+ 所引用文件的文件名。
- `index: number`
@@ -349,19 +351,19 @@
- `URLCitation object { end_index, start_index, title, 2 more }`
- 用于生成模型响应的网页资源引用。
+ 用于生成模型响应的网页资源的引用。
- `end_index: number`
- 消息中 URL 引用末尾字符的索引。
+ 消息中该 URL 引用最后一个字符的索引。
- `start_index: number`
- 消息中 URL 引用起始字符的索引。
+ 消息中该 URL 引用第一个字符的索引。
- `title: string`
- 网页资源的标题。
+ 该网页资源的标题。
- `type: "url_citation"`
@@ -371,31 +373,31 @@
- `url: string`
- 网页资源的 URL。
+ 该网页资源的 URL。
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
- 用于生成模型响应的容器文件引用。
+ 用于生成模型响应的容器文件的引用。
- `container_id: string`
- 容器文件的 ID。
+ 该容器文件的 ID。
- `end_index: number`
- 消息中容器文件引用末尾字符的索引。
+ 消息中该容器文件引用最后一个字符的索引。
- `file_id: string`
- 文件的 ID。
+ 该文件的 ID。
- `filename: string`
- 所引用容器文件的文件名。
+ 所引用的容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用起始字符的索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -409,7 +411,7 @@
- `file_id: string`
- 文件的 ID。
+ 该文件的 ID。
- `index: number`
@@ -449,15 +451,15 @@
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝。
+ 模型的拒绝内容。
- `refusal: string`
- 模型的拒绝解释。
+ 模型给出的拒绝原因说明。
- `type: "refusal"`
- 拒绝的类型。始终为 `refusal`.
+ 拒绝内容的类型。始终为 `refusal`.
- `"refusal"`
@@ -469,7 +471,7 @@
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`,或
+ 消息输入的状态。可选值为 `in_progress`, `completed`,或
`incomplete`。之一。当输入项通过 API 返回时填充。
- `"in_progress"`
@@ -486,9 +488,9 @@
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间注释(`commentary`)或最终回答(`final_answer`).
- 对于类似 `gpt-5.3-codex` 及更高的模型,在发送后续请求时,请保留并重新发送
- 阶段于所有助手消息上——丢弃它可能会降低性能。不用于用户消息。
+ 将 `assistant` 消息标记为中间评论(`commentary`)或最终答案(`final_answer`).
+ 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,保留并重新发送
+ 阶段的所有助手消息——遗漏该字段可能导致性能下降。不用于用户消息。
- `"commentary"`
@@ -505,11 +507,11 @@
- `queries: array of string`
- 用于搜索文件的查询。
+ 用于搜索文件的查询语句。
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。可选值为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -524,7 +526,7 @@
- `type: "file_search_call"`
- 文件搜索 工具调用的类型。始终为 `file_search_call`.
+ 文件搜索 工具调用的类型。始终 `file_search_call`.
- `"file_search_call"`
@@ -534,11 +536,11 @@
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 个键值对集合。可用于
- 以结构化格式存储关于对象的附加信息,并通过 API 或仪表板查询对象。键为字符串
- 格式,以及通过 接口 或仪表板查询对象。键为字符串
- 最大长度为 64 个字符。值是字符串、
- 长度为 512 个字符以内的字符串、布尔值或数字。
+ 可附加到对象的 16 组键值对。这可用于
+ 以结构化格式存储有关对象的附加信息,并
+ 通过 API 或控制台查询对象。键为字符串,长度上限
+ 为 64 个字符。值为字符串,长度上限为 512
+ 个字符、布尔值或数字。
- `string`
@@ -556,7 +558,7 @@
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性评分,介于 0 到 1 之间。
- `text: optional string`
@@ -564,12 +566,12 @@
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
- 对计算机使用工具的工具调用。参见
+ 对计算机使用工具的工具调用。请参阅
[computer use guide](/docs/guides/tools-computer-use) 了解更多信息。
- `id: string`
- 该计算机调用的唯一 ID。
+ 计算机调用的唯一 ID。
- `call_id: string`
@@ -577,7 +579,7 @@
- `pending_safety_checks: array of object { id, code, message }`
- 该计算机调用的待处理安全检查。
+ 针对计算机调用的待处理安全检查。
- `id: string`
@@ -593,7 +595,7 @@
- `status: "in_progress" or "completed" or "incomplete"`
- 该条目的状态。值为 `in_progress`, `completed`,或
+ 项目的状态。取值之一为 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -604,7 +606,7 @@
- `type: "computer_call"`
- 电脑调用的类型。始终为 `computer_call`.
+ 计算机调用的类型。始终为 `computer_call`.
- `"computer_call"`
@@ -618,7 +620,7 @@
- `button: "left" or "right" or "wheel" or 2 more`
- 表示点击时按下的鼠标按键。取值为 `left`, `right`, `wheel`, `back`,或 `forward`.
+ 表示点击时按下的是哪个鼠标按钮。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -632,17 +634,17 @@
- `type: "click"`
- 指定事件类型。对于点击动作,此属性始终为 `click`.
+ 指定事件类型。对于点击动作,该属性始终为 `click`.
- `"click"`
- `x: number`
- 点击发生位置的 x 坐标。
+ 发生点击的 x 坐标。
- `y: number`
- 点击发生位置的 y 坐标。
+ 发生点击的 y 坐标。
- `keys: optional array of string or null`
@@ -658,17 +660,17 @@
- `type: "double_click"`
- 指定事件类型。对于双击动作,此属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
- `"double_click"`
- `x: number`
- 双击发生位置的 x 坐标。
+ 发生双击的 x 坐标。
- `y: number`
- 双击发生位置的 y 坐标。
+ 发生双击的 y 坐标。
- `Drag object { path, type, keys }`
@@ -676,7 +678,7 @@
- `path: array of object { x, y }`
- 表示拖动动作路径的坐标数组。坐标以对象数组形式呈现,例如
+ 表示拖动动作路径的坐标数组。坐标将以对象数组的形式出现,例如
```
[
@@ -695,7 +697,7 @@
- `type: "drag"`
- 指定事件类型。对于拖动动作,此属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
- `"drag"`
@@ -705,11 +707,11 @@
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的按键集合。
- `keys: array of string`
- 模型请求按下的按键组合。它是一个字符串数组,每个字符串代表一个键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
- `type: "keypress"`
@@ -769,11 +771,11 @@
- `x: number`
- 发生滚动处的 x 坐标。
+ 滚动发生位置的 x 坐标。
- `y: number`
- 发生滚动处的 y 坐标。
+ 滚动发生位置的 y 坐标。
- `keys: optional array of string or null`
@@ -781,7 +783,7 @@
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -805,8 +807,8 @@
- `actions: optional ComputerActionList`
- 扁平化批处理操作,用于 `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 批量操作展平后的结果用于 `computer_use`。每个操作包含一个
+ `type` 判别字段及操作特有的字段。
- `Click object { button, type, x, 2 more }`
@@ -822,7 +824,7 @@
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的按键集合。
- `Move object { type, x, y, keys }`
@@ -838,7 +840,7 @@
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -854,11 +856,11 @@
- `output: ResponseComputerToolCallOutputScreenshot`
- 与计算机使用工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图图像。
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,此属性
+ 指定事件类型。对于计算机截图,该属性
始终设置为 `computer_screenshot`.
- `"computer_screenshot"`
@@ -883,7 +885,7 @@
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 已被开发者确认的 API 报告的安全检查。
+ 由开发者确认的 API 上报的安全检查。
- `id: string`
@@ -899,7 +901,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值为 `in_progress`, `completed`,或 `incomplete`。之一。当输入项通过 API 返回时填充。
+ 消息输入的状态。可选值为 `in_progress`, `completed`,或 `incomplete`。之一。当输入项通过 API 返回时填充。
- `"in_progress"`
@@ -909,21 +911,21 @@
- `WebSearchCall object { id, action, status, type }`
- 网页搜索工具调用的结果。请参阅
- [网页搜索指南](/docs/guides/tools-web-search) 了解更多信息。
+ 网页搜索 工具调用的结果。请参阅
+ [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
- `id: string`
- 网页搜索工具调用的唯一 ID。
+ 网页搜索 工具调用的唯一 ID。
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述本次 网页搜索调用中所执行具体操作的对象。
- 包含模型使用网页的详细信息(search、open_page、find_in_page)。
+ 描述本次 网页搜索 调用中所执行的具体操作的对象。
+ 包含模型使用网页方式的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" - 执行一次 网页搜索查询。
+ 操作类型 "search" - 执行 网页搜索 查询。
- `type: "search"`
@@ -933,7 +935,7 @@
- `queries: optional array of string`
- 搜索查询。
+ 搜索查询列表。
- `query: optional string`
@@ -955,7 +957,7 @@
- `OpenPage object { type, url }`
- 操作类型 "open_page" - 打开搜索结果中的特定 URL。
+ 动作类型 "open_page" - 从搜索结果中打开特定 URL。
- `type: "open_page"`
@@ -969,11 +971,11 @@
- `FindInPage object { pattern, type, url }`
- 操作类型 "find_in_page":在已加载页面中搜索某个模式。
+ 动作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
- 在页面内搜索的模式或文本。
+ 要在页面内搜索的模式或文本。
- `type: "find_in_page"`
@@ -983,7 +985,7 @@
- `url: string`
- 搜索该模式的页面 URL。
+ 在其中搜索该模式的页面的 URL。
- `status: "in_progress" or "searching" or "completed" or "failed"`
@@ -1005,7 +1007,7 @@
- `FunctionCall object { arguments, call_id, name, 5 more }`
- 用于运行函数的工具调用。请参阅
+ 运行函数的工具调用。参见
[函数调用指南](/docs/guides/function-calling) 了解更多信息。
- `arguments: string`
@@ -1056,7 +1058,7 @@
- `status: optional "in_progress" or "completed" or "incomplete"`
- 该条目的状态。值为 `in_progress`, `completed`,或
+ 项目的状态。取值之一为 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -1097,7 +1099,7 @@
- `prompt_cache_breakpoint: optional object { mode } or null`
- 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用提示前缀的精确断点。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会四舍五入到 token 块。
- `mode: "explicit"`
@@ -1107,7 +1109,7 @@
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
+ 发送到模型的图像输入。了解有关 [图像输入](/docs/guides/vision)
- `type: "input_image"`
@@ -1117,19 +1119,19 @@
- `detail: optional ImageDetail or null`
- 发送给模型的图像的详细级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
+ 发送到模型的图像详细程度。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: optional string or null`
- 要发送给模型的文件。
+ 发送到模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完整 URL,也可以是 data URL 中 base64 编码的图片。
+ 要发送给模型的图片链接。可以是完全限定的 URL,也可以是 data URL 中 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode } or null`
- 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用提示前缀的精确断点。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会四舍五入到 token 块。
- `mode: "explicit"`
@@ -1139,7 +1141,7 @@
- `ResponseInputFileContent object { type, detail, file_data, 4 more }`
- 发送给模型的文件输入。
+ 传递给模型的文件输入。
- `type: "input_file"`
@@ -1149,7 +1151,7 @@
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会增加输入 token 使用量。使用 `low` 可降低渲染成本,或 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节等级。使用 `auto` 可让系统选择细节等级;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会提高输入 token 用量。使用 `low` 可降低渲染成本,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
- `"auto"`
@@ -1159,23 +1161,23 @@
- `file_data: optional string or null`
- 要发送给模型的文件的 base64 编码数据。
+ 发送到模型的文件的 base64 编码数据。
- `file_id: optional string or null`
- 要发送给模型的文件。
+ 发送到模型的文件的 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用提示前缀的精确断点。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会四舍五入到 token 块。
- `mode: "explicit"`
@@ -1223,15 +1225,15 @@
- `name: optional string or null`
- 生成该输出的工具的名称。
+ 生成输出的工具的名称。
- `namespace: optional string or null`
- 生成该输出的工具的命名空间。
+ 生成输出的工具的命名空间。
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 该条目的状态。值为 `in_progress`, `completed`,或 `incomplete`。当通过 API 返回条目时填充。
+ 项目的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -1261,7 +1263,7 @@
- `execution: optional "server" or "client"`
- 工具搜索是由服务端执行还是由客户端执行。
+ 工具搜索是由服务端还是由客户端执行的。
- `"server"`
@@ -1285,7 +1287,7 @@
- `Function object { name, parameters, strict, 5 more }`
- 在你自己的代码中定义一个可供模型选择的函数。了解更多关于 [function calling](https://platform.openai.com/docs/guides/function-calling).
+ 在你自己的代码中定义一个模型可以选择调用的函数。了解更多信息 [函数调用](https://platform.openai.com/docs/guides/function-calling).
- `name: string`
@@ -1301,7 +1303,7 @@
- `type: "function"`
- 函数工具的类型,恒为 `function`.
+ 函数工具的类型,始终为 `function`.
- `"function"`
@@ -1315,7 +1317,7 @@
- `defer_loading: optional boolean`
- 该函数是否被延迟加载,并通过工具搜索加载。
+ 此函数是否延迟加载并通过工具搜索载入。
- `description: optional string or null`
@@ -1323,29 +1325,29 @@
- `output_schema: optional map[unknown] or null`
- 描述该函数在字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 用于描述该函数的字符串输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容的工具。详细了解 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 用于从已上传文件中搜索相关内容的一款工具。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索 工具的类型,恒为 `file_search`.
+ 文件搜索工具的类型,始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将指定属性键与给定值按定义比较运算进行比较的筛选条件。
+ 用于通过已定义的比较运算将指定属性键与给定值进行比较的筛选器。
- `key: string`
@@ -1355,14 +1357,14 @@
指定比较运算符: `eq`, `ne`, `gt`, `gte`, `lt`, `lte`, `in`, `nin`.
- - `eq`:等于
- - `ne`:不等于
- - `gt`:大于
- - `gte`:大于等于
- - `lt`:小于
- - `lte`:小于等于
- - `in`:包含于
- - `nin`:不包含于
+ - `eq`: equals
+ - `ne`: not equal
+ - `gt`: greater than
+ - `gte`: 大于等于
+ - `lt`: 小于
+ - `lte`: 小于等于
+ - `in`: 包含于
+ - `nin`: 不包含于
- `"eq"`
@@ -1382,7 +1384,7 @@
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值,支持字符串、数字或布尔类型。
+ 与属性键进行比较的值;支持字符串、数字或布尔类型。
- `string`
@@ -1398,7 +1400,7 @@
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
@@ -1406,7 +1408,7 @@
- `ComparisonFilter object { key, type, value }`
- 用于将指定属性键与给定值按定义比较运算进行比较的筛选条件。
+ 用于通过已定义的比较运算将指定属性键与给定值进行比较的筛选器。
- `unknown`
@@ -1420,7 +1422,7 @@
- `max_num_results: optional number`
- 返回结果的最大数量。该数量应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -1428,15 +1430,15 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 用于在启用混合搜索时,控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
+ 在启用混合搜索时,用于控制互逆排名融合中语义嵌入匹配与稀疏关键词匹配平衡的权重。
- `embedding_weight: number`
- 嵌入在倒数排名融合中的权重。
+ 互逆排名融合中嵌入的权重。
- `text_weight: number`
- 文本在倒数排名融合中的权重。
+ 互逆排名融合中文本的权重。
- `ranker: optional "auto" or "default-2024-11-15"`
@@ -1448,21 +1450,21 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,介于 0 到 1 之间。越接近 1,尝试返回的结果越相关,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间。越接近 1 的数值会尝试仅返回最相关的结果,但可能返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer 工具的类型,始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -1494,12 +1496,12 @@
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 通过互联网搜索与提示相关的来源。了解更多关于
+ 搜索互联网以查找与提示词相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型。取值为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型。取值之一为 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -1507,7 +1509,7 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 进行实时联网访问。省略时默认为 true。当设为 false 时,网页搜索工具将以离线/仅缓存模式运行,并且不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
@@ -1515,14 +1517,14 @@
- `allowed_domains: optional array of string or null`
- 允许搜索的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索允许使用的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样被允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指导。取值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 搜索所用上下文窗口空间的高层级使用指导,取值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -1536,11 +1538,11 @@
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如 `San Francisco`.
+ 用于用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 用户的两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 表示用户所在国家/地区,例如。 `US`.
- `region: optional string or null`
@@ -1548,22 +1550,22 @@
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如。 `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 表示用户所在国家/地区,例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
- 位置近似值的类型。始终为 `approximate`.
+ 位置近似类型。始终为 `approximate`.
- `"approximate"`
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP) 服务器为模型提供对其他工具的访问。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中识别它。
+ 此 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -1585,32 +1587,32 @@
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 包含允许的工具名称的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的过滤对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此过滤器。
+ 指示工具是否会修改数据,还是属于只读。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 它就会匹配此过滤器。
- `tool_names: optional array of string`
- 允许的工具名称列表。
+ 允许使用的工具名称列表。
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP
- 服务器 URL 或服务连接器使用。你的应用
- 必须处理 OAuth 授权流程并在此处提供令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,可与自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
+ 程序必须自行处理 OAuth 授权流程,并在此处提供该令牌。
+ 必须自行处理 OAuth 授权流程,并在此处提供该令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的连接器。其中之一
- `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
+ 服务连接器的标识符,例如 ChatGPT 中提供的那些连接器。其中之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。了解更多
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -1642,54 +1644,54 @@
- `defer_loading: optional boolean`
- 此 MCP 工具是否被延迟,并通过工具搜索发现。
+ 该 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务器的可选 HTTP 标头。用于身份验证
+ 发送到 MCP 服务器的可选 HTTP 头。可用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务器的哪些工具需要审批。
+ 指定 MCP 服务器中哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务器的哪些工具需要审批。可以是
- `always`, `never`,或与需要审批的工具关联的过滤对象
- 。
+ 指定 MCP 服务器中哪些工具需要审批。可以是
+ `always`, `never`,也可以是与工具关联的过滤器对象
+ 用于指定需要审批的工具。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的过滤对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此过滤器。
+ 指示工具是否会修改数据,还是属于只读。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 它就会匹配此过滤器。
- `tool_names: optional array of string`
- 允许的工具名称列表。
+ 允许使用的工具名称列表。
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的过滤对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此过滤器。
+ 指示工具是否会修改数据,还是属于只读。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 它就会匹配此过滤器。
- `tool_names: optional array of string`
- 允许的工具名称列表。
+ 允许使用的工具名称列表。
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定单个审批策略。其一为 `always` 或
+ 为所有工具指定统一的审批策略。可选值为 `always` 或
`never`. 当设置为 `always`,时,所有工具都需要审批。当
设置为 `never`,时,所有工具都不需要审批。
@@ -1703,22 +1705,22 @@
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`,或
- `tunnel_id` 之一。
+ MCP 服务器的 URL。以下其中之一 `server_url`, `connector_id`,或
+ `tunnel_id` 必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的 Secure MCP Tunnel ID。必须提供
- `server_url`, `connector_id`,或 `tunnel_id` 之一。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。以下其中之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 用于运行 Python 代码以帮助生成对提示词回应的工具。
+ 一个运行 Python 代码以帮助生成对提示词回复的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID,也可以是指定可供你代码使用的已上传文件 ID 的对象,以及一个
- 用于指定可供你代码使用的已上传文件 ID 的对象,以及一个
+ 代码解释器容器。可以是容器 ID 或指定上传文件 ID 的对象,以便你的代码可访问这些文件,以及一个
+ 指定上传文件 ID 以便你的代码可访问,并附带一个
可选的 `memory_limit` 设置。
- `string`
@@ -1727,7 +1729,7 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要对其运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定要在其上运行代码的文件 ID。
- `type: "auto"`
@@ -1737,7 +1739,7 @@
- `file_ids: optional array of string`
- 可供你代码使用的已上传文件的可选列表。
+ 可供你的代码使用的上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -1759,7 +1761,7 @@
- `type: "disabled"`
- 禁用对外网络访问。始终 `disabled`.
+ 禁用出站网络访问。始终 `disabled`.
- `"disabled"`
@@ -1771,21 +1773,21 @@
- `type: "allowlist"`
- 仅允许向指定域名的出站网络访问。始终 `allowlist`.
+ 仅允许向指定域进行出站网络访问。始终 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 允许列表中域名对应的可选域级密钥。
+ 允许列表中域名对应的可选域范围密钥。
- `domain: string`
- 与该密钥关联的域名。
+ 与该密钥关联的域。
- `name: string`
- 要为该域名注入的密钥名称。
+ 为该域注入的密钥名称。
- `value: string`
@@ -1793,7 +1795,7 @@
- `type: "code_interpreter"`
- 代码解释器工具的类型。始终为 `code_interpreter`.
+ 代码解释器工具的类型。始终 `code_interpreter`.
- `"code_interpreter"`
@@ -1809,7 +1811,7 @@
- `type: "programmatic_tool_calling"`
- 该工具的类型。始终为 `programmatic_tool_calling`.
+ 工具的类型。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
@@ -1819,7 +1821,7 @@
- `type: "image_generation"`
- 图像生成工具的类型。始终为 `image_generation`.
+ 图像生成工具的类型。始终 `image_generation`.
- `"image_generation"`
@@ -1836,7 +1838,7 @@
- `background: optional "transparent" or "opaque" or "auto"`
设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。透明背景适用于
+ `opaque`,或 `auto`。之一。透明背景可用于
支持的 GPT Image 模型。对于 `gpt-image-2` 和
`gpt-image-2-2026-04-21`,该支持处于预览阶段。使用
`transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
@@ -1849,7 +1851,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持,不受 `gpt-image-1-mini`。支持 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅对 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持,不支持 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -1857,20 +1859,20 @@
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复(inpainting)的可选遮罩。包含 `image_url`
- (string,可选)和 `file_id` (string,可选)。
+ 用于局部重绘的可选蒙版。包含 `image_url`
+ (字符串,可选)和 `file_id` (字符串,可选)。
- `file_id: optional string`
- 遮罩图像的文件 ID。
+ 蒙版图像的文件 ID。
- `image_url: optional string`
- Base64 编码的遮罩图像。
+ Base64 编码的蒙版图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
- 要使用的图像生成模型,取值为以下之一: `gpt-image-1`,
+ 要使用的图像生成模型。其值之一为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
`gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
@@ -1879,7 +1881,7 @@
- `"gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
- 要使用的图像生成模型,取值为以下之一: `gpt-image-1`,
+ 要使用的图像生成模型。其值之一为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
`gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
@@ -1908,7 +1910,7 @@
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式,取值为以下之一: `png`, `webp`,或
+ 生成图像的输出格式。其值之一为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -1919,11 +1921,11 @@
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,范围为 0(默认值)到 3。
+ 在流式模式下生成的部分图像数量,范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
- 生成图像的质量,取值为以下之一: `low`, `medium`, `high`,
+ 生成图像的质量。其值之一为 `low`, `medium`, `high`,
或 `auto`。默认值: `auto`.
- `"low"`
@@ -1936,13 +1938,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率属于实验性功能,且最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素与边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,使用其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,采用 `WIDTHxHEIGHT` 字符串形式,例如 `1536x864`。宽度和高度必须均为 16 的倍数,且所请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边数限制。GPT 图像模型支持的标准尺寸 `1024x1024`, `1536x1024`,以及 `1024x1536` 也由 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率属于实验性功能,且最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素与边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,使用其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,采用 `WIDTHxHEIGHT` 字符串形式,例如 `1536x864`。宽度和高度必须均为 16 的倍数,且所请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边数限制。GPT 图像模型支持的标准尺寸 `1024x1024`, `1536x1024`,以及 `1024x1536` 也由 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -1986,13 +1988,13 @@
- `type: "container_auto"`
- 自动为本次请求创建一个容器
+ 自动为本次请求创建容器
- `"container_auto"`
- `file_ids: optional array of string`
- 可供你代码使用的已上传文件的可选列表。
+ 可供你的代码使用的上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -2016,13 +2018,13 @@
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 ID 引用或使用内联数据。
- `SkillReference object { skill_id, type, version }`
- `skill_id: string`
- 被引用技能的 ID。
+ 所引用技能的 ID。
- `type: "skill_reference"`
@@ -2032,7 +2034,7 @@
- `version: optional string`
- 可选的技能版本。使用正整数或 'latest'。省略则使用默认值。
+ 可选的技能版本。使用正整数或 'latest'。省略以使用默认值。
- `InlineSkill object { description, name, source, type }`
@@ -2046,7 +2048,7 @@
- `source: InlineSkillSource`
- 内联技能负载
+ 内联技能载荷
- `data: string`
@@ -2054,13 +2056,13 @@
- `media_type: "application/zip"`
- 内联技能负载的媒体类型。必须为 `application/zip`.
+ 内联技能载荷的媒体类型,必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能源的类型。必须为 `base64`.
+ 内联技能源的类型,必须为 `base64`.
- `"base64"`
@@ -2080,7 +2082,7 @@
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -2098,7 +2100,7 @@
- `container_id: string`
- 所引用容器的 ID。
+ 被引用容器的 ID。
- `type: "container_reference"`
@@ -2112,7 +2114,7 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中识别它。
+ 自定义工具的名称,用于在工具调用中标识它。
- `type: "custom"`
@@ -2130,7 +2132,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具,并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -2138,15 +2140,15 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `Text object { type }`
- 不受约束的自由格式文本。
+ 无约束的自由格式文本。
- `type: "text"`
- 不受约束的文本格式。始终为 `text`.
+ 无约束文本格式。始终为 `text`.
- `"text"`
@@ -2160,7 +2162,7 @@
- `syntax: "lark" or "regex"`
- 语法定义的语法格式。可选值之一 `lark` 或 `regex`.
+ 语法定义的语法格式。可选值为 `lark` 或 `regex`.
- `"lark"`
@@ -2186,7 +2188,7 @@
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 该命名空间内可用的函数/自定义工具。
+ 此命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -2206,19 +2208,19 @@
- `defer_loading: optional boolean`
- 该函数是否应被延迟并通过工具搜索被发现。
+ 此函数是否应被延迟,并通过工具搜索被发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 描述该函数工具字符串输出中所编码 JSON 值的 JSON Schema。此项不描述 content 数组形式的输出。
+ 用于描述此函数工具字符串输出中所编码 JSON 值的 JSON Schema。该描述不适用于 content-array 输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否启用严格的参数校验。若省略,当 响应接口 在 schema 兼容时会尝试使用严格校验,否则回退到非严格校验。
+ 是否启用严格的参数校验。如果省略,Responses 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -2226,7 +2228,7 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中识别它。
+ 自定义工具的名称,用于在工具调用中标识它。
- `type: "custom"`
@@ -2244,7 +2246,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具,并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -2252,31 +2254,31 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `type: "namespace"`
- 该工具的类型。始终为 `namespace`.
+ 工具的类型。始终 `namespace`.
- `"namespace"`
- `ToolSearch object { type, description, execution, parameters }`
- 针对延迟工具的托管或 BYOT 工具搜索配置。
+ 用于延迟工具的托管或 BYOT 工具搜索配置。
- `type: "tool_search"`
- 该工具的类型。始终为 `tool_search`.
+ 工具的类型。始终 `tool_search`.
- `"tool_search"`
- `description: optional string or null`
- 展示给模型、用于客户端执行的工具搜索工具的描述。
+ 在客户端执行的工具搜索工具中向模型展示的描述。
- `execution: optional "server" or "client"`
- 工具搜索是由服务端还是由客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -2292,7 +2294,7 @@
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型。取值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型。取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -2306,7 +2308,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指导。取值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 搜索所用上下文窗口空间的高层级使用指导,取值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -2316,21 +2318,21 @@
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户所在的位置。
+ 用户的位置。
- `type: "approximate"`
- 位置近似值的类型。始终为 `approximate`.
+ 位置近似类型。始终为 `approximate`.
- `"approximate"`
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如 `San Francisco`.
+ 用于用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 用户的两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 表示用户所在国家/地区,例如。 `US`.
- `region: optional string or null`
@@ -2338,7 +2340,7 @@
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如。 `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 表示用户所在国家/地区,例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
@@ -2346,7 +2348,7 @@
- `type: "apply_patch"`
- 该工具的类型。始终为 `apply_patch`.
+ 工具的类型。始终 `apply_patch`.
- `"apply_patch"`
@@ -2374,7 +2376,7 @@
- `execution: optional "server" or "client"`
- 工具搜索是由服务端执行还是由客户端执行。
+ 工具搜索是由服务端还是由客户端执行的。
- `"server"`
@@ -2382,7 +2384,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 该工具搜索输出的状态。
+ 工具搜索输出的状态。
- `"in_progress"`
@@ -2400,11 +2402,11 @@
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目中可用的额外工具列表。
+ 在此项中提供的额外工具列表。
- `Function object { name, parameters, strict, 5 more }`
- 在你自己的代码中定义一个可供模型选择的函数。了解更多关于 [function calling](https://platform.openai.com/docs/guides/function-calling).
+ 在你自己的代码中定义一个模型可以选择调用的函数。了解更多信息 [函数调用](https://platform.openai.com/docs/guides/function-calling).
- `name: string`
@@ -2420,7 +2422,7 @@
- `type: "function"`
- 函数工具的类型,恒为 `function`.
+ 函数工具的类型,始终为 `function`.
- `"function"`
@@ -2434,7 +2436,7 @@
- `defer_loading: optional boolean`
- 该函数是否被延迟加载,并通过工具搜索加载。
+ 此函数是否延迟加载并通过工具搜索载入。
- `description: optional string or null`
@@ -2442,37 +2444,37 @@
- `output_schema: optional map[unknown] or null`
- 描述该函数在字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 用于描述该函数的字符串输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容的工具。详细了解 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 用于从已上传文件中搜索相关内容的一款工具。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索 工具的类型,恒为 `file_search`.
+ 文件搜索工具的类型,始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将指定属性键与给定值按定义比较运算进行比较的筛选条件。
+ 用于通过已定义的比较运算将指定属性键与给定值进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数量应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -2480,15 +2482,15 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 用于在启用混合搜索时,控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
+ 在启用混合搜索时,用于控制互逆排名融合中语义嵌入匹配与稀疏关键词匹配平衡的权重。
- `embedding_weight: number`
- 嵌入在倒数排名融合中的权重。
+ 互逆排名融合中嵌入的权重。
- `text_weight: number`
- 文本在倒数排名融合中的权重。
+ 互逆排名融合中文本的权重。
- `ranker: optional "auto" or "default-2024-11-15"`
@@ -2500,21 +2502,21 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,介于 0 到 1 之间。越接近 1,尝试返回的结果越相关,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间。越接近 1 的数值会尝试仅返回最相关的结果,但可能返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer 工具的类型,始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -2546,12 +2548,12 @@
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 通过互联网搜索与提示相关的来源。了解更多关于
+ 搜索互联网以查找与提示词相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型。取值为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型。取值之一为 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -2559,7 +2561,7 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 进行实时联网访问。省略时默认为 true。当设为 false 时,网页搜索工具将以离线/仅缓存模式运行,并且不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
@@ -2567,14 +2569,14 @@
- `allowed_domains: optional array of string or null`
- 允许搜索的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索允许使用的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样被允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指导。取值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 搜索所用上下文窗口空间的高层级使用指导,取值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -2588,11 +2590,11 @@
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如 `San Francisco`.
+ 用于用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 用户的两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 表示用户所在国家/地区,例如。 `US`.
- `region: optional string or null`
@@ -2600,22 +2602,22 @@
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如。 `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 表示用户所在国家/地区,例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
- 位置近似值的类型。始终为 `approximate`.
+ 位置近似类型。始终为 `approximate`.
- `"approximate"`
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP) 服务器为模型提供对其他工具的访问。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中识别它。
+ 此 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -2637,32 +2639,32 @@
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 包含允许的工具名称的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的过滤对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此过滤器。
+ 指示工具是否会修改数据,还是属于只读。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 它就会匹配此过滤器。
- `tool_names: optional array of string`
- 允许的工具名称列表。
+ 允许使用的工具名称列表。
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP
- 服务器 URL 或服务连接器使用。你的应用
- 必须处理 OAuth 授权流程并在此处提供令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,可与自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
+ 程序必须自行处理 OAuth 授权流程,并在此处提供该令牌。
+ 必须自行处理 OAuth 授权流程,并在此处提供该令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的连接器。其中之一
- `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
+ 服务连接器的标识符,例如 ChatGPT 中提供的那些连接器。其中之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。了解更多
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -2694,54 +2696,54 @@
- `defer_loading: optional boolean`
- 此 MCP 工具是否被延迟,并通过工具搜索发现。
+ 该 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务器的可选 HTTP 标头。用于身份验证
+ 发送到 MCP 服务器的可选 HTTP 头。可用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务器的哪些工具需要审批。
+ 指定 MCP 服务器中哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务器的哪些工具需要审批。可以是
- `always`, `never`,或与需要审批的工具关联的过滤对象
- 。
+ 指定 MCP 服务器中哪些工具需要审批。可以是
+ `always`, `never`,也可以是与工具关联的过滤器对象
+ 用于指定需要审批的工具。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的过滤对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此过滤器。
+ 指示工具是否会修改数据,还是属于只读。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 它就会匹配此过滤器。
- `tool_names: optional array of string`
- 允许的工具名称列表。
+ 允许使用的工具名称列表。
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的过滤对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此过滤器。
+ 指示工具是否会修改数据,还是属于只读。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 它就会匹配此过滤器。
- `tool_names: optional array of string`
- 允许的工具名称列表。
+ 允许使用的工具名称列表。
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定单个审批策略。其一为 `always` 或
+ 为所有工具指定统一的审批策略。可选值为 `always` 或
`never`. 当设置为 `always`,时,所有工具都需要审批。当
设置为 `never`,时,所有工具都不需要审批。
@@ -2755,22 +2757,22 @@
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`,或
- `tunnel_id` 之一。
+ MCP 服务器的 URL。以下其中之一 `server_url`, `connector_id`,或
+ `tunnel_id` 必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的 Secure MCP Tunnel ID。必须提供
- `server_url`, `connector_id`,或 `tunnel_id` 之一。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。以下其中之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 用于运行 Python 代码以帮助生成对提示词回应的工具。
+ 一个运行 Python 代码以帮助生成对提示词回复的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID,也可以是指定可供你代码使用的已上传文件 ID 的对象,以及一个
- 用于指定可供你代码使用的已上传文件 ID 的对象,以及一个
+ 代码解释器容器。可以是容器 ID 或指定上传文件 ID 的对象,以便你的代码可访问这些文件,以及一个
+ 指定上传文件 ID 以便你的代码可访问,并附带一个
可选的 `memory_limit` 设置。
- `string`
@@ -2779,7 +2781,7 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要对其运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定要在其上运行代码的文件 ID。
- `type: "auto"`
@@ -2789,7 +2791,7 @@
- `file_ids: optional array of string`
- 可供你代码使用的已上传文件的可选列表。
+ 可供你的代码使用的上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -2813,7 +2815,7 @@
- `type: "code_interpreter"`
- 代码解释器工具的类型。始终为 `code_interpreter`.
+ 代码解释器工具的类型。始终 `code_interpreter`.
- `"code_interpreter"`
@@ -2829,7 +2831,7 @@
- `type: "programmatic_tool_calling"`
- 该工具的类型。始终为 `programmatic_tool_calling`.
+ 工具的类型。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
@@ -2839,7 +2841,7 @@
- `type: "image_generation"`
- 图像生成工具的类型。始终为 `image_generation`.
+ 图像生成工具的类型。始终 `image_generation`.
- `"image_generation"`
@@ -2856,7 +2858,7 @@
- `background: optional "transparent" or "opaque" or "auto"`
设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。透明背景适用于
+ `opaque`,或 `auto`。之一。透明背景可用于
支持的 GPT Image 模型。对于 `gpt-image-2` 和
`gpt-image-2-2026-04-21`,该支持处于预览阶段。使用
`transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
@@ -2869,7 +2871,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持,不受 `gpt-image-1-mini`。支持 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅对 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持,不支持 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -2877,20 +2879,20 @@
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复(inpainting)的可选遮罩。包含 `image_url`
- (string,可选)和 `file_id` (string,可选)。
+ 用于局部重绘的可选蒙版。包含 `image_url`
+ (字符串,可选)和 `file_id` (字符串,可选)。
- `file_id: optional string`
- 遮罩图像的文件 ID。
+ 蒙版图像的文件 ID。
- `image_url: optional string`
- Base64 编码的遮罩图像。
+ Base64 编码的蒙版图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
- 要使用的图像生成模型,取值为以下之一: `gpt-image-1`,
+ 要使用的图像生成模型。其值之一为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
`gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
@@ -2899,7 +2901,7 @@
- `"gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
- 要使用的图像生成模型,取值为以下之一: `gpt-image-1`,
+ 要使用的图像生成模型。其值之一为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
`gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
@@ -2928,7 +2930,7 @@
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式,取值为以下之一: `png`, `webp`,或
+ 生成图像的输出格式。其值之一为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -2939,11 +2941,11 @@
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,范围为 0(默认值)到 3。
+ 在流式模式下生成的部分图像数量,范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
- 生成图像的质量,取值为以下之一: `low`, `medium`, `high`,
+ 生成图像的质量。其值之一为 `low`, `medium`, `high`,
或 `auto`。默认值: `auto`.
- `"low"`
@@ -2956,13 +2958,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率属于实验性功能,且最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素与边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,使用其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,采用 `WIDTHxHEIGHT` 字符串形式,例如 `1536x864`。宽度和高度必须均为 16 的倍数,且所请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边数限制。GPT 图像模型支持的标准尺寸 `1024x1024`, `1536x1024`,以及 `1024x1536` 也由 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率属于实验性功能,且最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素与边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,使用其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,采用 `WIDTHxHEIGHT` 字符串形式,例如 `1536x864`。宽度和高度必须均为 16 的倍数,且所请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边数限制。GPT 图像模型支持的标准尺寸 `1024x1024`, `1536x1024`,以及 `1024x1536` 也由 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -3014,7 +3016,7 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中识别它。
+ 自定义工具的名称,用于在工具调用中标识它。
- `type: "custom"`
@@ -3032,7 +3034,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具,并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -3040,7 +3042,7 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `Namespace object { description, name, tools, type }`
@@ -3056,7 +3058,7 @@
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 该命名空间内可用的函数/自定义工具。
+ 此命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -3076,19 +3078,19 @@
- `defer_loading: optional boolean`
- 该函数是否应被延迟并通过工具搜索被发现。
+ 此函数是否应被延迟,并通过工具搜索被发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 描述该函数工具字符串输出中所编码 JSON 值的 JSON Schema。此项不描述 content 数组形式的输出。
+ 用于描述此函数工具字符串输出中所编码 JSON 值的 JSON Schema。该描述不适用于 content-array 输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否启用严格的参数校验。若省略,当 响应接口 在 schema 兼容时会尝试使用严格校验,否则回退到非严格校验。
+ 是否启用严格的参数校验。如果省略,Responses 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -3096,7 +3098,7 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中识别它。
+ 自定义工具的名称,用于在工具调用中标识它。
- `type: "custom"`
@@ -3114,7 +3116,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具,并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -3122,31 +3124,31 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `type: "namespace"`
- 该工具的类型。始终为 `namespace`.
+ 工具的类型。始终 `namespace`.
- `"namespace"`
- `ToolSearch object { type, description, execution, parameters }`
- 针对延迟工具的托管或 BYOT 工具搜索配置。
+ 用于延迟工具的托管或 BYOT 工具搜索配置。
- `type: "tool_search"`
- 该工具的类型。始终为 `tool_search`.
+ 工具的类型。始终 `tool_search`.
- `"tool_search"`
- `description: optional string or null`
- 展示给模型、用于客户端执行的工具搜索工具的描述。
+ 在客户端执行的工具搜索工具中向模型展示的描述。
- `execution: optional "server" or "client"`
- 工具搜索是由服务端还是由客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -3162,7 +3164,7 @@
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型。取值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型。取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -3176,7 +3178,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指导。取值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 搜索所用上下文窗口空间的高层级使用指导,取值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -3186,21 +3188,21 @@
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户所在的位置。
+ 用户的位置。
- `type: "approximate"`
- 位置近似值的类型。始终为 `approximate`.
+ 位置近似类型。始终为 `approximate`.
- `"approximate"`
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如 `San Francisco`.
+ 用于用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 用户的两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 表示用户所在国家/地区,例如。 `US`.
- `region: optional string or null`
@@ -3208,7 +3210,7 @@
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如。 `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 表示用户所在国家/地区,例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
@@ -3216,7 +3218,7 @@
- `type: "apply_patch"`
- 该工具的类型。始终为 `apply_patch`.
+ 工具的类型。始终 `apply_patch`.
- `"apply_patch"`
@@ -3236,13 +3238,13 @@
- `id: optional string or null`
- 该额外工具条目的唯一 ID。
+ 此额外工具项的唯一 ID。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链描述。请务必将这些条目包含在你的 `input` 到 Responses API
- 用于对话的后续轮次,前提是你正在手动
+ 对推理模型在生成
+ 响应时所使用的思维链的描述。请确保将这些项包含在你的 `input` 到 Responses API
+ 以便在手动
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -3255,17 +3257,17 @@
- `text: string`
- 模型到目前为止的推理输出摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
- 对象的类型,始终为 `summary_text`.
+ 对象的类型。始终为 `summary_text`.
- `"summary_text"`
- `type: "reasoning"`
- 对象的类型,始终为 `reasoning`.
+ 对象的类型。始终为 `reasoning`.
- `"reasoning"`
@@ -3275,29 +3277,29 @@
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
- 推理文本的类型,始终为 `reasoning_text`.
+ 推理文本的类型。始终为 `reasoning_text`.
- `"reasoning_text"`
- `encrypted_content: optional string or null`
- 推理项的加密内容。默认情况下会填充该字段
- ,适用于通过 `POST /v1/responses` 和 WebSocket
- `response.create` 请求返回的推理项。
+ 推理条目的加密内容。默认情况下会填充该字段,
+ 用于通过 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理条目。
- 流式传输时,请在后续请求中使用已完成的推理项及其
- `encrypted_content` 事件中的 `response.output_item.done` 字段。
- 后续请求中的 `encrypted_content` 可能
- `response.output_item.added` 不完整。这种情况在
- 在以下情况时尤其重要 `store` : `false` 或在使用 Zero Data Retention 时。
+ 在流式传输时,请在后续请求中使用来自
+ `encrypted_content` 事件的 `response.output_item.done` 中的
+ 已完成推理条目及其 `encrypted_content` 。
+ `response.output_item.added` 可能不完整。这一点在
+ 在以下情况下尤为重要 `store` 或 `false` 使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 该条目的状态。值为 `in_progress`, `completed`,或
+ 项目的状态。取值之一为 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -3308,7 +3310,7 @@
- `Compaction object { encrypted_content, type, id }`
- 由 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下来源生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -3316,7 +3318,7 @@
- `type: "compaction"`
- 该项的类型。始终为 `compaction`.
+ 项的类型,始终为 `compaction`.
- `"compaction"`
@@ -3326,7 +3328,7 @@
- `ImageGenerationCall object { id, result, status, type }`
- 由模型发起的图像生成请求。
+ 模型发起的图像生成请求。
- `id: string`
@@ -3350,7 +3352,7 @@
- `type: "image_generation_call"`
- 图像生成调用的类型。始终为 `image_generation_call`.
+ 图像生成调用的类型,始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -3364,7 +3366,7 @@
- `code: string or null`
- 要运行的代码,如果不可用则为 null。
+ 要运行的代码,若不可用则为 null。
- `container_id: string`
@@ -3372,8 +3374,8 @@
- `outputs: array of object { logs, type } or object { type, url } or null`
- 由代码解释器生成的输出,例如日志或图像。
- 如果没有可用输出则可为 null。
+ 代码解释器生成的输出,例如日志或图像。
+ 如果没有可用的输出,可以为 null。
- `Logs object { logs, type }`
@@ -3391,7 +3393,7 @@
- `Image object { type, url }`
- 来自代码解释器的图像输出。
+ 代码解释器生成的图像输出。
- `type: "image"`
@@ -3401,11 +3403,11 @@
- `url: string`
- 来自代码解释器的图像输出的 URL。
+ 代码解释器生成的图像输出 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
- 代码解释器工具调用的状态。有效值包括 `in_progress`, `completed`, `incomplete`, `interpreting`,和 `failed`.
+ 代码解释器工具调用的状态。有效值为 `in_progress`, `completed`, `incomplete`, `interpreting`,以及 `failed`.
- `"in_progress"`
@@ -3425,7 +3427,7 @@
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 用于在本地 shell 中运行命令的工具调用。
- `id: string`
@@ -3433,7 +3435,7 @@
- `action: object { command, env, type, 3 more }`
- 在服务端执行 shell 命令。
+ 在服务器上执行 shell 命令。
- `command: array of string`
@@ -3441,7 +3443,7 @@
- `env: map[string]`
- 为该命令设置的环境变量。
+ 要为命令设置的环境变量。
- `type: "exec"`
@@ -3451,19 +3453,19 @@
- `timeout_ms: optional number or null`
- 命令的可选超时时间(毫秒)。
+ 命令的可选超时时间(以毫秒为单位)。
- `user: optional string or null`
- 运行该命令所使用的可选用户。
+ 运行命令时使用的可选用户。
- `working_directory: optional string or null`
- 运行该命令所使用的可选工作目录。
+ 运行命令时使用的可选工作目录。
- `call_id: string`
- 由模型生成的本地 shell 工具调用的唯一 ID。
+ 模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -3487,7 +3489,7 @@
- `id: string`
- 由模型生成的本地 shell 工具调用的唯一 ID。
+ 模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -3501,7 +3503,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 该条目的状态。值为 `in_progress`, `completed`,或 `incomplete`.
+ 项目的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -3511,15 +3513,15 @@
- `ShellCall object { action, call_id, type, 4 more }`
- 表示执行一条或多条 shell 命令请求的工具。
+ 表示请求执行一个或多个 shell 命令的工具。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行该工具调用的 shell 命令和限制。
+ 描述如何运行该工具调用的 shell 命令及限制。
- `commands: array of string`
- 由执行环境运行的有序 shell 命令。
+ 由执行环境按顺序运行的 shell 命令。
- `max_output_length: optional number or null`
@@ -3535,7 +3537,7 @@
- `type: "shell_call"`
- 该项的类型。始终为 `shell_call`.
+ 项的类型,始终为 `shell_call`.
- `"shell_call"`
@@ -3569,7 +3571,7 @@
- `environment: optional LocalEnvironment or ContainerReference or null`
- 用于执行 shell 命令的环境。
+ 执行 shell 命令所使用的环境。
- `LocalEnvironment object { type, skills }`
@@ -3577,7 +3579,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态。可选值之一: `in_progress`, `completed`,或 `incomplete`.
+ shell 调用的状态。取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -3587,7 +3589,7 @@
- `ShellCallOutput object { call_id, output, type, 4 more }`
- 由 shell 工具调用发出的流式输出条目。
+ shell 工具调用发出的流式输出条目。
- `call_id: string`
@@ -3595,7 +3597,7 @@
- `output: array of ResponseFunctionShellCallOutputContent`
- 捕获的 stdout 和 stderr 输出块及其关联的结果。
+ 捕获的 stdout 和 stderr 输出分块及其对应的执行结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -3603,7 +3605,7 @@
- `Timeout object { type }`
- 表示 shell 调用超出了其配置的时间限制。
+ 表示该 shell 调用超出了其配置的时间限制。
- `type: "timeout"`
@@ -3635,7 +3637,7 @@
- `type: "shell_call_output"`
- 该项的类型。始终为 `shell_call_output`.
+ 项的类型,始终为 `shell_call_output`.
- `"shell_call_output"`
@@ -3669,7 +3671,7 @@
- `max_output_length: optional number or null`
- 为该 shell 调用的合并输出捕获的最大 UTF-8 字符数。
+ 为该 shell 调用合并输出所捕获的最大 UTF-8 字符数。
- `status: optional "in_progress" or "completed" or "incomplete" or null`
@@ -3683,7 +3685,7 @@
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 表示通过 diff 补丁创建、删除或更新文件请求的工具调用。
+ 表示使用 diff 补丁创建、删除或更新文件的工具调用。
- `call_id: string`
@@ -3691,7 +3693,7 @@
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 针对 apply_patch 工具调用的具体创建、删除或更新指令。
+ apply_patch 工具调用的具体创建、删除或更新指令。
- `CreateFile object { diff, path, type }`
@@ -3699,11 +3701,11 @@
- `diff: string`
- 创建文件时要应用的统一 diff 内容。
+ 创建文件时要应用的 unified diff 内容。
- `path: string`
- 相对于工作区根目录的要创建的文件的路径。
+ 相对于工作区根目录要创建的文件的路径。
- `type: "create_file"`
@@ -3717,7 +3719,7 @@
- `path: string`
- 相对于工作区根目录的要删除的文件的路径。
+ 相对于工作区根目录要删除的文件的路径。
- `type: "delete_file"`
@@ -3731,11 +3733,11 @@
- `diff: string`
- 要应用到现有文件的统一 diff 内容。
+ 要应用到现有文件的 unified diff 内容。
- `path: string`
- 相对于工作区根目录的要更新的文件的路径。
+ 相对于工作区根目录要更新的文件的路径。
- `type: "update_file"`
@@ -3745,7 +3747,7 @@
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。值为以下之一: `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -3753,13 +3755,13 @@
- `type: "apply_patch_call"`
- 该项的类型。始终为 `apply_patch_call`.
+ 项的类型,始终为 `apply_patch_call`.
- `"apply_patch_call"`
- `id: optional string or null`
- apply patch 工具调用的唯一 ID。当该条目通过 API 返回时填充。
+ apply patch 工具调用的唯一 ID。通过 API 返回该项时会填充此字段。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -3795,7 +3797,7 @@
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。值为以下之一: `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -3803,13 +3805,13 @@
- `type: "apply_patch_call_output"`
- 该项的类型。始终为 `apply_patch_call_output`.
+ 项的类型,始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
- `id: optional string or null`
- apply patch 工具调用输出的唯一 ID。当该条目通过 API 返回时填充。
+ apply patch 工具调用输出的唯一 ID。通过 API 返回该项时会填充此字段。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -3837,15 +3839,15 @@
- `output: optional string or null`
- apply patch 工具返回的可选人类可读日志文本(例如补丁结果或错误)。
+ 来自 apply patch 工具的可选人类可读日志文本(例如补丁结果或错误)。
- `McpListTools object { id, server_label, tools, 2 more }`
- MCP 服务器上可用工具的列表。
+ MCP 服务器上可用的工具列表。
- `id: string`
- 该列表的唯一 ID。
+ 列表的唯一 ID。
- `server_label: string`
@@ -3861,25 +3863,25 @@
- `name: string`
- 该工具的名称。
+ 工具的名称。
- `annotations: optional unknown or null`
- 有关该工具的其他注释。
+ 关于该工具的附加注解。
- `description: optional string or null`
- 该工具的描述。
+ 工具的描述。
- `type: "mcp_list_tools"`
- 该项的类型。始终为 `mcp_list_tools`.
+ 项的类型,始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具,则返回错误消息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
@@ -3903,7 +3905,7 @@
- `type: "mcp_approval_request"`
- 该项的类型。始终为 `mcp_approval_request`.
+ 项的类型,始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
@@ -3913,25 +3915,25 @@
- `approval_request_id: string`
- 正在响应的审批请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 该请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 该项的类型。始终为 `mcp_approval_response`.
+ 项的类型,始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
- `id: optional string or null`
- 审批响应的唯一 ID。
+ 审批响应的唯一 ID
- `reason: optional string or null`
- 作出该决定的可选原因。
+ 可选的决策原因。
- `McpCall object { id, arguments, name, 6 more }`
@@ -3939,11 +3941,11 @@
- `id: string`
- 该工具调用的唯一 ID。
+ 工具调用的唯一 ID。
- `arguments: string`
- 传递给工具的参数的 JSON 字符串。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
@@ -3955,18 +3957,18 @@
- `type: "mcp_call"`
- 该项的类型。始终为 `mcp_call`.
+ 项的类型,始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` input 中传入该值以批准或拒绝对应的工具调用。
- `error: optional McpToolCallError or null`
- 工具调用的错误(如果有)。
+ 工具调用产生的错误(若有)。
- `McpProtocolError object { code, message, type }`
@@ -4002,7 +4004,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
+ 工具调用的状态,取值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -4016,16 +4018,16 @@
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 来自你的代码的自定义工具调用的输出,正在发送回模型。
+ 由你的代码生成的自定义工具调用输出,会回传给模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
由你的代码生成的自定义工具调用的输出。
- 可以是字符串或输出内容列表。
+ 可以是字符串或输出内容的列表。
- `StringOutput = string`
@@ -4041,21 +4043,21 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
+ 发送到模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
- 发送给模型的文件输入。
+ 传递给模型的文件输入。
- `type: "custom_tool_call_output"`
- 自定义工具调用输出的类型。始终为 `custom_tool_call_output`.
+ 自定义工具调用输出的类型,始终为 `custom_tool_call_output`.
- `"custom_tool_call_output"`
- `id: optional string`
- 该自定义工具调用输出在 OpenAI 平台中的唯一 ID。
+ 在 OpenAI 平台上自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -4091,7 +4093,7 @@
- `input: string`
- 由模型生成的自定义工具调用的输入。
+ 模型为自定义工具调用生成的输入。
- `name: string`
@@ -4105,7 +4107,7 @@
- `id: optional string`
- OpenAI 平台上此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -4137,7 +4139,7 @@
- `type: "compaction_trigger"`
- 该项的类型。始终为 `compaction_trigger`.
+ 项的类型,始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -4147,15 +4149,15 @@
- `ItemReference object { id, type }`
- 用于引用某个项的内部标识符。
+ 用于引用某个条目的内部标识符。
- `id: string`
- 要引用的项的 ID。
+ 要引用的条目的 ID。
- `type: optional "item_reference" or null`
- 要引用的项的类型。始终为 `item_reference`.
+ 要引用的条目的类型。始终为 `item_reference`.
- `"item_reference"`
@@ -4163,19 +4165,19 @@
- `id: string`
- 此程序项的唯一 ID。
+ 此程序条目的唯一 ID。
- `call_id: string`
- 此程序项的稳定调用 ID。
+ 程序条目的稳定调用 ID。
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
- 必须往返透传的不透明程序重放指纹。
+ 必须往返传输的不透明程序回放指纹。
- `type: "program"`
@@ -4187,15 +4189,15 @@
- `id: string`
- 此程序输出项的唯一 ID。
+ 此程序输出条目的唯一 ID。
- `call_id: string`
- 此程序项的调用 ID。
+ 程序条目的调用 ID。
- `result: string`
- 程序项产生的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -4213,19 +4215,19 @@
- `metadata: Metadata or null`
- 可附加到对象的 16 个键值对集合。可用于
- 以结构化格式存储关于对象的附加信息,并通过 API 或仪表板查询对象。键为字符串
+ 可附加到对象的 16 组键值对。这可用于
+ 以结构化格式存储有关对象的附加信息,并
format,以及通过 API 或控制台查询对象。
- 键为字符串,最大长度为 64 个字符。值为字符串
+ 键是字符串,最大长度为 64 个字符。值是字符串
最大长度为 512 个字符。
- `model: ResponsesModel`
- 用于生成响应的模型 ID,例如 `gpt-5.6-sol`. OpenAI
- 提供了多种具有不同能力、性能
- 特性和价位的模型。请参阅 [模型指南](/docs/models)
- 以浏览和比较可用的模型。
+ 用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI
+ 提供多种能力、性能
+ 特性和价格定位各异的模型。请参阅 [模型指南](/docs/models)
+ 以浏览和比较可用模型。
- `string`
@@ -4439,7 +4441,7 @@
- `object: "response"`
- 此资源的对象类型,始终设置为 `response`.
+ 此资源的对象类型 - 始终设置为 `response`.
- `"response"`
@@ -4447,12 +4449,12 @@
由模型生成的内容项数组。
- - 数组中项的长度和顺序取决于 `output` 模型的响应。
- 与其访问数组中的第一项并。
- - 假设它是一 `output` 条包含由
- 模型生成的内容的消 `assistant` 息,你可以考虑使用
- 属性(在受支持的 SDK 中),其中 `output_text` 包含模型的输出文本。
- 如 开发工具包 支持。
+ - 中各项的长度和顺序取决于 `output` 数组取决于
+ 模型的响应。
+ - 与直接访问 `output` 数组中的第一项并
+ 假定它是一 `assistant` 条包含由模型生成的内容的消息
+ 相比,你可以考虑使用该 `output_text` 属性(在
+ SDK 支持时)。
- `ResponseOutputMessage object { id, content, role, 3 more }`
@@ -4469,11 +4471,11 @@
- `queries: array of string`
- 用于搜索文件的查询。
+ 用于搜索文件的查询语句。
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。可选值为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -4488,7 +4490,7 @@
- `type: "file_search_call"`
- 文件搜索 工具调用的类型。始终为 `file_search_call`.
+ 文件搜索 工具调用的类型。始终 `file_search_call`.
- `"file_search_call"`
@@ -4498,11 +4500,11 @@
- `attributes: optional map[string or number or boolean] or null`
- 可附加到对象的 16 个键值对集合。可用于
- 以结构化格式存储关于对象的附加信息,并通过 API 或仪表板查询对象。键为字符串
- 格式,以及通过 接口 或仪表板查询对象。键为字符串
- 最大长度为 64 个字符。值是字符串、
- 长度为 512 个字符以内的字符串、布尔值或数字。
+ 可附加到对象的 16 组键值对。这可用于
+ 以结构化格式存储有关对象的附加信息,并
+ 通过 API 或控制台查询对象。键为字符串,长度上限
+ 为 64 个字符。值为字符串,长度上限为 512
+ 个字符、布尔值或数字。
- `string`
@@ -4520,7 +4522,7 @@
- `score: optional number`
- 文件的相关性评分,取值范围为 0 到 1。
+ 文件的相关性评分,介于 0 到 1 之间。
- `text: optional string`
@@ -4528,7 +4530,7 @@
- `FunctionCall object { arguments, call_id, name, 5 more }`
- 用于运行函数的工具调用。请参阅
+ 运行函数的工具调用。参见
[函数调用指南](/docs/guides/function-calling) 了解更多信息。
- `arguments: string`
@@ -4579,7 +4581,7 @@
- `status: optional "in_progress" or "completed" or "incomplete"`
- 该条目的状态。值为 `in_progress`, `completed`,或
+ 项目的状态。取值之一为 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -4597,7 +4599,7 @@
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
由你的代码生成的函数调用的输出。
- 可以是字符串或输出内容列表。
+ 可以是字符串或输出内容的列表。
- `StringOutput = string`
@@ -4613,15 +4615,15 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
+ 发送到模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
- 发送给模型的文件输入。
+ 传递给模型的文件输入。
- `status: "in_progress" or "completed" or "incomplete"`
- 该条目的状态。值为 `in_progress`, `completed`,或
+ 项目的状态。取值之一为 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -4666,33 +4668,33 @@
- `created_by: optional string`
- 创建该条目的参与方的标识符。
+ 创建该条目的参与者的标识符。
- `name: optional string`
- 生成该输出的工具的名称。
+ 生成输出的工具的名称。
- `namespace: optional string`
- 生成该输出的工具的命名空间。
+ 生成输出的工具的命名空间。
- `WebSearchCall object { id, action, status, type }`
- 网页搜索工具调用的结果。请参阅
- [网页搜索指南](/docs/guides/tools-web-search) 了解更多信息。
+ 网页搜索 工具调用的结果。请参阅
+ [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
- `id: string`
- 网页搜索工具调用的唯一 ID。
+ 网页搜索 工具调用的唯一 ID。
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述本次 网页搜索调用中所执行具体操作的对象。
- 包含模型使用网页的详细信息(search、open_page、find_in_page)。
+ 描述本次 网页搜索 调用中所执行的具体操作的对象。
+ 包含模型使用网页方式的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" - 执行一次 网页搜索查询。
+ 操作类型 "search" - 执行 网页搜索 查询。
- `type: "search"`
@@ -4702,7 +4704,7 @@
- `queries: optional array of string`
- 搜索查询。
+ 搜索查询列表。
- `query: optional string`
@@ -4724,7 +4726,7 @@
- `OpenPage object { type, url }`
- 操作类型 "open_page" - 打开搜索结果中的特定 URL。
+ 动作类型 "open_page" - 从搜索结果中打开特定 URL。
- `type: "open_page"`
@@ -4738,11 +4740,11 @@
- `FindInPage object { pattern, type, url }`
- 操作类型 "find_in_page":在已加载页面中搜索某个模式。
+ 动作类型 "find_in_page":在已加载的页面中搜索匹配模式。
- `pattern: string`
- 在页面内搜索的模式或文本。
+ 要在页面内搜索的模式或文本。
- `type: "find_in_page"`
@@ -4752,7 +4754,7 @@
- `url: string`
- 搜索该模式的页面 URL。
+ 在其中搜索该模式的页面的 URL。
- `status: "in_progress" or "searching" or "completed" or "failed"`
@@ -4774,12 +4776,12 @@
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
- 对计算机使用工具的工具调用。参见
+ 对计算机使用工具的工具调用。请参阅
[computer use guide](/docs/guides/tools-computer-use) 了解更多信息。
- `id: string`
- 该计算机调用的唯一 ID。
+ 计算机调用的唯一 ID。
- `call_id: string`
@@ -4787,7 +4789,7 @@
- `pending_safety_checks: array of object { id, code, message }`
- 该计算机调用的待处理安全检查。
+ 针对计算机调用的待处理安全检查。
- `id: string`
@@ -4803,7 +4805,7 @@
- `status: "in_progress" or "completed" or "incomplete"`
- 该条目的状态。值为 `in_progress`, `completed`,或
+ 项目的状态。取值之一为 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -4814,7 +4816,7 @@
- `type: "computer_call"`
- 电脑调用的类型。始终为 `computer_call`.
+ 计算机调用的类型。始终为 `computer_call`.
- `"computer_call"`
@@ -4824,8 +4826,8 @@
- `actions: optional ComputerActionList`
- 扁平化批处理操作,用于 `computer_use`。每个操作包含一个
- `type` 判别字段和操作专属字段。
+ 批量操作展平后的结果用于 `computer_use`。每个操作包含一个
+ `type` 判别字段及操作特有的字段。
- `ComputerCallOutput object { id, call_id, output, 4 more }`
@@ -4839,11 +4841,11 @@
- `output: ResponseComputerToolCallOutputScreenshot`
- 与计算机使用工具一起使用的计算机截图图像。
+ 与计算机使用工具配合使用的计算机截图图像。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`,或
+ 消息输入的状态。可选值为 `in_progress`, `completed`,或
`incomplete`。之一。当输入项通过 API 返回时填充。
- `"completed"`
@@ -4862,7 +4864,7 @@
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告的、且已被
+ 由 API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -4879,13 +4881,13 @@
- `created_by: optional string`
- 创建该条目的参与方的标识符。
+ 创建该条目的参与者的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成
- 响应时所使用的思维链描述。请务必将这些条目包含在你的 `input` 到 Responses API
- 用于对话的后续轮次,前提是你正在手动
+ 对推理模型在生成
+ 响应时所使用的思维链的描述。请确保将这些项包含在你的 `input` 到 Responses API
+ 以便在手动
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -4898,15 +4900,15 @@
- `text: string`
- 模型到目前为止的推理输出摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
- 对象的类型,始终为 `summary_text`.
+ 对象的类型。始终为 `summary_text`.
- `type: "reasoning"`
- 对象的类型,始终为 `reasoning`.
+ 对象的类型。始终为 `reasoning`.
- `"reasoning"`
@@ -4916,29 +4918,29 @@
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
- 推理文本的类型,始终为 `reasoning_text`.
+ 推理文本的类型。始终为 `reasoning_text`.
- `"reasoning_text"`
- `encrypted_content: optional string or null`
- 推理项的加密内容。默认情况下会填充该字段
- ,适用于通过 `POST /v1/responses` 和 WebSocket
- `response.create` 请求返回的推理项。
+ 推理条目的加密内容。默认情况下会填充该字段,
+ 用于通过 `POST /v1/responses` 和 WebSocket
+ `response.create` 请求返回的推理条目。
- 流式传输时,请在后续请求中使用已完成的推理项及其
- `encrypted_content` 事件中的 `response.output_item.done` 字段。
- 后续请求中的 `encrypted_content` 可能
- `response.output_item.added` 不完整。这种情况在
- 在以下情况时尤其重要 `store` : `false` 或在使用 Zero Data Retention 时。
+ 在流式传输时,请在后续请求中使用来自
+ `encrypted_content` 事件的 `response.output_item.done` 中的
+ 已完成推理条目及其 `encrypted_content` 。
+ `response.output_item.added` 可能不完整。这一点在
+ 在以下情况下尤为重要 `store` 或 `false` 使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 该条目的状态。值为 `in_progress`, `completed`,或
+ 项目的状态。取值之一为 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -4951,23 +4953,23 @@
- `id: string`
- 该程序条目的唯一 ID。
+ 程序条目的唯一 ID。
- `call_id: string`
- 此程序项的稳定调用 ID。
+ 程序条目的稳定调用 ID。
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
- 必须往返透传的不透明程序重放指纹。
+ 必须往返传输的不透明程序回放指纹。
- `type: "program"`
- 该项的类型。始终为 `program`.
+ 项的类型,始终为 `program`.
- `"program"`
@@ -4979,15 +4981,15 @@
- `call_id: string`
- 此程序项的调用 ID。
+ 程序条目的调用 ID。
- `result: string`
- 程序项产生的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
- 程序输出条目的最终状态。
+ 程序输出条目的终止状态。
- `"completed"`
@@ -4995,7 +4997,7 @@
- `type: "program_output"`
- 该项的类型。始终为 `program_output`.
+ 项的类型,始终为 `program_output`.
- `"program_output"`
@@ -5015,7 +5017,7 @@
- `execution: "server" or "client"`
- 工具搜索是由服务端执行还是由客户端执行。
+ 工具搜索是由服务端还是由客户端执行的。
- `"server"`
@@ -5033,13 +5035,13 @@
- `type: "tool_search_call"`
- 该项的类型。始终为 `tool_search_call`.
+ 项的类型,始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的参与方的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -5053,7 +5055,7 @@
- `execution: "server" or "client"`
- 工具搜索是由服务端执行还是由客户端执行。
+ 工具搜索是由服务端还是由客户端执行的。
- `"server"`
@@ -5075,7 +5077,7 @@
- `Function object { name, parameters, strict, 5 more }`
- 在你自己的代码中定义一个可供模型选择的函数。了解更多关于 [function calling](https://platform.openai.com/docs/guides/function-calling).
+ 在你自己的代码中定义一个模型可以选择调用的函数。了解更多信息 [函数调用](https://platform.openai.com/docs/guides/function-calling).
- `name: string`
@@ -5091,7 +5093,7 @@
- `type: "function"`
- 函数工具的类型,恒为 `function`.
+ 函数工具的类型,始终为 `function`.
- `"function"`
@@ -5105,7 +5107,7 @@
- `defer_loading: optional boolean`
- 该函数是否被延迟加载,并通过工具搜索加载。
+ 此函数是否延迟加载并通过工具搜索载入。
- `description: optional string or null`
@@ -5113,37 +5115,37 @@
- `output_schema: optional map[unknown] or null`
- 描述该函数在字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 用于描述该函数的字符串输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容的工具。详细了解 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 用于从已上传文件中搜索相关内容的一款工具。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索 工具的类型,恒为 `file_search`.
+ 文件搜索工具的类型,始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将指定属性键与给定值按定义比较运算进行比较的筛选条件。
+ 用于通过已定义的比较运算将指定属性键与给定值进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数量应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -5151,15 +5153,15 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 用于在启用混合搜索时,控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
+ 在启用混合搜索时,用于控制互逆排名融合中语义嵌入匹配与稀疏关键词匹配平衡的权重。
- `embedding_weight: number`
- 嵌入在倒数排名融合中的权重。
+ 互逆排名融合中嵌入的权重。
- `text_weight: number`
- 文本在倒数排名融合中的权重。
+ 互逆排名融合中文本的权重。
- `ranker: optional "auto" or "default-2024-11-15"`
@@ -5171,21 +5173,21 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,介于 0 到 1 之间。越接近 1,尝试返回的结果越相关,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间。越接近 1 的数值会尝试仅返回最相关的结果,但可能返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer 工具的类型,始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -5217,12 +5219,12 @@
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 通过互联网搜索与提示相关的来源。了解更多关于
+ 搜索互联网以查找与提示词相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型。取值为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型。取值之一为 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -5230,7 +5232,7 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 进行实时联网访问。省略时默认为 true。当设为 false 时,网页搜索工具将以离线/仅缓存模式运行,并且不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
@@ -5238,14 +5240,14 @@
- `allowed_domains: optional array of string or null`
- 允许搜索的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索允许使用的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样被允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指导。取值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 搜索所用上下文窗口空间的高层级使用指导,取值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -5259,11 +5261,11 @@
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如 `San Francisco`.
+ 用于用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 用户的两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 表示用户所在国家/地区,例如。 `US`.
- `region: optional string or null`
@@ -5271,22 +5273,22 @@
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如。 `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 表示用户所在国家/地区,例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
- 位置近似值的类型。始终为 `approximate`.
+ 位置近似类型。始终为 `approximate`.
- `"approximate"`
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP) 服务器为模型提供对其他工具的访问。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中识别它。
+ 此 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -5308,32 +5310,32 @@
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 包含允许的工具名称的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的过滤对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此过滤器。
+ 指示工具是否会修改数据,还是属于只读。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 它就会匹配此过滤器。
- `tool_names: optional array of string`
- 允许的工具名称列表。
+ 允许使用的工具名称列表。
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP
- 服务器 URL 或服务连接器使用。你的应用
- 必须处理 OAuth 授权流程并在此处提供令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,可与自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
+ 程序必须自行处理 OAuth 授权流程,并在此处提供该令牌。
+ 必须自行处理 OAuth 授权流程,并在此处提供该令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的连接器。其中之一
- `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
+ 服务连接器的标识符,例如 ChatGPT 中提供的那些连接器。其中之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。了解更多
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -5365,54 +5367,54 @@
- `defer_loading: optional boolean`
- 此 MCP 工具是否被延迟,并通过工具搜索发现。
+ 该 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务器的可选 HTTP 标头。用于身份验证
+ 发送到 MCP 服务器的可选 HTTP 头。可用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务器的哪些工具需要审批。
+ 指定 MCP 服务器中哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务器的哪些工具需要审批。可以是
- `always`, `never`,或与需要审批的工具关联的过滤对象
- 。
+ 指定 MCP 服务器中哪些工具需要审批。可以是
+ `always`, `never`,也可以是与工具关联的过滤器对象
+ 用于指定需要审批的工具。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的过滤对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此过滤器。
+ 指示工具是否会修改数据,还是属于只读。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 它就会匹配此过滤器。
- `tool_names: optional array of string`
- 允许的工具名称列表。
+ 允许使用的工具名称列表。
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的过滤对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此过滤器。
+ 指示工具是否会修改数据,还是属于只读。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 它就会匹配此过滤器。
- `tool_names: optional array of string`
- 允许的工具名称列表。
+ 允许使用的工具名称列表。
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定单个审批策略。其一为 `always` 或
+ 为所有工具指定统一的审批策略。可选值为 `always` 或
`never`. 当设置为 `always`,时,所有工具都需要审批。当
设置为 `never`,时,所有工具都不需要审批。
@@ -5426,22 +5428,22 @@
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`,或
- `tunnel_id` 之一。
+ MCP 服务器的 URL。以下其中之一 `server_url`, `connector_id`,或
+ `tunnel_id` 必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的 Secure MCP Tunnel ID。必须提供
- `server_url`, `connector_id`,或 `tunnel_id` 之一。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。以下其中之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 用于运行 Python 代码以帮助生成对提示词回应的工具。
+ 一个运行 Python 代码以帮助生成对提示词回复的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID,也可以是指定可供你代码使用的已上传文件 ID 的对象,以及一个
- 用于指定可供你代码使用的已上传文件 ID 的对象,以及一个
+ 代码解释器容器。可以是容器 ID 或指定上传文件 ID 的对象,以便你的代码可访问这些文件,以及一个
+ 指定上传文件 ID 以便你的代码可访问,并附带一个
可选的 `memory_limit` 设置。
- `string`
@@ -5450,7 +5452,7 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要对其运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定要在其上运行代码的文件 ID。
- `type: "auto"`
@@ -5460,7 +5462,7 @@
- `file_ids: optional array of string`
- 可供你代码使用的已上传文件的可选列表。
+ 可供你的代码使用的上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -5484,7 +5486,7 @@
- `type: "code_interpreter"`
- 代码解释器工具的类型。始终为 `code_interpreter`.
+ 代码解释器工具的类型。始终 `code_interpreter`.
- `"code_interpreter"`
@@ -5500,7 +5502,7 @@
- `type: "programmatic_tool_calling"`
- 该工具的类型。始终为 `programmatic_tool_calling`.
+ 工具的类型。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
@@ -5510,7 +5512,7 @@
- `type: "image_generation"`
- 图像生成工具的类型。始终为 `image_generation`.
+ 图像生成工具的类型。始终 `image_generation`.
- `"image_generation"`
@@ -5527,7 +5529,7 @@
- `background: optional "transparent" or "opaque" or "auto"`
设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。透明背景适用于
+ `opaque`,或 `auto`。之一。透明背景可用于
支持的 GPT Image 模型。对于 `gpt-image-2` 和
`gpt-image-2-2026-04-21`,该支持处于预览阶段。使用
`transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
@@ -5540,7 +5542,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持,不受 `gpt-image-1-mini`。支持 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅对 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持,不支持 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -5548,20 +5550,20 @@
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复(inpainting)的可选遮罩。包含 `image_url`
- (string,可选)和 `file_id` (string,可选)。
+ 用于局部重绘的可选蒙版。包含 `image_url`
+ (字符串,可选)和 `file_id` (字符串,可选)。
- `file_id: optional string`
- 遮罩图像的文件 ID。
+ 蒙版图像的文件 ID。
- `image_url: optional string`
- Base64 编码的遮罩图像。
+ Base64 编码的蒙版图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
- 要使用的图像生成模型,取值为以下之一: `gpt-image-1`,
+ 要使用的图像生成模型。其值之一为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
`gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
@@ -5570,7 +5572,7 @@
- `"gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
- 要使用的图像生成模型,取值为以下之一: `gpt-image-1`,
+ 要使用的图像生成模型。其值之一为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
`gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
@@ -5599,7 +5601,7 @@
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式,取值为以下之一: `png`, `webp`,或
+ 生成图像的输出格式。其值之一为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -5610,11 +5612,11 @@
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,范围为 0(默认值)到 3。
+ 在流式模式下生成的部分图像数量,范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
- 生成图像的质量,取值为以下之一: `low`, `medium`, `high`,
+ 生成图像的质量。其值之一为 `low`, `medium`, `high`,
或 `auto`。默认值: `auto`.
- `"low"`
@@ -5627,13 +5629,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率属于实验性功能,且最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素与边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,使用其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,采用 `WIDTHxHEIGHT` 字符串形式,例如 `1536x864`。宽度和高度必须均为 16 的倍数,且所请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边数限制。GPT 图像模型支持的标准尺寸 `1024x1024`, `1536x1024`,以及 `1024x1536` 也由 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率属于实验性功能,且最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素与边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,使用其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,采用 `WIDTHxHEIGHT` 字符串形式,例如 `1536x864`。宽度和高度必须均为 16 的倍数,且所请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边数限制。GPT 图像模型支持的标准尺寸 `1024x1024`, `1536x1024`,以及 `1024x1536` 也由 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -5685,7 +5687,7 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中识别它。
+ 自定义工具的名称,用于在工具调用中标识它。
- `type: "custom"`
@@ -5703,7 +5705,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具,并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -5711,7 +5713,7 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `Namespace object { description, name, tools, type }`
@@ -5727,7 +5729,7 @@
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 该命名空间内可用的函数/自定义工具。
+ 此命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -5747,19 +5749,19 @@
- `defer_loading: optional boolean`
- 该函数是否应被延迟并通过工具搜索被发现。
+ 此函数是否应被延迟,并通过工具搜索被发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 描述该函数工具字符串输出中所编码 JSON 值的 JSON Schema。此项不描述 content 数组形式的输出。
+ 用于描述此函数工具字符串输出中所编码 JSON 值的 JSON Schema。该描述不适用于 content-array 输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否启用严格的参数校验。若省略,当 响应接口 在 schema 兼容时会尝试使用严格校验,否则回退到非严格校验。
+ 是否启用严格的参数校验。如果省略,Responses 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -5767,7 +5769,7 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中识别它。
+ 自定义工具的名称,用于在工具调用中标识它。
- `type: "custom"`
@@ -5785,7 +5787,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具,并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -5793,31 +5795,31 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `type: "namespace"`
- 该工具的类型。始终为 `namespace`.
+ 工具的类型。始终 `namespace`.
- `"namespace"`
- `ToolSearch object { type, description, execution, parameters }`
- 针对延迟工具的托管或 BYOT 工具搜索配置。
+ 用于延迟工具的托管或 BYOT 工具搜索配置。
- `type: "tool_search"`
- 该工具的类型。始终为 `tool_search`.
+ 工具的类型。始终 `tool_search`.
- `"tool_search"`
- `description: optional string or null`
- 展示给模型、用于客户端执行的工具搜索工具的描述。
+ 在客户端执行的工具搜索工具中向模型展示的描述。
- `execution: optional "server" or "client"`
- 工具搜索是由服务端还是由客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -5833,7 +5835,7 @@
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型。取值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型。取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -5847,7 +5849,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指导。取值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 搜索所用上下文窗口空间的高层级使用指导,取值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -5857,21 +5859,21 @@
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户所在的位置。
+ 用户的位置。
- `type: "approximate"`
- 位置近似值的类型。始终为 `approximate`.
+ 位置近似类型。始终为 `approximate`.
- `"approximate"`
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如 `San Francisco`.
+ 用于用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 用户的两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 表示用户所在国家/地区,例如。 `US`.
- `region: optional string or null`
@@ -5879,7 +5881,7 @@
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如。 `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 表示用户所在国家/地区,例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
@@ -5887,7 +5889,7 @@
- `type: "apply_patch"`
- 该工具的类型。始终为 `apply_patch`.
+ 工具的类型。始终 `apply_patch`.
- `"apply_patch"`
@@ -5901,23 +5903,23 @@
- `type: "tool_search_output"`
- 该项的类型。始终为 `tool_search_output`.
+ 项的类型,始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的参与方的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
- `id: string`
- 额外工具条目的唯一 ID。
+ 附加工具条目的唯一 ID。
- `role: "unknown" or "user" or "assistant" or 5 more`
- 提供额外工具的角色。
+ 提供附加工具的角色。
- `"unknown"`
@@ -5937,11 +5939,11 @@
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在该条目下可用的额外工具定义。
+ 在该条目下可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
- 在你自己的代码中定义一个可供模型选择的函数。了解更多关于 [function calling](https://platform.openai.com/docs/guides/function-calling).
+ 在你自己的代码中定义一个模型可以选择调用的函数。了解更多信息 [函数调用](https://platform.openai.com/docs/guides/function-calling).
- `name: string`
@@ -5957,7 +5959,7 @@
- `type: "function"`
- 函数工具的类型,恒为 `function`.
+ 函数工具的类型,始终为 `function`.
- `"function"`
@@ -5971,7 +5973,7 @@
- `defer_loading: optional boolean`
- 该函数是否被延迟加载,并通过工具搜索加载。
+ 此函数是否延迟加载并通过工具搜索载入。
- `description: optional string or null`
@@ -5979,37 +5981,37 @@
- `output_schema: optional map[unknown] or null`
- 描述该函数在字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 用于描述该函数的字符串输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容的工具。详细了解 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 用于从已上传文件中搜索相关内容的一款工具。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索 工具的类型,恒为 `file_search`.
+ 文件搜索工具的类型,始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将指定属性键与给定值按定义比较运算进行比较的筛选条件。
+ 用于通过已定义的比较运算将指定属性键与给定值进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数量应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -6017,15 +6019,15 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 用于在启用混合搜索时,控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
+ 在启用混合搜索时,用于控制互逆排名融合中语义嵌入匹配与稀疏关键词匹配平衡的权重。
- `embedding_weight: number`
- 嵌入在倒数排名融合中的权重。
+ 互逆排名融合中嵌入的权重。
- `text_weight: number`
- 文本在倒数排名融合中的权重。
+ 互逆排名融合中文本的权重。
- `ranker: optional "auto" or "default-2024-11-15"`
@@ -6037,21 +6039,21 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,介于 0 到 1 之间。越接近 1,尝试返回的结果越相关,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间。越接近 1 的数值会尝试仅返回最相关的结果,但可能返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer 工具的类型,始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -6083,12 +6085,12 @@
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 通过互联网搜索与提示相关的来源。了解更多关于
+ 搜索互联网以查找与提示词相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型。取值为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型。取值之一为 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -6096,7 +6098,7 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 进行实时联网访问。省略时默认为 true。当设为 false 时,网页搜索工具将以离线/仅缓存模式运行,并且不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
@@ -6104,14 +6106,14 @@
- `allowed_domains: optional array of string or null`
- 允许搜索的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索允许使用的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样被允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指导。取值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 搜索所用上下文窗口空间的高层级使用指导,取值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -6125,11 +6127,11 @@
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如 `San Francisco`.
+ 用于用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 用户的两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 表示用户所在国家/地区,例如。 `US`.
- `region: optional string or null`
@@ -6137,22 +6139,22 @@
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如。 `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 表示用户所在国家/地区,例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
- 位置近似值的类型。始终为 `approximate`.
+ 位置近似类型。始终为 `approximate`.
- `"approximate"`
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP) 服务器为模型提供对其他工具的访问。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中识别它。
+ 此 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -6174,32 +6176,32 @@
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 包含允许的工具名称的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的过滤对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此过滤器。
+ 指示工具是否会修改数据,还是属于只读。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 它就会匹配此过滤器。
- `tool_names: optional array of string`
- 允许的工具名称列表。
+ 允许使用的工具名称列表。
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP
- 服务器 URL 或服务连接器使用。你的应用
- 必须处理 OAuth 授权流程并在此处提供令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,可与自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
+ 程序必须自行处理 OAuth 授权流程,并在此处提供该令牌。
+ 必须自行处理 OAuth 授权流程,并在此处提供该令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的连接器。其中之一
- `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
+ 服务连接器的标识符,例如 ChatGPT 中提供的那些连接器。其中之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。了解更多
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -6231,54 +6233,54 @@
- `defer_loading: optional boolean`
- 此 MCP 工具是否被延迟,并通过工具搜索发现。
+ 该 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务器的可选 HTTP 标头。用于身份验证
+ 发送到 MCP 服务器的可选 HTTP 头。可用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务器的哪些工具需要审批。
+ 指定 MCP 服务器中哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务器的哪些工具需要审批。可以是
- `always`, `never`,或与需要审批的工具关联的过滤对象
- 。
+ 指定 MCP 服务器中哪些工具需要审批。可以是
+ `always`, `never`,也可以是与工具关联的过滤器对象
+ 用于指定需要审批的工具。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的过滤对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此过滤器。
+ 指示工具是否会修改数据,还是属于只读。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 它就会匹配此过滤器。
- `tool_names: optional array of string`
- 允许的工具名称列表。
+ 允许使用的工具名称列表。
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的过滤对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此过滤器。
+ 指示工具是否会修改数据,还是属于只读。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 它就会匹配此过滤器。
- `tool_names: optional array of string`
- 允许的工具名称列表。
+ 允许使用的工具名称列表。
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定单个审批策略。其一为 `always` 或
+ 为所有工具指定统一的审批策略。可选值为 `always` 或
`never`. 当设置为 `always`,时,所有工具都需要审批。当
设置为 `never`,时,所有工具都不需要审批。
@@ -6292,22 +6294,22 @@
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`,或
- `tunnel_id` 之一。
+ MCP 服务器的 URL。以下其中之一 `server_url`, `connector_id`,或
+ `tunnel_id` 必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的 Secure MCP Tunnel ID。必须提供
- `server_url`, `connector_id`,或 `tunnel_id` 之一。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。以下其中之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 用于运行 Python 代码以帮助生成对提示词回应的工具。
+ 一个运行 Python 代码以帮助生成对提示词回复的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID,也可以是指定可供你代码使用的已上传文件 ID 的对象,以及一个
- 用于指定可供你代码使用的已上传文件 ID 的对象,以及一个
+ 代码解释器容器。可以是容器 ID 或指定上传文件 ID 的对象,以便你的代码可访问这些文件,以及一个
+ 指定上传文件 ID 以便你的代码可访问,并附带一个
可选的 `memory_limit` 设置。
- `string`
@@ -6316,7 +6318,7 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要对其运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定要在其上运行代码的文件 ID。
- `type: "auto"`
@@ -6326,7 +6328,7 @@
- `file_ids: optional array of string`
- 可供你代码使用的已上传文件的可选列表。
+ 可供你的代码使用的上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -6350,7 +6352,7 @@
- `type: "code_interpreter"`
- 代码解释器工具的类型。始终为 `code_interpreter`.
+ 代码解释器工具的类型。始终 `code_interpreter`.
- `"code_interpreter"`
@@ -6366,7 +6368,7 @@
- `type: "programmatic_tool_calling"`
- 该工具的类型。始终为 `programmatic_tool_calling`.
+ 工具的类型。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
@@ -6376,7 +6378,7 @@
- `type: "image_generation"`
- 图像生成工具的类型。始终为 `image_generation`.
+ 图像生成工具的类型。始终 `image_generation`.
- `"image_generation"`
@@ -6393,7 +6395,7 @@
- `background: optional "transparent" or "opaque" or "auto"`
设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。透明背景适用于
+ `opaque`,或 `auto`。之一。透明背景可用于
支持的 GPT Image 模型。对于 `gpt-image-2` 和
`gpt-image-2-2026-04-21`,该支持处于预览阶段。使用
`transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
@@ -6406,7 +6408,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持,不受 `gpt-image-1-mini`。支持 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅对 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持,不支持 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -6414,20 +6416,20 @@
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复(inpainting)的可选遮罩。包含 `image_url`
- (string,可选)和 `file_id` (string,可选)。
+ 用于局部重绘的可选蒙版。包含 `image_url`
+ (字符串,可选)和 `file_id` (字符串,可选)。
- `file_id: optional string`
- 遮罩图像的文件 ID。
+ 蒙版图像的文件 ID。
- `image_url: optional string`
- Base64 编码的遮罩图像。
+ Base64 编码的蒙版图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
- 要使用的图像生成模型,取值为以下之一: `gpt-image-1`,
+ 要使用的图像生成模型。其值之一为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
`gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
@@ -6436,7 +6438,7 @@
- `"gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
- 要使用的图像生成模型,取值为以下之一: `gpt-image-1`,
+ 要使用的图像生成模型。其值之一为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
`gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
@@ -6465,7 +6467,7 @@
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式,取值为以下之一: `png`, `webp`,或
+ 生成图像的输出格式。其值之一为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -6476,11 +6478,11 @@
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,范围为 0(默认值)到 3。
+ 在流式模式下生成的部分图像数量,范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
- 生成图像的质量,取值为以下之一: `low`, `medium`, `high`,
+ 生成图像的质量。其值之一为 `low`, `medium`, `high`,
或 `auto`。默认值: `auto`.
- `"low"`
@@ -6493,13 +6495,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率属于实验性功能,且最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素与边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,使用其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,采用 `WIDTHxHEIGHT` 字符串形式,例如 `1536x864`。宽度和高度必须均为 16 的倍数,且所请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边数限制。GPT 图像模型支持的标准尺寸 `1024x1024`, `1536x1024`,以及 `1024x1536` 也由 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率属于实验性功能,且最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素与边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,使用其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,采用 `WIDTHxHEIGHT` 字符串形式,例如 `1536x864`。宽度和高度必须均为 16 的倍数,且所请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边数限制。GPT 图像模型支持的标准尺寸 `1024x1024`, `1536x1024`,以及 `1024x1536` 也由 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -6551,7 +6553,7 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中识别它。
+ 自定义工具的名称,用于在工具调用中标识它。
- `type: "custom"`
@@ -6569,7 +6571,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具,并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -6577,7 +6579,7 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `Namespace object { description, name, tools, type }`
@@ -6593,7 +6595,7 @@
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 该命名空间内可用的函数/自定义工具。
+ 此命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -6613,19 +6615,19 @@
- `defer_loading: optional boolean`
- 该函数是否应被延迟并通过工具搜索被发现。
+ 此函数是否应被延迟,并通过工具搜索被发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 描述该函数工具字符串输出中所编码 JSON 值的 JSON Schema。此项不描述 content 数组形式的输出。
+ 用于描述此函数工具字符串输出中所编码 JSON 值的 JSON Schema。该描述不适用于 content-array 输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否启用严格的参数校验。若省略,当 响应接口 在 schema 兼容时会尝试使用严格校验,否则回退到非严格校验。
+ 是否启用严格的参数校验。如果省略,Responses 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -6633,7 +6635,7 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中识别它。
+ 自定义工具的名称,用于在工具调用中标识它。
- `type: "custom"`
@@ -6651,7 +6653,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具,并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -6659,31 +6661,31 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `type: "namespace"`
- 该工具的类型。始终为 `namespace`.
+ 工具的类型。始终 `namespace`.
- `"namespace"`
- `ToolSearch object { type, description, execution, parameters }`
- 针对延迟工具的托管或 BYOT 工具搜索配置。
+ 用于延迟工具的托管或 BYOT 工具搜索配置。
- `type: "tool_search"`
- 该工具的类型。始终为 `tool_search`.
+ 工具的类型。始终 `tool_search`.
- `"tool_search"`
- `description: optional string or null`
- 展示给模型、用于客户端执行的工具搜索工具的描述。
+ 在客户端执行的工具搜索工具中向模型展示的描述。
- `execution: optional "server" or "client"`
- 工具搜索是由服务端还是由客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -6699,7 +6701,7 @@
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型。取值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型。取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -6713,7 +6715,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指导。取值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 搜索所用上下文窗口空间的高层级使用指导,取值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -6723,21 +6725,21 @@
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户所在的位置。
+ 用户的位置。
- `type: "approximate"`
- 位置近似值的类型。始终为 `approximate`.
+ 位置近似类型。始终为 `approximate`.
- `"approximate"`
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如 `San Francisco`.
+ 用于用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 用户的两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 表示用户所在国家/地区,例如。 `US`.
- `region: optional string or null`
@@ -6745,7 +6747,7 @@
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如。 `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 表示用户所在国家/地区,例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
@@ -6753,7 +6755,7 @@
- `type: "apply_patch"`
- 该工具的类型。始终为 `apply_patch`.
+ 工具的类型。始终 `apply_patch`.
- `"apply_patch"`
@@ -6767,13 +6769,13 @@
- `type: "additional_tools"`
- 该项的类型。始终为 `additional_tools`.
+ 项的类型,始终为 `additional_tools`.
- `"additional_tools"`
- `Compaction object { id, encrypted_content, type, created_by }`
- 由 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由以下来源生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -6785,17 +6787,17 @@
- `type: "compaction"`
- 该项的类型。始终为 `compaction`.
+ 项的类型,始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的参与方的标识符。
+ 创建该条目的参与者的标识符。
- `ImageGenerationCall object { id, result, status, type }`
- 由模型发起的图像生成请求。
+ 模型发起的图像生成请求。
- `id: string`
@@ -6819,7 +6821,7 @@
- `type: "image_generation_call"`
- 图像生成调用的类型。始终为 `image_generation_call`.
+ 图像生成调用的类型,始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -6833,7 +6835,7 @@
- `code: string or null`
- 要运行的代码,如果不可用则为 null。
+ 要运行的代码,若不可用则为 null。
- `container_id: string`
@@ -6841,8 +6843,8 @@
- `outputs: array of object { logs, type } or object { type, url } or null`
- 由代码解释器生成的输出,例如日志或图像。
- 如果没有可用输出则可为 null。
+ 代码解释器生成的输出,例如日志或图像。
+ 如果没有可用的输出,可以为 null。
- `Logs object { logs, type }`
@@ -6860,7 +6862,7 @@
- `Image object { type, url }`
- 来自代码解释器的图像输出。
+ 代码解释器生成的图像输出。
- `type: "image"`
@@ -6870,11 +6872,11 @@
- `url: string`
- 来自代码解释器的图像输出的 URL。
+ 代码解释器生成的图像输出 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
- 代码解释器工具调用的状态。有效值包括 `in_progress`, `completed`, `incomplete`, `interpreting`,和 `failed`.
+ 代码解释器工具调用的状态。有效值为 `in_progress`, `completed`, `incomplete`, `interpreting`,以及 `failed`.
- `"in_progress"`
@@ -6894,7 +6896,7 @@
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 用于在本地 shell 中运行命令的工具调用。
- `id: string`
@@ -6902,7 +6904,7 @@
- `action: object { command, env, type, 3 more }`
- 在服务端执行 shell 命令。
+ 在服务器上执行 shell 命令。
- `command: array of string`
@@ -6910,7 +6912,7 @@
- `env: map[string]`
- 为该命令设置的环境变量。
+ 要为命令设置的环境变量。
- `type: "exec"`
@@ -6920,19 +6922,19 @@
- `timeout_ms: optional number or null`
- 命令的可选超时时间(毫秒)。
+ 命令的可选超时时间(以毫秒为单位)。
- `user: optional string or null`
- 运行该命令所使用的可选用户。
+ 运行命令时使用的可选用户。
- `working_directory: optional string or null`
- 运行该命令所使用的可选工作目录。
+ 运行命令时使用的可选工作目录。
- `call_id: string`
- 由模型生成的本地 shell 工具调用的唯一 ID。
+ 模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -6956,7 +6958,7 @@
- `id: string`
- 由模型生成的本地 shell 工具调用的唯一 ID。
+ 模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -6970,7 +6972,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 该条目的状态。值为 `in_progress`, `completed`,或 `incomplete`.
+ 项目的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -6980,7 +6982,7 @@
- `ShellCall object { id, action, call_id, 5 more }`
- 在托管环境中执行一个或多个 shell 命令的工具调用。
+ 在托管环境中执行一条或多条 shell 命令的工具调用。
- `id: string`
@@ -6988,13 +6990,13 @@
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行该工具调用的 shell 命令和限制。
+ 描述如何运行该工具调用的 shell 命令及限制。
- `commands: array of string`
- `max_output_length: number or null`
- 每个命令返回内容的可选最大字符数。
+ 可选的每个命令返回结果的最大字符数。
- `timeout_ms: number or null`
@@ -7006,11 +7008,11 @@
- `environment: ResponseLocalEnvironment or ResponseContainerReference or null`
- 表示使用本地环境执行 shell 操作。
+ 表示使用本地环境来执行 shell 操作。
- `ResponseLocalEnvironment object { type }`
- 表示使用本地环境执行 shell 操作。
+ 表示使用本地环境来执行 shell 操作。
- `type: "local"`
@@ -7020,7 +7022,7 @@
- `ResponseContainerReference object { container_id, type }`
- 表示使用 /v1/containers 创建的容器。
+ 表示通过 /v1/containers 创建的容器。
- `container_id: string`
@@ -7032,7 +7034,7 @@
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态。可选值之一: `in_progress`, `completed`,或 `incomplete`.
+ shell 调用的状态。取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -7042,7 +7044,7 @@
- `type: "shell_call"`
- 该项的类型。始终为 `shell_call`.
+ 项的类型,始终为 `shell_call`.
- `"shell_call"`
@@ -7068,7 +7070,7 @@
- `created_by: optional string`
- 创建此工具调用的实体的 ID。
+ 创建此工具调用的实体 ID。
- `ShellCallOutput object { id, call_id, max_output_length, 5 more }`
@@ -7084,7 +7086,7 @@
- `max_output_length: number or null`
- shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起传回。
+ shell 命令输出的最大长度。该值由模型生成,并应与原始输出一起回传。
- `output: array of object { outcome, stderr, stdout, created_by }`
@@ -7092,11 +7094,11 @@
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的退出结果(带退出码)或超时结果之一。
+ 表示 shell 调用输出块的退出结果(含退出码)或超时结果。
- `Timeout object { type }`
- 表示 shell 调用超出了其配置的时间限制。
+ 表示该 shell 调用超出了其配置的时间限制。
- `type: "timeout"`
@@ -7120,19 +7122,19 @@
- `stderr: string`
- 已捕获的标准错误输出。
+ 捕获到的标准错误输出。
- `stdout: string`
- 已捕获的标准输出。
+ 捕获到的标准输出。
- `created_by: optional string`
- 创建该条目的参与方的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`,或 `incomplete`.
+ shell 调用输出的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -7168,7 +7170,7 @@
- `created_by: optional string`
- 创建该条目的参与方的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -7176,7 +7178,7 @@
- `id: string`
- apply patch 工具调用的唯一 ID。当该条目通过 API 返回时填充。
+ apply patch 工具调用的唯一 ID。通过 API 返回该项时会填充此字段。
- `call_id: string`
@@ -7196,11 +7198,11 @@
- `path: string`
- 要创建的文件的路径。
+ 要创建文件的路径。
- `type: "create_file"`
- 使用提供的差异创建一个新文件。
+ 使用提供的差异创建新文件。
- `"create_file"`
@@ -7210,7 +7212,7 @@
- `path: string`
- 要删除的文件的路径。
+ 要删除文件的路径。
- `type: "delete_file"`
@@ -7228,7 +7230,7 @@
- `path: string`
- 要更新的文件的路径。
+ 要更新文件的路径。
- `type: "update_file"`
@@ -7238,7 +7240,7 @@
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。值为以下之一: `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -7246,7 +7248,7 @@
- `type: "apply_patch_call"`
- 该项的类型。始终为 `apply_patch_call`.
+ 项的类型,始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -7272,15 +7274,15 @@
- `created_by: optional string`
- 创建此工具调用的实体的 ID。
+ 创建此工具调用的实体 ID。
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply patch 工具调用发出的输出。
+ apply patch 工具调用产生的输出。
- `id: string`
- apply patch 工具调用输出的唯一 ID。当该条目通过 API 返回时填充。
+ apply patch 工具调用输出的唯一 ID。通过 API 返回该项时会填充此字段。
- `call_id: string`
@@ -7288,7 +7290,7 @@
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。值为以下之一: `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
- `"completed"`
@@ -7296,7 +7298,7 @@
- `type: "apply_patch_call_output"`
- 该项的类型。始终为 `apply_patch_call_output`.
+ 项的类型,始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -7322,7 +7324,7 @@
- `created_by: optional string`
- 创建此工具调用输出的实体 ID。
+ 创建此工具调出输出的实体 ID。
- `output: optional string or null`
@@ -7334,11 +7336,11 @@
- `id: string`
- 该工具调用的唯一 ID。
+ 工具调用的唯一 ID。
- `arguments: string`
- 传递给工具的参数的 JSON 字符串。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
@@ -7350,18 +7352,18 @@
- `type: "mcp_call"`
- 该项的类型。始终为 `mcp_call`.
+ 项的类型,始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` input 中传入该值以批准或拒绝对应的工具调用。
- `error: optional McpToolCallError or null`
- 工具调用的错误(如果有)。
+ 工具调用产生的错误(若有)。
- `output: optional string or null`
@@ -7369,7 +7371,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
+ 工具调用的状态,取值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -7383,11 +7385,11 @@
- `McpListTools object { id, server_label, tools, 2 more }`
- MCP 服务器上可用工具的列表。
+ MCP 服务器上可用的工具列表。
- `id: string`
- 该列表的唯一 ID。
+ 列表的唯一 ID。
- `server_label: string`
@@ -7403,25 +7405,25 @@
- `name: string`
- 该工具的名称。
+ 工具的名称。
- `annotations: optional unknown or null`
- 有关该工具的其他注释。
+ 关于该工具的附加注解。
- `description: optional string or null`
- 该工具的描述。
+ 工具的描述。
- `type: "mcp_list_tools"`
- 该项的类型。始终为 `mcp_list_tools`.
+ 项的类型,始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具,则返回错误消息。
+ 如果服务器无法列出工具时的错误信息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
@@ -7445,7 +7447,7 @@
- `type: "mcp_approval_request"`
- 该项的类型。始终为 `mcp_approval_request`.
+ 项的类型,始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
@@ -7455,25 +7457,25 @@
- `id: string`
- 审批响应的唯一 ID。
+ 审批响应的唯一 ID
- `approval_request_id: string`
- 正在响应的审批请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 该请求是否已获批准。
+ 请求是否已批准。
- `type: "mcp_approval_response"`
- 该项的类型。始终为 `mcp_approval_response`.
+ 项的类型,始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
- `reason: optional string or null`
- 作出该决定的可选原因。
+ 可选的决策原因。
- `CustomToolCall object { call_id, input, name, 4 more }`
@@ -7485,7 +7487,7 @@
- `input: string`
- 由模型生成的自定义工具调用的输入。
+ 模型为自定义工具调用生成的输入。
- `name: string`
@@ -7499,7 +7501,7 @@
- `id: optional string`
- OpenAI 平台上此自定义工具调用的唯一 ID。
+ 在 OpenAI 平台中自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -7529,16 +7531,16 @@
- `id: string`
- 自定义工具调用输出项的唯一 ID。
+ 自定义工具调出输出项的唯一 ID。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
由你的代码生成的自定义工具调用的输出。
- 可以是字符串或输出内容列表。
+ 可以是字符串或输出内容的列表。
- `StringOutput = string`
@@ -7554,15 +7556,15 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
+ 发送到模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
- 发送给模型的文件输入。
+ 传递给模型的文件输入。
- `status: "in_progress" or "completed" or "incomplete"`
- 该条目的状态。值为 `in_progress`, `completed`,或
+ 项目的状态。取值之一为 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -7573,7 +7575,7 @@
- `type: "custom_tool_call_output"`
- 自定义工具调用输出的类型。始终为 `custom_tool_call_output`.
+ 自定义工具调用输出的类型,始终为 `custom_tool_call_output`.
- `"custom_tool_call_output"`
@@ -7603,7 +7605,7 @@
- `created_by: optional string`
- 创建该条目的参与方的标识符。
+ 创建该条目的参与者的标识符。
- `parallel_tool_calls: boolean`
@@ -7611,13 +7613,13 @@
- `temperature: number or null`
- 使用的采样温度,介于 0 和 2 之间。较高的值(例如 0.8)会使输出更加随机,而较低的值(例如 0.2)会使输出更加聚焦和确定。
- 我们通常建议更改此设置或 `top_p` ,但不要同时更改两者。
+ 使用的采样温度,介于 0 到 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使其更加聚焦和确定。
+ 我们通常建议调整此项或 `top_p` 但不要同时调整两者。
- `tool_choice: ToolChoiceOptions or ToolChoiceAllowed or ToolChoiceTypes or 6 more`
模型在生成时应如何选择要使用的工具
- 响应。请参阅 `tools` 参数以了解如何指定要使用的工具
+ 响应时使用的工具。请参阅 `tools` 参数以了解如何指定可用的工具
模型可以调用。
- `ToolChoiceOptions = "none" or "auto" or "required"`
@@ -7645,10 +7647,10 @@
将模型可用的工具限制为预定义集合。
- `auto` 允许模型从允许的工具中选择并生成一条
+ `auto` 允许模型从允许的工具中进行选择并生成一条
消息。
- `required` 要求模型调用允许的工具中的一个或多个。
+ `required` 要求模型调用一个或多个允许的工具。
- `"auto"`
@@ -7656,7 +7658,7 @@
- `tools: array of map[unknown]`
- 允许模型调用的工具定义列表。
+ 模型应允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -7676,7 +7678,7 @@
- `ToolChoiceTypes object { type }`
- 指示模型应使用内置工具生成响应。
+ 指示模型应使用内置工具来生成响应。
[了解有关内置工具的更多信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
@@ -7684,7 +7686,7 @@
模型应使用的 托管工具 类型。了解有关
[内置工具](/docs/guides/tools).
- 允许的值为:
+ 允许的取值为:
- `file_search`
- `web_search_preview`
@@ -7726,11 +7728,11 @@
- `ToolChoiceMcp object { server_label, type, name }`
- 使用此选项可以强制模型调用远程 MCP 服务器上的特定工具。
+ 使用此选项可强制模型调用远程 MCP 服务器上的特定工具。
- `server_label: string`
- 要使用的 MCP 服务器的标签。
+ 要使用的 MCP 服务器的名称。
- `type: "mcp"`
@@ -7740,11 +7742,11 @@
- `name: optional string or null`
- 要在服务器上调用的工具名称。
+ 要在服务器上调用的工具的名称。
- `ToolChoiceCustom object { name, type }`
- 使用此选项可以强制模型调用特定的自定义工具。
+ 使用此选项可强制模型调用特定的自定义工具。
- `name: string`
@@ -7793,20 +7795,20 @@
- **内置工具**:由 OpenAI 提供的工具,用于扩展
模型的能力,例如 [网页搜索](/docs/guides/tools-web-search)
- 或 [文件搜索](/docs/guides/tools-file-search)。了解有关
+ 或 [文件搜索](/docs/guides/tools-file-search)。详细了解
[内置工具](/docs/guides/tools).
- - **MCP Tools**: 通过自定义 MCP 服务器与第三方系统集成
- 或 Google Drive、SharePoint 等预定义连接器。了解有关
- [MCP Tools](/docs/guides/tools-connectors-mcp).
- - **Function calls (custom tools)**: 由你定义的函数,
+ - **MCP 工具**:通过自定义 MCP 服务器与第三方系统集成
+ 或预定义连接器(例如 Google Drive 和 SharePoint)集成。了解更多关于
+ [MCP 工具](/docs/guides/tools-connectors-mcp).
+ - **函数调用(自定义工具)**:由你定义的函数,
使模型能够使用强类型参数调用你自己的代码
- 并返回输出。了解有关
- [function calling](/docs/guides/function-calling)。你也可以使用
+ 并获得输出。了解更多关于
+ [函数调用](/docs/guides/function-calling)。你还可以使用
自定义工具来调用你自己的代码。
- `Function object { name, parameters, strict, 5 more }`
- 在你自己的代码中定义一个可供模型选择的函数。了解更多关于 [function calling](https://platform.openai.com/docs/guides/function-calling).
+ 在你自己的代码中定义一个模型可以选择调用的函数。了解更多信息 [函数调用](https://platform.openai.com/docs/guides/function-calling).
- `name: string`
@@ -7822,7 +7824,7 @@
- `type: "function"`
- 函数工具的类型,恒为 `function`.
+ 函数工具的类型,始终为 `function`.
- `"function"`
@@ -7836,7 +7838,7 @@
- `defer_loading: optional boolean`
- 该函数是否被延迟加载,并通过工具搜索加载。
+ 此函数是否延迟加载并通过工具搜索载入。
- `description: optional string or null`
@@ -7844,37 +7846,37 @@
- `output_schema: optional map[unknown] or null`
- 描述该函数在字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 用于描述该函数的字符串输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 从已上传文件中搜索相关内容的工具。详细了解 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 用于从已上传文件中搜索相关内容的一款工具。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索 工具的类型,恒为 `file_search`.
+ 文件搜索工具的类型,始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的筛选条件。
+ 要应用的筛选器。
- `ComparisonFilter object { key, type, value }`
- 用于将指定属性键与给定值按定义比较运算进行比较的筛选条件。
+ 用于通过已定义的比较运算将指定属性键与给定值进行比较的筛选器。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用 `and` 或 `or`.
- `max_num_results: optional number`
- 返回结果的最大数量。该数量应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -7882,15 +7884,15 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 用于在启用混合搜索时,控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
+ 在启用混合搜索时,用于控制互逆排名融合中语义嵌入匹配与稀疏关键词匹配平衡的权重。
- `embedding_weight: number`
- 嵌入在倒数排名融合中的权重。
+ 互逆排名融合中嵌入的权重。
- `text_weight: number`
- 文本在倒数排名融合中的权重。
+ 互逆排名融合中文本的权重。
- `ranker: optional "auto" or "default-2024-11-15"`
@@ -7902,21 +7904,21 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,介于 0 到 1 之间。越接近 1,尝试返回的结果越相关,但返回的结果数量可能更少。
+ 文件搜索的分数阈值,介于 0 到 1 之间。越接近 1 的数值会尝试仅返回最相关的结果,但可能返回更少的结果。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
- computer 工具的类型,始终为 `computer`.
+ 计算机工具的类型。始终为 `computer`.
- `"computer"`
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -7948,12 +7950,12 @@
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 通过互联网搜索与提示相关的来源。了解更多关于
+ 搜索互联网以查找与提示词相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索工具的类型。取值为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型。取值之一为 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -7961,7 +7963,7 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 访问实时互联网。省略时默认为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索 进行实时联网访问。省略时默认为 true。当设为 false 时,网页搜索工具将以离线/仅缓存模式运行,并且不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
@@ -7969,14 +7971,14 @@
- `allowed_domains: optional array of string or null`
- 允许搜索的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 搜索允许使用的域名。如果未提供,则允许所有域名。
+ 所提供域名的子域名同样被允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指导。取值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 搜索所用上下文窗口空间的高层级使用指导,取值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -7990,11 +7992,11 @@
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如 `San Francisco`.
+ 用于用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 用户的两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 表示用户所在国家/地区,例如。 `US`.
- `region: optional string or null`
@@ -8002,22 +8004,22 @@
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如。 `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 表示用户所在国家/地区,例如。 `America/Los_Angeles`.
- `type: optional "approximate"`
- 位置近似值的类型。始终为 `approximate`.
+ 位置近似类型。始终为 `approximate`.
- `"approximate"`
- `Mcp object { server_label, type, allowed_callers, 9 more }`
通过远程 Model Context Protocol
- (MCP) 服务器为模型提供对其他工具的访问。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
+ (MCP) 服务器为模型提供对其他工具的访问。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中识别它。
+ 此 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -8039,32 +8041,32 @@
- `McpAllowedTools = array of string`
- 允许的工具名称的字符串数组
+ 包含允许的工具名称的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的过滤对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此过滤器。
+ 指示工具是否会修改数据,还是属于只读。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 它就会匹配此过滤器。
- `tool_names: optional array of string`
- 允许的工具名称列表。
+ 允许使用的工具名称列表。
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,配合自定义 MCP
- 服务器 URL 或服务连接器使用。你的应用
- 必须处理 OAuth 授权流程并在此处提供令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,可与自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
+ 程序必须自行处理 OAuth 授权流程,并在此处提供该令牌。
+ 必须自行处理 OAuth 授权流程,并在此处提供该令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的连接器。其中之一
- `server_url`, `connector_id`,或 `tunnel_id` 必须提供。详细了解
+ 服务连接器的标识符,例如 ChatGPT 中提供的那些连接器。其中之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。了解更多
关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
当前支持 `connector_id` 的值为:
@@ -8096,54 +8098,54 @@
- `defer_loading: optional boolean`
- 此 MCP 工具是否被延迟,并通过工具搜索发现。
+ 该 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务器的可选 HTTP 标头。用于身份验证
+ 发送到 MCP 服务器的可选 HTTP 头。可用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务器的哪些工具需要审批。
+ 指定 MCP 服务器中哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务器的哪些工具需要审批。可以是
- `always`, `never`,或与需要审批的工具关联的过滤对象
- 。
+ 指定 MCP 服务器中哪些工具需要审批。可以是
+ `always`, `never`,也可以是与工具关联的过滤器对象
+ 用于指定需要审批的工具。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的过滤对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此过滤器。
+ 指示工具是否会修改数据,还是属于只读。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 它就会匹配此过滤器。
- `tool_names: optional array of string`
- 允许的工具名称列表。
+ 允许使用的工具名称列表。
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的过滤对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否修改数据或为只读。如果某个
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此过滤器。
+ 指示工具是否会修改数据,还是属于只读。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ 它就会匹配此过滤器。
- `tool_names: optional array of string`
- 允许的工具名称列表。
+ 允许使用的工具名称列表。
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定单个审批策略。其一为 `always` 或
+ 为所有工具指定统一的审批策略。可选值为 `always` 或
`never`. 当设置为 `always`,时,所有工具都需要审批。当
设置为 `never`,时,所有工具都不需要审批。
@@ -8157,22 +8159,22 @@
- `server_url: optional string`
- MCP 服务器的 URL。必须提供 `server_url`, `connector_id`,或
- `tunnel_id` 之一。
+ MCP 服务器的 URL。以下其中之一 `server_url`, `connector_id`,或
+ `tunnel_id` 必须提供。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的 Secure MCP Tunnel ID。必须提供
- `server_url`, `connector_id`,或 `tunnel_id` 之一。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。以下其中之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 用于运行 Python 代码以帮助生成对提示词回应的工具。
+ 一个运行 Python 代码以帮助生成对提示词回复的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID,也可以是指定可供你代码使用的已上传文件 ID 的对象,以及一个
- 用于指定可供你代码使用的已上传文件 ID 的对象,以及一个
+ 代码解释器容器。可以是容器 ID 或指定上传文件 ID 的对象,以便你的代码可访问这些文件,以及一个
+ 指定上传文件 ID 以便你的代码可访问,并附带一个
可选的 `memory_limit` 设置。
- `string`
@@ -8181,7 +8183,7 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要对其运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定要在其上运行代码的文件 ID。
- `type: "auto"`
@@ -8191,7 +8193,7 @@
- `file_ids: optional array of string`
- 可供你代码使用的已上传文件的可选列表。
+ 可供你的代码使用的上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -8215,7 +8217,7 @@
- `type: "code_interpreter"`
- 代码解释器工具的类型。始终为 `code_interpreter`.
+ 代码解释器工具的类型。始终 `code_interpreter`.
- `"code_interpreter"`
@@ -8231,7 +8233,7 @@
- `type: "programmatic_tool_calling"`
- 该工具的类型。始终为 `programmatic_tool_calling`.
+ 工具的类型。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
@@ -8241,7 +8243,7 @@
- `type: "image_generation"`
- 图像生成工具的类型。始终为 `image_generation`.
+ 图像生成工具的类型。始终 `image_generation`.
- `"image_generation"`
@@ -8258,7 +8260,7 @@
- `background: optional "transparent" or "opaque" or "auto"`
设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。透明背景适用于
+ `opaque`,或 `auto`。之一。透明背景可用于
支持的 GPT Image 模型。对于 `gpt-image-2` 和
`gpt-image-2-2026-04-21`,该支持处于预览阶段。使用
`transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
@@ -8271,7 +8273,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需的投入程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持,不受 `gpt-image-1-mini`。支持 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。该参数仅对 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持,不支持 `gpt-image-1-mini`. 支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -8279,20 +8281,20 @@
- `input_image_mask: optional object { file_id, image_url }`
- 用于修复(inpainting)的可选遮罩。包含 `image_url`
- (string,可选)和 `file_id` (string,可选)。
+ 用于局部重绘的可选蒙版。包含 `image_url`
+ (字符串,可选)和 `file_id` (字符串,可选)。
- `file_id: optional string`
- 遮罩图像的文件 ID。
+ 蒙版图像的文件 ID。
- `image_url: optional string`
- Base64 编码的遮罩图像。
+ Base64 编码的蒙版图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
- 要使用的图像生成模型,取值为以下之一: `gpt-image-1`,
+ 要使用的图像生成模型。其值之一为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
`gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
@@ -8301,7 +8303,7 @@
- `"gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
- 要使用的图像生成模型,取值为以下之一: `gpt-image-1`,
+ 要使用的图像生成模型。其值之一为 `gpt-image-1`,
`gpt-image-1-mini`, `gpt-image-1.5`, `gpt-image-2`,
`gpt-image-2-2026-04-21`,或 `chatgpt-image-latest`。默认值:
`gpt-image-1`.
@@ -8330,7 +8332,7 @@
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式,取值为以下之一: `png`, `webp`,或
+ 生成图像的输出格式。其值之一为 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -8341,11 +8343,11 @@
- `partial_images: optional number`
- 在流式模式下要生成的中间图像数量,范围为 0(默认值)到 3。
+ 在流式模式下生成的部分图像数量,范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
- 生成图像的质量,取值为以下之一: `low`, `medium`, `high`,
+ 生成图像的质量。其值之一为 `low`, `medium`, `high`,
或 `auto`。默认值: `auto`.
- `"low"`
@@ -8358,13 +8360,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率属于实验性功能,且最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素与边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,使用其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,采用 `WIDTHxHEIGHT` 字符串形式,例如 `1536x864`。宽度和高度必须均为 16 的倍数,且所请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边数限制。GPT 图像模型支持的标准尺寸 `1024x1024`, `1536x1024`,以及 `1024x1536` 也由 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以 `WIDTHxHEIGHT` 字符串形式指定的任意分辨率,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率属于实验性功能,且最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素与边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,使用其中之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,采用 `WIDTHxHEIGHT` 字符串形式,例如 `1536x864`。宽度和高度必须均为 16 的倍数,且所请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边数限制。GPT 图像模型支持的标准尺寸 `1024x1024`, `1536x1024`,以及 `1024x1536` 也由 GPT 图像模型支持; `auto` 适用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,请使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -8416,7 +8418,7 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中识别它。
+ 自定义工具的名称,用于在工具调用中标识它。
- `type: "custom"`
@@ -8434,7 +8436,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具,并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -8442,7 +8444,7 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `Namespace object { description, name, tools, type }`
@@ -8458,7 +8460,7 @@
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 该命名空间内可用的函数/自定义工具。
+ 此命名空间内可用的函数/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -8478,19 +8480,19 @@
- `defer_loading: optional boolean`
- 该函数是否应被延迟并通过工具搜索被发现。
+ 此函数是否应被延迟,并通过工具搜索被发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 描述该函数工具字符串输出中所编码 JSON 值的 JSON Schema。此项不描述 content 数组形式的输出。
+ 用于描述此函数工具字符串输出中所编码 JSON 值的 JSON Schema。该描述不适用于 content-array 输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否启用严格的参数校验。若省略,当 响应接口 在 schema 兼容时会尝试使用严格校验,否则回退到非严格校验。
+ 是否启用严格的参数校验。如果省略,Responses 会在 schema 兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -8498,7 +8500,7 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中识别它。
+ 自定义工具的名称,用于在工具调用中标识它。
- `type: "custom"`
@@ -8516,7 +8518,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具,并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -8524,31 +8526,31 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `type: "namespace"`
- 该工具的类型。始终为 `namespace`.
+ 工具的类型。始终 `namespace`.
- `"namespace"`
- `ToolSearch object { type, description, execution, parameters }`
- 针对延迟工具的托管或 BYOT 工具搜索配置。
+ 用于延迟工具的托管或 BYOT 工具搜索配置。
- `type: "tool_search"`
- 该工具的类型。始终为 `tool_search`.
+ 工具的类型。始终 `tool_search`.
- `"tool_search"`
- `description: optional string or null`
- 展示给模型、用于客户端执行的工具搜索工具的描述。
+ 在客户端执行的工具搜索工具中向模型展示的描述。
- `execution: optional "server" or "client"`
- 工具搜索是由服务端还是由客户端执行。
+ 工具搜索由服务端执行还是由客户端执行。
- `"server"`
@@ -8564,7 +8566,7 @@
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索工具的类型。取值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型。取值之一为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -8578,7 +8580,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指导。取值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 搜索所用上下文窗口空间的高层级使用指导,取值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -8588,21 +8590,21 @@
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户所在的位置。
+ 用户的位置。
- `type: "approximate"`
- 位置近似值的类型。始终为 `approximate`.
+ 位置近似类型。始终为 `approximate`.
- `"approximate"`
- `city: optional string or null`
- 用户所在城市的自由文本输入,例如 `San Francisco`.
+ 用于用户所在城市的自由文本输入,例如 `San Francisco`.
- `country: optional string or null`
- 用户的两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) 表示用户所在国家/地区,例如。 `US`.
- `region: optional string or null`
@@ -8610,7 +8612,7 @@
- `timezone: optional string or null`
- 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) ,例如。 `America/Los_Angeles`.
+ 该 [IANA timezone](https://timeapi.io/documentation/iana-timezones) 表示用户所在国家/地区,例如。 `America/Los_Angeles`.
- `ApplyPatch object { type, allowed_callers }`
@@ -8618,7 +8620,7 @@
- `type: "apply_patch"`
- 该工具的类型。始终为 `apply_patch`.
+ 工具的类型。始终 `apply_patch`.
- `"apply_patch"`
@@ -8632,12 +8634,12 @@
- `top_p: number or null`
- 一种温度采样的替代方法,称为核采样,
- 模型只考虑 top_p 概率质量所对应的 token 结果。
- 因此 0.1 表示只考虑组成前 10% 概率质量的 token。
- 。
+ 另一种采用温度采样的替代方法,称为核采样,
+ 模型仅考虑 top_p 概率质量范围内的标记结果。
+ 因此 0.1 表示仅考虑构成前 10% 概率质量的标记。
+ 采样时所使用的标记。
- 我们通常建议更改此设置或 `temperature` ,但不要同时更改两者。
+ 我们通常建议调整此项或 `temperature` 但不要同时调整两者。
- `background: optional boolean or null`
@@ -8651,27 +8653,27 @@
- `conversation: optional object { id } or null`
- 此 Response 所属的对话。该 Response 的输入项和输出项已自动添加到此对话中。
+ 此响应所属的对话。此次响应中的输入项和输出项已自动添加到此对话中。
- `id: string`
- 与此 Response 关联的对话的唯一 ID。
+ 与此响应关联的对话的唯一 ID。
- `max_output_tokens: optional number or null`
- 响应可生成 token 数量的上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
+ 可在响应中生成的最大 token 数量上限,包括可见输出 token 和 [推理 token](/docs/guides/reasoning).
- `max_tool_calls: optional number or null`
- 响应中可处理的内置工具调用总次数上限。此上限适用于所有内置工具调用,而非单个工具。模型任何进一步调用工具的尝试都将被忽略。
+ 可在一次响应中处理的内置工具的最大调用总数。该上限适用于所有内置工具调用,而不是按单个工具计算。模型发起的任何后续工具调用尝试都将被忽略。
- `moderation: optional object { input, output } or null`
- 响应输入和输出的审核结果(如果请求了被审核的补全)。
+ 如果请求了受审核补全,则为响应输入和输出的审核结果。
- `input: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输入的审核结果。
+ 对响应输入的审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
@@ -8679,11 +8681,11 @@
- `categories: map[boolean]`
- 一个将审核类别映射到布尔值的字典,如果输入在该类别下被标记则为 True。
+ 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所反映的输入模态。
+ 反映每个类别得分的输入模态。
- `"text"`
@@ -8691,7 +8693,7 @@
- `category_scores: map[number]`
- 一个将审核类别映射到分数的字典。
+ 从审核类别到得分的字典。
- `flagged: boolean`
@@ -8703,7 +8705,7 @@
- `type: "moderation_result"`
- 对象类型,始终为 `moderation_result` (针对成功的审核结果)。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
@@ -8721,13 +8723,13 @@
- `type: "error"`
- 对象类型,始终为 `error` (针对审核失败)。
+ 对象类型,对于成功的审核结果始终为 `error` (用于审核失败)。
- `"error"`
- `output: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- 响应输出的审核结果。
+ 对响应输出的审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
@@ -8735,11 +8737,11 @@
- `categories: map[boolean]`
- 一个将审核类别映射到布尔值的字典,如果输入在该类别下被标记则为 True。
+ 从审核类别到布尔值的字典,如果输入被该类别标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所反映的输入模态。
+ 反映每个类别得分的输入模态。
- `"text"`
@@ -8747,7 +8749,7 @@
- `category_scores: map[number]`
- 一个将审核类别映射到分数的字典。
+ 从审核类别到得分的字典。
- `flagged: boolean`
@@ -8759,7 +8761,7 @@
- `type: "moderation_result"`
- 对象类型,始终为 `moderation_result` (针对成功的审核结果)。
+ 对象类型,对于成功的审核结果始终为 `moderation_result` 。
- `"moderation_result"`
@@ -8777,21 +8779,21 @@
- `type: "error"`
- 对象类型,始终为 `error` (针对审核失败)。
+ 对象类型,对于成功的审核结果始终为 `error` (用于审核失败)。
- `"error"`
- `output_text: optional string or null`
- SDK 专属的便捷属性,包含汇总后的文本输出
- 来自所有 `output_text` items in the `output` 数组中的项(如果有的话)。
+ SDK 专属便捷属性,包含所有以下来源的聚合文本输出:
+ 来自所有 `output_text` 数组中的项(如果有的话) `output` 。
在 Python 和 JavaScript SDK 中受支持。
- `previous_response_id: optional string or null`
- 模型上一次响应的唯一 ID。使用它可以
+ 上一条针对该模型的响应的唯一 ID。使用此字段可以
创建多轮对话。详细了解
- [conversation state](/docs/guides/conversation-state)。不能与 `conversation`.
+ [对话状态](/docs/guides/conversation-state)。无法与 `conversation`.
- `prompt: optional ResponsePrompt or null`
@@ -8804,9 +8806,9 @@
- `variables: optional map[string or ResponseInputText or ResponseInputImage or ResponseInputFile] or null`
- 用于在你的
- 提示中替换变量的值映射。替换值可以是字符串,也可以是其他
- 响应输入类型,例如图像或文件。
+ 要在你的
+ prompt。替换值可以是字符串,也可以是其他
+ Response 输入类型,例如图像或文件。
- `string`
@@ -8816,11 +8818,11 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
+ 发送到模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
- 发送给模型的文件输入。
+ 传递给模型的文件输入。
- `version: optional string or null`
@@ -8828,11 +8830,11 @@
- `prompt_cache_key: optional string or null`
- 由 OpenAI 用于缓存相似请求的响应,以优化你的缓存命中率。取代 `user` 字段。 [了解更多](/docs/guides/prompt-caching).
+ 由 OpenAI 用于缓存相似请求的响应,以优化你的缓存命中率。取代了 `user` 字段。 [了解更多](/docs/guides/prompt-caching).
- `prompt_cache_options: optional object { mode, ttl }`
- 应用于该响应的提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。
+ 应用于响应的提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。
- `mode: "implicit" or "explicit"`
@@ -8850,15 +8852,15 @@
- `prompt_cache_retention: optional "in_memory" or "24h" or null`
- 已弃用。请使用 `prompt_cache_options.ttl` 。
+ 已弃用。使用 `prompt_cache_options.ttl` instead.
- 提示缓存的保留策略。设置为 `24h` 可启用扩展提示缓存,使缓存的前缀保持更长时间,最长可达 24 小时。 [了解更多](/docs/guides/prompt-caching#prompt-cache-retention).
+ prompt cache 的保留策略。设置为 `24h` 以启用扩展 prompt 缓存,使缓存的前缀保持更长时间的活跃状态,最长可达 24 小时。 [了解更多](/docs/guides/prompt-caching#prompt-cache-retention).
该字段表示最大保留策略,而
- `prompt_cache_options.ttl` 表示最短缓存生命周期。这两个
+ `prompt_cache_options.ttl` 表示最小缓存生命周期。两个
字段相互独立,不会相互影响。
- 对于 `gpt-5.5`, `gpt-5.5-pro`,以及未来模型,仅 `24h` 。
+ For `gpt-5.5`, `gpt-5.5-pro`,以及未来的模型,仅 `24h` 。
- 对于同时支持两者的较旧模型 `in_memory` 和 `24h`,默认值取决于你所在组织的数据保留策略:
+ 对于同时支持这两者的较旧模型 `in_memory` 和 `24h`,默认值取决于你所在组织的数据保留策略:
- 未启用 ZDR 的组织默认使用 `24h`.
- 已启用 ZDR 的组织默认使用 `in_memory` 当 `prompt_cache_retention` 未指定时。
@@ -8869,18 +8871,18 @@
- `reasoning: optional Reasoning or null`
- 的配置选项
+ 针对以下内容的配置选项
[推理模型](https://platform.openai.com/docs/guides/reasoning).
- `context: optional "auto" or "current_turn" or "all_turns" or null`
- 控制在后续轮次中哪些推理项会被渲染回模型。
- 如果省略或设置为 `auto`,模型将自行决定上下文模式。
- `gpt-5.6` 模型系列默认为 `all_turns`;早期模型默认为
+ 控制哪些推理项会在后续轮次中被传回给模型。
+ 如果省略或设置为 `auto`,则由模型决定上下文模式。该
+ `gpt-5.6` 模型族默认使用 `all_turns`;旧模型默认为
`current_turn`.
- 在响应中返回时,这是该响应所使用的有效推理上下文模式
- 用于该响应。
+ 在响应中返回时,表示该响应所用的实际推理上下文模式
+ 。
- `"auto"`
@@ -8890,13 +8892,13 @@
- `effort: optional ReasoningEffort or null`
- 约束推理模型在推理上的投入程度。当前支持
- 的取值包括 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
- 降低推理投入程度可以让响应更快,并减少响应中用于推理的
- token 数量。并非所有推理模型都支持每个
- 取值。请参阅
+ 限制推理模型在推理上的投入程度。当前支持
+ 的取值包括 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,以及 `max`.
+ 降低推理投入程度可使响应更快,并减少响应中推理所消耗的令牌数。并非所有推理模型都支持
+ 每个取值。模型的具体支持情况请参阅
+ 推理指南
[推理指南](https://platform.openai.com/docs/guides/reasoning)
- 了解特定模型的支持情况。
+ 。
- `"none"`
@@ -8914,11 +8916,11 @@
- `generate_summary: optional "auto" or "concise" or "detailed" or null`
- **已弃用:** 请使用 `summary` 。
+ **已弃用:** 使用 `summary` instead.
- 模型执行推理的摘要。这可以
- 有助于调试和理解模型的推理过程。
- 以下之一 `auto`, `concise`,或 `detailed`.
+ 模型执行的推理摘要。此字段可用于
+ 调试和理解模型的推理过程。
+ 其值之一为 `auto`, `concise`,或 `detailed`.
- `"auto"`
@@ -8930,7 +8932,7 @@
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 当在响应中返回时,该字段表示有效的执行模式。
- `string`
@@ -8938,7 +8940,7 @@
控制请求的推理执行模式。
- 在响应中返回时,这是有效的执行模式。
+ 当在响应中返回时,该字段表示有效的执行模式。
- `"standard"`
@@ -8946,11 +8948,11 @@
- `summary: optional "auto" or "concise" or "detailed" or null`
- 模型执行推理的摘要。这可以
- 有助于调试和理解模型的推理过程。
- 以下之一 `auto`, `concise`,或 `detailed`.
+ 模型执行的推理摘要。此字段可用于
+ 调试和理解模型的推理过程。
+ 其值之一为 `auto`, `concise`,或 `detailed`.
- `concise` 受支持 `computer-use-preview` 模型以及之后的所有推理模型 `gpt-5`.
+ `concise` 在以下模型中受支持: `computer-use-preview` 模型以及之后发布的所有推理模型 `gpt-5`.
- `"auto"`
@@ -8960,21 +8962,21 @@
- `safety_identifier: optional string or null`
- 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用策略的应用程序用户。
- ID 应为字符串,用于唯一标识每个用户,最大长度为 64 个字符。建议对其用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份信息。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
+ 用于帮助检测可能违反 OpenAI 使用政策的应用用户的稳定标识符。
+ ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。建议对其用户名或电子邮件地址进行哈希处理,以避免向我们发送任何可识别信息。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
- `service_tier: optional ServiceTier or null`
- 指定用于处理该请求的处理类型。
+ 指定用于服务该请求的处理类型。
- - 如果设置为 'auto',则该请求将使用 Project 设置中配置的服务层级进行处理。除非另行配置,否则 Project 将使用 'default'。
- - 如果设置为 'default',则该请求将按所选模型的标准定价和性能进行处理。
+ - 如果设置为 'auto',则该请求将使用项目设置中配置的服务层级进行处理。除非另有配置,否则项目将使用 'default'。
+ - 如果设置为 'default',则该请求将按照所选模型的标准定价和性能进行处理。
- 如果设置为 '[flex](/docs/guides/flex-processing)',则该请求将使用 Flex Processing 服务层级进行处理。
- - 若要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请为 Responses 或 Chat Completions 传入 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你在请求中是否指定 `service_tier=fast` 或 `priority` 。
- - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级提供服务的响应将显示 `service_tier=ultrafast`.
- - 未设置时,默认行为为 'auto'。
+ - 要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 请求中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定了 `service_tier=fast` 或 `priority` 。
+ - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级服务的响应将显示 `service_tier=ultrafast`.
+ - 如果未设置,默认行为为 'auto'。
- 当设置了 `service_tier` 参数时,响应体将包含基于实际用于处理该请求的处理模式所得到的 `service_tier` 值。该响应值可能与参数中设置的值不同。
+ 当设置了 `service_tier` 参数时,响应体将根据实际用于服务该请求的处理模式包含对应的 `service_tier` 值。该响应值可能与参数中设置的值不同。
- `"auto"`
@@ -8992,7 +8994,7 @@
- `status: optional ResponseStatus`
- 响应生成的状态。取值为 `completed`, `failed`,
+ 响应生成的状态。取值之一为 `completed`, `failed`,
`in_progress`, `cancelled`, `queued`,或 `incomplete`.
- `"completed"`
@@ -9010,26 +9012,26 @@
- `text: optional ResponseTextConfig`
模型文本响应的配置选项。可以是纯
- 文本或结构化 JSON 数据。了解更多:
+ 文本,也可以是结构化的 JSON 数据。了解更多:
- - [文本输入和输出](/docs/guides/text)
+ - [文本输入与输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
- `format: optional ResponseFormatTextConfig`
用于指定模型必须输出的格式的对象。
- 配置 `{ "type": "json_schema" }` 可启用结构化输出,
- 从而确保模型匹配你提供的 JSON schema。更多信息请参阅
+ 配置 `{ "type": "json_schema" }` 会启用结构化输出,
+ 确保模型的输出匹配你提供的 JSON schema。详见
[结构化输出指南](/docs/guides/structured-outputs).
- 默认格式为 `{ "type": "text" }` ,不包含其他选项。
+ 默认格式为 `{ "type": "text" }` ,且无其他附加选项。
**不建议用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 会启用较旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法 JSON。对于支持 `json_schema`
- 的模型,建议优先使用它。
+ 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,它
+ 可确保模型生成的消息是合法 JSON。对于支持 `json_schema`
+ 的模型,推荐优先使用。
- `ResponseFormatText object { type }`
@@ -9037,18 +9039,18 @@
- `type: "text"`
- 正在定义的响应格式类型。始终为 `text`.
+ 正在定义的响应格式的类型。始终为 `text`.
- `"text"`
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化 JSON 响应。
- 详细了解 [结构化输出](/docs/guides/structured-outputs).
+ JSON Schema 响应格式。用于生成结构化的 JSON 响应。
+ 了解更多关于 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
- 响应格式的名称。必须为 a-z、A-Z、0-9,或包含
+ 响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
下划线和短横线,最大长度为 64。
- `schema: map[unknown]`
@@ -9058,41 +9060,41 @@
- `type: "json_schema"`
- 正在定义的响应格式类型。始终为 `json_schema`.
+ 正在定义的响应格式的类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
- A description of what the response format is for, used by the model to
- determine how to respond in the format.
+ 响应格式用途的描述,供模型用于
+ 确定如何按该格式进行响应。
- `strict: optional boolean or null`
- Whether to enable strict schema adherence when generating the output.
- If set to true, the model will always follow the exact schema defined
- in the `schema` 字段。仅支持 JSON Schema 的一个子集,
- `strict` : `true`。有关详情,请参阅 [结构化输出
+ 是否在生成输出时启用严格的 schema 遵从。
+ 若设置为 true,模型将始终遵循在
+ 字段中定义的 `schema` 确切 schema。仅支持 JSON Schema 的一个子集,当
+ `strict` 或 `true`。时可用。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较旧的生成 JSON 响应的方式。
- 使用 `json_schema` 推荐用于支持它的模型。注意,
- 在没有系统或用户消息指示的情况下,模型不会生成 JSON,
+ JSON 对象响应格式。一种生成 JSON 响应的较旧方法。
+ 使用 `json_schema` 对支持它的模型是推荐做法。请注意,模型
+ 在没有系统或用户消息指示的情况下不会生成 JSON
。
- `type: "json_object"`
- 正在定义的响应格式类型。始终为 `json_object`.
+ 正在定义的响应格式的类型。始终为 `json_object`.
- `"json_object"`
- `verbosity: optional "low" or "medium" or "high" or null`
- 约束模型响应的详细程度。较低的值将导致
- 更简洁的响应,而较高的值将导致更详细的响应。
- 当前支持的值包括 `low`, `medium`,和 `high`。默认值为
+ 约束模型响应的详细程度。较低的值将产生
+ 更简洁的响应,而较高的值将产生更冗长的响应。
+ 当前支持的值包括 `low`, `medium`,以及 `high`。默认值为
`medium`.
- `"low"`
@@ -9103,8 +9105,8 @@
- `top_logprobs: optional number or null`
- 一个介于 0 到 20 之间的整数,指定在每个 token 位置返回的最可能
- token 的最大数量,每个 token 都附带对应的对数
+ 一个介于 0 到 20 之间的整数,指定在每个 token 位置返回的最多可能性较高的
+ token 数量,每个 token 都附带相应的 log
概率。在某些情况下,返回的 token 数量可能少于
请求的数量。
@@ -9112,10 +9114,10 @@
用于模型响应的截断策略。
- - `auto`:如果此 Response 的输入超出
- 模型的上下文窗口大小,模型将通过从对话开头丢弃条目来截断
- 响应,以适配上下文窗口。
- - `disabled` (默认):如果输入大小将超出模型的上下文窗口
+ - `auto`:如果此 Response 的输入超过
+ 模型的上下文窗口大小,模型将通过丢弃对话开头的项目来截断
+ 响应以适应上下文窗口。
+ - `disabled` (默认):如果输入大小将超过模型的上下文窗口
大小,请求将失败并返回 400 错误。
- `"auto"`
@@ -9124,8 +9126,8 @@
- `usage: optional ResponseUsage`
- 表示 token 使用详情,包括输入 token、输出 token、
- 输出 token 的细分,以及使用的 token 总数。
+ 表示 token 使用情况详细信息,包括输入 token、输出 token、
+ 输出 token 的细分以及所使用的 token 总数。
- `input_tokens: number`
@@ -9150,7 +9152,7 @@
- `output_tokens_details: object { reasoning_tokens }`
- 输出 token 的详细分类统计。
+ 输出 token 的详细分类。
- `reasoning_tokens: number`
@@ -9160,15 +9162,11 @@
使用的 token 总数。
- - `compute_units: optional number or null`
-
- 本次请求的计算单元。当前可用时为 null。
-
- `user: optional string`
- 该字段即将被 `safety_identifier` 和 `prompt_cache_key`。取代。请使用 `prompt_cache_key` 以保持缓存优化效果。
- 最终用户的稳定标识符。
- 用于通过更精细地对相似请求进行分桶来提升缓存命中率,并帮助 OpenAI 检测和防止滥用。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
+ 该字段将被替换为 `safety_identifier` 和 `prompt_cache_key`。请使用 `prompt_cache_key` 代替,以保持缓存优化效果。
+ 终端用户的稳定标识符。
+ 通过更好地对相似请求进行分桶来提升缓存命中率,并帮助 OpenAI 检测和防止滥用。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
### 示例
@@ -9178,7 +9176,7 @@ curl https://api.openai.com/v1/responses/$RESPONSE_ID/cancel \
-H "Authorization: Bearer $OPENAI_API_KEY"
```
-#### 响应
+#### Response
```json
{
@@ -9344,8 +9342,7 @@ curl https://api.openai.com/v1/responses/$RESPONSE_ID/cancel \
"output_tokens_details": {
"reasoning_tokens": 0
},
- "total_tokens": 0,
- "compute_units": 0
+ "total_tokens": 0
},
"user": "user-1234"
}
@@ -9359,7 +9356,7 @@ curl -X POST https://api.openai.com/v1/responses/resp_123/cancel \
-H "Authorization: Bearer $OPENAI_API_KEY"
```
-#### 响应
+#### Response
```json
{
diff --git a/docs/zh/api/reference/resources/responses/methods/compact.md b/docs/zh/api/reference/resources/responses/methods/compact.md
index 1034c3a..05c03c7 100644
--- a/docs/zh/api/reference/resources/responses/methods/compact.md
+++ b/docs/zh/api/reference/resources/responses/methods/compact.md
@@ -1,22 +1,22 @@
-> 如需完整的文档索引,请参阅 [llms.txt](/llms.txt)。可通过在页面 URL 末尾添加 `.md` 来获取文档页面的 Markdown 版本。
+> 如需完整文档索引,请参阅 [llms.txt](/llms.txt)。可通过在页面 URL 末尾追加 `.md` 来获取文档页面的 Markdown 版本。
## 压缩响应
**post** `/responses/compact`
-压缩对话。返回一个压缩后的响应对象。
+压缩一段对话。返回一个压缩后的响应对象。
-了解在何时以及如何压缩长时间运行的对话,请参阅 [对话状态指南](/docs/guides/conversation-state#managing-the-context-window).关于兼容 ZDR 的压缩细节,请参阅 [压缩(高级)](/docs/guides/conversation-state#compaction-advanced).
+了解在 [对话状态指南](/docs/guides/conversation-state#managing-the-context-window)。中何时以及如何压缩长对话。有关兼容 ZDR 的压缩细节,请参阅 [压缩(高级)](/docs/guides/conversation-state#compaction-advanced).
### 请求体参数
- `model: "gpt-5.6-sol" or "gpt-5.6-terra" or "gpt-5.6-luna" or 99 more or string or null`
- 用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI 提供多种具有不同能力、性能特征和价格区间的模型。请参阅 [模型指南](/docs/models) 以浏览和比较可用模型。
+ 用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI 提供多种模型,它们在能力、性能特征和价格上各有不同。请参阅 [模型指南](/docs/models) 以浏览和比较可用的模型。
- `"gpt-5.6-sol" or "gpt-5.6-terra" or "gpt-5.6-luna" or 99 more`
- 用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI 提供多种具有不同能力、性能特征和价格区间的模型。请参阅 [模型指南](/docs/models) 以浏览和比较可用模型。
+ 用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI 提供多种模型,它们在能力、性能特征和价格上各有不同。请参阅 [模型指南](/docs/models) 以浏览和比较可用的模型。
- `"gpt-5.6-sol"`
@@ -234,20 +234,20 @@
- `array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 提供给模型的一个或多个输入项的列表,包含不同的内容类型。
+ 提供给模型的一个或多个输入项列表,包含不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 提供给模型的消息输入,带有表示指令遵循
- 层级的角色。使用 `developer` 或 `system` 角色给出的指令优先级高于使用
- 角色给出的指令。带有 `user` 角色的消息被假定为在之前的
- `assistant` 交互中由模型生成。
- 中由模型生成。
+ 发送给模型的消息输入,其角色指示指令的优先级
+ 层级。使用 `developer` 或 `system` 角色给出的指令优先级高于使用
+ 角色给出的指令。带有 `user` 角色的消息假定为模型在之前的
+ `assistant` 交互中生成的回复。
+ 交互。
- `content: string or ResponseInputMessageContentList`
提供给模型的文本、图像或音频输入,用于生成响应。
- 也可以包含之前的助手响应。
+ 也可以包含之前的助手回复。
- `TextInput = string`
@@ -255,7 +255,7 @@
- `ResponseInputMessageContentList = array of ResponseInputContent`
- 提供给模型的一个或多个输入项的列表,包含不同的内容
+ 提供给模型的一个或多个输入项列表,包含不同的内容
类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
@@ -274,7 +274,7 @@
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承其所在请求的 TTL `prompt_cache_options.ttl`;边界不会按 token 块向下取整。
- `mode: "explicit"`
@@ -284,11 +284,11 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
+ 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- 发送给模型的图像细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -306,15 +306,15 @@
- `file_id: optional string or null`
- 发送给模型的文件的 ID。
+ 要发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图像 URL。可以是完全限定的 URL,也可以是 data URL 中的 base64 编码图像。
+ 要发送给模型的图像的 URL。可以是完全限定的 URL,也可以是 data URL 中的 base64 编码图像。
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承其所在请求的 TTL `prompt_cache_options.ttl`;边界不会按 token 块向下取整。
- `mode: "explicit"`
@@ -334,7 +334,7 @@
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会增加输入 token 用量。使用 `low` 可获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节级别。使用 `auto` 可让系统选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会增加输入 token 的用量。使用 `low` 可使用更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
- `"auto"`
@@ -344,11 +344,11 @@
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- 发送给模型的文件的 ID。
+ 要发送给模型的文件的 ID。
- `file_url: optional string`
@@ -360,7 +360,7 @@
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承其所在请求的 TTL `prompt_cache_options.ttl`;边界不会按 token 块向下取整。
- `mode: "explicit"`
@@ -370,7 +370,7 @@
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色。取值之一为 `user`, `assistant`, `system`,或
+ 消息输入的角色。取值为 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -383,9 +383,9 @@
- `phase: optional "commentary" or "final_answer" or null`
- 将消息标记为 `assistant` 中间评论(`commentary`)或最终回答(`final_answer`).
- 对于类似 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,保留并重新发送
- 阶段到所有助手消息上 —— 丢弃它可能会降低性能。不用于用户消息。
+ 将某条 `assistant` 消息标记为中间评论(`commentary`)或最终回答(`final_answer`).
+ 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
+ 阶段到所有助手消息上——丢弃它可能会降低性能。不用于用户消息。
- `"commentary"`
@@ -399,18 +399,18 @@
- `Message object { content, role, status, type }`
- 提供给模型的消息输入,带有表示指令遵循
- 层级的角色。使用 `developer` 或 `system` 角色给出的指令优先级高于使用
+ 发送给模型的消息输入,其角色指示指令的优先级
+ 层级。使用 `developer` 或 `system` 角色给出的指令优先级高于使用
角色给出的指令。带有 `user` 角色的文本输入。
- `content: ResponseInputMessageContentList`
- 提供给模型的一个或多个输入项的列表,包含不同的内容
+ 提供给模型的一个或多个输入项列表,包含不同的内容
类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色。取值之一为 `user`, `system`,或 `developer`.
+ 消息输入的角色。取值为 `user`, `system`,或 `developer`.
- `"user"`
@@ -420,7 +420,7 @@
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`,或
+ 条目的状态。取值为 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -449,7 +449,7 @@
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型的一条文本输出。
+ 模型输出的文本。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
@@ -457,7 +457,7 @@
- `FileCitation object { file_id, filename, index, type }`
- 对一个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -469,7 +469,7 @@
- `index: number`
- 文件列表中该文件的索引。
+ 文件在文件列表中的索引。
- `type: "file_citation"`
@@ -479,7 +479,7 @@
- `URLCitation object { end_index, start_index, title, 2 more }`
- 用于生成模型回复的网页资源引用。
+ 用于生成模型响应的网页资源引用。
- `end_index: number`
@@ -505,7 +505,7 @@
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
- 用于生成模型回复的容器文件引用。
+ 用于生成模型响应的容器文件引用。
- `container_id: string`
@@ -543,7 +543,7 @@
- `index: number`
- 文件列表中该文件的索引。
+ 文件在文件列表中的索引。
- `type: "file_path"`
@@ -569,7 +569,7 @@
- `text: string`
- 模型输出的文本。
+ 模型的文本输出。
- `type: "output_text"`
@@ -583,7 +583,7 @@
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型返回的拒绝说明。
- `type: "refusal"`
@@ -599,8 +599,8 @@
- `status: "in_progress" or "completed" or "incomplete"`
- 输入消息的状态。取值为 `in_progress`, `completed`,或
- `incomplete`。当通过 API 返回输入项时填充。
+ 消息输入的状态。取值之一 `in_progress`, `completed`,或
+ `incomplete`。当输入项通过 API 返回时填充。
- `"in_progress"`
@@ -616,9 +616,9 @@
- `phase: optional "commentary" or "final_answer" or null`
- 将消息标记为 `assistant` 中间评论(`commentary`)或最终回答(`final_answer`).
- 对于类似 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,保留并重新发送
- 阶段到所有助手消息上 —— 丢弃它可能会降低性能。不用于用户消息。
+ 将某条 `assistant` 消息标记为中间评论(`commentary`)或最终回答(`final_answer`).
+ 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
+ 阶段到所有助手消息上——丢弃它可能会降低性能。不用于用户消息。
- `"commentary"`
@@ -639,7 +639,7 @@
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -664,11 +664,11 @@
- `attributes: optional map[string or number or boolean] or null`
- 可以附加到对象的 16 组键值对。这对于以结构化
- 格式存储对象的附加信息,以及通过 API 或仪表板查询对象非常有用。键为字符串,
- 最大长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 个键值对。可用于以结构化
+ 格式存储关于对象的额外信息,并通过 API 或仪表板查询对象。键为字符串,
+ 格式存储关于对象的额外信息,并通过 接口 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。值为字符串(最大
+ 长度为 512 个字符)、布尔值或数字。
- `string`
@@ -682,11 +682,11 @@
- `filename: optional string`
- 文件的名称。
+ 文件名称。
- `score: optional number`
- 文件的相关性评分,取值在 0 到 1 之间。
+ 文件的相关性得分,介于 0 到 1 之间。
- `text: optional string`
@@ -694,8 +694,8 @@
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
- 对计算机使用工具的工具调用。参见
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ 对计算机使用工具的工具调用。参阅
+ [computer use guide](/docs/guides/tools-computer-use) 了解更多信息。
- `id: string`
@@ -703,11 +703,11 @@
- `call_id: string`
- 在向工具调用返回输出时所使用的标识符。
+ 使用输出响应工具调用时所使用的标识符。
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用中待处理的安全检查。
- `id: string`
@@ -719,11 +719,11 @@
- `message: optional string or null`
- 待处理安全检查的详细信息。
+ 关于待处理安全检查的详细信息。
- `status: "in_progress" or "completed" or "incomplete"`
- 该项的状态。取值之一为 `in_progress`, `completed`,或
+ 该项的状态,取值为 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -734,7 +734,7 @@
- `type: "computer_call"`
- 计算机调用的类型。始终为 `computer_call`.
+ 计算机调用的类型,始终为 `computer_call`.
- `"computer_call"`
@@ -748,7 +748,7 @@
- `button: "left" or "right" or "wheel" or 2 more`
- 指示在点击时按下了哪个鼠标按钮。取值之一为 `left`, `right`, `wheel`, `back`,或 `forward`.
+ 指示点击时按下的鼠标按键,取值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -762,17 +762,17 @@
- `type: "click"`
- 指定事件类型。对于点击操作,该属性始终为 `click`.
+ 指定事件类型。对于点击操作,此属性始终为 `click`.
- `"click"`
- `x: number`
- 发生点击的 x 坐标。
+ 点击发生的 x 坐标。
- `y: number`
- 发生点击的 y 坐标。
+ 点击发生的 y 坐标。
- `keys: optional array of string or null`
@@ -835,7 +835,7 @@
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
@@ -859,11 +859,11 @@
- `x: number`
- 要移至的 x 坐标。
+ 要移动到的 x 坐标。
- `y: number`
- 要移至的 y 坐标。
+ 要移动到的 y 坐标。
- `keys: optional array of string or null`
@@ -899,11 +899,11 @@
- `x: number`
- 发生滚动时的 x 坐标。
+ 发生滚动事件的 x 坐标。
- `y: number`
- 发生滚动时的 y 坐标。
+ 发生滚动事件的 y 坐标。
- `keys: optional array of string or null`
@@ -935,8 +935,8 @@
- `actions: optional ComputerActionList`
- 针对 `computer_use`。的扁平化批量操作。每个操作都包含一个
- `type` 鉴别字段以及操作专属字段。
+ 扁平化的批量操作列表,针对 `computer_use`。每个操作包含一个
+ `type` 判别字段以及操作特有的字段。
- `Click object { button, type, x, 2 more }`
@@ -952,7 +952,7 @@
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -988,8 +988,8 @@
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,此属性
- 始终设置为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终
+ 设置为 `computer_screenshot`.
- `"computer_screenshot"`
@@ -1013,7 +1013,7 @@
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 已被开发者确认的 API 报告的安全检查。
+ 开发者已确认的 API 报告的安全检查。
- `id: string`
@@ -1025,11 +1025,11 @@
- `message: optional string or null`
- 待处理安全检查的详细信息。
+ 关于待处理安全检查的详细信息。
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 输入消息的状态。取值为 `in_progress`, `completed`,或 `incomplete`。当通过 API 返回输入项时填充。
+ 消息输入的状态。取值之一 `in_progress`, `completed`,或 `incomplete`。当输入项通过 API 返回时填充。
- `"in_progress"`
@@ -1039,21 +1039,21 @@
- `WebSearchCall object { id, action, status, type }`
- 网页搜索工具调用的结果。参阅
- [网页搜索指南](/docs/guides/tools-web-search) 了解更多信息。
+ 网页搜索 工具调用的结果。详见
+ [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
- `id: string`
- 网页搜索工具调用的唯一 ID。
+ 网页搜索 工具调用的唯一 ID。
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行的具体操作的对象。
- 包含模型使用网页方式的详细信息(search、open_page、find_in_page)。
+ 描述本次 网页搜索 调用中所执行的具体操作的对象。
+ 包含模型如何使用网页(search、open_page、find_in_page)的详细信息。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" - 执行 网页搜索查询。
+ 操作类型 "search" - 执行 网页搜索 查询。
- `type: "search"`
@@ -1085,7 +1085,7 @@
- `OpenPage object { type, url }`
- 操作类型 "open_page" - 从搜索结果中打开特定 URL。
+ 操作类型 "open_page" - 打开搜索结果中的特定 URL。
- `type: "open_page"`
@@ -1099,11 +1099,11 @@
- `FindInPage object { pattern, type, url }`
- 操作类型 "find_in_page":在已加载页面内搜索匹配模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索某个模式。
- `pattern: string`
- 在页面中要搜索的模式或文本。
+ 在页面内搜索的模式或文本。
- `type: "find_in_page"`
@@ -1113,7 +1113,7 @@
- `url: string`
- 搜索该模式的页面的 URL。
+ 搜索该模式的页面 URL。
- `status: "in_progress" or "searching" or "completed" or "failed"`
@@ -1135,7 +1135,7 @@
- `FunctionCall object { arguments, call_id, name, 5 more }`
- 用于运行函数的工具调用。请参阅
+ 运行函数的工具调用。请参阅
[函数调用指南](/docs/guides/function-calling) 了解更多信息。
- `arguments: string`
@@ -1186,7 +1186,7 @@
- `status: optional "in_progress" or "completed" or "incomplete"`
- 该项的状态。取值之一为 `in_progress`, `completed`,或
+ 该项的状态,取值为 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -1201,7 +1201,7 @@
- `output: string or array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的文本、图片或文件输出。
+ 函数工具调用的文本、图像或文件输出。
- `string`
@@ -1209,7 +1209,7 @@
- `array of ResponseInputTextContent or ResponseInputImageContent or ResponseInputFileContent`
- 函数工具调用的内容输出(文本、图片、文件)数组。
+ 函数工具调用的内容输出(文本、图像、文件)数组。
- `ResponseInputTextContent object { text, type, prompt_cache_breakpoint }`
@@ -1227,7 +1227,7 @@
- `prompt_cache_breakpoint: optional object { mode } or null`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承其所在请求的 TTL `prompt_cache_options.ttl`;边界不会按 token 块向下取整。
- `mode: "explicit"`
@@ -1237,7 +1237,7 @@
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
+ 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision)
- `type: "input_image"`
@@ -1247,19 +1247,19 @@
- `detail: optional ImageDetail or null`
- 发送给模型的图像细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: optional string or null`
- 发送给模型的文件的 ID。
+ 要发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图像 URL。可以是完全限定的 URL,也可以是 data URL 中的 base64 编码图像。
+ 要发送给模型的图像的 URL。可以是完全限定的 URL,也可以是 data URL 中的 base64 编码图像。
- `prompt_cache_breakpoint: optional object { mode } or null`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承其所在请求的 TTL `prompt_cache_options.ttl`;边界不会按 token 块向下取整。
- `mode: "explicit"`
@@ -1279,7 +1279,7 @@
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会增加输入 token 用量。使用 `low` 可获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节级别。使用 `auto` 可让系统选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会增加输入 token 的用量。使用 `low` 可使用更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
- `"auto"`
@@ -1293,7 +1293,7 @@
- `file_id: optional string or null`
- 发送给模型的文件的 ID。
+ 要发送给模型的文件的 ID。
- `file_url: optional string or null`
@@ -1305,7 +1305,7 @@
- `prompt_cache_breakpoint: optional object { mode } or null`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承其所在请求的 TTL `prompt_cache_options.ttl`;边界不会按 token 块向下取整。
- `mode: "explicit"`
@@ -1321,7 +1321,7 @@
- `id: optional string or null`
- 函数工具调用的唯一 ID。当此条目通过 API 返回时填充。
+ 函数工具调用的唯一输出 ID。当此条目经由 API 返回时填充。
- `call_id: optional string or null`
@@ -1353,15 +1353,15 @@
- `name: optional string or null`
- 生成该输出的工具名称。
+ 产生该输出的工具的名称。
- `namespace: optional string or null`
- 生成该输出的工具命名空间。
+ 产生该输出的工具的命名空间。
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 该项的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。当通过 API 返回条目时填充。
+ 该项的状态,取值为 `in_progress`, `completed`,或 `incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -1387,11 +1387,11 @@
- `call_id: optional string or null`
- 由模型生成的工具搜索调用的唯一 ID。
+ 模型生成的工具搜索调用的唯一 ID。
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索是由服务端执行还是由客户端执行。
- `"server"`
@@ -1415,7 +1415,7 @@
- `Function object { name, parameters, strict, 5 more }`
- 在你自己的代码中定义一个可供模型选择调用的函数。详细了解 [函数调用](https://platform.openai.com/docs/guides/function-calling).
+ 在你自己的代码中定义一个可供模型选择调用的函数。了解有关 [函数调用](https://platform.openai.com/docs/guides/function-calling).
- `name: string`
@@ -1423,11 +1423,11 @@
- `parameters: map[unknown] or null`
- 用于描述函数参数的 JSON schema 对象。
+ 描述该函数参数的 JSON schema 对象。
- `strict: boolean or null`
- 此函数工具是否启用严格的参数校验。
+ 是否为该函数工具强制执行严格的参数校验。
- `type: "function"`
@@ -1445,29 +1445,29 @@
- `defer_loading: optional boolean`
- 此函数是否被延迟并通过工具搜索加载。
+ 该函数是否被延迟并通过工具搜索加载。
- `description: optional string or null`
- 函数的描述,供模型用来决定是否调用该函数。
+ 对该函数的描述,供模型用于判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述此函数的字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 一个用于描述此函数 string 输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索 tool](https://platform.openai.com/docs/guides/tools-file-search).
+ 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索 工具的类型。通常为 `file_search`.
+ 文件搜索 工具的类型,始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储的 ID。
+ 要搜索的向量存储的 ID 列表。
- `filters: optional ComparisonFilter or CompoundFilter or null`
@@ -1475,7 +1475,7 @@
- `ComparisonFilter object { key, type, value }`
- 用于通过定义的比较操作将指定的属性键与给定值进行比较的筛选条件。
+ 使用已定义的比较运算,将指定的属性键与给定值进行比较的筛选条件。
- `key: string`
@@ -1512,7 +1512,7 @@
- `value: string or number or boolean or array of string or number`
- 要与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 要与属性键进行比较的值;支持 string、number 或 boolean 类型。
- `string`
@@ -1528,15 +1528,15 @@
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。各项可以为 `ComparisonFilter` 或 `CompoundFilter`.
+ 组合多个筛选条件的数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于通过定义的比较操作将指定的属性键与给定值进行比较的筛选条件。
+ 使用已定义的比较运算,将指定的属性键与给定值进行比较的筛选条件。
- `unknown`
@@ -1550,7 +1550,7 @@
- `max_num_results: optional number`
- 要返回的最大结果数。该数值应介于 1 到 50 之间(含端点)。
+ 要返回的最大结果数。该数字应在 1 到 50 之间(含)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -1558,15 +1558,15 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于控制互逆排名融合(reciprocal rank fusion)在语义嵌入匹配与稀疏关键词匹配之间平衡程度的权重。
+ 启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡程度的权重。
- `embedding_weight: number`
- 互逆排名融合中嵌入的权重。
+ 倒数排名融合中嵌入的权重。
- `text_weight: number`
- 互逆排名融合中文本匹配的权重。
+ 倒数排名融合中文本的权重。
- `ranker: optional "auto" or "default-2024-11-15"`
@@ -1578,11 +1578,11 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,取值范围为 0 到 1。越接近 1 的数值会尝试仅返回相关性最高的结果,但返回的结果数量可能会更少。
+ 文件搜索的分数阈值,取值范围为 0 到 1。数值越接近 1,尝试返回的结果越相关,但返回的结果数量可能更少。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
@@ -1592,7 +1592,7 @@
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -1624,7 +1624,7 @@
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。了解更多关于
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
@@ -1637,22 +1637,22 @@
- `external_web_access: optional boolean`
- 允许网页搜索实时访问互联网。省略时默认值为 true。当值为 false 时,网页搜索工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 是否允许网页搜索进行实时互联网访问。省略时默认为 true。当为 false 时,网页搜索工具以离线/仅缓存模式运行,不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤条件。
- `allowed_domains: optional array of string or null`
- 允许搜索的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供的域名的子域名也同样被允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索所使用的上下文窗口空间的高级指引。可选值为以下之一 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 用于搜索的上下文窗口空间使用量的高层指导,取值之一为 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -1662,7 +1662,7 @@
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的大致位置。
+ 用户的近似位置。
- `city: optional string or null`
@@ -1670,7 +1670,7 @@
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 用户所在地的两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
- `region: optional string or null`
@@ -1682,22 +1682,22 @@
- `type: optional "approximate"`
- 近似位置的类型。始终为 `approximate`.
+ 位置近似类型,始终为 `approximate`.
- `"approximate"`
- `Mcp object { server_label, type, allowed_callers, 9 more }`
- 通过远程模型上下文协议
- (MCP)服务器,为模型提供对其他工具的访问能力。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
+ 通过远程 Model Context Protocol
+ (MCP)服务器为模型提供额外的工具访问能力。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 该 MCP 服务器的标签,用于在工具调用中标识它。
+ 此 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
- MCP 工具的类型。始终为 `mcp`.
+ MCP 工具的类型,始终为 `mcp`.
- `"mcp"`
@@ -1719,13 +1719,13 @@
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤器对象。
- `read_only: optional boolean`
- 指示工具是否会修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否修改数据或为只读。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则它将匹配此过滤器。
- `tool_names: optional array of string`
@@ -1733,25 +1733,25 @@
- `authorization: optional string`
- 可与远程 MCP 服务器一起使用的 OAuth 访问令牌,可搭配
- 自定义 MCP 服务器 URL 或服务连接器使用。你的应用
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,可与
+ 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
必须处理 OAuth 授权流程并在此处提供令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些连接器。必须提供其中之一
- `server_url`, `connector_id`,或 `tunnel_id` 。了解更多
- 关于服务连接器的 [信息](/docs/guides/tools-remote-mcp#connectors).
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供
+ `server_url`, `connector_id`,或 `tunnel_id` 之一。了解更多
+ 关于服务连接器 [的信息](/docs/guides/tools-remote-mcp#connectors).
- 当前支持的 `connector_id` 值为:
+ 当前支持的 `connector_id` 值包括:
- Dropbox: `connector_dropbox`
- Gmail: `connector_gmail`
- Google Calendar: `connector_googlecalendar`
- Google Drive: `connector_googledrive`
- Microsoft Teams: `connector_microsoftteams`
- - Outlook Calendar: `connector_outlookcalendar`
- - Outlook Email: `connector_outlookemail`
+ - Outlook 日历: `connector_outlookcalendar`
+ - Outlook 邮箱: `connector_outlookemail`
- SharePoint: `connector_sharepoint`
- `"connector_dropbox"`
@@ -1772,7 +1772,7 @@
- `defer_loading: optional boolean`
- 此 MCP 工具是否被延迟,并通过工具搜索发现。
+ 该 MCP 工具是否被延迟加载并通过工具搜索发现。
- `headers: optional map[string] or null`
@@ -1786,18 +1786,18 @@
- `McpToolApprovalFilter object { always, never }`
指定 MCP 服务器中哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的筛选器对象
- ,这些工具需要审批。
+ `always`, `never`,也可以是与需要审批的工具相关联的过滤器对象
+ 。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤器对象。
- `read_only: optional boolean`
- 指示工具是否会修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否修改数据或为只读。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则它将匹配此过滤器。
- `tool_names: optional array of string`
@@ -1805,13 +1805,13 @@
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤器对象。
- `read_only: optional boolean`
- 指示工具是否会修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否修改数据或为只读。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则它将匹配此过滤器。
- `tool_names: optional array of string`
@@ -1819,8 +1819,8 @@
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值之一 `always` 或
- `never`。当设置为 `always`,时,所有工具都需要审批。当
+ 为所有工具指定统一的审批策略。可选值为 `always` 或
+ `never`。之一。当设置为 `always`,时,所有工具都需要审批。当
设置为 `never`,时,所有工具都不需要审批。
- `"always"`
@@ -1833,23 +1833,23 @@
- `server_url: optional string`
- MCP 服务器的 URL。以下之一 `server_url`, `connector_id`,或
- `tunnel_id` 必须提供。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 必须提供其中之一。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。以下之一
- `server_url`, `connector_id`,或 `tunnel_id` 必须提供。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供其中之一。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词响应的工具。
+ 运行 Python 代码以辅助生成对提示词回应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID 或一个对象,该对象
- 指定可供你的代码使用的已上传文件 ID,以及一个
- 可选的 `memory_limit` 设置。
+ 代码解释器容器。可以是容器 ID,也可以是一个对象,用于
+ 指定可供代码使用的已上传文件 ID,以及一个可填的
+ 设置。 `memory_limit` 配置。
- `string`
@@ -1857,7 +1857,7 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要用于运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
- `type: "auto"`
@@ -1867,7 +1867,7 @@
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -1897,29 +1897,29 @@
- `allowed_domains: array of string`
- 当类型为时允许访问的域名列表 `allowlist`.
+ 当 type 为 `allowlist`.
- `type: "allowlist"`
- 仅允许向指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域进行出站访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 用于已加入白名单域的可选域范围密钥。
+ 允许列表中域的可选域作用域密钥。
- `domain: string`
- 与该密钥关联的域。
+ 与密钥关联的域。
- `name: string`
- 为该域注入的密钥名称。
+ 要为该域注入的密钥名称。
- `value: string`
- 为该域注入的密钥值。
+ 要为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -1955,7 +1955,7 @@
- `action: optional "generate" or "edit" or "auto"`
- 生成新图像还是编辑已有图像。默认值: `auto`.
+ 是生成新图像还是编辑现有图像。默认值: `auto`.
- `"generate"`
@@ -1966,9 +1966,9 @@
- `background: optional "transparent" or "opaque" or "auto"`
设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。之一。受支持的 GPT Image 模型可使用透明背景。对于
- 受支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该功能处于预览阶段。当使用
+ `opaque`,或 `auto`。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。使用
`transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -1979,7 +1979,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像风格和特征(尤其是面部特征)时所投入的精力。该参数仅在 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型中受支持,在 `gpt-image-1-mini`。中不受支持。支持的值包括 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时将付出的努力程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`。支持。支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -1987,16 +1987,16 @@
- `input_image_mask: optional object { file_id, image_url }`
- 用于局部重绘的可选蒙版。包含 `image_url`
+ 用于修复的可选遮罩。包含 `image_url`
(字符串,可选)和 `file_id` (字符串,可选)。
- `file_id: optional string`
- 蒙版图像的文件 ID。
+ 遮罩图像的文件 ID。
- `image_url: optional string`
- Base64 编码的蒙版图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
@@ -2034,11 +2034,11 @@
- `output_compression: optional number`
- 输出图像的压缩级别。默认值:100。
+ 输出图片的压缩级别。默认值:100。
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`,或
+ 生成图片的输出格式。取值之一 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -2049,11 +2049,11 @@
- `partial_images: optional number`
- 在流式模式下要生成的中间图片数量,范围为 0(默认值)到 3。
+ 在流式模式下生成的部分图片数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
- 生成图像的质量。可选值为 `low`, `medium`, `high`,
+ 生成图片的质量。取值之一 `low`, `medium`, `high`,
或 `auto`。默认值: `auto`.
- `"low"`
@@ -2066,13 +2066,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定的任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,以及 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动调整尺寸的模型支持。对于 `dall-e-2`,使用以下值之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下值之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图片的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的纵横比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT image 模型支持; `auto` 受支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定的任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,以及 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动调整尺寸的模型支持。对于 `dall-e-2`,使用以下值之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下值之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图片的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的纵横比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT image 模型支持; `auto` 受支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -2116,13 +2116,13 @@
- `type: "container_auto"`
- 为此请求自动创建一个容器
+ 自动为本次请求创建容器
- `"container_auto"`
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -2146,7 +2146,7 @@
- `skills: optional array of SkillReference or InlineSkill`
- 通过 ID 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
@@ -2184,13 +2184,13 @@
- `media_type: "application/zip"`
- 内联技能负载的媒体类型,必须为 `application/zip`.
+ 内联技能负载的媒体类型。必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能来源的类型,必须为 `base64`.
+ 内联技能源的类型。必须为 `base64`.
- `"base64"`
@@ -2222,7 +2222,7 @@
- `path: string`
- 包含该技能的目录路径。
+ 包含技能的目录路径。
- `ContainerReference object { container_id, type }`
@@ -2232,7 +2232,7 @@
- `type: "container_reference"`
- 引用通过 /v1/containers 端点创建的容器。
+ 引用通过 /v1/containers 端点创建的容器
- `"container_reference"`
@@ -2242,7 +2242,7 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中识别它。
+ 自定义工具的名称,用于在工具调用中标识它。
- `type: "custom"`
@@ -2260,7 +2260,7 @@
- `defer_loading: optional boolean`
- 此工具是否应被延迟并通过工具搜索发现。
+ 该工具是否应被延迟,并通过工具搜索发现。
- `description: optional string`
@@ -2304,7 +2304,7 @@
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入共享命名空间。
- `description: string`
@@ -2312,7 +2312,7 @@
- `name: string`
- 用于工具调用中的命名空间名称(例如, `crm`).
+ 在工具调用中使用的命名空间名称(例如, `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
@@ -2336,19 +2336,19 @@
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 该函数是否应被延迟,并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 用于描述此函数工具字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
+ 用于描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该项不描述内容数组输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,对于兼容的 schema,Responses 会尝试使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -2356,7 +2356,7 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中识别它。
+ 自定义工具的名称,用于在工具调用中标识它。
- `type: "custom"`
@@ -2374,7 +2374,7 @@
- `defer_loading: optional boolean`
- 此工具是否应被延迟并通过工具搜索发现。
+ 该工具是否应被延迟,并通过工具搜索发现。
- `description: optional string`
@@ -2402,11 +2402,11 @@
- `description: optional string or null`
- 展示给模型的、由客户端执行的工具搜索工具的描述。
+ 展示给模型的客户端执行工具搜索工具的描述。
- `execution: optional "server" or "client"`
- 工具搜索是由服务端执行还是由客户端执行。
+ 工具搜索是由服务端还是由客户端执行。
- `"server"`
@@ -2418,7 +2418,7 @@
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具会在网页中搜索可在响应中使用的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会搜索网页以获取可在回复中使用的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
@@ -2436,7 +2436,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索所使用的上下文窗口空间的高级指引。可选值为以下之一 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 用于搜索的上下文窗口空间使用量的高层指导,取值之一为 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -2446,11 +2446,11 @@
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户所在位置。
+ 用户所在的位置。
- `type: "approximate"`
- 近似位置的类型。始终为 `approximate`.
+ 位置近似类型,始终为 `approximate`.
- `"approximate"`
@@ -2460,7 +2460,7 @@
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 用户所在地的两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
- `region: optional string or null`
@@ -2500,11 +2500,11 @@
- `call_id: optional string or null`
- 由模型生成的工具搜索调用的唯一 ID。
+ 模型生成的工具搜索调用的唯一 ID。
- `execution: optional "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索是由服务端执行还是由客户端执行。
- `"server"`
@@ -2530,11 +2530,11 @@
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此项中可用的额外工具列表。
+ 在此项中提供的额外工具列表。
- `Function object { name, parameters, strict, 5 more }`
- 在你自己的代码中定义一个可供模型选择调用的函数。详细了解 [函数调用](https://platform.openai.com/docs/guides/function-calling).
+ 在你自己的代码中定义一个可供模型选择调用的函数。了解有关 [函数调用](https://platform.openai.com/docs/guides/function-calling).
- `name: string`
@@ -2542,11 +2542,11 @@
- `parameters: map[unknown] or null`
- 用于描述函数参数的 JSON schema 对象。
+ 描述该函数参数的 JSON schema 对象。
- `strict: boolean or null`
- 此函数工具是否启用严格的参数校验。
+ 是否为该函数工具强制执行严格的参数校验。
- `type: "function"`
@@ -2564,29 +2564,29 @@
- `defer_loading: optional boolean`
- 此函数是否被延迟并通过工具搜索加载。
+ 该函数是否被延迟并通过工具搜索加载。
- `description: optional string or null`
- 函数的描述,供模型用来决定是否调用该函数。
+ 对该函数的描述,供模型用于判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述此函数的字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 一个用于描述此函数 string 输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索 tool](https://platform.openai.com/docs/guides/tools-file-search).
+ 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索 工具的类型。通常为 `file_search`.
+ 文件搜索 工具的类型,始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储的 ID。
+ 要搜索的向量存储的 ID 列表。
- `filters: optional ComparisonFilter or CompoundFilter or null`
@@ -2594,15 +2594,15 @@
- `ComparisonFilter object { key, type, value }`
- 用于通过定义的比较操作将指定的属性键与给定值进行比较的筛选条件。
+ 使用已定义的比较运算,将指定的属性键与给定值进行比较的筛选条件。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用 `and` 或 `or`.
- `max_num_results: optional number`
- 要返回的最大结果数。该数值应介于 1 到 50 之间(含端点)。
+ 要返回的最大结果数。该数字应在 1 到 50 之间(含)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -2610,15 +2610,15 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于控制互逆排名融合(reciprocal rank fusion)在语义嵌入匹配与稀疏关键词匹配之间平衡程度的权重。
+ 启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡程度的权重。
- `embedding_weight: number`
- 互逆排名融合中嵌入的权重。
+ 倒数排名融合中嵌入的权重。
- `text_weight: number`
- 互逆排名融合中文本匹配的权重。
+ 倒数排名融合中文本的权重。
- `ranker: optional "auto" or "default-2024-11-15"`
@@ -2630,11 +2630,11 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,取值范围为 0 到 1。越接近 1 的数值会尝试仅返回相关性最高的结果,但返回的结果数量可能会更少。
+ 文件搜索的分数阈值,取值范围为 0 到 1。数值越接近 1,尝试返回的结果越相关,但返回的结果数量可能更少。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
@@ -2644,7 +2644,7 @@
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -2676,7 +2676,7 @@
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。了解更多关于
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
@@ -2689,22 +2689,22 @@
- `external_web_access: optional boolean`
- 允许网页搜索实时访问互联网。省略时默认值为 true。当值为 false 时,网页搜索工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 是否允许网页搜索进行实时互联网访问。省略时默认为 true。当为 false 时,网页搜索工具以离线/仅缓存模式运行,不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤条件。
- `allowed_domains: optional array of string or null`
- 允许搜索的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供的域名的子域名也同样被允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索所使用的上下文窗口空间的高级指引。可选值为以下之一 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 用于搜索的上下文窗口空间使用量的高层指导,取值之一为 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -2714,7 +2714,7 @@
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的大致位置。
+ 用户的近似位置。
- `city: optional string or null`
@@ -2722,7 +2722,7 @@
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 用户所在地的两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
- `region: optional string or null`
@@ -2734,22 +2734,22 @@
- `type: optional "approximate"`
- 近似位置的类型。始终为 `approximate`.
+ 位置近似类型,始终为 `approximate`.
- `"approximate"`
- `Mcp object { server_label, type, allowed_callers, 9 more }`
- 通过远程模型上下文协议
- (MCP)服务器,为模型提供对其他工具的访问能力。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
+ 通过远程 Model Context Protocol
+ (MCP)服务器为模型提供额外的工具访问能力。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 该 MCP 服务器的标签,用于在工具调用中标识它。
+ 此 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
- MCP 工具的类型。始终为 `mcp`.
+ MCP 工具的类型,始终为 `mcp`.
- `"mcp"`
@@ -2771,13 +2771,13 @@
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤器对象。
- `read_only: optional boolean`
- 指示工具是否会修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否修改数据或为只读。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则它将匹配此过滤器。
- `tool_names: optional array of string`
@@ -2785,25 +2785,25 @@
- `authorization: optional string`
- 可与远程 MCP 服务器一起使用的 OAuth 访问令牌,可搭配
- 自定义 MCP 服务器 URL 或服务连接器使用。你的应用
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,可与
+ 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
必须处理 OAuth 授权流程并在此处提供令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些连接器。必须提供其中之一
- `server_url`, `connector_id`,或 `tunnel_id` 。了解更多
- 关于服务连接器的 [信息](/docs/guides/tools-remote-mcp#connectors).
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供
+ `server_url`, `connector_id`,或 `tunnel_id` 之一。了解更多
+ 关于服务连接器 [的信息](/docs/guides/tools-remote-mcp#connectors).
- 当前支持的 `connector_id` 值为:
+ 当前支持的 `connector_id` 值包括:
- Dropbox: `connector_dropbox`
- Gmail: `connector_gmail`
- Google Calendar: `connector_googlecalendar`
- Google Drive: `connector_googledrive`
- Microsoft Teams: `connector_microsoftteams`
- - Outlook Calendar: `connector_outlookcalendar`
- - Outlook Email: `connector_outlookemail`
+ - Outlook 日历: `connector_outlookcalendar`
+ - Outlook 邮箱: `connector_outlookemail`
- SharePoint: `connector_sharepoint`
- `"connector_dropbox"`
@@ -2824,7 +2824,7 @@
- `defer_loading: optional boolean`
- 此 MCP 工具是否被延迟,并通过工具搜索发现。
+ 该 MCP 工具是否被延迟加载并通过工具搜索发现。
- `headers: optional map[string] or null`
@@ -2838,18 +2838,18 @@
- `McpToolApprovalFilter object { always, never }`
指定 MCP 服务器中哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的筛选器对象
- ,这些工具需要审批。
+ `always`, `never`,也可以是与需要审批的工具相关联的过滤器对象
+ 。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤器对象。
- `read_only: optional boolean`
- 指示工具是否会修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否修改数据或为只读。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则它将匹配此过滤器。
- `tool_names: optional array of string`
@@ -2857,13 +2857,13 @@
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤器对象。
- `read_only: optional boolean`
- 指示工具是否会修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否修改数据或为只读。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则它将匹配此过滤器。
- `tool_names: optional array of string`
@@ -2871,8 +2871,8 @@
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值之一 `always` 或
- `never`。当设置为 `always`,时,所有工具都需要审批。当
+ 为所有工具指定统一的审批策略。可选值为 `always` 或
+ `never`。之一。当设置为 `always`,时,所有工具都需要审批。当
设置为 `never`,时,所有工具都不需要审批。
- `"always"`
@@ -2885,23 +2885,23 @@
- `server_url: optional string`
- MCP 服务器的 URL。以下之一 `server_url`, `connector_id`,或
- `tunnel_id` 必须提供。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 必须提供其中之一。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。以下之一
- `server_url`, `connector_id`,或 `tunnel_id` 必须提供。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供其中之一。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词响应的工具。
+ 运行 Python 代码以辅助生成对提示词回应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID 或一个对象,该对象
- 指定可供你的代码使用的已上传文件 ID,以及一个
- 可选的 `memory_limit` 设置。
+ 代码解释器容器。可以是容器 ID,也可以是一个对象,用于
+ 指定可供代码使用的已上传文件 ID,以及一个可填的
+ 设置。 `memory_limit` 配置。
- `string`
@@ -2909,7 +2909,7 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要用于运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
- `type: "auto"`
@@ -2919,7 +2919,7 @@
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -2975,7 +2975,7 @@
- `action: optional "generate" or "edit" or "auto"`
- 生成新图像还是编辑已有图像。默认值: `auto`.
+ 是生成新图像还是编辑现有图像。默认值: `auto`.
- `"generate"`
@@ -2986,9 +2986,9 @@
- `background: optional "transparent" or "opaque" or "auto"`
设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。之一。受支持的 GPT Image 模型可使用透明背景。对于
- 受支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该功能处于预览阶段。当使用
+ `opaque`,或 `auto`。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。使用
`transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -2999,7 +2999,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像风格和特征(尤其是面部特征)时所投入的精力。该参数仅在 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型中受支持,在 `gpt-image-1-mini`。中不受支持。支持的值包括 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时将付出的努力程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`。支持。支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -3007,16 +3007,16 @@
- `input_image_mask: optional object { file_id, image_url }`
- 用于局部重绘的可选蒙版。包含 `image_url`
+ 用于修复的可选遮罩。包含 `image_url`
(字符串,可选)和 `file_id` (字符串,可选)。
- `file_id: optional string`
- 蒙版图像的文件 ID。
+ 遮罩图像的文件 ID。
- `image_url: optional string`
- Base64 编码的蒙版图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
@@ -3054,11 +3054,11 @@
- `output_compression: optional number`
- 输出图像的压缩级别。默认值:100。
+ 输出图片的压缩级别。默认值:100。
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`,或
+ 生成图片的输出格式。取值之一 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -3069,11 +3069,11 @@
- `partial_images: optional number`
- 在流式模式下要生成的中间图片数量,范围为 0(默认值)到 3。
+ 在流式模式下生成的部分图片数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
- 生成图像的质量。可选值为 `low`, `medium`, `high`,
+ 生成图片的质量。取值之一 `low`, `medium`, `high`,
或 `auto`。默认值: `auto`.
- `"low"`
@@ -3086,13 +3086,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定的任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,以及 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动调整尺寸的模型支持。对于 `dall-e-2`,使用以下值之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下值之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图片的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的纵横比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT image 模型支持; `auto` 受支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定的任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,以及 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动调整尺寸的模型支持。对于 `dall-e-2`,使用以下值之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下值之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图片的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的纵横比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT image 模型支持; `auto` 受支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -3144,7 +3144,7 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中识别它。
+ 自定义工具的名称,用于在工具调用中标识它。
- `type: "custom"`
@@ -3162,7 +3162,7 @@
- `defer_loading: optional boolean`
- 此工具是否应被延迟并通过工具搜索发现。
+ 该工具是否应被延迟,并通过工具搜索发现。
- `description: optional string`
@@ -3174,7 +3174,7 @@
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入共享命名空间。
- `description: string`
@@ -3182,7 +3182,7 @@
- `name: string`
- 用于工具调用中的命名空间名称(例如, `crm`).
+ 在工具调用中使用的命名空间名称(例如, `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
@@ -3206,19 +3206,19 @@
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 该函数是否应被延迟,并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 用于描述此函数工具字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
+ 用于描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该项不描述内容数组输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,对于兼容的 schema,Responses 会尝试使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -3226,7 +3226,7 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中识别它。
+ 自定义工具的名称,用于在工具调用中标识它。
- `type: "custom"`
@@ -3244,7 +3244,7 @@
- `defer_loading: optional boolean`
- 此工具是否应被延迟并通过工具搜索发现。
+ 该工具是否应被延迟,并通过工具搜索发现。
- `description: optional string`
@@ -3272,11 +3272,11 @@
- `description: optional string or null`
- 展示给模型的、由客户端执行的工具搜索工具的描述。
+ 展示给模型的客户端执行工具搜索工具的描述。
- `execution: optional "server" or "client"`
- 工具搜索是由服务端执行还是由客户端执行。
+ 工具搜索是由服务端还是由客户端执行。
- `"server"`
@@ -3288,7 +3288,7 @@
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具会在网页中搜索可在响应中使用的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会搜索网页以获取可在回复中使用的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
@@ -3306,7 +3306,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索所使用的上下文窗口空间的高级指引。可选值为以下之一 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 用于搜索的上下文窗口空间使用量的高层指导,取值之一为 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -3316,11 +3316,11 @@
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户所在位置。
+ 用户所在的位置。
- `type: "approximate"`
- 近似位置的类型。始终为 `approximate`.
+ 位置近似类型,始终为 `approximate`.
- `"approximate"`
@@ -3330,7 +3330,7 @@
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 用户所在地的两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
- `region: optional string or null`
@@ -3370,10 +3370,10 @@
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成响应时使用的思维链描述。请务必将这些项包含在
- 传回给 Responses API `input` 的输入中,以便在手动管理
- 上下文时用于对话的后续轮次。
- [管理上下文](/docs/guides/conversation-state).
+ 对推理模型在生成回复时所使用的思维链的描述。如果你正在手动
+ 管理上下文,请务必在后续对话轮次中将这些项包含到你的 `input` Responses API 中
+ ,以便在手动管理上下文时供后续轮次使用
+ [手动管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -3385,7 +3385,7 @@
- `text: string`
- 到目前为止模型推理输出的摘要。
+ 迄今为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -3415,19 +3415,19 @@
- `encrypted_content: optional string or null`
- 推理项的加密内容。默认情况下会填充该字段
- 用于通过 `POST /v1/responses` 和 WebSocket
+ 推理项的加密内容。默认填充该字段
+ 适用于通过 `POST /v1/responses` 和 WebSocket
`response.create` 请求返回的推理项。
- 流式传输时,请在后续请求中使用已完成的推理项及其
- `encrypted_content` 中的 `response.output_item.done` 事件。
- 后续请求。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。这一点尤其
- 重要,当 `store` 为 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请在后续请求中使用来自
+ `encrypted_content` 事件的 `response.output_item.done` 已完成推理项及其
+ 。该 `encrypted_content` 在
+ `response.output_item.added` 中可能不完整。这一点在
+ 为以下情况时尤为 `store` 重要 `false` :或使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 该项的状态。取值之一为 `in_progress`, `completed`,或
+ 该项的状态,取值为 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -3438,7 +3438,7 @@
- `Compaction object { encrypted_content, type, id }`
- 由该模型生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由 API 生成的压缩项 [`v1/responses/compact` 接口](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -3446,7 +3446,7 @@
- `type: "compaction"`
- 该项的类型。始终为 `compaction`.
+ 项的类型。始终为 `compaction`.
- `"compaction"`
@@ -3456,19 +3456,19 @@
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 模型发起的图片生成请求。
- `id: string`
- 图像生成调用的唯一 ID。
+ 该图片生成调用的唯一 ID。
- `result: string or null`
- 以 base64 编码的生成图像。
+ 以 base64 编码的生成图片。
- `status: "in_progress" or "completed" or "generating" or "failed"`
- 图像生成调用的状态。
+ 该图片生成调用的状态。
- `"in_progress"`
@@ -3480,7 +3480,7 @@
- `type: "image_generation_call"`
- 图像生成调用的类型。始终为 `image_generation_call`.
+ 图片生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
@@ -3490,11 +3490,11 @@
- `id: string`
- 代码解释器工具调用的唯一 ID。
+ 该代码解释器工具调用的唯一 ID。
- `code: string or null`
- 要运行的代码,若不可用则为 null。
+ 要运行的代码,如果不可用则为 null。
- `container_id: string`
@@ -3502,7 +3502,7 @@
- `outputs: array of object { logs, type } or object { type, url } or null`
- 代码解释器生成的输出,例如日志或图像。
+ 代码解释器生成的输出,例如日志或图片。
如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -3521,7 +3521,7 @@
- `Image object { type, url }`
- 代码解释器输出的图像。
+ 代码解释器输出的图片。
- `type: "image"`
@@ -3531,11 +3531,11 @@
- `url: string`
- 代码解释器输出图像的 URL。
+ 代码解释器输出图片的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
- 代码解释器工具调用的状态。有效值为 `in_progress`, `completed`, `incomplete`, `interpreting`,以及 `failed`.
+ 代码解释器工具调用的状态。有效值为 `in_progress`, `completed`, `incomplete`, `interpreting`,和 `failed`.
- `"in_progress"`
@@ -3555,11 +3555,11 @@
- `LocalShellCall object { id, action, call_id, 2 more }`
- 在本地 shell 上运行命令的工具调用。
+ 用于在本地 shell 上运行命令的工具调用。
- `id: string`
- 本地 shell 调用的唯一 ID。
+ 该本地 shell 调用的唯一 ID。
- `action: object { command, env, type, 3 more }`
@@ -3571,7 +3571,7 @@
- `env: map[string]`
- 为该命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
@@ -3581,19 +3581,19 @@
- `timeout_ms: optional number or null`
- 该命令的可选超时时间(毫秒)。
+ 命令的可选超时时间,以毫秒为单位。
- `user: optional string or null`
- 运行该命令所使用的可选用户。
+ 用于运行命令的可选用户。
- `working_directory: optional string or null`
- 运行该命令的可选工作目录。
+ 运行命令时使用的可选工作目录。
- `call_id: string`
- 由模型生成的本地 shell 工具调用的唯一 ID。
+ 模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -3617,7 +3617,7 @@
- `id: string`
- 由模型生成的本地 shell 工具调用的唯一 ID。
+ 模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -3631,7 +3631,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 该项的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`.
+ 该项的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -3653,25 +3653,25 @@
- `max_output_length: optional number or null`
- 从合并的 stdout 和 stderr 输出中捕获的最大 UTF-8 字符数。
+ 从合并后的 stdout 和 stderr 输出中捕获的最大 UTF-8 字符数。
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最大挂钟时间(毫秒)。
+ 允许 shell 命令运行的最长 wall-clock 时间,以毫秒为单位。
- `call_id: string`
- 由模型生成的 shell 工具调用的唯一 ID。
+ 模型生成的 shell 工具调用的唯一 ID。
- `type: "shell_call"`
- 该项的类型。始终为 `shell_call`.
+ 项的类型。始终为 `shell_call`.
- `"shell_call"`
- `id: optional string or null`
- shell 工具调用的唯一 ID。当此项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。通过 API 返回此条目时会填充该字段。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -3721,11 +3721,11 @@
- `call_id: string`
- 由模型生成的 shell 工具调用的唯一 ID。
+ 模型生成的 shell 工具调用的唯一 ID。
- `output: array of ResponseFunctionShellCallOutputContent`
- 捕获的 stdout 和 stderr 输出块及其相关结果。
+ 捕获到的 stdout 和 stderr 输出块,以及它们关联的结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -3733,7 +3733,7 @@
- `Timeout object { type }`
- 表示 shell 调用超出了其配置的时间限制。
+ 表示该 shell 调用超出了其配置的时间限制。
- `type: "timeout"`
@@ -3743,7 +3743,7 @@
- `Exit object { exit_code, type }`
- 表示 shell 命令已执行完毕并返回了退出码。
+ 表示该 shell 命令已执行完毕并返回了退出码。
- `exit_code: number`
@@ -3757,21 +3757,21 @@
- `stderr: string`
- 为该 shell 调用捕获的 stderr 输出。
+ 该 shell 调用捕获到的 stderr 输出。
- `stdout: string`
- 为该 shell 调用捕获的 stdout 输出。
+ 该 shell 调用捕获到的 stdout 输出。
- `type: "shell_call_output"`
- 该项的类型。始终为 `shell_call_output`.
+ 项的类型。始终为 `shell_call_output`.
- `"shell_call_output"`
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。当通过 API 返回此项时填充。
+ 该 shell 工具调用输出的唯一 ID。通过 API 返回该项时填充此字段。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -3799,7 +3799,7 @@
- `max_output_length: optional number or null`
- 为此 shell 调用的 combined output 捕获的最大 UTF-8 字符数。
+ 该 shell 调用合并输出可捕获的最大 UTF-8 字符数。
- `status: optional "in_progress" or "completed" or "incomplete" or null`
@@ -3829,11 +3829,11 @@
- `diff: string`
- 创建文件时要应用的 unified diff 内容。
+ 创建文件时要应用的统一差异内容。
- `path: string`
- 相对于工作区根目录的要创建文件的路径。
+ 相对于工作区根目录的要创建的文件的路径。
- `type: "create_file"`
@@ -3847,7 +3847,7 @@
- `path: string`
- 相对于工作区根目录的要删除的文件路径。
+ 相对于工作区根目录的要删除文件的路径。
- `type: "delete_file"`
@@ -3861,11 +3861,11 @@
- `diff: string`
- 要应用到现有文件的 unified diff 内容。
+ 要应用到现有文件的统一差异内容。
- `path: string`
- 相对于工作区根目录的要更新的文件路径。
+ 相对于工作区根目录的要更新文件的路径。
- `type: "update_file"`
@@ -3875,7 +3875,7 @@
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。之一 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -3883,7 +3883,7 @@
- `type: "apply_patch_call"`
- 该项的类型。始终为 `apply_patch_call`.
+ 项的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -3925,7 +3925,7 @@
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。之一 `completed` 或 `failed`.
- `"completed"`
@@ -3933,7 +3933,7 @@
- `type: "apply_patch_call_output"`
- 该项的类型。始终为 `apply_patch_call_output`.
+ 项的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -3967,7 +3967,7 @@
- `output: optional string or null`
- apply patch 工具的可读日志文本(例如补丁结果或错误)。
+ 来自 apply patch 工具的可选人类可读日志文本(例如补丁结果或错误)。
- `McpListTools object { id, server_label, tools, 2 more }`
@@ -3991,29 +3991,29 @@
- `name: string`
- 工具的名称。
+ 该工具的名称。
- `annotations: optional unknown or null`
- 关于该工具的附加注解。
+ 关于该工具的附加注释。
- `description: optional string or null`
- 工具的描述。
+ 该工具的描述。
- `type: "mcp_list_tools"`
- 该项的类型。始终为 `mcp_list_tools`.
+ 项的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 服务器无法列出工具时的错误消息。
+ 如果服务器无法列出工具,则显示错误消息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 对工具调用的人工审批请求。
+ 工具调用的人工审批请求。
- `id: string`
@@ -4021,7 +4021,7 @@
- `arguments: string`
- 该工具的参数 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
@@ -4033,7 +4033,7 @@
- `type: "mcp_approval_request"`
- 该项的类型。始终为 `mcp_approval_request`.
+ 项的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
@@ -4051,7 +4051,7 @@
- `type: "mcp_approval_response"`
- 该项的类型。始终为 `mcp_approval_response`.
+ 项的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -4061,11 +4061,11 @@
- `reason: optional string or null`
- 可选的决策原因。
+ 决策的可选原因。
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上工具的调用。
+ 对 MCP 服务器上某个工具的调用。
- `id: string`
@@ -4073,11 +4073,11 @@
- `arguments: string`
- 传递给该工具的参数 JSON 字符串。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行工具的名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -4085,14 +4085,14 @@
- `type: "mcp_call"`
- 该项的类型。始终为 `mcp_call`.
+ 项的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中包含此值以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -4146,16 +4146,16 @@
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 你代码中自定义工具调用的输出,被发回给模型。
+ 由你的代码生成的自定义工具调用输出,会被发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 由你的代码产生的自定义工具调用的输出。
- 可以是字符串或输出内容列表。
+ 由你的代码生成的自定义工具调用的输出。
+ 可以是字符串,也可以是输出内容列表。
- `StringOutput = string`
@@ -4163,7 +4163,7 @@
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 自定义工具调用的文本、图片或文件输出。
+ 自定义工具调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
@@ -4171,7 +4171,7 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
+ 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -4185,7 +4185,7 @@
- `id: optional string`
- 在 OpenAI 平台上自定义工具调用输出的唯一 ID。
+ 该自定义工具调用输出在 OpenAI 平台上的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -4213,7 +4213,7 @@
- `CustomToolCall object { call_id, input, name, 4 more }`
- 对模型创建的自定义工具的调用。
+ 由模型创建的、对自定义工具的调用。
- `call_id: string`
@@ -4235,7 +4235,7 @@
- `id: optional string`
- 在 OpenAI 平台上自定义工具调用的唯一 ID。
+ 该自定义工具调用在 OpenAI 平台上的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -4263,11 +4263,11 @@
- `CompactionTrigger object { type, id }`
- 压缩当前上下文。必须是最后一个输入项。
+ 压缩当前上下文。必须是最后一项输入项。
- `type: "compaction_trigger"`
- 该项的类型。始终为 `compaction_trigger`.
+ 项的类型。始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -4277,15 +4277,15 @@
- `ItemReference object { id, type }`
- 用于引用某个项的内部标识符。
+ 用于引用某个条目的内部标识符。
- `id: string`
- 要引用的项的 ID。
+ 要引用的条目 ID。
- `type: optional "item_reference" or null`
- 要引用的条目类型。始终为 `item_reference`.
+ 要引用的条目类型。始终 `item_reference`.
- `"item_reference"`
@@ -4293,19 +4293,19 @@
- `id: string`
- 该程序条目的唯一 ID。
+ 此程序条目的唯一 ID。
- `call_id: string`
- 该程序条目的稳定调用 ID。
+ 程序条目的稳定调用 ID。
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
- 必须原样回传的不透明程序重放指纹。
+ 必须往返传递的不透明程序回放指纹。
- `type: "program"`
@@ -4317,19 +4317,19 @@
- `id: string`
- 该程序输出条目的唯一 ID。
+ 此程序输出条目的唯一 ID。
- `call_id: string`
- 该程序条目的调用 ID。
+ 程序条目的调用 ID。
- `result: string`
- 该程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
- 程序输出的终态状态。
+ 程序输出的最终状态。
- `"completed"`
@@ -4344,23 +4344,23 @@
- `instructions: optional string or null`
插入到模型上下文中的系统(或开发者)消息。
- 。当与 `previous_response_id`,一起使用时,上一次响应中的指令不会延续到下一次响应。这样可以方便地在新响应中替换系统(或开发者)消息。
+ 当与 `previous_response_id`,一起使用时,来自上一次响应的指令不会延续到下一个响应。这样可以方便地在新响应中替换系统(或开发者)消息。
- `previous_response_id: optional string or null`
- 上一次模型响应的唯一 ID。使用它来创建多轮对话。详细了解 [对话状态](/docs/guides/conversation-state)。不能与 `conversation`.
+ 上一次模型响应的唯一 ID。使用此字段可以创建多轮对话。详细了解 [对话状态](/docs/guides/conversation-state)。无法与 `conversation`.
- `prompt_cache_key: optional string or null`
- 读取或写入提示缓存时使用的密钥。
+ 读取或写入提示缓存时使用的键。
- `prompt_cache_options: optional object { mode, ttl } or null`
- 提示缓存选项。支持 `gpt-5.6` 及更高版本模型。默认情况下,OpenAI 会自动选择一个隐式缓存断点。可以使用 `prompt_cache_breakpoint`。为内容块添加显式断点。每个请求最多可写入四个断点。在缓存匹配时,OpenAI 会考虑对话中最多最近的 80 个断点,且不限制内容块回溯范围。将 `mode` 设置为 `explicit` 以禁用隐式断点。 `ttl` 默认为 `30m`,这是当前唯一支持的值。参见 [提示缓存指南](/docs/guides/prompt-caching) 了解最新详情。
+ 提示缓存的选项。支持 `gpt-5.6` 及更高版本模型。默认情况下,OpenAI 会自动选择一个隐式缓存断点。你可以使用 `prompt_cache_breakpoint`。为内容块添加显式断点。每个请求最多可以写入四个断点。对于缓存匹配,OpenAI 会考虑对话中最近的 80 个断点,且没有内容块回溯限制。设置 `mode` 为 `explicit` 以禁用隐式断点。该 `ttl` 默认为 `30m`,这是当前唯一支持的值。参见 [prompt caching guide](/docs/guides/prompt-caching) 了解当前详情。
- `mode: optional "implicit" or "explicit"`
- 控制是否允许 OpenAI 自动创建隐式缓存断点。默认为 `implicit`。设置为 `implicit`,时,OpenAI 会创建一个隐式断点,并写入请求中最近的最多三个显式断点。设置为 `explicit`,时,OpenAI 不会创建隐式断点,并写入请求中最近的最多四个显式断点。如果没有显式断点,则该请求不使用提示缓存。
+ 控制是否由 OpenAI 自动创建隐式缓存断点。默认为 `implicit`。当设置为 `implicit`,时,OpenAI 会创建一个隐式断点,并写入请求中最多最新的三个显式断点。当设置为 `explicit`,时,OpenAI 不会创建隐式断点,并写入最多最新的四个显式断点。如果没有显式断点,则该请求不使用 prompt caching。
- `"implicit"`
@@ -4368,13 +4368,13 @@
- `ttl: optional "30m"`
- 应用于该请求所写入的每个隐式和显式缓存断点的最短生存时间。默认为 `30m`,这是当前唯一支持的值。后端可能会将缓存条目保留更长时间。
+ 应用于请求写入的每个隐式和显式缓存断点的最短生命周期。默认为 `30m`,这是当前唯一支持的值。后端可能会保留缓存条目更长时间。
- `"30m"`
- `prompt_cache_retention: optional "in_memory" or "24h" or null`
- 本次请求所创建的提示缓存条目的保留时长。
+ 由该请求创建的 prompt cache 条目的保留时长。
- `"in_memory"`
@@ -4382,8 +4382,8 @@
- `service_tier: optional "auto" or "default" or "fast" or 2 more or null`
- 指定用于处理该请求的处理类型。 - 若设置为 'auto',则请求将使用项目设置中配置的服务层级。除非另行配置,项目将使用 'default'。 - 若设置为 'default',则请求将按所选模型的标准定价和性能进行处理。 - 若设置为 '[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。 - 若要在请求级别启用 [Fast 模式](/api/docs/guides/fast-mode) ,请为 Responses 或 Chat Completions 包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定了 `service_tier=fast` 或 `priority` 。 - 若未设置,默认行为为 'auto'。
- 当 `service_tier` 参数时,响应正文将包含基于实际用于处理请求的处理模式的 `service_tier` 值。此响应值可能与参数中设置的值不同。
+ 指定用于处理该请求的处理类型。 - 若设置为 'auto',则请求将使用在项目设置中配置的服务层级进行处理。除非另有配置,否则该项目将使用 'default'。 - 若设置为 'default',则请求将按所选模型的标准定价和性能进行处理。 - 若设置为 '[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。 - 若要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含该 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定了 `service_tier=fast` 或 `priority` 。 - 当未设置时,默认行为为 'auto'。
+ 当设置 `service_tier` 参数时,响应体将基于实际用于处理请求的处理模式返回相应的 `service_tier` 值。此响应值可能与参数中设置的值不同。
- `"auto"`
@@ -4405,7 +4405,7 @@
- `created_at: number`
- 创建压缩对话时的 Unix 时间戳(以秒为单位)。
+ 创建压缩对话时的 Unix 时间戳(单位:秒)。
- `object: "response.compaction"`
@@ -4419,7 +4419,7 @@
- `Message object { id, content, role, 3 more }`
- 与模型之间发送或接收的消息。
+ 发送给模型或来自模型的消息。
- `id: string`
@@ -4445,7 +4445,7 @@
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承其所在请求的 TTL `prompt_cache_options.ttl`;边界不会按 token 块向下取整。
- `mode: "explicit"`
@@ -4455,7 +4455,7 @@
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型的一条文本输出。
+ 模型输出的文本。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
@@ -4463,7 +4463,7 @@
- `FileCitation object { file_id, filename, index, type }`
- 对一个文件的引用。
+ 对文件的引用。
- `file_id: string`
@@ -4475,7 +4475,7 @@
- `index: number`
- 文件列表中该文件的索引。
+ 文件在文件列表中的索引。
- `type: "file_citation"`
@@ -4485,7 +4485,7 @@
- `URLCitation object { end_index, start_index, title, 2 more }`
- 用于生成模型回复的网页资源引用。
+ 用于生成模型响应的网页资源引用。
- `end_index: number`
@@ -4511,7 +4511,7 @@
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
- 用于生成模型回复的容器文件引用。
+ 用于生成模型响应的容器文件引用。
- `container_id: string`
@@ -4549,7 +4549,7 @@
- `index: number`
- 文件列表中该文件的索引。
+ 文件在文件列表中的索引。
- `type: "file_path"`
@@ -4575,7 +4575,7 @@
- `text: string`
- 模型输出的文本。
+ 模型的文本输出。
- `type: "output_text"`
@@ -4595,11 +4595,11 @@
- `SummaryTextContent object { text, type }`
- 模型生成的摘要文本。
+ 来自模型的摘要文本。
- `text: string`
- 到目前为止模型推理输出的摘要。
+ 迄今为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -4609,7 +4609,7 @@
- `ReasoningText object { text, type }`
- 模型生成的推理文本。
+ 来自模型的推理文本。
- `text: string`
@@ -4627,7 +4627,7 @@
- `refusal: string`
- 模型给出的拒绝说明。
+ 模型返回的拒绝说明。
- `type: "refusal"`
@@ -4637,11 +4637,11 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
+ 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- 发送给模型的图像细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
+ 发送给模型的图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -4659,15 +4659,15 @@
- `file_id: optional string or null`
- 发送给模型的文件的 ID。
+ 要发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图像 URL。可以是完全限定的 URL,也可以是 data URL 中的 base64 编码图像。
+ 要发送给模型的图像的 URL。可以是完全限定的 URL,也可以是 data URL 中的 base64 编码图像。
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承其所在请求的 TTL `prompt_cache_options.ttl`;边界不会按 token 块向下取整。
- `mode: "explicit"`
@@ -4677,11 +4677,11 @@
- `ComputerScreenshotContent object { detail, file_id, image_url, 2 more }`
- 计算机屏幕截图。
+ 计算机的屏幕截图。
- `detail: ImageDetail`
- 发送给模型的截图图像的细节级别。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
+ 发送给模型的截图图像的细节级别。取值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: string or null`
@@ -4699,7 +4699,7 @@
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承其所在请求的 TTL `prompt_cache_options.ttl`;边界不会按 token 块向下取整。
- `mode: "explicit"`
@@ -4719,7 +4719,7 @@
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会增加输入 token 用量。使用 `low` 可获得更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
+ 发送给模型的文件的细节级别。使用 `auto` 可让系统选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会增加输入 token 的用量。使用 `low` 可使用更低成本的渲染,或使用 `high` 以更高质量渲染文件。默认为 `auto`.
- `"auto"`
@@ -4729,11 +4729,11 @@
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- 发送给模型的文件的 ID。
+ 要发送给模型的文件的 ID。
- `file_url: optional string`
@@ -4745,7 +4745,7 @@
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会取整到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承其所在请求的 TTL `prompt_cache_options.ttl`;边界不会按 token 块向下取整。
- `mode: "explicit"`
@@ -4755,7 +4755,7 @@
- `role: "unknown" or "user" or "assistant" or 5 more`
- 消息的角色。可选值为 `unknown`, `user`, `assistant`, `system`, `critic`, `discriminator`, `developer`,或 `tool`.
+ 消息的角色。取值为 `unknown`, `user`, `assistant`, `system`, `critic`, `discriminator`, `developer`,或 `tool`.
- `"unknown"`
@@ -4775,7 +4775,7 @@
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。当通过 API 返回条目时填充。
+ 条目的状态。取值为 `in_progress`, `completed`,或 `incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -4791,7 +4791,7 @@
- `phase: optional "commentary" or "final_answer" or null`
- 将消息标记为 `assistant` 中间评论(`commentary`)或最终回答(`final_answer`)。对于类似 `gpt-5.3-codex` 等模型,在发送后续请求时,请在所有助手消息上保留并重新发送 phase 参数——省略它可能会降低性能。该参数不用于用户消息。
+ 将某条 `assistant` 消息标记为中间评论(`commentary`)或最终回答(`final_answer`)。对于类似 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请在所有助手消息上保留并重新发送 phase——省略它可能会导致性能下降。不用于用户消息。
- `"commentary"`
@@ -4805,19 +4805,19 @@
- `call_id: string`
- 该程序条目的稳定调用 ID。
+ 程序条目的稳定调用 ID。
- `code: string`
- 由程序化工具调用执行的 JavaScript 源代码。
+ 由程序化工具调用执行的 JavaScript 源码。
- `fingerprint: string`
- 必须原样回传的不透明程序重放指纹。
+ 必须往返传递的不透明程序回放指纹。
- `type: "program"`
- 该项的类型。始终为 `program`.
+ 项的类型。始终为 `program`.
- `"program"`
@@ -4829,11 +4829,11 @@
- `call_id: string`
- 该程序条目的调用 ID。
+ 程序条目的调用 ID。
- `result: string`
- 该程序条目生成的结果。
+ 程序条目生成的结果。
- `status: "completed" or "incomplete"`
@@ -4845,13 +4845,13 @@
- `type: "program_output"`
- 该项的类型。始终为 `program_output`.
+ 项的类型。始终为 `program_output`.
- `"program_output"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
- 用于运行函数的工具调用。请参阅
+ 运行函数的工具调用。请参阅
[函数调用指南](/docs/guides/function-calling) 了解更多信息。
- `arguments: string`
@@ -4902,7 +4902,7 @@
- `status: optional "in_progress" or "completed" or "incomplete"`
- 该项的状态。取值之一为 `in_progress`, `completed`,或
+ 该项的状态,取值为 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -4923,11 +4923,11 @@
- `call_id: string or null`
- 由模型生成的工具搜索调用的唯一 ID。
+ 模型生成的工具搜索调用的唯一 ID。
- `execution: "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索是由服务端执行还是由客户端执行。
- `"server"`
@@ -4945,13 +4945,13 @@
- `type: "tool_search_call"`
- 该项的类型。始终为 `tool_search_call`.
+ 项的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -4961,11 +4961,11 @@
- `call_id: string or null`
- 由模型生成的工具搜索调用的唯一 ID。
+ 模型生成的工具搜索调用的唯一 ID。
- `execution: "server" or "client"`
- 工具搜索由服务端还是客户端执行。
+ 工具搜索是由服务端执行还是由客户端执行。
- `"server"`
@@ -4983,11 +4983,11 @@
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 工具搜索返回的已加载工具定义。
+ 由工具搜索返回的已加载工具定义。
- `Function object { name, parameters, strict, 5 more }`
- 在你自己的代码中定义一个可供模型选择调用的函数。详细了解 [函数调用](https://platform.openai.com/docs/guides/function-calling).
+ 在你自己的代码中定义一个可供模型选择调用的函数。了解有关 [函数调用](https://platform.openai.com/docs/guides/function-calling).
- `name: string`
@@ -4995,11 +4995,11 @@
- `parameters: map[unknown] or null`
- 用于描述函数参数的 JSON schema 对象。
+ 描述该函数参数的 JSON schema 对象。
- `strict: boolean or null`
- 此函数工具是否启用严格的参数校验。
+ 是否为该函数工具强制执行严格的参数校验。
- `type: "function"`
@@ -5017,29 +5017,29 @@
- `defer_loading: optional boolean`
- 此函数是否被延迟并通过工具搜索加载。
+ 该函数是否被延迟并通过工具搜索加载。
- `description: optional string or null`
- 函数的描述,供模型用来决定是否调用该函数。
+ 对该函数的描述,供模型用于判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述此函数的字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 一个用于描述此函数 string 输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索 tool](https://platform.openai.com/docs/guides/tools-file-search).
+ 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索 工具的类型。通常为 `file_search`.
+ 文件搜索 工具的类型,始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储的 ID。
+ 要搜索的向量存储的 ID 列表。
- `filters: optional ComparisonFilter or CompoundFilter or null`
@@ -5047,7 +5047,7 @@
- `ComparisonFilter object { key, type, value }`
- 用于通过定义的比较操作将指定的属性键与给定值进行比较的筛选条件。
+ 使用已定义的比较运算,将指定的属性键与给定值进行比较的筛选条件。
- `key: string`
@@ -5084,7 +5084,7 @@
- `value: string or number or boolean or array of string or number`
- 要与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 要与属性键进行比较的值;支持 string、number 或 boolean 类型。
- `string`
@@ -5100,15 +5100,15 @@
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的筛选条件数组。各项可以为 `ComparisonFilter` 或 `CompoundFilter`.
+ 组合多个筛选条件的数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于通过定义的比较操作将指定的属性键与给定值进行比较的筛选条件。
+ 使用已定义的比较运算,将指定的属性键与给定值进行比较的筛选条件。
- `unknown`
@@ -5122,7 +5122,7 @@
- `max_num_results: optional number`
- 要返回的最大结果数。该数值应介于 1 到 50 之间(含端点)。
+ 要返回的最大结果数。该数字应在 1 到 50 之间(含)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -5130,15 +5130,15 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于控制互逆排名融合(reciprocal rank fusion)在语义嵌入匹配与稀疏关键词匹配之间平衡程度的权重。
+ 启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡程度的权重。
- `embedding_weight: number`
- 互逆排名融合中嵌入的权重。
+ 倒数排名融合中嵌入的权重。
- `text_weight: number`
- 互逆排名融合中文本匹配的权重。
+ 倒数排名融合中文本的权重。
- `ranker: optional "auto" or "default-2024-11-15"`
@@ -5150,11 +5150,11 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,取值范围为 0 到 1。越接近 1 的数值会尝试仅返回相关性最高的结果,但返回的结果数量可能会更少。
+ 文件搜索的分数阈值,取值范围为 0 到 1。数值越接近 1,尝试返回的结果越相关,但返回的结果数量可能更少。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
@@ -5164,7 +5164,7 @@
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -5196,7 +5196,7 @@
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。了解更多关于
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
@@ -5209,22 +5209,22 @@
- `external_web_access: optional boolean`
- 允许网页搜索实时访问互联网。省略时默认值为 true。当值为 false 时,网页搜索工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 是否允许网页搜索进行实时互联网访问。省略时默认为 true。当为 false 时,网页搜索工具以离线/仅缓存模式运行,不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤条件。
- `allowed_domains: optional array of string or null`
- 允许搜索的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供的域名的子域名也同样被允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索所使用的上下文窗口空间的高级指引。可选值为以下之一 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 用于搜索的上下文窗口空间使用量的高层指导,取值之一为 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -5234,7 +5234,7 @@
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的大致位置。
+ 用户的近似位置。
- `city: optional string or null`
@@ -5242,7 +5242,7 @@
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 用户所在地的两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
- `region: optional string or null`
@@ -5254,22 +5254,22 @@
- `type: optional "approximate"`
- 近似位置的类型。始终为 `approximate`.
+ 位置近似类型,始终为 `approximate`.
- `"approximate"`
- `Mcp object { server_label, type, allowed_callers, 9 more }`
- 通过远程模型上下文协议
- (MCP)服务器,为模型提供对其他工具的访问能力。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
+ 通过远程 Model Context Protocol
+ (MCP)服务器为模型提供额外的工具访问能力。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 该 MCP 服务器的标签,用于在工具调用中标识它。
+ 此 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
- MCP 工具的类型。始终为 `mcp`.
+ MCP 工具的类型,始终为 `mcp`.
- `"mcp"`
@@ -5291,13 +5291,13 @@
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤器对象。
- `read_only: optional boolean`
- 指示工具是否会修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否修改数据或为只读。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则它将匹配此过滤器。
- `tool_names: optional array of string`
@@ -5305,25 +5305,25 @@
- `authorization: optional string`
- 可与远程 MCP 服务器一起使用的 OAuth 访问令牌,可搭配
- 自定义 MCP 服务器 URL 或服务连接器使用。你的应用
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,可与
+ 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
必须处理 OAuth 授权流程并在此处提供令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些连接器。必须提供其中之一
- `server_url`, `connector_id`,或 `tunnel_id` 。了解更多
- 关于服务连接器的 [信息](/docs/guides/tools-remote-mcp#connectors).
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供
+ `server_url`, `connector_id`,或 `tunnel_id` 之一。了解更多
+ 关于服务连接器 [的信息](/docs/guides/tools-remote-mcp#connectors).
- 当前支持的 `connector_id` 值为:
+ 当前支持的 `connector_id` 值包括:
- Dropbox: `connector_dropbox`
- Gmail: `connector_gmail`
- Google Calendar: `connector_googlecalendar`
- Google Drive: `connector_googledrive`
- Microsoft Teams: `connector_microsoftteams`
- - Outlook Calendar: `connector_outlookcalendar`
- - Outlook Email: `connector_outlookemail`
+ - Outlook 日历: `connector_outlookcalendar`
+ - Outlook 邮箱: `connector_outlookemail`
- SharePoint: `connector_sharepoint`
- `"connector_dropbox"`
@@ -5344,7 +5344,7 @@
- `defer_loading: optional boolean`
- 此 MCP 工具是否被延迟,并通过工具搜索发现。
+ 该 MCP 工具是否被延迟加载并通过工具搜索发现。
- `headers: optional map[string] or null`
@@ -5358,18 +5358,18 @@
- `McpToolApprovalFilter object { always, never }`
指定 MCP 服务器中哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的筛选器对象
- ,这些工具需要审批。
+ `always`, `never`,也可以是与需要审批的工具相关联的过滤器对象
+ 。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤器对象。
- `read_only: optional boolean`
- 指示工具是否会修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否修改数据或为只读。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则它将匹配此过滤器。
- `tool_names: optional array of string`
@@ -5377,13 +5377,13 @@
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤器对象。
- `read_only: optional boolean`
- 指示工具是否会修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否修改数据或为只读。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则它将匹配此过滤器。
- `tool_names: optional array of string`
@@ -5391,8 +5391,8 @@
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值之一 `always` 或
- `never`。当设置为 `always`,时,所有工具都需要审批。当
+ 为所有工具指定统一的审批策略。可选值为 `always` 或
+ `never`。之一。当设置为 `always`,时,所有工具都需要审批。当
设置为 `never`,时,所有工具都不需要审批。
- `"always"`
@@ -5405,23 +5405,23 @@
- `server_url: optional string`
- MCP 服务器的 URL。以下之一 `server_url`, `connector_id`,或
- `tunnel_id` 必须提供。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 必须提供其中之一。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。以下之一
- `server_url`, `connector_id`,或 `tunnel_id` 必须提供。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供其中之一。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词响应的工具。
+ 运行 Python 代码以辅助生成对提示词回应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID 或一个对象,该对象
- 指定可供你的代码使用的已上传文件 ID,以及一个
- 可选的 `memory_limit` 设置。
+ 代码解释器容器。可以是容器 ID,也可以是一个对象,用于
+ 指定可供代码使用的已上传文件 ID,以及一个可填的
+ 设置。 `memory_limit` 配置。
- `string`
@@ -5429,7 +5429,7 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要用于运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
- `type: "auto"`
@@ -5439,7 +5439,7 @@
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -5469,29 +5469,29 @@
- `allowed_domains: array of string`
- 当类型为时允许访问的域名列表 `allowlist`.
+ 当 type 为 `allowlist`.
- `type: "allowlist"`
- 仅允许向指定域进行出站网络访问。始终为 `allowlist`.
+ 仅允许向指定域进行出站访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 用于已加入白名单域的可选域范围密钥。
+ 允许列表中域的可选域作用域密钥。
- `domain: string`
- 与该密钥关联的域。
+ 与密钥关联的域。
- `name: string`
- 为该域注入的密钥名称。
+ 要为该域注入的密钥名称。
- `value: string`
- 为该域注入的密钥值。
+ 要为该域注入的密钥值。
- `type: "code_interpreter"`
@@ -5527,7 +5527,7 @@
- `action: optional "generate" or "edit" or "auto"`
- 生成新图像还是编辑已有图像。默认值: `auto`.
+ 是生成新图像还是编辑现有图像。默认值: `auto`.
- `"generate"`
@@ -5538,9 +5538,9 @@
- `background: optional "transparent" or "opaque" or "auto"`
设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。之一。受支持的 GPT Image 模型可使用透明背景。对于
- 受支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该功能处于预览阶段。当使用
+ `opaque`,或 `auto`。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。使用
`transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -5551,7 +5551,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像风格和特征(尤其是面部特征)时所投入的精力。该参数仅在 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型中受支持,在 `gpt-image-1-mini`。中不受支持。支持的值包括 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时将付出的努力程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`。支持。支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -5559,16 +5559,16 @@
- `input_image_mask: optional object { file_id, image_url }`
- 用于局部重绘的可选蒙版。包含 `image_url`
+ 用于修复的可选遮罩。包含 `image_url`
(字符串,可选)和 `file_id` (字符串,可选)。
- `file_id: optional string`
- 蒙版图像的文件 ID。
+ 遮罩图像的文件 ID。
- `image_url: optional string`
- Base64 编码的蒙版图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
@@ -5606,11 +5606,11 @@
- `output_compression: optional number`
- 输出图像的压缩级别。默认值:100。
+ 输出图片的压缩级别。默认值:100。
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`,或
+ 生成图片的输出格式。取值之一 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -5621,11 +5621,11 @@
- `partial_images: optional number`
- 在流式模式下要生成的中间图片数量,范围为 0(默认值)到 3。
+ 在流式模式下生成的部分图片数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
- 生成图像的质量。可选值为 `low`, `medium`, `high`,
+ 生成图片的质量。取值之一 `low`, `medium`, `high`,
或 `auto`。默认值: `auto`.
- `"low"`
@@ -5638,13 +5638,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定的任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,以及 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动调整尺寸的模型支持。对于 `dall-e-2`,使用以下值之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下值之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图片的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的纵横比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT image 模型支持; `auto` 受支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定的任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,以及 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动调整尺寸的模型支持。对于 `dall-e-2`,使用以下值之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下值之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图片的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的纵横比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT image 模型支持; `auto` 受支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -5688,13 +5688,13 @@
- `type: "container_auto"`
- 为此请求自动创建一个容器
+ 自动为本次请求创建容器
- `"container_auto"`
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -5718,7 +5718,7 @@
- `skills: optional array of SkillReference or InlineSkill`
- 通过 ID 或内联数据引用的可选技能列表。
+ 可选的技能列表,通过 id 或内联数据引用。
- `SkillReference object { skill_id, type, version }`
@@ -5756,13 +5756,13 @@
- `media_type: "application/zip"`
- 内联技能负载的媒体类型,必须为 `application/zip`.
+ 内联技能负载的媒体类型。必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能来源的类型,必须为 `base64`.
+ 内联技能源的类型。必须为 `base64`.
- `"base64"`
@@ -5794,7 +5794,7 @@
- `path: string`
- 包含该技能的目录路径。
+ 包含技能的目录路径。
- `ContainerReference object { container_id, type }`
@@ -5804,7 +5804,7 @@
- `type: "container_reference"`
- 引用通过 /v1/containers 端点创建的容器。
+ 引用通过 /v1/containers 端点创建的容器
- `"container_reference"`
@@ -5814,7 +5814,7 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中识别它。
+ 自定义工具的名称,用于在工具调用中标识它。
- `type: "custom"`
@@ -5832,7 +5832,7 @@
- `defer_loading: optional boolean`
- 此工具是否应被延迟并通过工具搜索发现。
+ 该工具是否应被延迟,并通过工具搜索发现。
- `description: optional string`
@@ -5876,7 +5876,7 @@
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入共享命名空间。
- `description: string`
@@ -5884,7 +5884,7 @@
- `name: string`
- 用于工具调用中的命名空间名称(例如, `crm`).
+ 在工具调用中使用的命名空间名称(例如, `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
@@ -5908,19 +5908,19 @@
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 该函数是否应被延迟,并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 用于描述此函数工具字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
+ 用于描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该项不描述内容数组输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,对于兼容的 schema,Responses 会尝试使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -5928,7 +5928,7 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中识别它。
+ 自定义工具的名称,用于在工具调用中标识它。
- `type: "custom"`
@@ -5946,7 +5946,7 @@
- `defer_loading: optional boolean`
- 此工具是否应被延迟并通过工具搜索发现。
+ 该工具是否应被延迟,并通过工具搜索发现。
- `description: optional string`
@@ -5974,11 +5974,11 @@
- `description: optional string or null`
- 展示给模型的、由客户端执行的工具搜索工具的描述。
+ 展示给模型的客户端执行工具搜索工具的描述。
- `execution: optional "server" or "client"`
- 工具搜索是由服务端执行还是由客户端执行。
+ 工具搜索是由服务端还是由客户端执行。
- `"server"`
@@ -5990,7 +5990,7 @@
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具会在网页中搜索可在响应中使用的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会搜索网页以获取可在回复中使用的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
@@ -6008,7 +6008,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索所使用的上下文窗口空间的高级指引。可选值为以下之一 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 用于搜索的上下文窗口空间使用量的高层指导,取值之一为 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -6018,11 +6018,11 @@
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户所在位置。
+ 用户所在的位置。
- `type: "approximate"`
- 近似位置的类型。始终为 `approximate`.
+ 位置近似类型,始终为 `approximate`.
- `"approximate"`
@@ -6032,7 +6032,7 @@
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 用户所在地的两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
- `region: optional string or null`
@@ -6062,23 +6062,23 @@
- `type: "tool_search_output"`
- 该项的类型。始终为 `tool_search_output`.
+ 项的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `AdditionalTools object { id, role, tools, type }`
- `id: string`
- 附加工具条目的唯一 ID。
+ 额外工具条目的唯一 ID。
- `role: "unknown" or "user" or "assistant" or 5 more`
- 提供附加工具的角色。
+ 提供额外工具的角色。
- `"unknown"`
@@ -6098,11 +6098,11 @@
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目中可用的附加工具定义。
+ 在此条目中可用的额外工具定义。
- `Function object { name, parameters, strict, 5 more }`
- 在你自己的代码中定义一个可供模型选择调用的函数。详细了解 [函数调用](https://platform.openai.com/docs/guides/function-calling).
+ 在你自己的代码中定义一个可供模型选择调用的函数。了解有关 [函数调用](https://platform.openai.com/docs/guides/function-calling).
- `name: string`
@@ -6110,11 +6110,11 @@
- `parameters: map[unknown] or null`
- 用于描述函数参数的 JSON schema 对象。
+ 描述该函数参数的 JSON schema 对象。
- `strict: boolean or null`
- 此函数工具是否启用严格的参数校验。
+ 是否为该函数工具强制执行严格的参数校验。
- `type: "function"`
@@ -6132,29 +6132,29 @@
- `defer_loading: optional boolean`
- 此函数是否被延迟并通过工具搜索加载。
+ 该函数是否被延迟并通过工具搜索加载。
- `description: optional string or null`
- 函数的描述,供模型用来决定是否调用该函数。
+ 对该函数的描述,供模型用于判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述此函数的字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 一个用于描述此函数 string 输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索 tool](https://platform.openai.com/docs/guides/tools-file-search).
+ 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索 工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索 工具的类型。通常为 `file_search`.
+ 文件搜索 工具的类型,始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储的 ID。
+ 要搜索的向量存储的 ID 列表。
- `filters: optional ComparisonFilter or CompoundFilter or null`
@@ -6162,15 +6162,15 @@
- `ComparisonFilter object { key, type, value }`
- 用于通过定义的比较操作将指定的属性键与给定值进行比较的筛选条件。
+ 使用已定义的比较运算,将指定的属性键与给定值进行比较的筛选条件。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个筛选条件 `and` 或 `or`.
+ 使用 `and` 或 `or`.
- `max_num_results: optional number`
- 要返回的最大结果数。该数值应介于 1 到 50 之间(含端点)。
+ 要返回的最大结果数。该数字应在 1 到 50 之间(含)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -6178,15 +6178,15 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于控制互逆排名融合(reciprocal rank fusion)在语义嵌入匹配与稀疏关键词匹配之间平衡程度的权重。
+ 启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡程度的权重。
- `embedding_weight: number`
- 互逆排名融合中嵌入的权重。
+ 倒数排名融合中嵌入的权重。
- `text_weight: number`
- 互逆排名融合中文本匹配的权重。
+ 倒数排名融合中文本的权重。
- `ranker: optional "auto" or "default-2024-11-15"`
@@ -6198,11 +6198,11 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,取值范围为 0 到 1。越接近 1 的数值会尝试仅返回相关性最高的结果,但返回的结果数量可能会更少。
+ 文件搜索的分数阈值,取值范围为 0 到 1。数值越接近 1,尝试返回的结果越相关,但返回的结果数量可能更少。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
@@ -6212,7 +6212,7 @@
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -6244,7 +6244,7 @@
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示词相关的来源。了解更多关于
+ 在互联网上搜索与提示相关的来源。详细了解
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
@@ -6257,22 +6257,22 @@
- `external_web_access: optional boolean`
- 允许网页搜索实时访问互联网。省略时默认值为 true。当值为 false 时,网页搜索工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 是否允许网页搜索进行实时互联网访问。省略时默认为 true。当为 false 时,网页搜索工具以离线/仅缓存模式运行,不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的筛选条件。
+ 搜索的过滤条件。
- `allowed_domains: optional array of string or null`
- 允许搜索的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名同样被允许。
+ 搜索所允许的域名。如果未提供,则允许所有域名。
+ 所提供的域名的子域名也同样被允许。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索所使用的上下文窗口空间的高级指引。可选值为以下之一 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 用于搜索的上下文窗口空间使用量的高层指导,取值之一为 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -6282,7 +6282,7 @@
- `user_location: optional object { city, country, region, 2 more } or null`
- 用户的大致位置。
+ 用户的近似位置。
- `city: optional string or null`
@@ -6290,7 +6290,7 @@
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 用户所在地的两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
- `region: optional string or null`
@@ -6302,22 +6302,22 @@
- `type: optional "approximate"`
- 近似位置的类型。始终为 `approximate`.
+ 位置近似类型,始终为 `approximate`.
- `"approximate"`
- `Mcp object { server_label, type, allowed_callers, 9 more }`
- 通过远程模型上下文协议
- (MCP)服务器,为模型提供对其他工具的访问能力。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
+ 通过远程 Model Context Protocol
+ (MCP)服务器为模型提供额外的工具访问能力。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 该 MCP 服务器的标签,用于在工具调用中标识它。
+ 此 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
- MCP 工具的类型。始终为 `mcp`.
+ MCP 工具的类型,始终为 `mcp`.
- `"mcp"`
@@ -6339,13 +6339,13 @@
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤器对象。
- `read_only: optional boolean`
- 指示工具是否会修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否修改数据或为只读。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则它将匹配此过滤器。
- `tool_names: optional array of string`
@@ -6353,25 +6353,25 @@
- `authorization: optional string`
- 可与远程 MCP 服务器一起使用的 OAuth 访问令牌,可搭配
- 自定义 MCP 服务器 URL 或服务连接器使用。你的应用
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,可与
+ 自定义 MCP 服务器 URL 或服务连接器一起使用。你的应用
必须处理 OAuth 授权流程并在此处提供令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的那些连接器。必须提供其中之一
- `server_url`, `connector_id`,或 `tunnel_id` 。了解更多
- 关于服务连接器的 [信息](/docs/guides/tools-remote-mcp#connectors).
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些。必须提供
+ `server_url`, `connector_id`,或 `tunnel_id` 之一。了解更多
+ 关于服务连接器 [的信息](/docs/guides/tools-remote-mcp#connectors).
- 当前支持的 `connector_id` 值为:
+ 当前支持的 `connector_id` 值包括:
- Dropbox: `connector_dropbox`
- Gmail: `connector_gmail`
- Google Calendar: `connector_googlecalendar`
- Google Drive: `connector_googledrive`
- Microsoft Teams: `connector_microsoftteams`
- - Outlook Calendar: `connector_outlookcalendar`
- - Outlook Email: `connector_outlookemail`
+ - Outlook 日历: `connector_outlookcalendar`
+ - Outlook 邮箱: `connector_outlookemail`
- SharePoint: `connector_sharepoint`
- `"connector_dropbox"`
@@ -6392,7 +6392,7 @@
- `defer_loading: optional boolean`
- 此 MCP 工具是否被延迟,并通过工具搜索发现。
+ 该 MCP 工具是否被延迟加载并通过工具搜索发现。
- `headers: optional map[string] or null`
@@ -6406,18 +6406,18 @@
- `McpToolApprovalFilter object { always, never }`
指定 MCP 服务器中哪些工具需要审批。可以是
- `always`, `never`,或与工具关联的筛选器对象
- ,这些工具需要审批。
+ `always`, `never`,也可以是与需要审批的工具相关联的过滤器对象
+ 。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤器对象。
- `read_only: optional boolean`
- 指示工具是否会修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否修改数据或为只读。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则它将匹配此过滤器。
- `tool_names: optional array of string`
@@ -6425,13 +6425,13 @@
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤器对象。
- `read_only: optional boolean`
- 指示工具是否会修改数据或为只读。如果某个
- MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否修改数据或为只读。如果某个
+ MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则它将匹配此过滤器。
- `tool_names: optional array of string`
@@ -6439,8 +6439,8 @@
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值之一 `always` 或
- `never`。当设置为 `always`,时,所有工具都需要审批。当
+ 为所有工具指定统一的审批策略。可选值为 `always` 或
+ `never`。之一。当设置为 `always`,时,所有工具都需要审批。当
设置为 `never`,时,所有工具都不需要审批。
- `"always"`
@@ -6453,23 +6453,23 @@
- `server_url: optional string`
- MCP 服务器的 URL。以下之一 `server_url`, `connector_id`,或
- `tunnel_id` 必须提供。
+ MCP 服务器的 URL。 `server_url`, `connector_id`,或
+ `tunnel_id` 必须提供其中之一。
- `tunnel_id: optional string`
- 用于替代直接服务器 URL 的安全 MCP 隧道 ID。以下之一
- `server_url`, `connector_id`,或 `tunnel_id` 必须提供。
+ 用于代替直接服务器 URL 的安全 MCP 隧道 ID。
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供其中之一。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示词响应的工具。
+ 运行 Python 代码以辅助生成对提示词回应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID 或一个对象,该对象
- 指定可供你的代码使用的已上传文件 ID,以及一个
- 可选的 `memory_limit` 设置。
+ 代码解释器容器。可以是容器 ID,也可以是一个对象,用于
+ 指定可供代码使用的已上传文件 ID,以及一个可填的
+ 设置。 `memory_limit` 配置。
- `string`
@@ -6477,7 +6477,7 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要用于运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定要运行代码的文件 ID。
- `type: "auto"`
@@ -6487,7 +6487,7 @@
- `file_ids: optional array of string`
- 可供你的代码使用的已上传文件的可选列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -6543,7 +6543,7 @@
- `action: optional "generate" or "edit" or "auto"`
- 生成新图像还是编辑已有图像。默认值: `auto`.
+ 是生成新图像还是编辑现有图像。默认值: `auto`.
- `"generate"`
@@ -6554,9 +6554,9 @@
- `background: optional "transparent" or "opaque" or "auto"`
设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。之一。受支持的 GPT Image 模型可使用透明背景。对于
- 受支持的 GPT Image 模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该功能处于预览阶段。当使用
+ `opaque`,或 `auto`。透明背景适用于受支持的
+ GPT Image 模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。使用
`transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -6567,7 +6567,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像风格和特征(尤其是面部特征)时所投入的精力。该参数仅在 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型中受支持,在 `gpt-image-1-mini`。中不受支持。支持的值包括 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时将付出的努力程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不受 `gpt-image-1-mini`。支持。支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -6575,16 +6575,16 @@
- `input_image_mask: optional object { file_id, image_url }`
- 用于局部重绘的可选蒙版。包含 `image_url`
+ 用于修复的可选遮罩。包含 `image_url`
(字符串,可选)和 `file_id` (字符串,可选)。
- `file_id: optional string`
- 蒙版图像的文件 ID。
+ 遮罩图像的文件 ID。
- `image_url: optional string`
- Base64 编码的蒙版图像。
+ Base64 编码的遮罩图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
@@ -6622,11 +6622,11 @@
- `output_compression: optional number`
- 输出图像的压缩级别。默认值:100。
+ 输出图片的压缩级别。默认值:100。
- `output_format: optional "png" or "webp" or "jpeg"`
- 生成图像的输出格式。可选值为 `png`, `webp`,或
+ 生成图片的输出格式。取值之一 `png`, `webp`,或
`jpeg`。默认值: `png`.
- `"png"`
@@ -6637,11 +6637,11 @@
- `partial_images: optional number`
- 在流式模式下要生成的中间图片数量,范围为 0(默认值)到 3。
+ 在流式模式下生成的部分图片数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
- 生成图像的质量。可选值为 `low`, `medium`, `high`,
+ 生成图片的质量。取值之一 `low`, `medium`, `high`,
或 `auto`。默认值: `auto`.
- `"low"`
@@ -6654,13 +6654,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定的任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,以及 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动调整尺寸的模型支持。对于 `dall-e-2`,使用以下值之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下值之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图片的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的纵横比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT image 模型支持; `auto` 受支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定的任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,以及 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动调整尺寸的模型支持。对于 `dall-e-2`,使用以下值之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下值之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图片的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且所请求的纵横比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。所请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受 GPT image 模型支持; `auto` 受支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -6712,7 +6712,7 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中识别它。
+ 自定义工具的名称,用于在工具调用中标识它。
- `type: "custom"`
@@ -6730,7 +6730,7 @@
- `defer_loading: optional boolean`
- 此工具是否应被延迟并通过工具搜索发现。
+ 该工具是否应被延迟,并通过工具搜索发现。
- `description: optional string`
@@ -6742,7 +6742,7 @@
- `Namespace object { description, name, tools, type }`
- 在共享命名空间下对函数/自定义工具进行分组。
+ 将函数/自定义工具归入共享命名空间。
- `description: string`
@@ -6750,7 +6750,7 @@
- `name: string`
- 用于工具调用中的命名空间名称(例如, `crm`).
+ 在工具调用中使用的命名空间名称(例如, `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
@@ -6774,19 +6774,19 @@
- `defer_loading: optional boolean`
- 此函数是否应被延迟并通过工具搜索发现。
+ 该函数是否应被延迟,并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 用于描述此函数工具字符串输出中所编码 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
+ 用于描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。该项不描述内容数组输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。如果省略,对于兼容的 schema,Responses 会尝试使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -6794,7 +6794,7 @@
- `name: string`
- 自定义工具的名称,用于在工具调用中识别它。
+ 自定义工具的名称,用于在工具调用中标识它。
- `type: "custom"`
@@ -6812,7 +6812,7 @@
- `defer_loading: optional boolean`
- 此工具是否应被延迟并通过工具搜索发现。
+ 该工具是否应被延迟,并通过工具搜索发现。
- `description: optional string`
@@ -6840,11 +6840,11 @@
- `description: optional string or null`
- 展示给模型的、由客户端执行的工具搜索工具的描述。
+ 展示给模型的客户端执行工具搜索工具的描述。
- `execution: optional "server" or "client"`
- 工具搜索是由服务端执行还是由客户端执行。
+ 工具搜索是由服务端还是由客户端执行。
- `"server"`
@@ -6856,7 +6856,7 @@
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具会在网页中搜索可在响应中使用的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 该工具会搜索网页以获取可在回复中使用的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
@@ -6874,7 +6874,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索所使用的上下文窗口空间的高级指引。可选值为以下之一 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 用于搜索的上下文窗口空间使用量的高层指导,取值之一为 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -6884,11 +6884,11 @@
- `user_location: optional object { type, city, country, 2 more } or null`
- 用户所在位置。
+ 用户所在的位置。
- `type: "approximate"`
- 近似位置的类型。始终为 `approximate`.
+ 位置近似类型,始终为 `approximate`.
- `"approximate"`
@@ -6898,7 +6898,7 @@
- `country: optional string or null`
- 两位字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 用户所在地的两位字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
- `region: optional string or null`
@@ -6928,7 +6928,7 @@
- `type: "additional_tools"`
- 该项的类型。始终为 `additional_tools`.
+ 项的类型。始终为 `additional_tools`.
- `"additional_tools"`
@@ -6939,7 +6939,7 @@
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
由你的代码生成的函数调用的输出。
- 可以是字符串或输出内容列表。
+ 可以是字符串,也可以是输出内容列表。
- `StringOutput = string`
@@ -6947,7 +6947,7 @@
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
@@ -6955,7 +6955,7 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
+ 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -7002,15 +7002,15 @@
- `name: optional string`
- 生成该输出的工具名称。
+ 产生该输出的工具的名称。
- `namespace: optional string`
- 生成该输出的工具命名空间。
+ 产生该输出的工具的命名空间。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 该项的状态。取值之一为 `in_progress`, `completed`,或
+ 该项的状态,取值为 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -7034,7 +7034,7 @@
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。取值之一 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -7059,11 +7059,11 @@
- `attributes: optional map[string or number or boolean] or null`
- 可以附加到对象的 16 组键值对。这对于以结构化
- 格式存储对象的附加信息,以及通过 API 或仪表板查询对象非常有用。键为字符串,
- 最大长度为 64 个字符。值为字符串,最大
- 长度为 512 个字符、布尔值或数字。
- 长度为 512 个字符、布尔值或数字。
+ 可附加到对象的 16 个键值对。可用于以结构化
+ 格式存储关于对象的额外信息,并通过 API 或仪表板查询对象。键为字符串,
+ 格式存储关于对象的额外信息,并通过 接口 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。值为字符串(最大
+ 长度为 512 个字符)、布尔值或数字。
- `string`
@@ -7077,11 +7077,11 @@
- `filename: optional string`
- 文件的名称。
+ 文件名称。
- `score: optional number`
- 文件的相关性评分,取值在 0 到 1 之间。
+ 文件的相关性得分,介于 0 到 1 之间。
- `text: optional string`
@@ -7089,21 +7089,21 @@
- `WebSearchCall object { id, action, status, type }`
- 网页搜索工具调用的结果。参阅
- [网页搜索指南](/docs/guides/tools-web-search) 了解更多信息。
+ 网页搜索 工具调用的结果。详见
+ [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
- `id: string`
- 网页搜索工具调用的唯一 ID。
+ 网页搜索 工具调用的唯一 ID。
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述此次 网页搜索调用中所执行的具体操作的对象。
- 包含模型使用网页方式的详细信息(search、open_page、find_in_page)。
+ 描述本次 网页搜索 调用中所执行的具体操作的对象。
+ 包含模型如何使用网页(search、open_page、find_in_page)的详细信息。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" - 执行 网页搜索查询。
+ 操作类型 "search" - 执行 网页搜索 查询。
- `type: "search"`
@@ -7135,7 +7135,7 @@
- `OpenPage object { type, url }`
- 操作类型 "open_page" - 从搜索结果中打开特定 URL。
+ 操作类型 "open_page" - 打开搜索结果中的特定 URL。
- `type: "open_page"`
@@ -7149,11 +7149,11 @@
- `FindInPage object { pattern, type, url }`
- 操作类型 "find_in_page":在已加载页面内搜索匹配模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索某个模式。
- `pattern: string`
- 在页面中要搜索的模式或文本。
+ 在页面内搜索的模式或文本。
- `type: "find_in_page"`
@@ -7163,7 +7163,7 @@
- `url: string`
- 搜索该模式的页面的 URL。
+ 搜索该模式的页面 URL。
- `status: "in_progress" or "searching" or "completed" or "failed"`
@@ -7185,19 +7185,19 @@
- `ImageGenerationCall object { id, result, status, type }`
- 模型发起的图像生成请求。
+ 模型发起的图片生成请求。
- `id: string`
- 图像生成调用的唯一 ID。
+ 该图片生成调用的唯一 ID。
- `result: string or null`
- 以 base64 编码的生成图像。
+ 以 base64 编码的生成图片。
- `status: "in_progress" or "completed" or "generating" or "failed"`
- 图像生成调用的状态。
+ 该图片生成调用的状态。
- `"in_progress"`
@@ -7209,14 +7209,14 @@
- `type: "image_generation_call"`
- 图像生成调用的类型。始终为 `image_generation_call`.
+ 图片生成调用的类型。始终为 `image_generation_call`.
- `"image_generation_call"`
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
- 对计算机使用工具的工具调用。参见
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ 对计算机使用工具的工具调用。参阅
+ [computer use guide](/docs/guides/tools-computer-use) 了解更多信息。
- `id: string`
@@ -7224,11 +7224,11 @@
- `call_id: string`
- 在向工具调用返回输出时所使用的标识符。
+ 使用输出响应工具调用时所使用的标识符。
- `pending_safety_checks: array of object { id, code, message }`
- 计算机调用的待处理安全检查。
+ 计算机调用中待处理的安全检查。
- `id: string`
@@ -7240,11 +7240,11 @@
- `message: optional string or null`
- 待处理安全检查的详细信息。
+ 关于待处理安全检查的详细信息。
- `status: "in_progress" or "completed" or "incomplete"`
- 该项的状态。取值之一为 `in_progress`, `completed`,或
+ 该项的状态,取值为 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -7255,7 +7255,7 @@
- `type: "computer_call"`
- 计算机调用的类型。始终为 `computer_call`.
+ 计算机调用的类型,始终为 `computer_call`.
- `"computer_call"`
@@ -7269,7 +7269,7 @@
- `button: "left" or "right" or "wheel" or 2 more`
- 指示在点击时按下了哪个鼠标按钮。取值之一为 `left`, `right`, `wheel`, `back`,或 `forward`.
+ 指示点击时按下的鼠标按键,取值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -7283,17 +7283,17 @@
- `type: "click"`
- 指定事件类型。对于点击操作,该属性始终为 `click`.
+ 指定事件类型。对于点击操作,此属性始终为 `click`.
- `"click"`
- `x: number`
- 发生点击的 x 坐标。
+ 点击发生的 x 坐标。
- `y: number`
- 发生点击的 y 坐标。
+ 点击发生的 y 坐标。
- `keys: optional array of string or null`
@@ -7356,7 +7356,7 @@
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
@@ -7380,11 +7380,11 @@
- `x: number`
- 要移至的 x 坐标。
+ 要移动到的 x 坐标。
- `y: number`
- 要移至的 y 坐标。
+ 要移动到的 y 坐标。
- `keys: optional array of string or null`
@@ -7420,11 +7420,11 @@
- `x: number`
- 发生滚动时的 x 坐标。
+ 发生滚动事件的 x 坐标。
- `y: number`
- 发生滚动时的 y 坐标。
+ 发生滚动事件的 y 坐标。
- `keys: optional array of string or null`
@@ -7456,8 +7456,8 @@
- `actions: optional ComputerActionList`
- 针对 `computer_use`。的扁平化批量操作。每个操作都包含一个
- `type` 鉴别字段以及操作专属字段。
+ 扁平化的批量操作列表,针对 `computer_use`。每个操作包含一个
+ `type` 判别字段以及操作特有的字段。
- `Click object { button, type, x, 2 more }`
@@ -7473,7 +7473,7 @@
- `Keypress object { keys, type }`
- 模型希望执行的一系列按键操作。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
@@ -7511,8 +7511,8 @@
- `type: "computer_screenshot"`
- 指定事件类型。对于计算机截图,此属性
- 始终设置为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性始终
+ 设置为 `computer_screenshot`.
- `"computer_screenshot"`
@@ -7526,8 +7526,8 @@
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 输入消息的状态。取值为 `in_progress`, `completed`,或
- `incomplete`。当通过 API 返回输入项时填充。
+ 消息输入的状态。取值之一 `in_progress`, `completed`,或
+ `incomplete`。当输入项通过 API 返回时填充。
- `"completed"`
@@ -7545,7 +7545,7 @@
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 上报的、已被
+ 由 API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -7558,18 +7558,18 @@
- `message: optional string or null`
- 待处理安全检查的详细信息。
+ 关于待处理安全检查的详细信息。
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成响应时使用的思维链描述。请务必将这些项包含在
- 传回给 Responses API `input` 的输入中,以便在手动管理
- 上下文时用于对话的后续轮次。
- [管理上下文](/docs/guides/conversation-state).
+ 对推理模型在生成回复时所使用的思维链的描述。如果你正在手动
+ 管理上下文,请务必在后续对话轮次中将这些项包含到你的 `input` Responses API 中
+ ,以便在手动管理上下文时供后续轮次使用
+ [手动管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -7581,7 +7581,7 @@
- `text: string`
- 到目前为止模型推理输出的摘要。
+ 迄今为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -7609,19 +7609,19 @@
- `encrypted_content: optional string or null`
- 推理项的加密内容。默认情况下会填充该字段
- 用于通过 `POST /v1/responses` 和 WebSocket
+ 推理项的加密内容。默认填充该字段
+ 适用于通过 `POST /v1/responses` 和 WebSocket
`response.create` 请求返回的推理项。
- 流式传输时,请在后续请求中使用已完成的推理项及其
- `encrypted_content` 中的 `response.output_item.done` 事件。
- 后续请求。该 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。这一点尤其
- 重要,当 `store` 为 `false` 或使用 Zero Data Retention 时。
+ 在流式传输时,请在后续请求中使用来自
+ `encrypted_content` 事件的 `response.output_item.done` 已完成推理项及其
+ 。该 `encrypted_content` 在
+ `response.output_item.added` 中可能不完整。这一点在
+ 为以下情况时尤为 `store` 重要 `false` :或使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 该项的状态。取值之一为 `in_progress`, `completed`,或
+ 该项的状态,取值为 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回条目时填充。
- `"in_progress"`
@@ -7632,7 +7632,7 @@
- `Compaction object { id, encrypted_content, type, created_by }`
- 由该模型生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由 API 生成的压缩项 [`v1/responses/compact` 接口](/docs/api-reference/responses/compact).
- `id: string`
@@ -7640,17 +7640,17 @@
- `encrypted_content: string`
- 由压缩产生的加密内容。
+ 由压缩生成的加密内容。
- `type: "compaction"`
- 该项的类型。始终为 `compaction`.
+ 项的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `CodeInterpreterCall object { id, code, container_id, 3 more }`
@@ -7658,11 +7658,11 @@
- `id: string`
- 代码解释器工具调用的唯一 ID。
+ 该代码解释器工具调用的唯一 ID。
- `code: string or null`
- 要运行的代码,若不可用则为 null。
+ 要运行的代码,如果不可用则为 null。
- `container_id: string`
@@ -7670,7 +7670,7 @@
- `outputs: array of object { logs, type } or object { type, url } or null`
- 代码解释器生成的输出,例如日志或图像。
+ 代码解释器生成的输出,例如日志或图片。
如果没有可用输出,可以为 null。
- `Logs object { logs, type }`
@@ -7689,7 +7689,7 @@
- `Image object { type, url }`
- 代码解释器输出的图像。
+ 代码解释器输出的图片。
- `type: "image"`
@@ -7699,11 +7699,11 @@
- `url: string`
- 代码解释器输出图像的 URL。
+ 代码解释器输出图片的 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
- 代码解释器工具调用的状态。有效值为 `in_progress`, `completed`, `incomplete`, `interpreting`,以及 `failed`.
+ 代码解释器工具调用的状态。有效值为 `in_progress`, `completed`, `incomplete`, `interpreting`,和 `failed`.
- `"in_progress"`
@@ -7723,11 +7723,11 @@
- `LocalShellCall object { id, action, call_id, 2 more }`
- 在本地 shell 上运行命令的工具调用。
+ 用于在本地 shell 上运行命令的工具调用。
- `id: string`
- 本地 shell 调用的唯一 ID。
+ 该本地 shell 调用的唯一 ID。
- `action: object { command, env, type, 3 more }`
@@ -7739,7 +7739,7 @@
- `env: map[string]`
- 为该命令设置的环境变量。
+ 为命令设置的环境变量。
- `type: "exec"`
@@ -7749,19 +7749,19 @@
- `timeout_ms: optional number or null`
- 该命令的可选超时时间(毫秒)。
+ 命令的可选超时时间,以毫秒为单位。
- `user: optional string or null`
- 运行该命令所使用的可选用户。
+ 用于运行命令的可选用户。
- `working_directory: optional string or null`
- 运行该命令的可选工作目录。
+ 运行命令时使用的可选工作目录。
- `call_id: string`
- 由模型生成的本地 shell 工具调用的唯一 ID。
+ 模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -7785,7 +7785,7 @@
- `id: string`
- 由模型生成的本地 shell 工具调用的唯一 ID。
+ 模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -7799,7 +7799,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 该项的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`.
+ 该项的状态,取值为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -7809,11 +7809,11 @@
- `ShellCall object { id, action, call_id, 5 more }`
- 在托管环境中执行一个或多个 shell 命令的工具调用。
+ 在托管环境中执行一条或多条 shell 命令的工具调用。
- `id: string`
- shell 工具调用的唯一 ID。当此项通过 API 返回时填充。
+ shell 工具调用的唯一 ID。通过 API 返回此条目时会填充该字段。
- `action: object { commands, max_output_length, timeout_ms }`
@@ -7823,7 +7823,7 @@
- `max_output_length: number or null`
- 每个命令返回结果的可选最大字符数。
+ 每个命令返回内容的可选最大字符数。
- `timeout_ms: number or null`
@@ -7831,15 +7831,15 @@
- `call_id: string`
- 由模型生成的 shell 工具调用的唯一 ID。
+ 模型生成的 shell 工具调用的唯一 ID。
- `environment: ResponseLocalEnvironment or ResponseContainerReference or null`
- 表示使用本地环境执行 shell 操作。
+ 表示使用本地环境来执行 shell 操作。
- `ResponseLocalEnvironment object { type }`
- 表示使用本地环境执行 shell 操作。
+ 表示使用本地环境来执行 shell 操作。
- `type: "local"`
@@ -7871,7 +7871,7 @@
- `type: "shell_call"`
- 该项的类型。始终为 `shell_call`.
+ 项的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -7909,11 +7909,11 @@
- `call_id: string`
- 由模型生成的 shell 工具调用的唯一 ID。
+ 模型生成的 shell 工具调用的唯一 ID。
- `max_output_length: number or null`
- shell 命令输出的最大长度。此值由模型生成,应与原始输出一起传回。
+ shell 命令输出的最大长度。该值由模型生成,应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
@@ -7921,11 +7921,11 @@
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(带有退出码)或超时结果。
- `Timeout object { type }`
- 表示 shell 调用超出了其配置的时间限制。
+ 表示该 shell 调用超出了其配置的时间限制。
- `type: "timeout"`
@@ -7935,7 +7935,7 @@
- `Exit object { exit_code, type }`
- 表示 shell 命令已执行完毕并返回了退出码。
+ 表示该 shell 命令已执行完毕并返回了退出码。
- `exit_code: number`
@@ -7949,19 +7949,19 @@
- `stderr: string`
- 捕获到的标准错误输出。
+ 已捕获的标准错误输出。
- `stdout: string`
- 捕获到的标准输出。
+ 已捕获的标准输出。
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值为 `in_progress`, `completed`,或 `incomplete`.
+ shell 调用输出的状态。取值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -7997,7 +7997,7 @@
- `created_by: optional string`
- 创建该条目的行为者的标识符。
+ 创建该条目的参与者的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -8021,53 +8021,53 @@
- `diff: string`
- Diff to apply.
+ 要应用的差异。
- `path: string`
- Path of the file to create.
+ 要创建的文件的路径。
- `type: "create_file"`
- Create a new file with the provided diff.
+ 使用提供的差异创建新文件。
- `"create_file"`
- `DeleteFile object { path, type }`
- Instruction describing how to delete a file via the apply_patch tool.
+ 描述如何通过 apply_patch 工具删除文件的说明。
- `path: string`
- Path of the file to delete.
+ 要删除的文件的路径。
- `type: "delete_file"`
- Delete the specified file.
+ 删除指定的文件。
- `"delete_file"`
- `UpdateFile object { diff, path, type }`
- Instruction describing how to update a file via the apply_patch tool.
+ 描述如何通过 apply_patch 工具更新文件的说明。
- `diff: string`
- Diff to apply.
+ 要应用的差异。
- `path: string`
- Path of the file to update.
+ 要更新的文件的路径。
- `type: "update_file"`
- Update an existing file with the provided diff.
+ 使用提供的差异更新现有文件。
- `"update_file"`
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。取值为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。之一 `in_progress` 或 `completed`.
- `"in_progress"`
@@ -8075,7 +8075,7 @@
- `type: "apply_patch_call"`
- 该项的类型。始终为 `apply_patch_call`.
+ 项的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -8105,7 +8105,7 @@
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- The output emitted by an apply patch tool call.
+ apply patch 工具调用发出的输出。
- `id: string`
@@ -8117,7 +8117,7 @@
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。取值为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。之一 `completed` 或 `failed`.
- `"completed"`
@@ -8125,7 +8125,7 @@
- `type: "apply_patch_call_output"`
- 该项的类型。始终为 `apply_patch_call_output`.
+ 项的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -8151,11 +8151,11 @@
- `created_by: optional string`
- The ID of the entity that created this tool call output.
+ 创建此工具调用输出的实体 ID。
- `output: optional string or null`
- Optional textual output returned by the apply patch tool.
+ apply patch 工具返回的可选文本输出。
- `McpListTools object { id, server_label, tools, 2 more }`
@@ -8179,29 +8179,29 @@
- `name: string`
- 工具的名称。
+ 该工具的名称。
- `annotations: optional unknown or null`
- 关于该工具的附加注解。
+ 关于该工具的附加注释。
- `description: optional string or null`
- 工具的描述。
+ 该工具的描述。
- `type: "mcp_list_tools"`
- 该项的类型。始终为 `mcp_list_tools`.
+ 项的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 服务器无法列出工具时的错误消息。
+ 如果服务器无法列出工具,则显示错误消息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 对工具调用的人工审批请求。
+ 工具调用的人工审批请求。
- `id: string`
@@ -8209,7 +8209,7 @@
- `arguments: string`
- 该工具的参数 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
@@ -8221,7 +8221,7 @@
- `type: "mcp_approval_request"`
- 该项的类型。始终为 `mcp_approval_request`.
+ 项的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
@@ -8243,17 +8243,17 @@
- `type: "mcp_approval_response"`
- 该项的类型。始终为 `mcp_approval_response`.
+ 项的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
- `reason: optional string or null`
- 可选的决策原因。
+ 决策的可选原因。
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上工具的调用。
+ 对 MCP 服务器上某个工具的调用。
- `id: string`
@@ -8261,11 +8261,11 @@
- `arguments: string`
- 传递给该工具的参数 JSON 字符串。
+ 传递给该工具的参数的 JSON 字符串。
- `name: string`
- 已运行工具的名称。
+ 已运行的工具的名称。
- `server_label: string`
@@ -8273,14 +8273,14 @@
- `type: "mcp_call"`
- 该项的类型。始终为 `mcp_call`.
+ 项的类型。始终为 `mcp_call`.
- `"mcp_call"`
- `approval_request_id: optional string or null`
MCP 工具调用审批请求的唯一标识符。
- 在后续的 `mcp_approval_response` 输入中包含此值以批准或拒绝相应的工具调用。
+ 在后续的 `mcp_approval_response` 输入中包含此值,以批准或拒绝相应的工具调用。
- `error: optional McpToolCallError or null`
@@ -8334,7 +8334,7 @@
- `CustomToolCall object { call_id, input, name, 4 more }`
- 对模型创建的自定义工具的调用。
+ 由模型创建的、对自定义工具的调用。
- `call_id: string`
@@ -8356,7 +8356,7 @@
- `id: optional string`
- 在 OpenAI 平台上自定义工具调用的唯一 ID。
+ 该自定义工具调用在 OpenAI 平台上的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -8384,16 +8384,16 @@
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 你代码中自定义工具调用的输出,被发回给模型。
+ 由你的代码生成的自定义工具调用输出,会被发送回模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到自定义工具调用。
+ 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 由你的代码产生的自定义工具调用的输出。
- 可以是字符串或输出内容列表。
+ 由你的代码生成的自定义工具调用的输出。
+ 可以是字符串,也可以是输出内容列表。
- `StringOutput = string`
@@ -8401,7 +8401,7 @@
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 自定义工具调用的文本、图片或文件输出。
+ 自定义工具调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
@@ -8409,7 +8409,7 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
+ 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -8423,7 +8423,7 @@
- `id: optional string`
- 在 OpenAI 平台上自定义工具调用输出的唯一 ID。
+ 该自定义工具调用输出在 OpenAI 平台上的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -8451,32 +8451,32 @@
- `usage: ResponseUsage`
- Token accounting for the compaction pass, including cached, reasoning, and total tokens.
+ 压缩过程的 token 统计,包括缓存、推理和总 token。
- `input_tokens: number`
- The number of input tokens.
+ 输入 token 数。
- `input_tokens_details: object { cache_write_tokens, cached_tokens }`
- A detailed breakdown of the input tokens.
+ 输入 token 的详细细分。
- `cache_write_tokens: number`
- The number of input tokens that were written to the cache.
+ 写入缓存的输入 token 数。
- `cached_tokens: number`
- The number of tokens that were retrieved from the cache.
- [More on prompt caching](/docs/guides/prompt-caching).
+ 从缓存中检索的 token 数。
+ [详细了解提示词缓存](/docs/guides/prompt-caching).
- `output_tokens: number`
- The number of output tokens.
+ 输出 token 数。
- `output_tokens_details: object { reasoning_tokens }`
- A detailed breakdown of the output tokens.
+ 输出 token 的详细细分。
- `reasoning_tokens: number`
@@ -8486,10 +8486,6 @@
使用的 token 总数。
- - `compute_units: optional number or null`
-
- 本次请求的计算单元。在可用时,当前为 null。
-
### 示例
```http
@@ -8537,8 +8533,7 @@ curl https://api.openai.com/v1/responses/compact \
"output_tokens_details": {
"reasoning_tokens": 0
},
- "total_tokens": 0,
- "compute_units": 0
+ "total_tokens": 0
}
}
```
diff --git a/docs/zh/api/reference/resources/responses/methods/create.md b/docs/zh/api/reference/resources/responses/methods/create.md
index 9b7d067..8ab2089 100644
--- a/docs/zh/api/reference/resources/responses/methods/create.md
+++ b/docs/zh/api/reference/resources/responses/methods/create.md
@@ -1,4 +1,4 @@
-> 如需查看完整的文档索引,请参阅 [llms.txt](/llms.txt)。你可以在页面 URL 末尾追加 `.md` 以获取文档页面的 Markdown 版本。
+> 完整的文档索引请参见 [llms.txt](/llms.txt)。在页面 URL 末尾追加 `.md` 即可获取该页面的 Markdown 版本。
## 创建模型响应
@@ -8,11 +8,11 @@
[图像](/docs/guides/images) 输入以生成 [文本](/docs/guides/text)
或 [JSON](/docs/guides/structured-outputs) 输出。让模型调用
你自己的 [自定义代码](/docs/guides/function-calling) 或使用内置的
-[工具](/docs/guides/tools) 例如 [网页搜索](/docs/guides/tools-web-search)
+[工具](/docs/guides/tools) 如 [网页搜索](/docs/guides/tools-web-search)
或 [文件搜索](/docs/guides/tools-file-search) 以使用你自己的数据
作为模型响应的输入。
-### 正文参数
+### Body Parameters
- `background: optional boolean or null`
@@ -29,12 +29,12 @@
- `compact_threshold: optional number or null`
- 触发此条目压缩操作的 token 阈值。
+ 在此条目触发压缩时所使用的 token 阈值。
- `conversation: optional string or ResponseConversationParam or null`
- 此响应所属的对话。该对话中的条目会被前置到 `input_items` 用于本次响应请求。
- 本次响应的输入条目和输出条目会在响应完成后自动添加到此对话中。
+ 此响应所属的对话。该对话中的条目会预置到 `input_items` 此次响应请求的输入中。
+ 此响应的输入条目和输出条目会在响应完成后自动添加到此对话中。
- `ConversationID = string`
@@ -50,15 +50,15 @@
- `include: optional array of ResponseIncludable or null`
- 指定要包含在模型响应中的其他输出数据。目前支持的值包括:
+ 指定要在模型响应中包含的额外输出数据。目前支持的值包括:
- `web_search_call.action.sources`:包含 网页搜索 工具调用的来源。
- `code_interpreter_call.outputs`:在代码解释器工具调用项中包含 Python 代码执行的输出。
- - `computer_call_output.output.image_url`:包含来自计算机调用输出的图像 URL。
+ - `computer_call_output.output.image_url`:包含计算机调用输出中的图像 URL。
- `file_search_call.results`:包含 文件搜索 工具调用的搜索结果。
- - `message.input_image.image_url`:包含来自输入消息的图像 URL。
+ - `message.input_image.image_url`:包含输入消息中的图像 URL。
- `message.output_text.logprobs`:在助手消息中包含 logprobs。
- - `reasoning.encrypted_content`:在推理项输出中包含加密版本的推理 token。这使得在以无状态方式使用 Responses API 时(例如当 `store` 参数被设置为 `false`,或当组织已加入零数据保留计划时),推理项可在多轮对话中使用。
+ - `reasoning.encrypted_content`:在推理项输出中包含加密版本的推理 token。这使得在使用 Responses API 以无状态方式进行的多轮对话中能够使用推理项(例如当 `store` 参数被设置为 `false`,或当组织已加入零数据保留计划时)。
- `"file_search_call.results"`
@@ -78,9 +78,9 @@
- `input: optional string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 传递给模型的文本、图像或文件输入,用于生成响应。
+ 提供给模型的文本、图像或文件输入,用于生成响应。
- 了解更多:
+ 了解详情:
- [文本输入与输出](/docs/guides/text)
- [图像输入](/docs/guides/images)
@@ -90,25 +90,25 @@
- `TextInput = string`
- 传递给模型的文本输入,等同于带有
- `user` 角色的文本输入。
+ 对模型的文本输入,等同于使用以下 role 的文本输入:
+ `user` role。
- `InputItemList = array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 包含一个或多个输入项的列表,传递给模型,这些输入项可
- 包含不同的内容类型。
+ 包含一个或多个输入项的列表,用于提供给模型,其中包含
+ 不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 传递给模型的消息输入,其角色用于指示指令优先级。通过
- 层级角色给出的指令优先级,高于 `developer` 或 `system` 角色给出的指令。带有
- 层级角色的指令优先于使用 `user` 角色给出的指令。带有
- `assistant` 角色的消息被视为模型在之前的交互中
- 生成的内容。
+ 对模型的消息输入,使用 role 指示指令的优先级层次。使用以下 role
+ 给出的指令优先于使用以下 role `developer` 或 `system` 给出的指令。
+ 优先级高于使用以下 role 给出的指令。使用以下 role `user` 的消息被假定为模型在先前交互中生成的
+ `assistant` 消息。使用以下 role 的消息被假定为模型在先前
+ 交互中生成的。
- `content: string or ResponseInputMessageContentList`
- 传递给模型的文本、图像或音频输入,用于生成响应。
+ 提供给模型的文本、图像或音频输入,用于生成响应。
也可以包含之前的助手响应。
- `TextInput = string`
@@ -117,7 +117,7 @@
- `ResponseInputMessageContentList = array of ResponseInputContent`
- 发送给模型的一条或多条输入项的列表,包含不同的内容
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
@@ -136,7 +136,7 @@
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会对齐到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
- `mode: "explicit"`
@@ -146,7 +146,7 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
+ 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
@@ -168,15 +168,15 @@
- `file_id: optional string or null`
- 发送给模型的文件的 ID。
+ 发送给模型的文件 ID。
- `image_url: optional string or null`
- 发送给模型的图像的 URL。可以是完整的 URL,也可以是 data URL 中的 base64 编码图像。
+ 发送给模型的图像 URL。完全限定的 URL 或 data URL 中 base64 编码的图像。
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会对齐到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
- `mode: "explicit"`
@@ -196,7 +196,7 @@
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会增加输入 token 使用量。使用 `low` 用于以更低成本进行渲染,或 `high` 以更高质量渲染文件时使用。默认为 `auto`.
+ 发送给模型的文件的细节级别。使用 `auto` 让系统选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会增加输入 token 使用量。使用 `low` 以降低渲染成本,或 `high` 以更高质量渲染文件。默认为 `auto`.
- `"auto"`
@@ -206,23 +206,23 @@
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- 发送给模型的文件的 ID。
+ 发送给模型的文件 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会对齐到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
- `mode: "explicit"`
@@ -232,7 +232,7 @@
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色,取值为 `user`, `assistant`, `system`,或
+ 消息输入的角色。可选值为 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -245,9 +245,9 @@
- `phase: optional "commentary" or "final_answer" or null`
- 将该 `assistant` 消息标记为中间说明性内容(`commentary`)或最终答复(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段在所有助手消息上——丢弃它可能导致性能下降。不适用于用户消息。
+ 将 `assistant` 消息标记为中间评论(`commentary`)或最终答案(`final_answer`).
+ 对于像 `gpt-5.3-codex` 及更高版本等模型,在发送后续请求时,请保留并重新发送
+ 阶段到所有助手消息——丢弃它可能会降低性能。不用于用户消息。
- `"commentary"`
@@ -255,24 +255,24 @@
- `type: optional "message"`
- 消息输入的类型,始终为 `message`.
+ 消息输入的类型。始终为 `message`.
- `"message"`
- `Message object { content, role, status, type }`
- 传递给模型的消息输入,其角色用于指示指令优先级。通过
- 层级角色给出的指令优先级,高于 `developer` 或 `system` 角色给出的指令。带有
- 层级角色的指令优先于使用 `user` 角色的文本输入。
+ 对模型的消息输入,使用 role 指示指令的优先级层次。使用以下 role
+ 给出的指令优先于使用以下 role `developer` 或 `system` 给出的指令。
+ 优先级高于使用以下 role 给出的指令。使用以下 role `user` role。
- `content: ResponseInputMessageContentList`
- 发送给模型的一条或多条输入项的列表,包含不同的内容
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色,取值为 `user`, `system`,或 `developer`.
+ 消息输入的角色。可选值为 `user`, `system`,或 `developer`.
- `"user"`
@@ -282,8 +282,8 @@
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态,取值为 `in_progress`, `completed`,或
- `incomplete`。之一。当通过 API 返回条目时填充。
+ 项的状态。可选值为 `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回项时填充。
- `"in_progress"`
@@ -293,13 +293,13 @@
- `type: optional "message"`
- 消息输入的类型,始终设置为 `message`.
+ 消息输入的类型。始终设置为 `message`.
- `"message"`
- `ResponseOutputMessage object { id, content, role, 3 more }`
- 模型输出的消息。
+ 模型的输出消息。
- `id: string`
@@ -311,11 +311,11 @@
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型输出的文本。
+ 模型的文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
@@ -341,7 +341,7 @@
- `URLCitation object { end_index, start_index, title, 2 more }`
- 用于生成模型回答的网页资源引用。
+ 用于生成模型响应的网页资源引用。
- `end_index: number`
@@ -367,7 +367,7 @@
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
- 用于生成模型回答的容器文件引用。
+ 用于生成模型响应的容器文件引用。
- `container_id: string`
@@ -431,7 +431,7 @@
- `text: string`
- 模型输出的文本。
+ 模型生成的文本输出。
- `type: "output_text"`
@@ -445,7 +445,7 @@
- `refusal: string`
- 模型的拒绝解释。
+ 模型给出的拒绝解释。
- `type: "refusal"`
@@ -461,8 +461,8 @@
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`,或
- `incomplete`。之一。通过 API 返回输入项时填充。
+ 消息输入的状态。可选值为 `in_progress`, `completed`,或
+ `incomplete`。之一。当通过 API 返回输入项时填充该字段。
- `"in_progress"`
@@ -478,9 +478,9 @@
- `phase: optional "commentary" or "final_answer" or null`
- 将该 `assistant` 消息标记为中间说明性内容(`commentary`)或最终答复(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段在所有助手消息上——丢弃它可能导致性能下降。不适用于用户消息。
+ 将 `assistant` 消息标记为中间评论(`commentary`)或最终答案(`final_answer`).
+ 对于像 `gpt-5.3-codex` 及更高版本等模型,在发送后续请求时,请保留并重新发送
+ 阶段到所有助手消息——丢弃它可能会降低性能。不用于用户消息。
- `"commentary"`
@@ -488,7 +488,7 @@
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。参见
+ 文件搜索 工具调用的结果。请参阅
[文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
- `id: string`
@@ -497,11 +497,11 @@
- `queries: array of string`
- 用于搜索文件的查询。
+ 用于搜索文件的查询语句。
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。可选值为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -526,11 +526,11 @@
- `attributes: optional map[string or number or boolean] or null`
- 可以附加到对象的 16 个键值对集合。可用于
- 以结构化格式存储有关对象的附加信息,并通过
- API 或控制台查询对象。键为字符串
- 最大长度为 64 个字符。值是最大
- 长度为 512 个字符的字符串、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于
+ 以结构化格式存储对象的附加信息,并通过
+ API 或控制台查询对象。键为字符串,
+ 最大长度为 64 个字符。值为最大
+ 长度 512 个字符的字符串、布尔值或数字。
- `string`
@@ -548,7 +548,7 @@
- `score: optional number`
- 文件的相关性评分,介于 0 和 1 之间。
+ 文件的相关性得分——介于 0 和 1 之间的值。
- `text: optional string`
@@ -556,16 +556,16 @@
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
- 对计算机使用工具的工具调用。参见
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ 对计算机使用工具的工具调用。请参阅
+ [computer use 指南](/docs/guides/tools-computer-use) 了解更多信息。
- `id: string`
- 计算机调用的唯一 ID。
+ 该计算机调用的唯一 ID。
- `call_id: string`
- 在向工具调用提供输出时使用的标识符。
+ 在用输出响应工具调用时使用的标识符。
- `pending_safety_checks: array of object { id, code, message }`
@@ -581,12 +581,12 @@
- `message: optional string or null`
- 有关待处理安全检查的详细信息。
+ 关于待处理安全检查的详细信息。
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值为 `in_progress`, `completed`,或
- `incomplete`。之一。当通过 API 返回条目时填充。
+ 该条目的状态。取值之一: `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回项时填充。
- `"in_progress"`
@@ -596,21 +596,21 @@
- `type: "computer_call"`
- 计算机调用的类型,恒为 `computer_call`.
+ 计算机调用的类型。始终为 `computer_call`.
- `"computer_call"`
- `action: optional ComputerAction`
- 点击动作。
+ 点击操作。
- `Click object { button, type, x, 2 more }`
- 点击动作。
+ 点击操作。
- `button: "left" or "right" or "wheel" or 2 more`
- 指明点击时按下的鼠标按键。取值为 `left`, `right`, `wheel`, `back`,或 `forward`.
+ 表示点击时按下的鼠标按键。取值之一: `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -624,21 +624,21 @@
- `type: "click"`
- 指定事件类型。对于点击动作,该属性恒为 `click`.
+ 指定事件类型。对于点击操作,此属性始终为 `click`.
- `"click"`
- `x: number`
- 点击发生位置的 x 坐标。
+ 发生点击的 x 坐标。
- `y: number`
- 点击发生位置的 y 坐标。
+ 发生点击的 y 坐标。
- `keys: optional array of string or null`
- 点击时按住的按键。
+ 点击时按住的键。
- `DoubleClick object { keys, type, x, y }`
@@ -646,21 +646,21 @@
- `keys: array of string or null`
- 双击时按住的按键。
+ 双击时按住的键。
- `type: "double_click"`
- 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,此属性始终设置为 `double_click`.
- `"double_click"`
- `x: number`
- 双击发生位置的 x 坐标。
+ 发生双击的 x 坐标。
- `y: number`
- 双击发生位置的 y 坐标。
+ 发生双击的 y 坐标。
- `Drag object { path, type, keys }`
@@ -668,7 +668,7 @@
- `path: array of object { x, y }`
- 一个由坐标构成的数组,表示拖动动作的路径。坐标将作为对象数组出现,例如
+ 表示拖动动作路径的坐标数组。坐标将作为对象数组出现,例如
```
[
@@ -687,25 +687,25 @@
- `type: "drag"`
- 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,此属性始终设置为 `drag`.
- `"drag"`
- `keys: optional array of string or null`
- 拖动鼠标时按住的按键。
+ 拖动鼠标时按住的键。
- `Keypress object { keys, type }`
- 模型希望执行的按键操作的集合。
+ 模型希望执行的按键集合。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的键组合。这是一个字符串数组,每个字符串表示一个键。
- `type: "keypress"`
- 指定事件类型。对于按键动作,该属性始终设置为 `keypress`.
+ 指定事件类型。对于按键动作,此属性始终设置为 `keypress`.
- `"keypress"`
@@ -715,7 +715,7 @@
- `type: "move"`
- 指定事件类型。对于移动动作,该属性始终设置为 `move`.
+ 指定事件类型。对于移动动作,此属性始终设置为 `move`.
- `"move"`
@@ -729,7 +729,7 @@
- `keys: optional array of string or null`
- 在移动鼠标时按住的按键。
+ 在移动鼠标时按住的键。
- `Screenshot object { type }`
@@ -761,19 +761,19 @@
- `x: number`
- 发生滚动事件的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动事件的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的按键。
+ 滚动时按住的键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -781,7 +781,7 @@
- `type: "type"`
- 指定事件类型。对于输入操作,此属性始终设置为 `type`.
+ 指定事件类型。对于 type 操作,此属性始终设置为 `type`.
- `"type"`
@@ -797,12 +797,12 @@
- `actions: optional ComputerActionList`
- 针对的扁平化批处理操作 `computer_use`。每个操作都包含一个
- `type` 判别字段以及操作特有的字段。
+ 针对 `computer_use`。展平后的批量操作。每个操作都包含一个
+ `type` 判别字段以及操作专属字段。
- `Click object { button, type, x, 2 more }`
- 点击动作。
+ 点击操作。
- `DoubleClick object { keys, type, x, y }`
@@ -814,7 +814,7 @@
- `Keypress object { keys, type }`
- 模型希望执行的按键操作的集合。
+ 模型希望执行的按键集合。
- `Move object { type, x, y, keys }`
@@ -830,7 +830,7 @@
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -842,7 +842,7 @@
- `call_id: string`
- 生成该输出的计算机工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
@@ -861,21 +861,21 @@
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_call_output"`
- 计算机工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用的输出类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `id: optional string or null`
- 计算机工具调用输出的 ID。
+ 计算机工具调用的输出 ID。
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 由 API 报告的、已被开发者确认的安全检查。
+ 已被开发者确认的 API 所报告的安全检查。
- `id: string`
@@ -887,11 +887,11 @@
- `message: optional string or null`
- 有关待处理安全检查的详细信息。
+ 关于待处理安全检查的详细信息。
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值为 `in_progress`, `completed`,或 `incomplete`。之一。通过 API 返回输入项时填充。
+ 消息输入的状态。可选值为 `in_progress`, `completed`,或 `incomplete`。之一。当通过 API 返回输入项时填充该字段。
- `"in_progress"`
@@ -901,21 +901,21 @@
- `WebSearchCall object { id, action, status, type }`
- 网页搜索 工具调用的结果。请参阅
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ 网页搜索工具调用的结果。请参阅
+ [网页搜索指南](/docs/guides/tools-web-search) 了解更多信息。
- `id: string`
- 网页搜索 工具调用的唯一 ID。
+ 网页搜索工具调用的唯一 ID。
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述本次 网页搜索 调用中所执行的具体操作的对象。
+ 描述此次 网页搜索调用中所执行具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" - 执行 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -937,7 +937,7 @@
- `type: "url"`
- 来源类型。始终为 `url`.
+ 来源的类型。始终为 `url`.
- `"url"`
@@ -947,7 +947,7 @@
- `OpenPage object { type, url }`
- 操作类型 "open_page" —— 从搜索结果中打开指定的 URL。
+ 操作类型 "open_page" - 打开搜索结果中的指定 URL。
- `type: "open_page"`
@@ -961,11 +961,11 @@
- `FindInPage object { pattern, type, url }`
- 操作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索某个模式。
- `pattern: string`
- 要在页面中搜索的模式或文本。
+ 要在页面内搜索的模式或文本。
- `type: "find_in_page"`
@@ -1010,7 +1010,7 @@
- `name: string`
- 要运行的函数名称。
+ 要运行的函数的名称。
- `type: "function_call"`
@@ -1048,8 +1048,8 @@
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值为 `in_progress`, `completed`,或
- `incomplete`。之一。当通过 API 返回条目时填充。
+ 该条目的状态。取值之一: `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回项时填充。
- `"in_progress"`
@@ -1089,7 +1089,7 @@
- `prompt_cache_breakpoint: optional object { mode } or null`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会对齐到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
- `mode: "explicit"`
@@ -1099,7 +1099,7 @@
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
+ 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision)
- `type: "input_image"`
@@ -1113,15 +1113,15 @@
- `file_id: optional string or null`
- 发送给模型的文件的 ID。
+ 发送给模型的文件 ID。
- `image_url: optional string or null`
- 发送给模型的图像的 URL。可以是完整的 URL,也可以是 data URL 中的 base64 编码图像。
+ 发送给模型的图像 URL。完全限定的 URL 或 data URL 中 base64 编码的图像。
- `prompt_cache_breakpoint: optional object { mode } or null`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会对齐到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
- `mode: "explicit"`
@@ -1141,7 +1141,7 @@
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会增加输入 token 使用量。使用 `low` 用于以更低成本进行渲染,或 `high` 以更高质量渲染文件时使用。默认为 `auto`.
+ 发送给模型的文件的细节级别。使用 `auto` 让系统选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会增加输入 token 使用量。使用 `low` 以降低渲染成本,或 `high` 以更高质量渲染文件。默认为 `auto`.
- `"auto"`
@@ -1155,19 +1155,19 @@
- `file_id: optional string or null`
- 发送给模型的文件的 ID。
+ 发送给模型的文件 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会对齐到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
- `mode: "explicit"`
@@ -1183,7 +1183,7 @@
- `id: optional string or null`
- 函数工具调用输出的唯一 ID。当此条目通过 API 返回时填充。
+ 函数工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
- `call_id: optional string or null`
@@ -1215,15 +1215,15 @@
- `name: optional string or null`
- 生成该输出的工具的名称。
+ 产生该输出的工具名称。
- `namespace: optional string or null`
- 生成该输出的工具的命名空间。
+ 产生该输出的工具命名空间。
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值为 `in_progress`, `completed`,或 `incomplete`。之一。当通过 API 返回条目时填充。
+ 该条目的状态。取值之一: `in_progress`, `completed`,或 `incomplete`。当通过 API 返回项时填充。
- `"in_progress"`
@@ -1281,7 +1281,7 @@
- `name: string`
- 要调用的函数的名称。
+ 要调用的函数名称。
- `parameters: map[unknown] or null`
@@ -1289,7 +1289,7 @@
- `strict: boolean or null`
- 是否对该函数工具强制执行严格参数验证。
+ 是否对该函数工具强制执行严格的参数校验。
- `type: "function"`
@@ -1307,54 +1307,54 @@
- `defer_loading: optional boolean`
- 此函数是否被延迟加载并通过工具搜索加载。
+ 此函数是否被延迟,并通过工具搜索加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 对该函数的描述。供模型用于判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 用于描述此函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 用于描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 用于从已上传文件中搜索相关内容文件搜索 tool [文件搜索 tool](https://platform.openai.com/docs/guides/tools-file-search).
+ 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索 tool 的类型。始终为 `file_search`.
+ 文件搜索工具的类型,始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库 ID。
+ 要搜索的向量存储的 ID 列表。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的过滤器。
+ 要应用的筛选条件。
- `ComparisonFilter object { key, type, value }`
- 用于将指定属性键与给定值按照定义的比较运算进行比较的过滤器。
+ 用于将指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
- `key: string`
- 用于与值进行比较的键。
+ 用于与该值进行比较的键。
- `type: "eq" or "ne" or "gt" or 5 more`
指定比较运算符: `eq`, `ne`, `gt`, `gte`, `lt`, `lte`, `in`, `nin`.
- - `eq`: 等于
- - `ne`: 不等于
- - `gt`: 大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `eq`:等于
+ - `ne`:不等于
+ - `gt`:大于
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:属于
+ - `nin`:不属于
- `"eq"`
@@ -1374,7 +1374,7 @@
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性键进行比较的值;支持字符串、数字或布尔类型。
- `string`
@@ -1390,15 +1390,15 @@
- `CompoundFilter object { filters, type }`
- 使用以下方式合并多个过滤器 `and` 或 `or`.
+ 使用以下方式组合多个筛选条件 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的过滤器数组。条目可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的筛选条件数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将指定属性键与给定值按照定义的比较运算进行比较的过滤器。
+ 用于将指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
- `unknown`
@@ -1412,7 +1412,7 @@
- `max_num_results: optional number`
- 返回的最大结果数。该数字应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -1420,15 +1420,15 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于控制互逆排序融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
+ 在启用混合搜索时,控制倒数排名融合中语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
- 在互逆排序融合中嵌入的权重。
+ 倒数排名融合中嵌入的权重。
- `text_weight: number`
- 在互逆排序融合中文本的权重。
+ 倒数排名融合中文本的权重。
- `ranker: optional "auto" or "default-2024-11-15"`
@@ -1440,11 +1440,11 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数字会尝试仅返回最相关的结果,但可能返回的结果更少。
+ 文件搜索的分数阈值,取值范围为 0 到 1。越接近 1 的数值会尝试仅返回最相关的结果,但返回的结果可能更少。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
@@ -1454,15 +1454,15 @@
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
- 计算机显示屏的高度。
+ 计算机显示器的高度。
- `display_width: number`
- 计算机显示屏的宽度。
+ 计算机显示器的宽度。
- `environment: "windows" or "mac" or "linux" or 2 more`
@@ -1486,12 +1486,12 @@
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示相关的来源。详细了解
+ 在互联网上搜索与提示相关来源。了解更多关于
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索 工具的类型。可选值为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型。取以下值之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -1499,7 +1499,7 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 进行实时互联网访问。若省略,默认值为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索实时访问互联网。省略时默认为 true。当为 false 时,网页搜索工具以离线/仅缓存模式运行,并且不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
@@ -1508,13 +1508,13 @@
- `allowed_domains: optional array of string or null`
搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 同时允许所提供域名的子域名。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级使用指导。可选值为 `low`, `medium`,或 `high`. `medium` 是默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。取以下值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -1550,12 +1550,12 @@
- `Mcp object { server_label, type, allowed_callers, 9 more }`
- 允许模型通过远程模型上下文协议
- (MCP)服务器访问其他工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
+ 通过远程 Model Context Protocol
+ (MCP) 服务器为模型提供对其他工具的访问权限。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 此 MCP 服务器的标签,用于在工具调用中识别它。
- `type: "mcp"`
@@ -1573,21 +1573,21 @@
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许使用的工具名称列表或筛选对象。
+ 允许使用的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许使用的工具名称字符串数组
+ 允许使用的工具名称的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -1595,17 +1595,17 @@
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,可以与自定义 MCP 服务器
- URL 或服务连接器一起使用。你的应用程序必须处理 OAuth 授权流
- 并在此处提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,既可
+ 与自定义 MCP 服务器 URL 一起使用,也可与服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并在此处提供令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的连接器。必须提供以下之一。详细
- `server_url`, `connector_id`,或 `tunnel_id` 了解关于服务连接器
- about service connectors [here](/docs/guides/tools-remote-mcp#connectors).
+ 服务连接器的标识符,例如 ChatGPT 中提供的那些。必须提供
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一。详细了解
+ 服务连接器 [here](/docs/guides/tools-remote-mcp#connectors).
- Currently supported `connector_id` values are:
+ 目前支持的 `connector_id` 值包括:
- Dropbox: `connector_dropbox`
- Gmail: `connector_gmail`
@@ -1634,32 +1634,32 @@
- `defer_loading: optional boolean`
- Whether this MCP tool is deferred and discovered via tool search.
+ 此 MCP 工具是否为延迟加载,并通过工具搜索发现。
- `headers: optional map[string] or null`
- Optional HTTP headers to send to the MCP server. Use for authentication
- or other purposes.
+ 发送到 MCP 服务器的可选 HTTP 标头。用于身份验证
+ 或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- Specify which of the MCP server's tools require approval.
+ 指定 MCP 服务器的哪些工具需要批准。
- `McpToolApprovalFilter object { always, never }`
- Specify which of the MCP server's tools require approval. Can be
- `always`, `never`, or a filter object associated with tools
- that require approval.
+ 指定 MCP 服务器的哪些工具需要批准。可以是
+ `always`, `never`,或与需要批准的工具相关联的筛选器对象
+ 。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -1667,13 +1667,13 @@
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -1681,9 +1681,9 @@
- `McpToolApprovalSetting = "always" or "never"`
- Specify a single approval policy for all tools. One of `always` 或
- `never`. When set to `always`, all tools will require approval. When
- set to `never`, all tools will not require approval.
+ 为所有工具指定一个统一的批准策略。可选值包括 `always` 或
+ `never`。当设置为 `always`,时,所有工具都需要批准。当
+ 设置为 `never`,时,所有工具都不需要批准。
- `"always"`
@@ -1691,26 +1691,26 @@
- `server_description: optional string`
- Optional description of the MCP server, used to provide more context.
+ MCP 服务器的可选描述,用于提供更多上下文。
- `server_url: optional string`
- MCP 服务器的 URL。必须提供以下之一: `server_url`, `connector_id`,或
- `tunnel_id` 必须提供其中之一。
+ MCP 服务器的 URL。必须提供以下其中一项: `server_url`, `connector_id`,或
+ `tunnel_id` 。
- `tunnel_id: optional string`
- 用于代替直接服务器 URL 的安全 MCP 隧道 ID。必须提供以下之一:
- `server_url`, `connector_id`,或 `tunnel_id` 必须提供其中之一。
+ 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供以下其中一项:
+ `server_url`, `connector_id`,或 `tunnel_id` 。
- `CodeInterpreter object { container, type, allowed_callers }`
- 一个运行 Python 代码以帮助生成提示词回复的工具。
+ 一个用于运行 Python 代码以帮助生成对提示词回复的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID,也可以是一个用于指定可供你代码使用的已上传文件 ID 的对象,并提供
- 指定可供代码使用的已上传文件 ID,以及一个可选的
+ 代码解释器容器。可以是容器 ID,也可以是用于指定可供代码使用的已上传文件 ID 的对象,以及一个可选的
+ 设置。
可选的 `memory_limit` 设置。
- `string`
@@ -1719,17 +1719,17 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要对其运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定要在其上运行代码的文件 ID。
- `type: "auto"`
- Always `auto`.
+ 始终为 `auto`.
- `"auto"`
- `file_ids: optional array of string`
- 一个可选的已上传文件列表,供你的代码使用。
+ 可供代码使用的可选已上传文件列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -1751,7 +1751,7 @@
- `type: "disabled"`
- 禁用出站网络访问。Always `disabled`.
+ 禁用出站网络访问。始终为 `disabled`.
- `"disabled"`
@@ -1759,25 +1759,25 @@
- `allowed_domains: array of string`
- 当类型为 allowed_domains 时允许访问的域名列表。 `allowlist`.
+ 当类型为 `allowlist`.
- `type: "allowlist"`
- 仅允许向指定域发出出站网络访问。Always `allowlist`.
+ 时允许的域名列表。仅允许访问指定域名的出站网络。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 用于白名单域的可选域作用域密钥。
+ 针对已加入白名单域名的可选域作用域密钥。
- `domain: string`
- 与该密钥关联的域。
+ 与该密钥关联的域名。
- `name: string`
- 为该域注入的密钥名称。
+ 为该域名注入的密钥名称。
- `value: string`
@@ -1801,13 +1801,13 @@
- `type: "programmatic_tool_calling"`
- 工具的类型。始终为 `programmatic_tool_calling`.
+ 该工具的类型。始终为 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ImageGeneration object { type, action, background, 9 more }`
- 使用 GPT 图像模型生成图像的工具。
+ 使用 GPT 图像模型生成图片的工具。
- `type: "image_generation"`
@@ -1817,7 +1817,7 @@
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图片还是编辑已有图片。默认值: `auto`.
- `"generate"`
@@ -1827,11 +1827,11 @@
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。透明背景适用于受支持的 GPT
- 图像模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持处于预览阶段。使用
- `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图片的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。支持
+ 的 GPT Image 模型可使用透明背景。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,此功能处于预览阶段。当使用
+ `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -1841,7 +1841,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所付出的努力程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持,不支持 `gpt-image-1-mini`。支持 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图片的风格和特征(尤其是面部特征)时所投入的精力。该参数仅 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持, `gpt-image-1-mini`。不支持。支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -1854,11 +1854,11 @@
- `file_id: optional string`
- 蒙版图像的文件 ID。
+ 蒙版图片的文件 ID。
- `image_url: optional string`
- Base64 编码的蒙版图像。
+ Base64 编码的掩码图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
@@ -1888,7 +1888,7 @@
- `moderation: optional "auto" or "low"`
- 生成图像的内容审核级别。默认值: `auto`.
+ 生成图像的审核级别。默认值: `auto`.
- `"auto"`
@@ -1911,7 +1911,7 @@
- `partial_images: optional number`
- 在流式模式下生成的部分图像数量,范围为 0(默认值)到 3。
+ 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -1928,13 +1928,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,以 `WIDTHxHEIGHT` 字符串形式表示,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 受到支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一: `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一: `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式传入任意分辨率,例如 `WIDTHxHEIGHT` 。 `1536x864`,宽和高都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动尺寸的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,以 `WIDTHxHEIGHT` 字符串形式表示,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 受到支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一: `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一: `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式传入任意分辨率,例如 `WIDTHxHEIGHT` 。 `1536x864`,宽和高都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动尺寸的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -1984,7 +1984,7 @@
- `file_ids: optional array of string`
- 一个可选的已上传文件列表,供你的代码使用。
+ 可供代码使用的可选已上传文件列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -2008,7 +2008,7 @@
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 通过 ID 或内联数据引用的可选技能列表。
- `SkillReference object { skill_id, type, version }`
@@ -2024,7 +2024,7 @@
- `version: optional string`
- 可选的技能版本。使用正整数或 'latest'。省略时使用默认值。
+ 可选的技能版本。使用正整数或 'latest'。省略则使用默认值。
- `InlineSkill object { description, name, source, type }`
@@ -2058,7 +2058,7 @@
- `type: "inline"`
- 为本次请求定义一个内联技能。
+ 为该请求定义一个内联技能。
- `"inline"`
@@ -2066,13 +2066,13 @@
- `type: "local"`
- 使用本地计算机环境。
+ 使用本地计算环境。
- `"local"`
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -2122,7 +2122,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -2152,7 +2152,7 @@
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值为以下之一 `lark` 或 `regex`.
+ 语法定义的语法格式。可选值之一为 `lark` 或 `regex`.
- `"lark"`
@@ -2174,7 +2174,7 @@
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 在工具调用中使用的命名空间名称(例如, `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
@@ -2198,19 +2198,19 @@
- `defer_loading: optional boolean`
- 是否应延迟此函数并通过工具搜索发现它。
+ 此函数是否应被延迟并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。此字段不描述 content 数组形式的输出。
+ 用于描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。这不描述内容数组(content-array)输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否启用严格的参数校验。如果省略,当 schema 兼容时 Responses 尝试使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在模式兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -2236,7 +2236,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -2248,23 +2248,23 @@
- `type: "namespace"`
- 工具的类型。始终为 `namespace`.
+ 该工具的类型。始终为 `namespace`.
- `"namespace"`
- `ToolSearch object { type, description, execution, parameters }`
- 用于延迟工具的托管或 BYOT 工具搜索配置。
+ 用于延迟工具的托管工具搜索或 BYOT 工具搜索配置。
- `type: "tool_search"`
- 工具的类型。始终为 `tool_search`.
+ 该工具的类型。始终为 `tool_search`.
- `"tool_search"`
- `description: optional string or null`
- 向模型展示的客户端执行工具搜索工具的描述。
+ 展示给模型的、用于客户端执行的工具搜索工具的描述。
- `execution: optional "server" or "client"`
@@ -2276,15 +2276,15 @@
- `parameters: optional unknown or null`
- 客户端执行工具搜索工具的参数 schema。
+ 客户端执行的工具搜索工具的参数 schema。
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具会在网页上搜索相关结果以用于回复中。详细了解 Responses API [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 此工具会搜索网页以获取在响应中使用的结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索 工具的类型。可选值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型。取以下值之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -2298,7 +2298,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级使用指导。可选值为 `low`, `medium`,或 `high`. `medium` 是默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。取以下值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -2334,11 +2334,11 @@
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用 unified diff 创建、删除或更新文件。
+ 允许助手使用统一差异来创建、删除或更新文件。
- `type: "apply_patch"`
- 工具的类型。始终为 `apply_patch`.
+ 该工具的类型。始终为 `apply_patch`.
- `"apply_patch"`
@@ -2392,7 +2392,7 @@
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 此条目中可用的额外工具列表。
+ 在此项中提供的一系列额外工具。
- `Function object { name, parameters, strict, 5 more }`
@@ -2400,7 +2400,7 @@
- `name: string`
- 要调用的函数的名称。
+ 要调用的函数名称。
- `parameters: map[unknown] or null`
@@ -2408,7 +2408,7 @@
- `strict: boolean or null`
- 是否对该函数工具强制执行严格参数验证。
+ 是否对该函数工具强制执行严格的参数校验。
- `type: "function"`
@@ -2426,45 +2426,45 @@
- `defer_loading: optional boolean`
- 此函数是否被延迟加载并通过工具搜索加载。
+ 此函数是否被延迟,并通过工具搜索加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 对该函数的描述。供模型用于判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 用于描述此函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 用于描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 用于从已上传文件中搜索相关内容文件搜索 tool [文件搜索 tool](https://platform.openai.com/docs/guides/tools-file-search).
+ 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索 tool 的类型。始终为 `file_search`.
+ 文件搜索工具的类型,始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库 ID。
+ 要搜索的向量存储的 ID 列表。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的过滤器。
+ 要应用的筛选条件。
- `ComparisonFilter object { key, type, value }`
- 用于将指定属性键与给定值按照定义的比较运算进行比较的过滤器。
+ 用于将指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
- `CompoundFilter object { filters, type }`
- 使用以下方式合并多个过滤器 `and` 或 `or`.
+ 使用以下方式组合多个筛选条件 `and` 或 `or`.
- `max_num_results: optional number`
- 返回的最大结果数。该数字应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -2472,15 +2472,15 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于控制互逆排序融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
+ 在启用混合搜索时,控制倒数排名融合中语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
- 在互逆排序融合中嵌入的权重。
+ 倒数排名融合中嵌入的权重。
- `text_weight: number`
- 在互逆排序融合中文本的权重。
+ 倒数排名融合中文本的权重。
- `ranker: optional "auto" or "default-2024-11-15"`
@@ -2492,11 +2492,11 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数字会尝试仅返回最相关的结果,但可能返回的结果更少。
+ 文件搜索的分数阈值,取值范围为 0 到 1。越接近 1 的数值会尝试仅返回最相关的结果,但返回的结果可能更少。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
@@ -2506,15 +2506,15 @@
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
- 计算机显示屏的高度。
+ 计算机显示器的高度。
- `display_width: number`
- 计算机显示屏的宽度。
+ 计算机显示器的宽度。
- `environment: "windows" or "mac" or "linux" or 2 more`
@@ -2538,12 +2538,12 @@
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示相关的来源。详细了解
+ 在互联网上搜索与提示相关来源。了解更多关于
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索 工具的类型。可选值为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型。取以下值之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -2551,7 +2551,7 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 进行实时互联网访问。若省略,默认值为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索实时访问互联网。省略时默认为 true。当为 false 时,网页搜索工具以离线/仅缓存模式运行,并且不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
@@ -2560,13 +2560,13 @@
- `allowed_domains: optional array of string or null`
搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 同时允许所提供域名的子域名。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级使用指导。可选值为 `low`, `medium`,或 `high`. `medium` 是默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。取以下值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -2602,12 +2602,12 @@
- `Mcp object { server_label, type, allowed_callers, 9 more }`
- 允许模型通过远程模型上下文协议
- (MCP)服务器访问其他工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
+ 通过远程 Model Context Protocol
+ (MCP) 服务器为模型提供对其他工具的访问权限。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 此 MCP 服务器的标签,用于在工具调用中识别它。
- `type: "mcp"`
@@ -2625,21 +2625,21 @@
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许使用的工具名称列表或筛选对象。
+ 允许使用的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许使用的工具名称字符串数组
+ 允许使用的工具名称的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -2647,17 +2647,17 @@
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,可以与自定义 MCP 服务器
- URL 或服务连接器一起使用。你的应用程序必须处理 OAuth 授权流
- 并在此处提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,既可
+ 与自定义 MCP 服务器 URL 一起使用,也可与服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并在此处提供令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的连接器。必须提供以下之一。详细
- `server_url`, `connector_id`,或 `tunnel_id` 了解关于服务连接器
- about service connectors [here](/docs/guides/tools-remote-mcp#connectors).
+ 服务连接器的标识符,例如 ChatGPT 中提供的那些。必须提供
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一。详细了解
+ 服务连接器 [here](/docs/guides/tools-remote-mcp#connectors).
- Currently supported `connector_id` values are:
+ 目前支持的 `connector_id` 值包括:
- Dropbox: `connector_dropbox`
- Gmail: `connector_gmail`
@@ -2686,32 +2686,32 @@
- `defer_loading: optional boolean`
- Whether this MCP tool is deferred and discovered via tool search.
+ 此 MCP 工具是否为延迟加载,并通过工具搜索发现。
- `headers: optional map[string] or null`
- Optional HTTP headers to send to the MCP server. Use for authentication
- or other purposes.
+ 发送到 MCP 服务器的可选 HTTP 标头。用于身份验证
+ 或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- Specify which of the MCP server's tools require approval.
+ 指定 MCP 服务器的哪些工具需要批准。
- `McpToolApprovalFilter object { always, never }`
- Specify which of the MCP server's tools require approval. Can be
- `always`, `never`, or a filter object associated with tools
- that require approval.
+ 指定 MCP 服务器的哪些工具需要批准。可以是
+ `always`, `never`,或与需要批准的工具相关联的筛选器对象
+ 。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -2719,13 +2719,13 @@
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -2733,9 +2733,9 @@
- `McpToolApprovalSetting = "always" or "never"`
- Specify a single approval policy for all tools. One of `always` 或
- `never`. When set to `always`, all tools will require approval. When
- set to `never`, all tools will not require approval.
+ 为所有工具指定一个统一的批准策略。可选值包括 `always` 或
+ `never`。当设置为 `always`,时,所有工具都需要批准。当
+ 设置为 `never`,时,所有工具都不需要批准。
- `"always"`
@@ -2743,26 +2743,26 @@
- `server_description: optional string`
- Optional description of the MCP server, used to provide more context.
+ MCP 服务器的可选描述,用于提供更多上下文。
- `server_url: optional string`
- MCP 服务器的 URL。必须提供以下之一: `server_url`, `connector_id`,或
- `tunnel_id` 必须提供其中之一。
+ MCP 服务器的 URL。必须提供以下其中一项: `server_url`, `connector_id`,或
+ `tunnel_id` 。
- `tunnel_id: optional string`
- 用于代替直接服务器 URL 的安全 MCP 隧道 ID。必须提供以下之一:
- `server_url`, `connector_id`,或 `tunnel_id` 必须提供其中之一。
+ 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供以下其中一项:
+ `server_url`, `connector_id`,或 `tunnel_id` 。
- `CodeInterpreter object { container, type, allowed_callers }`
- 一个运行 Python 代码以帮助生成提示词回复的工具。
+ 一个用于运行 Python 代码以帮助生成对提示词回复的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID,也可以是一个用于指定可供你代码使用的已上传文件 ID 的对象,并提供
- 指定可供代码使用的已上传文件 ID,以及一个可选的
+ 代码解释器容器。可以是容器 ID,也可以是用于指定可供代码使用的已上传文件 ID 的对象,以及一个可选的
+ 设置。
可选的 `memory_limit` 设置。
- `string`
@@ -2771,17 +2771,17 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要对其运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定要在其上运行代码的文件 ID。
- `type: "auto"`
- Always `auto`.
+ 始终为 `auto`.
- `"auto"`
- `file_ids: optional array of string`
- 一个可选的已上传文件列表,供你的代码使用。
+ 可供代码使用的可选已上传文件列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -2821,13 +2821,13 @@
- `type: "programmatic_tool_calling"`
- 工具的类型。始终为 `programmatic_tool_calling`.
+ 该工具的类型。始终为 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ImageGeneration object { type, action, background, 9 more }`
- 使用 GPT 图像模型生成图像的工具。
+ 使用 GPT 图像模型生成图片的工具。
- `type: "image_generation"`
@@ -2837,7 +2837,7 @@
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图片还是编辑已有图片。默认值: `auto`.
- `"generate"`
@@ -2847,11 +2847,11 @@
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。透明背景适用于受支持的 GPT
- 图像模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持处于预览阶段。使用
- `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图片的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。支持
+ 的 GPT Image 模型可使用透明背景。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,此功能处于预览阶段。当使用
+ `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -2861,7 +2861,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所付出的努力程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持,不支持 `gpt-image-1-mini`。支持 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图片的风格和特征(尤其是面部特征)时所投入的精力。该参数仅 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持, `gpt-image-1-mini`。不支持。支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -2874,11 +2874,11 @@
- `file_id: optional string`
- 蒙版图像的文件 ID。
+ 蒙版图片的文件 ID。
- `image_url: optional string`
- Base64 编码的蒙版图像。
+ Base64 编码的掩码图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
@@ -2908,7 +2908,7 @@
- `moderation: optional "auto" or "low"`
- 生成图像的内容审核级别。默认值: `auto`.
+ 生成图像的审核级别。默认值: `auto`.
- `"auto"`
@@ -2931,7 +2931,7 @@
- `partial_images: optional number`
- 在流式模式下生成的部分图像数量,范围为 0(默认值)到 3。
+ 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -2948,13 +2948,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,以 `WIDTHxHEIGHT` 字符串形式表示,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 受到支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一: `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一: `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式传入任意分辨率,例如 `WIDTHxHEIGHT` 。 `1536x864`,宽和高都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动尺寸的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,以 `WIDTHxHEIGHT` 字符串形式表示,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 受到支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一: `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一: `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式传入任意分辨率,例如 `WIDTHxHEIGHT` 。 `1536x864`,宽和高都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动尺寸的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -3024,7 +3024,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -3044,7 +3044,7 @@
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 在工具调用中使用的命名空间名称(例如, `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
@@ -3068,19 +3068,19 @@
- `defer_loading: optional boolean`
- 是否应延迟此函数并通过工具搜索发现它。
+ 此函数是否应被延迟并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。此字段不描述 content 数组形式的输出。
+ 用于描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。这不描述内容数组(content-array)输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否启用严格的参数校验。如果省略,当 schema 兼容时 Responses 尝试使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在模式兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -3106,7 +3106,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -3118,23 +3118,23 @@
- `type: "namespace"`
- 工具的类型。始终为 `namespace`.
+ 该工具的类型。始终为 `namespace`.
- `"namespace"`
- `ToolSearch object { type, description, execution, parameters }`
- 用于延迟工具的托管或 BYOT 工具搜索配置。
+ 用于延迟工具的托管工具搜索或 BYOT 工具搜索配置。
- `type: "tool_search"`
- 工具的类型。始终为 `tool_search`.
+ 该工具的类型。始终为 `tool_search`.
- `"tool_search"`
- `description: optional string or null`
- 向模型展示的客户端执行工具搜索工具的描述。
+ 展示给模型的、用于客户端执行的工具搜索工具的描述。
- `execution: optional "server" or "client"`
@@ -3146,15 +3146,15 @@
- `parameters: optional unknown or null`
- 客户端执行工具搜索工具的参数 schema。
+ 客户端执行的工具搜索工具的参数 schema。
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具会在网页上搜索相关结果以用于回复中。详细了解 Responses API [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 此工具会搜索网页以获取在响应中使用的结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索 工具的类型。可选值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型。取以下值之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -3168,7 +3168,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级使用指导。可选值为 `low`, `medium`,或 `high`. `medium` 是默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。取以下值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -3204,11 +3204,11 @@
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用 unified diff 创建、删除或更新文件。
+ 允许助手使用统一差异来创建、删除或更新文件。
- `type: "apply_patch"`
- 工具的类型。始终为 `apply_patch`.
+ 该工具的类型。始终为 `apply_patch`.
- `"apply_patch"`
@@ -3228,13 +3228,13 @@
- `id: optional string or null`
- 此额外工具条目的唯一 ID。
+ 此额外工具项的唯一 ID。
- `Reasoning object { id, summary, type, 3 more }`
- 对推理模型在生成回复时所使用的思维链的描述。如果你手动管理上下文,请务必在后续对话轮次中将这些条目包含在提交给 响应接口 的
- 中。 `input` 请求里
- 。
+ 推理模型在生成响应时所使用的思维链的描述。如果你正在手动管理上下文,请务必在后续对话轮次中将这些项包含到你的
+ 调用中,以便将它们传入 `input` Responses API
+ ,用于后续对话轮次。如果你正在手动
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -3247,7 +3247,7 @@
- `text: string`
- 到目前为止模型推理输出的摘要。
+ 模型到目前为止的推理输出摘要。
- `type: "summary_text"`
@@ -3267,7 +3267,7 @@
- `text: string`
- 来自模型的推理文本。
+ 模型输出的推理文本。
- `type: "reasoning_text"`
@@ -3278,19 +3278,19 @@
- `encrypted_content: optional string or null`
推理条目的加密内容。默认情况下会填充
- 由 `POST /v1/responses` 和 WebSocket
+ 针对通过 `POST /v1/responses` 和 WebSocket
`response.create` 请求返回的推理条目。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 从 `response.output_item.done` 事件中
- 后续请求中获取。由于 `encrypted_content` 处于
- `response.output_item.added` 中的数据可能不完整。尤其是在
- important when `store` is `false` 或在使用 Zero Data Retention 时。
+ 在流式传输时,使用已完成的推理条目及其
+ `encrypted_content` 来自该 `response.output_item.done` 事件,在
+ 后续请求中使用 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这一点尤其
+ 重要,当 `store` 为 `false` 或使用零数据保留(Zero Data Retention)时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值为 `in_progress`, `completed`,或
- `incomplete`。之一。当通过 API 返回条目时填充。
+ 该条目的状态。取值之一: `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回项时填充。
- `"in_progress"`
@@ -3300,7 +3300,7 @@
- `Compaction object { encrypted_content, type, id }`
- 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -3308,7 +3308,7 @@
- `type: "compaction"`
- 该 item 的类型。始终为 `compaction`.
+ 该项的类型。始终为 `compaction`.
- `"compaction"`
@@ -3356,7 +3356,7 @@
- `code: string or null`
- 要运行的代码,若不可用则为 null。
+ 要运行的代码,如果不可用则为 null。
- `container_id: string`
@@ -3364,16 +3364,16 @@
- `outputs: array of object { logs, type } or object { type, url } or null`
- 代码解释器生成的输出,例如日志或图像。
- 若没有可用输出,可能为 null。
+ 由代码解释器生成的输出,例如日志或图像。
+ 如果没有可用的输出,可能为 null。
- `Logs object { logs, type }`
- 代码解释器输出的日志。
+ 由代码解释器输出的日志。
- `logs: string`
- 代码解释器输出的日志。
+ 由代码解释器输出的日志。
- `type: "logs"`
@@ -3383,7 +3383,7 @@
- `Image object { type, url }`
- 代码解释器输出的图像。
+ 由代码解释器输出的图像。
- `type: "image"`
@@ -3393,7 +3393,7 @@
- `url: string`
- 代码解释器输出图像的 URL。
+ 由代码解释器输出的图像 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -3433,7 +3433,7 @@
- `env: map[string]`
- 为命令设置的环境变量。
+ 为该命令设置的环境变量。
- `type: "exec"`
@@ -3443,15 +3443,15 @@
- `timeout_ms: optional number or null`
- 命令的可选超时时间(毫秒)。
+ 该命令的可选超时时间(毫秒)。
- `user: optional string or null`
- 运行命令时使用的可选用户。
+ 运行该命令时使用的可选用户。
- `working_directory: optional string or null`
- 运行命令时所在的可选工作目录。
+ 运行该命令时使用的可选工作目录。
- `call_id: string`
@@ -3493,7 +3493,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值为 `in_progress`, `completed`,或 `incomplete`.
+ 该条目的状态。取值之一: `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -3503,11 +3503,11 @@
- `ShellCall object { action, call_id, type, 4 more }`
- 表示请求执行一个或多个 shell 命令的工具。
+ 表示执行一个或多个 shell 命令请求的工具。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行该工具调用的 shell 命令及限制。
+ 描述如何运行该工具调用的 shell 命令和限制。
- `commands: array of string`
@@ -3515,25 +3515,25 @@
- `max_output_length: optional number or null`
- 从合并后的 stdout 和 stderr 输出中捕获的最大 UTF-8 字符数。
+ 从合并的 stdout 和 stderr 输出中捕获的最大 UTF-8 字符数。
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最长墙钟时间(毫秒)。
+ 允许 shell 命令运行的最大墙钟时间(毫秒)。
- `call_id: string`
- 由模型生成的 shell 工具调用的唯一 ID。
+ 模型生成的 shell 工具调用的唯一 ID。
- `type: "shell_call"`
- 该 item 的类型。始终为 `shell_call`.
+ 该项的类型。始终为 `shell_call`.
- `"shell_call"`
- `id: optional string or null`
- shell 工具调用的唯一 ID。在通过 API 返回此条目时填充。
+ shell 工具调用的唯一 ID。通过 API 返回该条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -3569,7 +3569,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态。可选值为 `in_progress`, `completed`,或 `incomplete`.
+ shell 调用的状态。取值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -3579,15 +3579,15 @@
- `ShellCallOutput object { call_id, output, type, 4 more }`
- shell 工具调用产生的流式输出条目。
+ 由 shell 工具调用流式输出的条目。
- `call_id: string`
- 由模型生成的 shell 工具调用的唯一 ID。
+ 模型生成的 shell 工具调用的唯一 ID。
- `output: array of ResponseFunctionShellCallOutputContent`
- 已捕获的 stdout 和 stderr 输出块及其关联的结果。
+ 捕获的 stdout 和 stderr 输出块及其关联的结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -3595,7 +3595,7 @@
- `Timeout object { type }`
- 表示该 shell 调用超出了其配置的时间限制。
+ 表示 shell 调用超过了其配置的时间限制。
- `type: "timeout"`
@@ -3605,11 +3605,11 @@
- `Exit object { exit_code, type }`
- 表示 shell 命令已结束并返回了退出码。
+ 表示 shell 命令已执行完毕并返回了退出码。
- `exit_code: number`
- 由 shell 进程返回的退出码。
+ shell 进程返回的退出码。
- `type: "exit"`
@@ -3627,13 +3627,13 @@
- `type: "shell_call_output"`
- 该 item 的类型。始终为 `shell_call_output`.
+ 该项的类型。始终为 `shell_call_output`.
- `"shell_call_output"`
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。在通过 API 返回此条目时填充。
+ shell 工具调用输出的唯一 ID。通过 API 返回该条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -3661,7 +3661,7 @@
- `max_output_length: optional number or null`
- 为该 shell 调用的合并输出捕获的最大 UTF-8 字符数。
+ 为此 shell 调用的合并输出捕获的最大 UTF-8 字符数。
- `status: optional "in_progress" or "completed" or "incomplete" or null`
@@ -3675,11 +3675,11 @@
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 一个表示使用 diff 补丁创建、删除或更新文件的工具调用。
+ 表示使用 diff 补丁来创建、删除或更新文件的工具调用。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
@@ -3691,11 +3691,11 @@
- `diff: string`
- 创建文件时要应用的 unified diff 内容。
+ 创建文件时应用的统一差异内容。
- `path: string`
- 相对于工作区根目录的要创建的文件的路径。
+ 相对于工作区根目录的待创建文件路径。
- `type: "create_file"`
@@ -3709,7 +3709,7 @@
- `path: string`
- 相对于工作区根目录的要删除的文件的路径。
+ 相对于工作区根目录的待删除文件路径。
- `type: "delete_file"`
@@ -3723,11 +3723,11 @@
- `diff: string`
- 要应用于现有文件的 unified diff 内容。
+ 应用于现有文件的统一差异内容。
- `path: string`
- 相对于工作区根目录的要更新的文件的路径。
+ 相对于工作区根目录的待更新文件路径。
- `type: "update_file"`
@@ -3745,7 +3745,7 @@
- `type: "apply_patch_call"`
- 该 item 的类型。始终为 `apply_patch_call`.
+ 该项的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -3779,11 +3779,11 @@
- `ApplyPatchCallOutput object { call_id, status, type, 3 more }`
- apply patch 工具调用发出的流式输出。
+ apply patch 工具调用产生的流式输出。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
@@ -3795,7 +3795,7 @@
- `type: "apply_patch_call_output"`
- 该 item 的类型。始终为 `apply_patch_call_output`.
+ 该项的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -3829,15 +3829,15 @@
- `output: optional string or null`
- 来自 apply patch 工具的可选人类可读日志文本(例如补丁结果或错误)。
+ apply patch 工具返回的可选人类可读的日志文本(例如补丁结果或错误)。
- `McpListTools object { id, server_label, tools, 2 more }`
- MCP 服务器上可用的工具列表。
+ MCP 服务器上可用工具的列表。
- `id: string`
- 该列表的唯一 ID。
+ 此列表的唯一 ID。
- `server_label: string`
@@ -3857,25 +3857,25 @@
- `annotations: optional unknown or null`
- 有关该工具的其他注释。
+ 关于该工具的附加注释。
- `description: optional string or null`
- 工具的描述。
+ 该工具的描述。
- `type: "mcp_list_tools"`
- 该 item 的类型。始终为 `mcp_list_tools`.
+ 该项的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具,则返回错误消息。
+ 如果服务端无法列出工具,则返回错误消息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工审批某个工具调用。
+ 对工具调用的人工审批请求。
- `id: string`
@@ -3883,7 +3883,7 @@
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
@@ -3895,7 +3895,7 @@
- `type: "mcp_approval_request"`
- 该 item 的类型。始终为 `mcp_approval_request`.
+ 该项的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
@@ -3905,15 +3905,15 @@
- `approval_request_id: string`
- 正在应答的审批请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已被批准。
+ 请求是否已获批准。
- `type: "mcp_approval_response"`
- 该 item 的类型。始终为 `mcp_approval_response`.
+ 该项的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -3927,7 +3927,7 @@
- `McpCall object { id, arguments, name, 6 more }`
- 在 MCP 服务器上对工具的一次调用。
+ 对 MCP 服务器上工具的调用。
- `id: string`
@@ -3947,7 +3947,7 @@
- `type: "mcp_call"`
- 该 item 的类型。始终为 `mcp_call`.
+ 该项的类型。始终为 `mcp_call`.
- `"mcp_call"`
@@ -3994,7 +3994,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
+ 工具调用的状态。取值之一 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -4008,7 +4008,7 @@
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 来自你代码的自定义工具调用输出,正在发回给模型。
+ 来自你的代码的自定义工具调用输出,将被发送回模型。
- `call_id: string`
@@ -4025,7 +4025,7 @@
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 自定义工具调用的文本、图片或文件输出。
+ 自定义工具调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
@@ -4033,7 +4033,7 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
+ 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -4083,7 +4083,7 @@
- `input: string`
- 模型生成的自定义工具调用的输入。
+ 由模型生成的自定义工具调用的输入。
- `name: string`
@@ -4129,7 +4129,7 @@
- `type: "compaction_trigger"`
- 该 item 的类型。始终为 `compaction_trigger`.
+ 该项的类型。始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -4143,11 +4143,11 @@
- `id: string`
- 要引用的条目的 ID。
+ 要引用的条目 ID。
- `type: optional "item_reference" or null`
- 要引用的条目的类型。始终为 `item_reference`.
+ 要引用的条目类型。始终为 `item_reference`.
- `"item_reference"`
@@ -4155,19 +4155,19 @@
- `id: string`
- 此程序条目的唯一 ID。
+ 此程序项的唯一 ID。
- `call_id: string`
- 程序条目的稳定调用 ID。
+ 程序项的稳定调用 ID。
- `code: string`
- 通过程序化工具调用执行的 JavaScript 源码。
+ 由程序化工具调用执行的 JavaScript 源代码。
- `fingerprint: string`
- 必须往返传输的不透明程序回放指纹。
+ 必须往返(round-trip)的不透明程序重放指纹。
- `type: "program"`
@@ -4179,15 +4179,15 @@
- `id: string`
- 此程序输出条目的唯一 ID。
+ 此程序输出项的唯一 ID。
- `call_id: string`
- 程序条目的调用 ID。
+ 程序项的调用 ID。
- `result: string`
- 由程序条目生成的结果。
+ 程序项生成的结果。
- `status: "completed" or "incomplete"`
@@ -4207,9 +4207,9 @@
插入到模型上下文中的系统(或开发者)消息。
- 在与 `previous_response_id`,一起使用时,前一次
- response 中的指令不会延续到下一次 response。这使得在新的响应中替换系统(或开发者)消息变得简单
- 。
+ 当与 `previous_response_id`,一起使用时,前一次
+ response 中的指令不会延续到下一次 response。这使得
+ 在新的 response 中替换系统(或开发者)消息变得简单。
- `max_output_tokens: optional number or null`
@@ -4217,22 +4217,22 @@
- `max_tool_calls: optional number or null`
- 单个响应中可处理的内置工具调用总次数上限。该上限适用于所有内置工具调用,而非单个工具。模型任何进一步的工具调用尝试都将被忽略。
+ 在一次响应中可处理的内置工具调用总次数上限。该上限适用于所有内置工具调用,而非按单个工具分别计数。模型后续对工具的任何调用尝试都将被忽略。
- `metadata: optional Metadata or null`
- 可以附加到对象的 16 个键值对集合。可用于
- 以结构化格式存储有关对象的附加信息,并通过
- format,以及通过 API 或控制台查询对象。
+ 可附加到对象的 16 组键值对。可用于
+ 以结构化格式存储对象的附加信息,并通过
+ 格式,以及通过 API 或控制台查询对象。
- 键为字符串,最大长度为 64 个字符。值为字符串,
- 最大长度为 512 个字符。
+ 键为字符串,最大长度为 64 个字符。值为字符串
+ ,最大长度为 512 个字符。
- `model: optional ResponsesModel`
- 用于生成响应的模型 ID,如 `gpt-5.6-sol`。OpenAI
- 提供多种不同能力、性能
- 特征和价格的模型。请参阅 [模型指南](/docs/models)
+ 用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI
+ 提供了众多具有不同能力、性能
+ 特征和价位的模型。请参阅 [模型指南](/docs/models)
以浏览和比较可用的模型。
- `string`
@@ -4447,11 +4447,11 @@
- `moderation: optional object { model, policy } or null`
- 用于对此响应的输入和输出运行内容安全审查的配置。
+ 用于对此响应的输入和输出运行审核的配置。
- `model: string`
- 用于已审核补全的内容安全审查模型,例如 'omni-moderation-latest'。
+ 用于已审核补全的审核模型,例如 "omni-moderation-latest"。
- `policy: optional object { input, output } or null`
@@ -4459,7 +4459,7 @@
- `input: optional object { mode } or null`
- 响应输入的内容安全审查策略。
+ 响应输入的审核策略。
- `mode: "score" or "block"`
@@ -4469,7 +4469,7 @@
- `output: optional object { mode } or null`
- 响应输出的内容安全审查策略。
+ 响应输出的审核策略。
- `mode: "score" or "block"`
@@ -4483,7 +4483,7 @@
- `previous_response_id: optional string or null`
- 上一次模型响应的唯一 ID。用它来
+ 上一次模型响应的唯一 ID。可使用此 ID
创建多轮对话。详细了解
[对话状态](/docs/guides/conversation-state)。不能与 `conversation`.
@@ -4494,13 +4494,13 @@
- `id: string`
- 要使用的提示词模板的唯一标识符。
+ 要使用的提示模板的唯一标识符。
- `variables: optional map[string or ResponseInputText or ResponseInputImage or ResponseInputFile] or null`
- 可选的映射,用于在你的
- 提示词中替换变量。替换值可以是字符串,也可以是其他
- Response 输入类型,例如图片或文件。
+ 用于替换你提示中变量的可选值映射。
+ 替换值可以是字符串,也可以是其他
+ Response 输入类型,例如图像或文件。
- `string`
@@ -4510,7 +4510,7 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
+ 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -4518,19 +4518,19 @@
- `version: optional string or null`
- 提示词模板的可选版本。
+ 提示模板的可选版本。
- `prompt_cache_key: optional string or null`
- 由 OpenAI 用于为相似请求缓存响应,从而优化你的缓存命中率。取代 `user` 字段。 [了解更多](/docs/guides/prompt-caching).
+ 由 OpenAI 用于缓存相似请求的响应,以优化你的缓存命中率。替换 prompt_cache_key `user` 字段。 [了解更多](/docs/guides/prompt-caching).
- `prompt_cache_options: optional object { mode, ttl }`
- 提示词缓存选项。受以下版本支持的模型: `gpt-5.6` 以及更高版本的模型。默认情况下,OpenAI 会自动选择一个隐式缓存断点。你可以使用 `prompt_cache_breakpoint`。为内容块添加显式断点。每个请求最多可写入四个断点。对于缓存匹配,OpenAI 会考虑对话中最多最近的 80 个断点,且不受内容块回溯限制。将 `mode` 设置为 `explicit` 以禁用隐式断点。 `ttl` 默认为 `30m`,这是当前唯一受支持的值。参阅 [提示词缓存指南](/docs/guides/prompt-caching) 了解当前详细信息。
+ 提示缓存选项。支持以下模型 `gpt-5.6` 及更高版本。默认情况下,OpenAI 会自动选择一个隐式缓存断点。你可以使用 cache_control `prompt_cache_breakpoint`。为内容块添加显式断点。每个请求最多可写入四个断点。对于缓存匹配,OpenAI 会考虑对话中最多最近的 80 个断点,且不限制内容块回溯。将 automatic `mode` 设置为 `explicit` 以禁用隐式断点。mode `ttl` 默认为 `30m`,目前是唯一受支持的值。参见 [提示缓存指南](/docs/guides/prompt-caching) 了解当前详细信息。
- `mode: optional "implicit" or "explicit"`
- 控制 OpenAI 是否自动创建隐式缓存断点。默认为 `implicit`。使用 `implicit`,时,OpenAI 会创建一个隐式断点,并在请求中写入最多最近的三个显式断点。使用 `explicit`,时,OpenAI 不会创建隐式断点,并写入最多最近的四个显式断点。如果没有显式断点,则该请求不会使用提示词缓存。
+ 控制 OpenAI 是否自动创建隐式缓存断点。默认为 `implicit`。当 `implicit`,为 enabled 时,OpenAI 会创建一个隐式断点,并在请求中写入最多最近的三个显式断点。当 `explicit`,为 disabled 时,OpenAI 不会创建隐式断点,并写入最多最近的四个显式断点。如果没有显式断点,则该请求不使用提示缓存。
- `"implicit"`
@@ -4538,7 +4538,7 @@
- `ttl: optional "30m"`
- 对请求中每个隐式和显式缓存断点应用的最小生命周期。默认为 `30m`,这是当前唯一受支持的值。后端可能会将缓存条目保留更长时间。
+ 应用于请求写入的每个隐式和显式缓存断点的最小生命周期。默认为 `30m`,这是当前唯一受支持的值。后端可能会保留缓存条目更长时间。
- `"30m"`
@@ -4547,15 +4547,15 @@
已弃用。请使用 `prompt_cache_options.ttl` 代替。
提示缓存的保留策略。设置为 `24h` 以启用扩展提示缓存,使缓存的前缀保持更长时间的活跃状态,最长可达 24 小时。 [了解更多](/docs/guides/prompt-caching#prompt-cache-retention).
- 此字段表示最大保留策略,而
- `prompt_cache_options.ttl` 表示最小缓存生命周期。这两个
- 字段是独立的,互不影响。
- 对于 `gpt-5.5`, `gpt-5.5-pro`,以及未来的模型,仅 `24h` 。
+ 该字段表示最大保留策略,而
+ `prompt_cache_options.ttl` 表示最小缓存生命周期。两个
+ 字段相互独立,互不影响。
+ 对于 `gpt-5.5`, `gpt-5.5-pro`,及未来模型,仅支持 `24h` 。
- 对于同时支持两者的较旧模型 `in_memory` 和 `24h`,默认值取决于你所在组织的数据保留策略:
+ 对于同时支持 `in_memory` 和 `24h`,的较旧模型,默认值取决于你组织的数据保留策略:
- 未启用 ZDR 的组织默认为 `24h`.
- - 已启用 ZDR 的组织默认为 `in_memory` 当 `prompt_cache_retention` 未指定时。
+ - 启用 ZDR 的组织默认为 `in_memory` 当 `prompt_cache_retention` 未指定时。
- `"in_memory"`
@@ -4563,17 +4563,17 @@
- `reasoning: optional Reasoning or null`
- 针对
+ 的配置选项
[推理模型](https://platform.openai.com/docs/guides/reasoning).
- `context: optional "auto" or "current_turn" or "all_turns" or null`
- 控制在后续轮次中哪些推理项会被重新渲染回模型。
- 如果省略或设置为 `auto`,模型将自行决定上下文模式。
- `gpt-5.6` 模型系列默认为 `all_turns`;较早的模型默认为
+ 控制在后续回合中哪些推理项会被渲染回给模型。
+ 如果省略或设置为 `auto`,模型将决定上下文模式。该
+ `gpt-5.6` 模型系列默认为 `all_turns`;更早的模型默认为
`current_turn`.
- 在响应中返回时,这是该响应使用的有效推理上下文模式
+ 在响应中返回时,这是响应所使用的有效推理上下文模式
。
- `"auto"`
@@ -4584,13 +4584,13 @@
- `effort: optional ReasoningEffort or null`
- 约束推理模型的推理力度。当前支持
- 的取值有 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
- 降低推理力度可以让响应更快,并减少响应中用于推理的令牌数量。
- 并非所有推理模型都支持每个
- 取值。请参阅
+ 在推理模型上限制推理的 effort。目前支持
+ 的值为 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
+ 降低推理 effort 可以使响应更快,并减少响应中推理所使用的 token 数量。并非所有推理模型都支持每个
+ 值。
+ value。参见
[推理指南](https://platform.openai.com/docs/guides/reasoning)
- 了解特定模型的支持情况。
+ 以了解特定模型的支持情况。
- `"none"`
@@ -4608,11 +4608,11 @@
- `generate_summary: optional "auto" or "concise" or "detailed" or null`
- **已弃用:** 使用 `summary` 代替。
+ **已弃用:** 请使用 `summary` 代替。
- 模型执行的推理摘要。这对于调试和理解模型的推理过程
- 很有用。
- 取值之一 `auto`, `concise`,或 `detailed`.
+ 模型执行的推理摘要。这可以
+ 有助于调试和理解模型的推理过程。
+ 以下值之一 `auto`, `concise`,或 `detailed`.
- `"auto"`
@@ -4640,11 +4640,11 @@
- `summary: optional "auto" or "concise" or "detailed" or null`
- 模型执行的推理摘要。这对于调试和理解模型的推理过程
- 很有用。
- 取值之一 `auto`, `concise`,或 `detailed`.
+ 模型执行的推理摘要。这可以
+ 有助于调试和理解模型的推理过程。
+ 以下值之一 `auto`, `concise`,或 `detailed`.
- `concise` 支持以下模型和之后的 `computer-use-preview` 推理模型 `gpt-5`.
+ `concise` 支持于 `computer-use-preview` 模型以及之后的全部推理模型 `gpt-5`.
- `"auto"`
@@ -4654,21 +4654,21 @@
- `safety_identifier: optional string or null`
- 一个稳定的标识符,用于帮助识别可能违反 OpenAI 使用政策的应用用户。
- 这些 ID 应为能够唯一标识每位用户的字符串,最大长度为 64 个字符。我们建议对其用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份信息。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
+ 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用政策的应用用户。
+ 这些 ID 应为字符串,唯一标识每个用户,最大长度为 64 个字符。建议对其用户名或电子邮件地址进行哈希处理,以避免向我们发送任何可识别信息。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
- `service_tier: optional ServiceTier or null`
- 指定用于处理该请求的处理类型。
+ 指定用于处理请求的处理类型。
- - 如果设置为 'auto',则该请求将按照项目设置中配置的服务层级进行处理。除非另行配置,项目将使用 'default'。
- - 如果设置为 'default',则该请求将按照所选模型的标准定价和性能进行处理。
- - 如果设置为 '[flex](/docs/guides/flex-processing)',则该请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 请求中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
- - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级返回的响应将显示 `service_tier=ultrafast`.
- - 未设置时,默认行为为 'auto'。
+ - 如果设置为 'auto',则请求将使用项目设置中配置的服务层级进行处理。除非另有配置,项目将使用 'default'。
+ - 如果设置为 'default',则请求将使用所选模型的标准定价和性能进行处理。
+ - 如果设置为 '[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。
+ - 如要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为 'ultrafast',则请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。此层级目前可用于 `gpt-5.6-sol`;通过它服务的响应将显示 `service_tier=ultrafast`.
+ - 当未设置时,默认行为为 'auto'。
- 当 `service_tier` 参数已设置,响应体将包含基于实际用于处理请求的 `service_tier` 处理模式所得到的值。该响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数已设置时,响应体将基于实际用于处理该请求的处理模式返回相应的 `service_tier` 取值。该响应值可能与参数中设置的值不同。
- `"auto"`
@@ -4691,53 +4691,53 @@
- `stream: optional boolean or null`
- 如果设置为 true,模型响应数据将以流式方式在生成时
- 发送到客户端,使用 [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
- 参见下方 [流式传输部分](/docs/api-reference/responses-streaming)
+ 如果设置为 true,模型响应数据将在生成时通过
+ 以流式方式传输到客户端,使用 [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
+ 请参阅下方 [Streaming 部分](/docs/api-reference/responses-streaming)
了解更多信息。
- `stream_options: optional object { include_obfuscation } or null`
- 流式响应的选项。仅当你设置了 `stream: true`.
+ 流式响应的相关选项。仅当你在设置 `stream: true`.
- `include_obfuscation: optional boolean`
- 为 true 时,将启用流混淆。流混淆会向流式
- 增量事件的某个字段添加 `obfuscation` 随机字符,以均衡负载大小,作为对某些侧信道
- 攻击的缓解措施。这些混淆字段默认会被包含,但会给数据流带来少量。
- 开销。如果你信任你的应用与 OpenAI API 之间的网络链路,可以将
- 设置为 false 以优化带宽。 `include_obfuscation` 设置为
- 为 false 以优化带宽,如果你信任你的应用与
- 该公司 接口 之间的网络链路。
+ 为 true 时,将启用流混淆。流混淆会在流式
+ 增量事件的 `obfuscation` 字段中添加随机字符,以规范化载荷大小,
+ 作为对某些侧信道攻击的缓解措施。
+ 这些混淆字段默认会被包含,但会给数据流带来少量
+ 开销。如果你信任你的应用与 OpenAI API 之间的网络链路,可以将 `include_obfuscation` 设置为
+ 设置为 false 以优化带宽。
+ 你的应用与 该公司 接口 之间。
- `temperature: optional number or null`
- 使用的采样温度,介于 0 和 2 之间。较高的值(例如 0.8)会使输出更加随机,而较低的值(例如 0.2)会使输出更加聚焦和确定性更强。
- 我们通常建议修改此参数或 `top_p` 但不能同时使用两者。
+ 使用的采样温度,介于 0 到 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加聚焦和确定性。
+ 我们通常建议修改此项或 `top_p` 但不能两者同时使用。
- `text: optional ResponseTextConfig`
- 用于配置模型返回的文本响应格式。可以是纯文本或结构化的 JSON 数据。了解更多:
- 文本或结构化 JSON 数据。了解更多:
+ 模型文本响应的配置选项。可以是纯
+ 文本,也可以是结构化的 JSON 数据。了解详情:
- [文本输入与输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
- `format: optional ResponseFormatTextConfig`
- 用于指定模型必须输出的格式的对象。
+ 一个用于指定模型必须输出的格式的对象。
配置 `{ "type": "json_schema" }` 可启用结构化输出,
- 从而确保模型的输出与你提供的 JSON schema 完全匹配。更多信息请参阅
+ 从而确保模型匹配你提供的 JSON schema。详细了解
[结构化输出指南](/docs/guides/structured-outputs).
- 默认格式为 `{ "type": "text" }` ,不包含额外选项。
+ 默认格式为 `{ "type": "text" }` ,且没有其他选项。
- **不推荐用于 gpt-4o 及更新的模型:**
+ **不推荐用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 可启用旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
- 的模型,推荐使用结构化输出。
+ 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
+ 确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
+ 的模型,更推荐使用它。
- `ResponseFormatText object { type }`
@@ -4745,7 +4745,7 @@
- `type: "text"`
- 正在定义的响应格式类型。始终为 `text`.
+ 正在定义的响应格式的类型。始终为 `text`.
- `"text"`
@@ -4756,50 +4756,50 @@
- `name: string`
- 响应格式的名称。必须为 a-z、A-Z、0-9,或包含
- 下划线和短横线,最大长度为 64。
+ 响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
+ 下划线和连字符,最大长度为 64。
- `schema: map[unknown]`
- 响应格式所对应的 schema,以 JSON Schema 对象形式描述。
+ 响应格式的 schema,以 JSON Schema 对象形式描述。
了解如何构建 JSON schema [here](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式类型。始终为 `json_schema`.
+ 正在定义的响应格式的类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
- 对响应格式用途的描述,供模型用于
- 确定如何在该格式中作出响应。
+ 响应格式用途的描述,供模型用于
+ 确定如何按该格式进行响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 遵从。
- 若设为 true,模型将始终遵循在
- 字段中定义的精确 schema。仅支持部分 JSON Schema, `schema` 当
- `strict` is `true`。为 true 时。要了解更多信息,请参阅 [结构化输出
+ 是否在生成输出时启用严格的 schema 遵循。
+ 如果设置为 true,模型将始终遵循所定义的确切 schema
+ 在 `schema` 字段。当使用 structured outputs 时仅支持 JSON Schema 的一个子集
+ `strict` 为 `true`。有关详细信息,请阅读 [结构化输出
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较老的生成 JSON 响应的方法。
- 建议使用 `json_schema` 以支持相关功能的模型。请注意,
- 模型在没有系统或用户消息指示的情况下不会生成 JSON,
- 指示它这样做。
+ JSON 对象响应格式。一种较旧的生成 JSON 响应的方法。
+ 推荐对支持的模型使用 `json_schema` 。请注意,如果没有系统或用户消息指示模型生成 JSON,
+ 模型将不会生成 JSON
+ 。
- `type: "json_object"`
- 正在定义的响应格式类型。始终为 `json_object`.
+ 正在定义的响应格式的类型。始终为 `json_object`.
- `"json_object"`
- `verbosity: optional "low" or "medium" or "high" or null`
- 限制模型响应的详细程度。较低的值会得到
- 更简洁的响应,而较高的值会得到更详细的响应。
+ 约束模型响应的详细程度。较低的值将产生更简洁的响应,而较高的值将产生更详细的响应。
+ 简洁的响应,而较高的值将产生更详细的响应。
当前支持的值包括 `low`, `medium`,和 `high`。默认值为
`medium`.
@@ -4811,18 +4811,18 @@
- `tool_choice: optional ToolChoiceOptions or ToolChoiceAllowed or ToolChoiceTypes or 6 more`
- 指定模型在生成响应时应如何选择使用哪个(或哪些)工具。
- 有关如何指定可调用工具的信息,请参阅 `tools` 参数。
- 模型可以调用的工具。
+ 在生成响应时,模型应如何选择要使用的工具(一个或多个)
+ 。请参阅 `tools` 参数了解如何指定模型可调用的工具
+ 。
- `ToolChoiceOptions = "none" or "auto" or "required"`
- 控制由模型调用哪个工具(如果有)。
+ 控制模型调用哪些工具(如果有)。
`none` 表示模型不会调用任何工具,而是生成一条消息。
- `auto` 表示模型可以在生成消息与调用一个或
- 多个工具之间进行选择。
+ `auto` 表示模型可以在生成消息或调用一个或
+ 多个工具之间选择。
`required` 表示模型必须调用一个或多个工具。
@@ -4834,16 +4834,16 @@
- `ToolChoiceAllowed object { mode, tools, type }`
- 将模型可使用的工具限制为一组预定义工具。
+ 将模型可用的工具限制为预定义的集合。
- `mode: "auto" or "required"`
- 将模型可使用的工具限制为一组预定义工具。
+ 将模型可用的工具限制为预定义的集合。
- `auto` 允许模型从允许的工具中进行选择并生成一条
+ `auto` 允许模型从允许的工具中挑选并生成一条
消息。
- `required` 要求模型调用允许的工具中的一个或多个。
+ `required` 要求模型调用一个或多个允许的工具。
- `"auto"`
@@ -4851,7 +4851,7 @@
- `tools: array of map[unknown]`
- 模型可以调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -4871,8 +4871,8 @@
- `ToolChoiceTypes object { type }`
- 指示模型应使用内置工具来生成响应。
- [详细了解内置工具](/docs/guides/tools).
+ 指示模型应使用内置工具生成响应。
+ [了解更多关于内置工具的信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
@@ -4907,11 +4907,11 @@
- `ToolChoiceFunction object { name, type }`
- 使用此选项可强制模型调用特定的函数。
+ 使用此选项以强制模型调用特定函数。
- `name: string`
- 要调用的函数的名称。
+ 要调用的函数名称。
- `type: "function"`
@@ -4921,7 +4921,7 @@
- `ToolChoiceMcp object { server_label, type, name }`
- 使用此选项可以强制模型调用远程 MCP 服务器上的特定工具。
+ 使用此选项以强制模型调用远程 MCP 服务器上的特定工具。
- `server_label: string`
@@ -4939,7 +4939,7 @@
- `ToolChoiceCustom object { name, type }`
- 使用此选项可以强制模型调用特定的自定义工具。
+ 使用此选项以强制模型调用特定的自定义工具。
- `name: string`
@@ -4955,27 +4955,27 @@
- `type: "programmatic_tool_calling"`
- 要调用的工具。始终为 `programmatic_tool_calling`.
+ 要调用的工具。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ToolChoiceApplyPatch object { type }`
- 强制模型在执行工具调用时调用 apply_patch 工具。
+ 在执行工具调用时强制模型调用 apply_patch 工具。
- `type: "apply_patch"`
- 要调用的工具。始终为 `apply_patch`.
+ 要调用的工具。始终 `apply_patch`.
- `"apply_patch"`
- `ToolChoiceShell object { type }`
- 在需要工具调用时,强制模型调用 shell 工具。
+ 在需要工具调用时强制模型调用 shell 工具。
- `type: "shell"`
- 要调用的工具。始终为 `shell`.
+ 要调用的工具。始终 `shell`.
- `"shell"`
@@ -4986,17 +4986,17 @@
我们支持以下类别的工具:
- - **内置工具**: 由 OpenAI 提供的可扩展模型能力的工具,例如
- 模型的能力,例如 [网页搜索](/docs/guides/tools-web-search)
+ - **内置工具**: 由 OpenAI 提供的工具,用于扩展模型的
+ 能力,例如 [网页搜索](/docs/guides/tools-web-search)
或 [文件搜索](/docs/guides/tools-file-search)。了解更多关于
[内置工具](/docs/guides/tools).
- - **MCP Tools**: 通过自定义 MCP 服务器或预定义连接器(如 Google Drive 和 SharePoint)与第三方系统集成。了解更多关于
- 或 Google Drive 和 SharePoint 等预定义连接器与第三方系统集成。了解更多关于
- [MCP Tools](/docs/guides/tools-connectors-mcp).
+ - **MCP 工具**: 通过自定义 MCP 服务器与第三方系统集成,
+ 或使用 Google Drive 和 SharePoint 等预定义连接器。了解更多关于
+ [MCP 工具](/docs/guides/tools-connectors-mcp).
- **函数调用(自定义工具)**: 由你定义的函数,
- 使模型能够使用强类型参数和输出调用你自己的代码
+ 使模型能够使用强类型参数调用你自己的代码
和输出。了解更多关于
- [函数调用](/docs/guides/function-calling)。你也可以使用
+ [函数调用](/docs/guides/function-calling)。你还可以使用
自定义工具来调用你自己的代码。
- `Function object { name, parameters, strict, 5 more }`
@@ -5005,7 +5005,7 @@
- `name: string`
- 要调用的函数的名称。
+ 要调用的函数名称。
- `parameters: map[unknown] or null`
@@ -5013,7 +5013,7 @@
- `strict: boolean or null`
- 是否对该函数工具强制执行严格参数验证。
+ 是否对该函数工具强制执行严格的参数校验。
- `type: "function"`
@@ -5031,45 +5031,45 @@
- `defer_loading: optional boolean`
- 此函数是否被延迟加载并通过工具搜索加载。
+ 此函数是否被延迟,并通过工具搜索加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 对该函数的描述。供模型用于判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 用于描述此函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 用于描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 用于从已上传文件中搜索相关内容文件搜索 tool [文件搜索 tool](https://platform.openai.com/docs/guides/tools-file-search).
+ 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索 tool 的类型。始终为 `file_search`.
+ 文件搜索工具的类型,始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库 ID。
+ 要搜索的向量存储的 ID 列表。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的过滤器。
+ 要应用的筛选条件。
- `ComparisonFilter object { key, type, value }`
- 用于将指定属性键与给定值按照定义的比较运算进行比较的过滤器。
+ 用于将指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
- `CompoundFilter object { filters, type }`
- 使用以下方式合并多个过滤器 `and` 或 `or`.
+ 使用以下方式组合多个筛选条件 `and` 或 `or`.
- `max_num_results: optional number`
- 返回的最大结果数。该数字应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -5077,15 +5077,15 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于控制互逆排序融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
+ 在启用混合搜索时,控制倒数排名融合中语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
- 在互逆排序融合中嵌入的权重。
+ 倒数排名融合中嵌入的权重。
- `text_weight: number`
- 在互逆排序融合中文本的权重。
+ 倒数排名融合中文本的权重。
- `ranker: optional "auto" or "default-2024-11-15"`
@@ -5097,11 +5097,11 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数字会尝试仅返回最相关的结果,但可能返回的结果更少。
+ 文件搜索的分数阈值,取值范围为 0 到 1。越接近 1 的数值会尝试仅返回最相关的结果,但返回的结果可能更少。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
@@ -5111,15 +5111,15 @@
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
- 计算机显示屏的高度。
+ 计算机显示器的高度。
- `display_width: number`
- 计算机显示屏的宽度。
+ 计算机显示器的宽度。
- `environment: "windows" or "mac" or "linux" or 2 more`
@@ -5143,12 +5143,12 @@
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示相关的来源。详细了解
+ 在互联网上搜索与提示相关来源。了解更多关于
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索 工具的类型。可选值为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型。取以下值之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -5156,7 +5156,7 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 进行实时互联网访问。若省略,默认值为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索实时访问互联网。省略时默认为 true。当为 false 时,网页搜索工具以离线/仅缓存模式运行,并且不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
@@ -5165,13 +5165,13 @@
- `allowed_domains: optional array of string or null`
搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 同时允许所提供域名的子域名。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级使用指导。可选值为 `low`, `medium`,或 `high`. `medium` 是默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。取以下值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -5207,12 +5207,12 @@
- `Mcp object { server_label, type, allowed_callers, 9 more }`
- 允许模型通过远程模型上下文协议
- (MCP)服务器访问其他工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
+ 通过远程 Model Context Protocol
+ (MCP) 服务器为模型提供对其他工具的访问权限。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 此 MCP 服务器的标签,用于在工具调用中识别它。
- `type: "mcp"`
@@ -5230,21 +5230,21 @@
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许使用的工具名称列表或筛选对象。
+ 允许使用的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许使用的工具名称字符串数组
+ 允许使用的工具名称的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -5252,17 +5252,17 @@
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,可以与自定义 MCP 服务器
- URL 或服务连接器一起使用。你的应用程序必须处理 OAuth 授权流
- 并在此处提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,既可
+ 与自定义 MCP 服务器 URL 一起使用,也可与服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并在此处提供令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的连接器。必须提供以下之一。详细
- `server_url`, `connector_id`,或 `tunnel_id` 了解关于服务连接器
- about service connectors [here](/docs/guides/tools-remote-mcp#connectors).
+ 服务连接器的标识符,例如 ChatGPT 中提供的那些。必须提供
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一。详细了解
+ 服务连接器 [here](/docs/guides/tools-remote-mcp#connectors).
- Currently supported `connector_id` values are:
+ 目前支持的 `connector_id` 值包括:
- Dropbox: `connector_dropbox`
- Gmail: `connector_gmail`
@@ -5291,32 +5291,32 @@
- `defer_loading: optional boolean`
- Whether this MCP tool is deferred and discovered via tool search.
+ 此 MCP 工具是否为延迟加载,并通过工具搜索发现。
- `headers: optional map[string] or null`
- Optional HTTP headers to send to the MCP server. Use for authentication
- or other purposes.
+ 发送到 MCP 服务器的可选 HTTP 标头。用于身份验证
+ 或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- Specify which of the MCP server's tools require approval.
+ 指定 MCP 服务器的哪些工具需要批准。
- `McpToolApprovalFilter object { always, never }`
- Specify which of the MCP server's tools require approval. Can be
- `always`, `never`, or a filter object associated with tools
- that require approval.
+ 指定 MCP 服务器的哪些工具需要批准。可以是
+ `always`, `never`,或与需要批准的工具相关联的筛选器对象
+ 。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -5324,13 +5324,13 @@
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -5338,9 +5338,9 @@
- `McpToolApprovalSetting = "always" or "never"`
- Specify a single approval policy for all tools. One of `always` 或
- `never`. When set to `always`, all tools will require approval. When
- set to `never`, all tools will not require approval.
+ 为所有工具指定一个统一的批准策略。可选值包括 `always` 或
+ `never`。当设置为 `always`,时,所有工具都需要批准。当
+ 设置为 `never`,时,所有工具都不需要批准。
- `"always"`
@@ -5348,26 +5348,26 @@
- `server_description: optional string`
- Optional description of the MCP server, used to provide more context.
+ MCP 服务器的可选描述,用于提供更多上下文。
- `server_url: optional string`
- MCP 服务器的 URL。必须提供以下之一: `server_url`, `connector_id`,或
- `tunnel_id` 必须提供其中之一。
+ MCP 服务器的 URL。必须提供以下其中一项: `server_url`, `connector_id`,或
+ `tunnel_id` 。
- `tunnel_id: optional string`
- 用于代替直接服务器 URL 的安全 MCP 隧道 ID。必须提供以下之一:
- `server_url`, `connector_id`,或 `tunnel_id` 必须提供其中之一。
+ 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供以下其中一项:
+ `server_url`, `connector_id`,或 `tunnel_id` 。
- `CodeInterpreter object { container, type, allowed_callers }`
- 一个运行 Python 代码以帮助生成提示词回复的工具。
+ 一个用于运行 Python 代码以帮助生成对提示词回复的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID,也可以是一个用于指定可供你代码使用的已上传文件 ID 的对象,并提供
- 指定可供代码使用的已上传文件 ID,以及一个可选的
+ 代码解释器容器。可以是容器 ID,也可以是用于指定可供代码使用的已上传文件 ID 的对象,以及一个可选的
+ 设置。
可选的 `memory_limit` 设置。
- `string`
@@ -5376,17 +5376,17 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要对其运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定要在其上运行代码的文件 ID。
- `type: "auto"`
- Always `auto`.
+ 始终为 `auto`.
- `"auto"`
- `file_ids: optional array of string`
- 一个可选的已上传文件列表,供你的代码使用。
+ 可供代码使用的可选已上传文件列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -5426,13 +5426,13 @@
- `type: "programmatic_tool_calling"`
- 工具的类型。始终为 `programmatic_tool_calling`.
+ 该工具的类型。始终为 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ImageGeneration object { type, action, background, 9 more }`
- 使用 GPT 图像模型生成图像的工具。
+ 使用 GPT 图像模型生成图片的工具。
- `type: "image_generation"`
@@ -5442,7 +5442,7 @@
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图片还是编辑已有图片。默认值: `auto`.
- `"generate"`
@@ -5452,11 +5452,11 @@
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。透明背景适用于受支持的 GPT
- 图像模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持处于预览阶段。使用
- `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图片的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。支持
+ 的 GPT Image 模型可使用透明背景。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,此功能处于预览阶段。当使用
+ `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -5466,7 +5466,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所付出的努力程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持,不支持 `gpt-image-1-mini`。支持 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图片的风格和特征(尤其是面部特征)时所投入的精力。该参数仅 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持, `gpt-image-1-mini`。不支持。支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -5479,11 +5479,11 @@
- `file_id: optional string`
- 蒙版图像的文件 ID。
+ 蒙版图片的文件 ID。
- `image_url: optional string`
- Base64 编码的蒙版图像。
+ Base64 编码的掩码图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
@@ -5513,7 +5513,7 @@
- `moderation: optional "auto" or "low"`
- 生成图像的内容审核级别。默认值: `auto`.
+ 生成图像的审核级别。默认值: `auto`.
- `"auto"`
@@ -5536,7 +5536,7 @@
- `partial_images: optional number`
- 在流式模式下生成的部分图像数量,范围为 0(默认值)到 3。
+ 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -5553,13 +5553,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,以 `WIDTHxHEIGHT` 字符串形式表示,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 受到支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一: `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一: `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式传入任意分辨率,例如 `WIDTHxHEIGHT` 。 `1536x864`,宽和高都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动尺寸的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,以 `WIDTHxHEIGHT` 字符串形式表示,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 受到支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一: `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一: `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式传入任意分辨率,例如 `WIDTHxHEIGHT` 。 `1536x864`,宽和高都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动尺寸的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -5629,7 +5629,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -5649,7 +5649,7 @@
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 在工具调用中使用的命名空间名称(例如, `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
@@ -5673,19 +5673,19 @@
- `defer_loading: optional boolean`
- 是否应延迟此函数并通过工具搜索发现它。
+ 此函数是否应被延迟并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。此字段不描述 content 数组形式的输出。
+ 用于描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。这不描述内容数组(content-array)输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否启用严格的参数校验。如果省略,当 schema 兼容时 Responses 尝试使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在模式兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -5711,7 +5711,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -5723,23 +5723,23 @@
- `type: "namespace"`
- 工具的类型。始终为 `namespace`.
+ 该工具的类型。始终为 `namespace`.
- `"namespace"`
- `ToolSearch object { type, description, execution, parameters }`
- 用于延迟工具的托管或 BYOT 工具搜索配置。
+ 用于延迟工具的托管工具搜索或 BYOT 工具搜索配置。
- `type: "tool_search"`
- 工具的类型。始终为 `tool_search`.
+ 该工具的类型。始终为 `tool_search`.
- `"tool_search"`
- `description: optional string or null`
- 向模型展示的客户端执行工具搜索工具的描述。
+ 展示给模型的、用于客户端执行的工具搜索工具的描述。
- `execution: optional "server" or "client"`
@@ -5751,15 +5751,15 @@
- `parameters: optional unknown or null`
- 客户端执行工具搜索工具的参数 schema。
+ 客户端执行的工具搜索工具的参数 schema。
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具会在网页上搜索相关结果以用于回复中。详细了解 Responses API [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 此工具会搜索网页以获取在响应中使用的结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索 工具的类型。可选值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型。取以下值之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -5773,7 +5773,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级使用指导。可选值为 `low`, `medium`,或 `high`. `medium` 是默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。取以下值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -5809,11 +5809,11 @@
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用 unified diff 创建、删除或更新文件。
+ 允许助手使用统一差异来创建、删除或更新文件。
- `type: "apply_patch"`
- 工具的类型。始终为 `apply_patch`.
+ 该工具的类型。始终为 `apply_patch`.
- `"apply_patch"`
@@ -5827,28 +5827,28 @@
- `top_logprobs: optional number or null`
- 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的
- 最大可能性 token 数量,每个 token 都带有对应的对数
- 概率。在某些情况下,返回的 token 数量可能少于
- 请求的数量。
+ 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的最可能的
+ 最大 token 数,每个 token 都带有对应的 log
+ 概率。在某些情况下,返回的 token 数量可能会少于
+ 所请求的数量。
- `top_p: optional number or null`
- 一种称为 nucleus 采样的温度采样替代方案,
- 模型在此考虑 top_p 概率对应的 token 结果
- 的位置。因此 0.1 表示仅考虑构成前 10% 概率质量的 token
+ 一种称为 nucleus 采样的温度采样替代方法,
+ 模型会考虑概率质量排名前 top_p 的 token 结果
+ 。因此 0.1 表示只考虑构成前 10% 概率质量的 token
。
- 我们通常建议修改此参数或 `temperature` 但不能同时使用两者。
+ 我们通常建议修改此项或 `temperature` 但不能两者同时使用。
- `truncation: optional "auto" or "disabled" or null`
用于模型响应的截断策略。
- - `auto`:如果此 Response 的输入超过
- 模型的上下文窗口大小,模型将通过从对话开头丢弃内容来截断
- 响应以适配上下文窗口。
- - `disabled` (默认):如果输入大小将超过模型的上下文窗口
+ - `auto`:如果此 Response 的输入超出
+ 模型的上下文窗口大小,模型将通过从对话开头丢弃条目来截断
+ 响应以适应上下文窗口。
+ - `disabled` (默认):如果输入大小将超出模型的上下文窗口
大小,请求将失败并返回 400 错误。
- `"auto"`
@@ -5857,11 +5857,11 @@
- `user: optional string`
- 此字段将被 `safety_identifier` 和 `prompt_cache_key`。取代。请使用 `prompt_cache_key` 以保持缓存优化效果。
- 为你的最终用户提供的一个稳定标识符。
- 用于通过更好地对相似请求进行分桶来提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
+ 此字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`,请使用 `prompt_cache_key` 以保持缓存优化效果。
+ 用于标识最终用户的稳定标识符。
+ 用于通过更好地对相似请求进行分桶来提高缓存命中率,并帮助 OpenAI 检测和防止滥用行为。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
-### 返回值
+### Returns
- `Response object { id, created_at, error, 32 more }`
@@ -5871,7 +5871,7 @@
- `created_at: number`
- 此 Response 创建时的 Unix 时间戳(以秒为单位)。
+ 创建此 Response 时的 Unix 时间戳(以秒为单位)。
- `error: ResponseError or null`
@@ -5879,7 +5879,7 @@
- `code: "server_error" or "rate_limit_exceeded" or "invalid_prompt" or 17 more`
- 响应的错误代码。
+ 该响应的错误代码。
- `"server_error"`
@@ -5923,49 +5923,51 @@
- `message: string`
- 易于阅读的错误描述。
+ 人类可读的错误描述。
- `incomplete_details: object { reason } or null`
有关响应未完成原因的详细信息。
- - `reason: optional "max_output_tokens" or "content_filter"`
+ - `reason: optional "max_output_tokens" or "max_messages" or "content_filter"`
响应未完成的原因。
- `"max_output_tokens"`
+ - `"max_messages"`
+
- `"content_filter"`
- `instructions: string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more or null`
插入到模型上下文中的系统(或开发者)消息。
- 在与 `previous_response_id`,一起使用时,前一次
- response 中的指令不会延续到下一次 response。这使得在新的响应中替换系统(或开发者)消息变得简单
- 。
+ 当与 `previous_response_id`,一起使用时,前一次
+ response 中的指令不会延续到下一次 response。这使得
+ 在新的 response 中替换系统(或开发者)消息变得简单。
- `string`
- 传递给模型的文本输入,等同于带有
- `developer` 角色的文本输入。
+ 对模型的文本输入,等同于使用以下 role 的文本输入:
+ `developer` role。
- `InputItemList = array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 包含一个或多个输入项的列表,传递给模型,这些输入项可
- 包含不同的内容类型。
+ 包含一个或多个输入项的列表,用于提供给模型,其中包含
+ 不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 传递给模型的消息输入,其角色用于指示指令优先级。通过
- 层级角色给出的指令优先级,高于 `developer` 或 `system` 角色给出的指令。带有
- 层级角色的指令优先于使用 `user` 角色给出的指令。带有
- `assistant` 角色的消息被视为模型在之前的交互中
- 生成的内容。
+ 对模型的消息输入,使用 role 指示指令的优先级层次。使用以下 role
+ 给出的指令优先于使用以下 role `developer` 或 `system` 给出的指令。
+ 优先级高于使用以下 role 给出的指令。使用以下 role `user` 的消息被假定为模型在先前交互中生成的
+ `assistant` 消息。使用以下 role 的消息被假定为模型在先前
+ 交互中生成的。
- `content: string or ResponseInputMessageContentList`
- 传递给模型的文本、图像或音频输入,用于生成响应。
+ 提供给模型的文本、图像或音频输入,用于生成响应。
也可以包含之前的助手响应。
- `TextInput = string`
@@ -5974,7 +5976,7 @@
- `ResponseInputMessageContentList = array of ResponseInputContent`
- 发送给模型的一条或多条输入项的列表,包含不同的内容
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
@@ -5993,7 +5995,7 @@
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会对齐到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
- `mode: "explicit"`
@@ -6003,7 +6005,7 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
+ 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
@@ -6025,15 +6027,15 @@
- `file_id: optional string or null`
- 发送给模型的文件的 ID。
+ 发送给模型的文件 ID。
- `image_url: optional string or null`
- 发送给模型的图像的 URL。可以是完整的 URL,也可以是 data URL 中的 base64 编码图像。
+ 发送给模型的图像 URL。完全限定的 URL 或 data URL 中 base64 编码的图像。
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会对齐到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
- `mode: "explicit"`
@@ -6053,7 +6055,7 @@
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会增加输入 token 使用量。使用 `low` 用于以更低成本进行渲染,或 `high` 以更高质量渲染文件时使用。默认为 `auto`.
+ 发送给模型的文件的细节级别。使用 `auto` 让系统选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会增加输入 token 使用量。使用 `low` 以降低渲染成本,或 `high` 以更高质量渲染文件。默认为 `auto`.
- `"auto"`
@@ -6063,23 +6065,23 @@
- `file_data: optional string`
- 发送给模型的文件内容。
+ 要发送给模型的文件内容。
- `file_id: optional string or null`
- 发送给模型的文件的 ID。
+ 发送给模型的文件 ID。
- `file_url: optional string`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会对齐到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
- `mode: "explicit"`
@@ -6089,7 +6091,7 @@
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色,取值为 `user`, `assistant`, `system`,或
+ 消息输入的角色。可选值为 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -6102,9 +6104,9 @@
- `phase: optional "commentary" or "final_answer" or null`
- 将该 `assistant` 消息标记为中间说明性内容(`commentary`)或最终答复(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段在所有助手消息上——丢弃它可能导致性能下降。不适用于用户消息。
+ 将 `assistant` 消息标记为中间评论(`commentary`)或最终答案(`final_answer`).
+ 对于像 `gpt-5.3-codex` 及更高版本等模型,在发送后续请求时,请保留并重新发送
+ 阶段到所有助手消息——丢弃它可能会降低性能。不用于用户消息。
- `"commentary"`
@@ -6112,24 +6114,24 @@
- `type: optional "message"`
- 消息输入的类型,始终为 `message`.
+ 消息输入的类型。始终为 `message`.
- `"message"`
- `Message object { content, role, status, type }`
- 传递给模型的消息输入,其角色用于指示指令优先级。通过
- 层级角色给出的指令优先级,高于 `developer` 或 `system` 角色给出的指令。带有
- 层级角色的指令优先于使用 `user` 角色的文本输入。
+ 对模型的消息输入,使用 role 指示指令的优先级层次。使用以下 role
+ 给出的指令优先于使用以下 role `developer` 或 `system` 给出的指令。
+ 优先级高于使用以下 role 给出的指令。使用以下 role `user` role。
- `content: ResponseInputMessageContentList`
- 发送给模型的一条或多条输入项的列表,包含不同的内容
+ 发送给模型的一个或多个输入项的列表,包含不同的内容
类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色,取值为 `user`, `system`,或 `developer`.
+ 消息输入的角色。可选值为 `user`, `system`,或 `developer`.
- `"user"`
@@ -6139,8 +6141,8 @@
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态,取值为 `in_progress`, `completed`,或
- `incomplete`。之一。当通过 API 返回条目时填充。
+ 项的状态。可选值为 `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回项时填充。
- `"in_progress"`
@@ -6150,13 +6152,13 @@
- `type: optional "message"`
- 消息输入的类型,始终设置为 `message`.
+ 消息输入的类型。始终设置为 `message`.
- `"message"`
- `ResponseOutputMessage object { id, content, role, 3 more }`
- 模型输出的消息。
+ 模型的输出消息。
- `id: string`
@@ -6168,11 +6170,11 @@
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 模型输出的文本。
+ 模型的文本输出。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
@@ -6198,7 +6200,7 @@
- `URLCitation object { end_index, start_index, title, 2 more }`
- 用于生成模型回答的网页资源引用。
+ 用于生成模型响应的网页资源引用。
- `end_index: number`
@@ -6224,7 +6226,7 @@
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
- 用于生成模型回答的容器文件引用。
+ 用于生成模型响应的容器文件引用。
- `container_id: string`
@@ -6288,7 +6290,7 @@
- `text: string`
- 模型输出的文本。
+ 模型生成的文本输出。
- `type: "output_text"`
@@ -6302,7 +6304,7 @@
- `refusal: string`
- 模型的拒绝解释。
+ 模型给出的拒绝解释。
- `type: "refusal"`
@@ -6318,8 +6320,8 @@
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值为 `in_progress`, `completed`,或
- `incomplete`。之一。通过 API 返回输入项时填充。
+ 消息输入的状态。可选值为 `in_progress`, `completed`,或
+ `incomplete`。之一。当通过 API 返回输入项时填充该字段。
- `"in_progress"`
@@ -6335,9 +6337,9 @@
- `phase: optional "commentary" or "final_answer" or null`
- 将该 `assistant` 消息标记为中间说明性内容(`commentary`)或最终答复(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高版本的模型,在发送后续请求时,请保留并重新发送
- 阶段在所有助手消息上——丢弃它可能导致性能下降。不适用于用户消息。
+ 将 `assistant` 消息标记为中间评论(`commentary`)或最终答案(`final_answer`).
+ 对于像 `gpt-5.3-codex` 及更高版本等模型,在发送后续请求时,请保留并重新发送
+ 阶段到所有助手消息——丢弃它可能会降低性能。不用于用户消息。
- `"commentary"`
@@ -6345,7 +6347,7 @@
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。参见
+ 文件搜索 工具调用的结果。请参阅
[文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
- `id: string`
@@ -6354,11 +6356,11 @@
- `queries: array of string`
- 用于搜索文件的查询。
+ 用于搜索文件的查询语句。
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。可选值为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -6383,11 +6385,11 @@
- `attributes: optional map[string or number or boolean] or null`
- 可以附加到对象的 16 个键值对集合。可用于
- 以结构化格式存储有关对象的附加信息,并通过
- API 或控制台查询对象。键为字符串
- 最大长度为 64 个字符。值是最大
- 长度为 512 个字符的字符串、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于
+ 以结构化格式存储对象的附加信息,并通过
+ API 或控制台查询对象。键为字符串,
+ 最大长度为 64 个字符。值为最大
+ 长度 512 个字符的字符串、布尔值或数字。
- `string`
@@ -6405,7 +6407,7 @@
- `score: optional number`
- 文件的相关性评分,介于 0 和 1 之间。
+ 文件的相关性得分——介于 0 和 1 之间的值。
- `text: optional string`
@@ -6413,16 +6415,16 @@
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
- 对计算机使用工具的工具调用。参见
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ 对计算机使用工具的工具调用。请参阅
+ [computer use 指南](/docs/guides/tools-computer-use) 了解更多信息。
- `id: string`
- 计算机调用的唯一 ID。
+ 该计算机调用的唯一 ID。
- `call_id: string`
- 在向工具调用提供输出时使用的标识符。
+ 在用输出响应工具调用时使用的标识符。
- `pending_safety_checks: array of object { id, code, message }`
@@ -6438,12 +6440,12 @@
- `message: optional string or null`
- 有关待处理安全检查的详细信息。
+ 关于待处理安全检查的详细信息。
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值为 `in_progress`, `completed`,或
- `incomplete`。之一。当通过 API 返回条目时填充。
+ 该条目的状态。取值之一: `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回项时填充。
- `"in_progress"`
@@ -6453,21 +6455,21 @@
- `type: "computer_call"`
- 计算机调用的类型,恒为 `computer_call`.
+ 计算机调用的类型。始终为 `computer_call`.
- `"computer_call"`
- `action: optional ComputerAction`
- 点击动作。
+ 点击操作。
- `Click object { button, type, x, 2 more }`
- 点击动作。
+ 点击操作。
- `button: "left" or "right" or "wheel" or 2 more`
- 指明点击时按下的鼠标按键。取值为 `left`, `right`, `wheel`, `back`,或 `forward`.
+ 表示点击时按下的鼠标按键。取值之一: `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -6481,21 +6483,21 @@
- `type: "click"`
- 指定事件类型。对于点击动作,该属性恒为 `click`.
+ 指定事件类型。对于点击操作,此属性始终为 `click`.
- `"click"`
- `x: number`
- 点击发生位置的 x 坐标。
+ 发生点击的 x 坐标。
- `y: number`
- 点击发生位置的 y 坐标。
+ 发生点击的 y 坐标。
- `keys: optional array of string or null`
- 点击时按住的按键。
+ 点击时按住的键。
- `DoubleClick object { keys, type, x, y }`
@@ -6503,21 +6505,21 @@
- `keys: array of string or null`
- 双击时按住的按键。
+ 双击时按住的键。
- `type: "double_click"`
- 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
+ 指定事件类型。对于双击动作,此属性始终设置为 `double_click`.
- `"double_click"`
- `x: number`
- 双击发生位置的 x 坐标。
+ 发生双击的 x 坐标。
- `y: number`
- 双击发生位置的 y 坐标。
+ 发生双击的 y 坐标。
- `Drag object { path, type, keys }`
@@ -6525,7 +6527,7 @@
- `path: array of object { x, y }`
- 一个由坐标构成的数组,表示拖动动作的路径。坐标将作为对象数组出现,例如
+ 表示拖动动作路径的坐标数组。坐标将作为对象数组出现,例如
```
[
@@ -6544,25 +6546,25 @@
- `type: "drag"`
- 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
+ 指定事件类型。对于拖动动作,此属性始终设置为 `drag`.
- `"drag"`
- `keys: optional array of string or null`
- 拖动鼠标时按住的按键。
+ 拖动鼠标时按住的键。
- `Keypress object { keys, type }`
- 模型希望执行的按键操作的集合。
+ 模型希望执行的按键集合。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
+ 模型请求按下的键组合。这是一个字符串数组,每个字符串表示一个键。
- `type: "keypress"`
- 指定事件类型。对于按键动作,该属性始终设置为 `keypress`.
+ 指定事件类型。对于按键动作,此属性始终设置为 `keypress`.
- `"keypress"`
@@ -6572,7 +6574,7 @@
- `type: "move"`
- 指定事件类型。对于移动动作,该属性始终设置为 `move`.
+ 指定事件类型。对于移动动作,此属性始终设置为 `move`.
- `"move"`
@@ -6586,7 +6588,7 @@
- `keys: optional array of string or null`
- 在移动鼠标时按住的按键。
+ 在移动鼠标时按住的键。
- `Screenshot object { type }`
@@ -6618,19 +6620,19 @@
- `x: number`
- 发生滚动事件的 x 坐标。
+ 发生滚动处的 x 坐标。
- `y: number`
- 发生滚动事件的 y 坐标。
+ 发生滚动处的 y 坐标。
- `keys: optional array of string or null`
- 滚动时按住的按键。
+ 滚动时按住的键。
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `text: string`
@@ -6638,7 +6640,7 @@
- `type: "type"`
- 指定事件类型。对于输入操作,此属性始终设置为 `type`.
+ 指定事件类型。对于 type 操作,此属性始终设置为 `type`.
- `"type"`
@@ -6654,12 +6656,12 @@
- `actions: optional ComputerActionList`
- 针对的扁平化批处理操作 `computer_use`。每个操作都包含一个
- `type` 判别字段以及操作特有的字段。
+ 针对 `computer_use`。展平后的批量操作。每个操作都包含一个
+ `type` 判别字段以及操作专属字段。
- `Click object { button, type, x, 2 more }`
- 点击动作。
+ 点击操作。
- `DoubleClick object { keys, type, x, y }`
@@ -6671,7 +6673,7 @@
- `Keypress object { keys, type }`
- 模型希望执行的按键操作的集合。
+ 模型希望执行的按键集合。
- `Move object { type, x, y, keys }`
@@ -6687,7 +6689,7 @@
- `Type object { text, type }`
- 输入文本的操作。
+ 用于输入文本的操作。
- `Wait object { type }`
@@ -6699,7 +6701,7 @@
- `call_id: string`
- 生成该输出的计算机工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
@@ -6718,21 +6720,21 @@
- `image_url: optional string`
- 截图图像的 URL。
+ 截图图片的 URL。
- `type: "computer_call_output"`
- 计算机工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用的输出类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `id: optional string or null`
- 计算机工具调用输出的 ID。
+ 计算机工具调用的输出 ID。
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 由 API 报告的、已被开发者确认的安全检查。
+ 已被开发者确认的 API 所报告的安全检查。
- `id: string`
@@ -6744,11 +6746,11 @@
- `message: optional string or null`
- 有关待处理安全检查的详细信息。
+ 关于待处理安全检查的详细信息。
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值为 `in_progress`, `completed`,或 `incomplete`。之一。通过 API 返回输入项时填充。
+ 消息输入的状态。可选值为 `in_progress`, `completed`,或 `incomplete`。之一。当通过 API 返回输入项时填充该字段。
- `"in_progress"`
@@ -6758,21 +6760,21 @@
- `WebSearchCall object { id, action, status, type }`
- 网页搜索 工具调用的结果。请参阅
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ 网页搜索工具调用的结果。请参阅
+ [网页搜索指南](/docs/guides/tools-web-search) 了解更多信息。
- `id: string`
- 网页搜索 工具调用的唯一 ID。
+ 网页搜索工具调用的唯一 ID。
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述本次 网页搜索 调用中所执行的具体操作的对象。
+ 描述此次 网页搜索调用中所执行具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" - 执行 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -6794,7 +6796,7 @@
- `type: "url"`
- 来源类型。始终为 `url`.
+ 来源的类型。始终为 `url`.
- `"url"`
@@ -6804,7 +6806,7 @@
- `OpenPage object { type, url }`
- 操作类型 "open_page" —— 从搜索结果中打开指定的 URL。
+ 操作类型 "open_page" - 打开搜索结果中的指定 URL。
- `type: "open_page"`
@@ -6818,11 +6820,11 @@
- `FindInPage object { pattern, type, url }`
- 操作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索某个模式。
- `pattern: string`
- 要在页面中搜索的模式或文本。
+ 要在页面内搜索的模式或文本。
- `type: "find_in_page"`
@@ -6867,7 +6869,7 @@
- `name: string`
- 要运行的函数名称。
+ 要运行的函数的名称。
- `type: "function_call"`
@@ -6905,8 +6907,8 @@
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值为 `in_progress`, `completed`,或
- `incomplete`。之一。当通过 API 返回条目时填充。
+ 该条目的状态。取值之一: `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回项时填充。
- `"in_progress"`
@@ -6946,7 +6948,7 @@
- `prompt_cache_breakpoint: optional object { mode } or null`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会对齐到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
- `mode: "explicit"`
@@ -6956,7 +6958,7 @@
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision)
+ 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision)
- `type: "input_image"`
@@ -6970,15 +6972,15 @@
- `file_id: optional string or null`
- 发送给模型的文件的 ID。
+ 发送给模型的文件 ID。
- `image_url: optional string or null`
- 发送给模型的图像的 URL。可以是完整的 URL,也可以是 data URL 中的 base64 编码图像。
+ 发送给模型的图像 URL。完全限定的 URL 或 data URL 中 base64 编码的图像。
- `prompt_cache_breakpoint: optional object { mode } or null`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会对齐到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
- `mode: "explicit"`
@@ -6998,7 +7000,7 @@
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会增加输入 token 使用量。使用 `low` 用于以更低成本进行渲染,或 `high` 以更高质量渲染文件时使用。默认为 `auto`.
+ 发送给模型的文件的细节级别。使用 `auto` 让系统选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会增加输入 token 使用量。使用 `low` 以降低渲染成本,或 `high` 以更高质量渲染文件。默认为 `auto`.
- `"auto"`
@@ -7012,19 +7014,19 @@
- `file_id: optional string or null`
- 发送给模型的文件的 ID。
+ 发送给模型的文件 ID。
- `file_url: optional string or null`
- 发送给模型的文件的 URL。
+ 要发送给模型的文件的 URL。
- `filename: optional string or null`
- 发送给模型的文件的名称。
+ 要发送给模型的文件的名称。
- `prompt_cache_breakpoint: optional object { mode } or null`
- 标记可复用提示前缀的精确结束位置。该断点的 TTL 继承自请求的 `prompt_cache_options.ttl`;边界不会对齐到 token 块。
+ 标记可复用提示前缀的确切结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
- `mode: "explicit"`
@@ -7040,7 +7042,7 @@
- `id: optional string or null`
- 函数工具调用输出的唯一 ID。当此条目通过 API 返回时填充。
+ 函数工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
- `call_id: optional string or null`
@@ -7072,15 +7074,15 @@
- `name: optional string or null`
- 生成该输出的工具的名称。
+ 产生该输出的工具名称。
- `namespace: optional string or null`
- 生成该输出的工具的命名空间。
+ 产生该输出的工具命名空间。
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值为 `in_progress`, `completed`,或 `incomplete`。之一。当通过 API 返回条目时填充。
+ 该条目的状态。取值之一: `in_progress`, `completed`,或 `incomplete`。当通过 API 返回项时填充。
- `"in_progress"`
@@ -7138,7 +7140,7 @@
- `name: string`
- 要调用的函数的名称。
+ 要调用的函数名称。
- `parameters: map[unknown] or null`
@@ -7146,7 +7148,7 @@
- `strict: boolean or null`
- 是否对该函数工具强制执行严格参数验证。
+ 是否对该函数工具强制执行严格的参数校验。
- `type: "function"`
@@ -7164,54 +7166,54 @@
- `defer_loading: optional boolean`
- 此函数是否被延迟加载并通过工具搜索加载。
+ 此函数是否被延迟,并通过工具搜索加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 对该函数的描述。供模型用于判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 用于描述此函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 用于描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 用于从已上传文件中搜索相关内容文件搜索 tool [文件搜索 tool](https://platform.openai.com/docs/guides/tools-file-search).
+ 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索 tool 的类型。始终为 `file_search`.
+ 文件搜索工具的类型,始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库 ID。
+ 要搜索的向量存储的 ID 列表。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的过滤器。
+ 要应用的筛选条件。
- `ComparisonFilter object { key, type, value }`
- 用于将指定属性键与给定值按照定义的比较运算进行比较的过滤器。
+ 用于将指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
- `key: string`
- 用于与值进行比较的键。
+ 用于与该值进行比较的键。
- `type: "eq" or "ne" or "gt" or 5 more`
指定比较运算符: `eq`, `ne`, `gt`, `gte`, `lt`, `lte`, `in`, `nin`.
- - `eq`: 等于
- - `ne`: 不等于
- - `gt`: 大于
- - `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `eq`:等于
+ - `ne`:不等于
+ - `gt`:大于
+ - `gte`:大于等于
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:属于
+ - `nin`:不属于
- `"eq"`
@@ -7231,7 +7233,7 @@
- `value: string or number or boolean or array of string or number`
- 用于与属性键进行比较的值;支持字符串、数字或布尔类型。
+ 与属性键进行比较的值;支持字符串、数字或布尔类型。
- `string`
@@ -7247,15 +7249,15 @@
- `CompoundFilter object { filters, type }`
- 使用以下方式合并多个过滤器 `and` 或 `or`.
+ 使用以下方式组合多个筛选条件 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的过滤器数组。条目可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 要组合的筛选条件数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于将指定属性键与给定值按照定义的比较运算进行比较的过滤器。
+ 用于将指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
- `unknown`
@@ -7269,7 +7271,7 @@
- `max_num_results: optional number`
- 返回的最大结果数。该数字应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -7277,15 +7279,15 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于控制互逆排序融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
+ 在启用混合搜索时,控制倒数排名融合中语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
- 在互逆排序融合中嵌入的权重。
+ 倒数排名融合中嵌入的权重。
- `text_weight: number`
- 在互逆排序融合中文本的权重。
+ 倒数排名融合中文本的权重。
- `ranker: optional "auto" or "default-2024-11-15"`
@@ -7297,11 +7299,11 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数字会尝试仅返回最相关的结果,但可能返回的结果更少。
+ 文件搜索的分数阈值,取值范围为 0 到 1。越接近 1 的数值会尝试仅返回最相关的结果,但返回的结果可能更少。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
@@ -7311,15 +7313,15 @@
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
- 计算机显示屏的高度。
+ 计算机显示器的高度。
- `display_width: number`
- 计算机显示屏的宽度。
+ 计算机显示器的宽度。
- `environment: "windows" or "mac" or "linux" or 2 more`
@@ -7343,12 +7345,12 @@
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示相关的来源。详细了解
+ 在互联网上搜索与提示相关来源。了解更多关于
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索 工具的类型。可选值为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型。取以下值之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -7356,7 +7358,7 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 进行实时互联网访问。若省略,默认值为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索实时访问互联网。省略时默认为 true。当为 false 时,网页搜索工具以离线/仅缓存模式运行,并且不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
@@ -7365,13 +7367,13 @@
- `allowed_domains: optional array of string or null`
搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 同时允许所提供域名的子域名。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级使用指导。可选值为 `low`, `medium`,或 `high`. `medium` 是默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。取以下值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -7407,12 +7409,12 @@
- `Mcp object { server_label, type, allowed_callers, 9 more }`
- 允许模型通过远程模型上下文协议
- (MCP)服务器访问其他工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
+ 通过远程 Model Context Protocol
+ (MCP) 服务器为模型提供对其他工具的访问权限。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 此 MCP 服务器的标签,用于在工具调用中识别它。
- `type: "mcp"`
@@ -7430,21 +7432,21 @@
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许使用的工具名称列表或筛选对象。
+ 允许使用的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许使用的工具名称字符串数组
+ 允许使用的工具名称的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -7452,17 +7454,17 @@
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,可以与自定义 MCP 服务器
- URL 或服务连接器一起使用。你的应用程序必须处理 OAuth 授权流
- 并在此处提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,既可
+ 与自定义 MCP 服务器 URL 一起使用,也可与服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并在此处提供令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的连接器。必须提供以下之一。详细
- `server_url`, `connector_id`,或 `tunnel_id` 了解关于服务连接器
- about service connectors [here](/docs/guides/tools-remote-mcp#connectors).
+ 服务连接器的标识符,例如 ChatGPT 中提供的那些。必须提供
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一。详细了解
+ 服务连接器 [here](/docs/guides/tools-remote-mcp#connectors).
- Currently supported `connector_id` values are:
+ 目前支持的 `connector_id` 值包括:
- Dropbox: `connector_dropbox`
- Gmail: `connector_gmail`
@@ -7491,32 +7493,32 @@
- `defer_loading: optional boolean`
- Whether this MCP tool is deferred and discovered via tool search.
+ 此 MCP 工具是否为延迟加载,并通过工具搜索发现。
- `headers: optional map[string] or null`
- Optional HTTP headers to send to the MCP server. Use for authentication
- or other purposes.
+ 发送到 MCP 服务器的可选 HTTP 标头。用于身份验证
+ 或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- Specify which of the MCP server's tools require approval.
+ 指定 MCP 服务器的哪些工具需要批准。
- `McpToolApprovalFilter object { always, never }`
- Specify which of the MCP server's tools require approval. Can be
- `always`, `never`, or a filter object associated with tools
- that require approval.
+ 指定 MCP 服务器的哪些工具需要批准。可以是
+ `always`, `never`,或与需要批准的工具相关联的筛选器对象
+ 。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -7524,13 +7526,13 @@
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -7538,9 +7540,9 @@
- `McpToolApprovalSetting = "always" or "never"`
- Specify a single approval policy for all tools. One of `always` 或
- `never`. When set to `always`, all tools will require approval. When
- set to `never`, all tools will not require approval.
+ 为所有工具指定一个统一的批准策略。可选值包括 `always` 或
+ `never`。当设置为 `always`,时,所有工具都需要批准。当
+ 设置为 `never`,时,所有工具都不需要批准。
- `"always"`
@@ -7548,26 +7550,26 @@
- `server_description: optional string`
- Optional description of the MCP server, used to provide more context.
+ MCP 服务器的可选描述,用于提供更多上下文。
- `server_url: optional string`
- MCP 服务器的 URL。必须提供以下之一: `server_url`, `connector_id`,或
- `tunnel_id` 必须提供其中之一。
+ MCP 服务器的 URL。必须提供以下其中一项: `server_url`, `connector_id`,或
+ `tunnel_id` 。
- `tunnel_id: optional string`
- 用于代替直接服务器 URL 的安全 MCP 隧道 ID。必须提供以下之一:
- `server_url`, `connector_id`,或 `tunnel_id` 必须提供其中之一。
+ 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供以下其中一项:
+ `server_url`, `connector_id`,或 `tunnel_id` 。
- `CodeInterpreter object { container, type, allowed_callers }`
- 一个运行 Python 代码以帮助生成提示词回复的工具。
+ 一个用于运行 Python 代码以帮助生成对提示词回复的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID,也可以是一个用于指定可供你代码使用的已上传文件 ID 的对象,并提供
- 指定可供代码使用的已上传文件 ID,以及一个可选的
+ 代码解释器容器。可以是容器 ID,也可以是用于指定可供代码使用的已上传文件 ID 的对象,以及一个可选的
+ 设置。
可选的 `memory_limit` 设置。
- `string`
@@ -7576,17 +7578,17 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要对其运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定要在其上运行代码的文件 ID。
- `type: "auto"`
- Always `auto`.
+ 始终为 `auto`.
- `"auto"`
- `file_ids: optional array of string`
- 一个可选的已上传文件列表,供你的代码使用。
+ 可供代码使用的可选已上传文件列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -7608,7 +7610,7 @@
- `type: "disabled"`
- 禁用出站网络访问。Always `disabled`.
+ 禁用出站网络访问。始终为 `disabled`.
- `"disabled"`
@@ -7616,25 +7618,25 @@
- `allowed_domains: array of string`
- 当类型为 allowed_domains 时允许访问的域名列表。 `allowlist`.
+ 当类型为 `allowlist`.
- `type: "allowlist"`
- 仅允许向指定域发出出站网络访问。Always `allowlist`.
+ 时允许的域名列表。仅允许访问指定域名的出站网络。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 用于白名单域的可选域作用域密钥。
+ 针对已加入白名单域名的可选域作用域密钥。
- `domain: string`
- 与该密钥关联的域。
+ 与该密钥关联的域名。
- `name: string`
- 为该域注入的密钥名称。
+ 为该域名注入的密钥名称。
- `value: string`
@@ -7658,13 +7660,13 @@
- `type: "programmatic_tool_calling"`
- 工具的类型。始终为 `programmatic_tool_calling`.
+ 该工具的类型。始终为 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ImageGeneration object { type, action, background, 9 more }`
- 使用 GPT 图像模型生成图像的工具。
+ 使用 GPT 图像模型生成图片的工具。
- `type: "image_generation"`
@@ -7674,7 +7676,7 @@
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图片还是编辑已有图片。默认值: `auto`.
- `"generate"`
@@ -7684,11 +7686,11 @@
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。透明背景适用于受支持的 GPT
- 图像模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持处于预览阶段。使用
- `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图片的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。支持
+ 的 GPT Image 模型可使用透明背景。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,此功能处于预览阶段。当使用
+ `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -7698,7 +7700,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所付出的努力程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持,不支持 `gpt-image-1-mini`。支持 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图片的风格和特征(尤其是面部特征)时所投入的精力。该参数仅 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持, `gpt-image-1-mini`。不支持。支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -7711,11 +7713,11 @@
- `file_id: optional string`
- 蒙版图像的文件 ID。
+ 蒙版图片的文件 ID。
- `image_url: optional string`
- Base64 编码的蒙版图像。
+ Base64 编码的掩码图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
@@ -7745,7 +7747,7 @@
- `moderation: optional "auto" or "low"`
- 生成图像的内容审核级别。默认值: `auto`.
+ 生成图像的审核级别。默认值: `auto`.
- `"auto"`
@@ -7768,7 +7770,7 @@
- `partial_images: optional number`
- 在流式模式下生成的部分图像数量,范围为 0(默认值)到 3。
+ 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -7785,13 +7787,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,以 `WIDTHxHEIGHT` 字符串形式表示,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 受到支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一: `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一: `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式传入任意分辨率,例如 `WIDTHxHEIGHT` 。 `1536x864`,宽和高都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动尺寸的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,以 `WIDTHxHEIGHT` 字符串形式表示,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 受到支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一: `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一: `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式传入任意分辨率,例如 `WIDTHxHEIGHT` 。 `1536x864`,宽和高都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动尺寸的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -7841,7 +7843,7 @@
- `file_ids: optional array of string`
- 一个可选的已上传文件列表,供你的代码使用。
+ 可供代码使用的可选已上传文件列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -7865,7 +7867,7 @@
- `skills: optional array of SkillReference or InlineSkill`
- 通过 id 或内联数据引用的可选技能列表。
+ 通过 ID 或内联数据引用的可选技能列表。
- `SkillReference object { skill_id, type, version }`
@@ -7881,7 +7883,7 @@
- `version: optional string`
- 可选的技能版本。使用正整数或 'latest'。省略时使用默认值。
+ 可选的技能版本。使用正整数或 'latest'。省略则使用默认值。
- `InlineSkill object { description, name, source, type }`
@@ -7915,7 +7917,7 @@
- `type: "inline"`
- 为本次请求定义一个内联技能。
+ 为该请求定义一个内联技能。
- `"inline"`
@@ -7923,13 +7925,13 @@
- `type: "local"`
- 使用本地计算机环境。
+ 使用本地计算环境。
- `"local"`
- `skills: optional array of LocalSkill`
- 可选的技能列表。
+ 一个可选的技能列表。
- `description: string`
@@ -7979,7 +7981,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -8009,7 +8011,7 @@
- `syntax: "lark" or "regex"`
- 语法定义的语法。取值为以下之一 `lark` 或 `regex`.
+ 语法定义的语法格式。可选值之一为 `lark` 或 `regex`.
- `"lark"`
@@ -8031,7 +8033,7 @@
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 在工具调用中使用的命名空间名称(例如, `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
@@ -8055,19 +8057,19 @@
- `defer_loading: optional boolean`
- 是否应延迟此函数并通过工具搜索发现它。
+ 此函数是否应被延迟并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。此字段不描述 content 数组形式的输出。
+ 用于描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。这不描述内容数组(content-array)输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否启用严格的参数校验。如果省略,当 schema 兼容时 Responses 尝试使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在模式兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -8093,7 +8095,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -8105,23 +8107,23 @@
- `type: "namespace"`
- 工具的类型。始终为 `namespace`.
+ 该工具的类型。始终为 `namespace`.
- `"namespace"`
- `ToolSearch object { type, description, execution, parameters }`
- 用于延迟工具的托管或 BYOT 工具搜索配置。
+ 用于延迟工具的托管工具搜索或 BYOT 工具搜索配置。
- `type: "tool_search"`
- 工具的类型。始终为 `tool_search`.
+ 该工具的类型。始终为 `tool_search`.
- `"tool_search"`
- `description: optional string or null`
- 向模型展示的客户端执行工具搜索工具的描述。
+ 展示给模型的、用于客户端执行的工具搜索工具的描述。
- `execution: optional "server" or "client"`
@@ -8133,15 +8135,15 @@
- `parameters: optional unknown or null`
- 客户端执行工具搜索工具的参数 schema。
+ 客户端执行的工具搜索工具的参数 schema。
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具会在网页上搜索相关结果以用于回复中。详细了解 Responses API [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 此工具会搜索网页以获取在响应中使用的结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索 工具的类型。可选值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型。取以下值之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -8155,7 +8157,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级使用指导。可选值为 `low`, `medium`,或 `high`. `medium` 是默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。取以下值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -8191,11 +8193,11 @@
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用 unified diff 创建、删除或更新文件。
+ 允许助手使用统一差异来创建、删除或更新文件。
- `type: "apply_patch"`
- 工具的类型。始终为 `apply_patch`.
+ 该工具的类型。始终为 `apply_patch`.
- `"apply_patch"`
@@ -8249,7 +8251,7 @@
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 此条目中可用的额外工具列表。
+ 在此项中提供的一系列额外工具。
- `Function object { name, parameters, strict, 5 more }`
@@ -8257,7 +8259,7 @@
- `name: string`
- 要调用的函数的名称。
+ 要调用的函数名称。
- `parameters: map[unknown] or null`
@@ -8265,7 +8267,7 @@
- `strict: boolean or null`
- 是否对该函数工具强制执行严格参数验证。
+ 是否对该函数工具强制执行严格的参数校验。
- `type: "function"`
@@ -8283,45 +8285,45 @@
- `defer_loading: optional boolean`
- 此函数是否被延迟加载并通过工具搜索加载。
+ 此函数是否被延迟,并通过工具搜索加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 对该函数的描述。供模型用于判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 用于描述此函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 用于描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 用于从已上传文件中搜索相关内容文件搜索 tool [文件搜索 tool](https://platform.openai.com/docs/guides/tools-file-search).
+ 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索 tool 的类型。始终为 `file_search`.
+ 文件搜索工具的类型,始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库 ID。
+ 要搜索的向量存储的 ID 列表。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的过滤器。
+ 要应用的筛选条件。
- `ComparisonFilter object { key, type, value }`
- 用于将指定属性键与给定值按照定义的比较运算进行比较的过滤器。
+ 用于将指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
- `CompoundFilter object { filters, type }`
- 使用以下方式合并多个过滤器 `and` 或 `or`.
+ 使用以下方式组合多个筛选条件 `and` 或 `or`.
- `max_num_results: optional number`
- 返回的最大结果数。该数字应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -8329,15 +8331,15 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于控制互逆排序融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
+ 在启用混合搜索时,控制倒数排名融合中语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
- 在互逆排序融合中嵌入的权重。
+ 倒数排名融合中嵌入的权重。
- `text_weight: number`
- 在互逆排序融合中文本的权重。
+ 倒数排名融合中文本的权重。
- `ranker: optional "auto" or "default-2024-11-15"`
@@ -8349,11 +8351,11 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数字会尝试仅返回最相关的结果,但可能返回的结果更少。
+ 文件搜索的分数阈值,取值范围为 0 到 1。越接近 1 的数值会尝试仅返回最相关的结果,但返回的结果可能更少。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
@@ -8363,15 +8365,15 @@
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
- 计算机显示屏的高度。
+ 计算机显示器的高度。
- `display_width: number`
- 计算机显示屏的宽度。
+ 计算机显示器的宽度。
- `environment: "windows" or "mac" or "linux" or 2 more`
@@ -8395,12 +8397,12 @@
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示相关的来源。详细了解
+ 在互联网上搜索与提示相关来源。了解更多关于
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索 工具的类型。可选值为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型。取以下值之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -8408,7 +8410,7 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 进行实时互联网访问。若省略,默认值为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索实时访问互联网。省略时默认为 true。当为 false 时,网页搜索工具以离线/仅缓存模式运行,并且不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
@@ -8417,13 +8419,13 @@
- `allowed_domains: optional array of string or null`
搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 同时允许所提供域名的子域名。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级使用指导。可选值为 `low`, `medium`,或 `high`. `medium` 是默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。取以下值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -8459,12 +8461,12 @@
- `Mcp object { server_label, type, allowed_callers, 9 more }`
- 允许模型通过远程模型上下文协议
- (MCP)服务器访问其他工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
+ 通过远程 Model Context Protocol
+ (MCP) 服务器为模型提供对其他工具的访问权限。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 此 MCP 服务器的标签,用于在工具调用中识别它。
- `type: "mcp"`
@@ -8482,21 +8484,21 @@
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许使用的工具名称列表或筛选对象。
+ 允许使用的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许使用的工具名称字符串数组
+ 允许使用的工具名称的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -8504,17 +8506,17 @@
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,可以与自定义 MCP 服务器
- URL 或服务连接器一起使用。你的应用程序必须处理 OAuth 授权流
- 并在此处提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,既可
+ 与自定义 MCP 服务器 URL 一起使用,也可与服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并在此处提供令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的连接器。必须提供以下之一。详细
- `server_url`, `connector_id`,或 `tunnel_id` 了解关于服务连接器
- about service connectors [here](/docs/guides/tools-remote-mcp#connectors).
+ 服务连接器的标识符,例如 ChatGPT 中提供的那些。必须提供
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一。详细了解
+ 服务连接器 [here](/docs/guides/tools-remote-mcp#connectors).
- Currently supported `connector_id` values are:
+ 目前支持的 `connector_id` 值包括:
- Dropbox: `connector_dropbox`
- Gmail: `connector_gmail`
@@ -8543,32 +8545,32 @@
- `defer_loading: optional boolean`
- Whether this MCP tool is deferred and discovered via tool search.
+ 此 MCP 工具是否为延迟加载,并通过工具搜索发现。
- `headers: optional map[string] or null`
- Optional HTTP headers to send to the MCP server. Use for authentication
- or other purposes.
+ 发送到 MCP 服务器的可选 HTTP 标头。用于身份验证
+ 或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- Specify which of the MCP server's tools require approval.
+ 指定 MCP 服务器的哪些工具需要批准。
- `McpToolApprovalFilter object { always, never }`
- Specify which of the MCP server's tools require approval. Can be
- `always`, `never`, or a filter object associated with tools
- that require approval.
+ 指定 MCP 服务器的哪些工具需要批准。可以是
+ `always`, `never`,或与需要批准的工具相关联的筛选器对象
+ 。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -8576,13 +8578,13 @@
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -8590,9 +8592,9 @@
- `McpToolApprovalSetting = "always" or "never"`
- Specify a single approval policy for all tools. One of `always` 或
- `never`. When set to `always`, all tools will require approval. When
- set to `never`, all tools will not require approval.
+ 为所有工具指定一个统一的批准策略。可选值包括 `always` 或
+ `never`。当设置为 `always`,时,所有工具都需要批准。当
+ 设置为 `never`,时,所有工具都不需要批准。
- `"always"`
@@ -8600,26 +8602,26 @@
- `server_description: optional string`
- Optional description of the MCP server, used to provide more context.
+ MCP 服务器的可选描述,用于提供更多上下文。
- `server_url: optional string`
- MCP 服务器的 URL。必须提供以下之一: `server_url`, `connector_id`,或
- `tunnel_id` 必须提供其中之一。
+ MCP 服务器的 URL。必须提供以下其中一项: `server_url`, `connector_id`,或
+ `tunnel_id` 。
- `tunnel_id: optional string`
- 用于代替直接服务器 URL 的安全 MCP 隧道 ID。必须提供以下之一:
- `server_url`, `connector_id`,或 `tunnel_id` 必须提供其中之一。
+ 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供以下其中一项:
+ `server_url`, `connector_id`,或 `tunnel_id` 。
- `CodeInterpreter object { container, type, allowed_callers }`
- 一个运行 Python 代码以帮助生成提示词回复的工具。
+ 一个用于运行 Python 代码以帮助生成对提示词回复的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID,也可以是一个用于指定可供你代码使用的已上传文件 ID 的对象,并提供
- 指定可供代码使用的已上传文件 ID,以及一个可选的
+ 代码解释器容器。可以是容器 ID,也可以是用于指定可供代码使用的已上传文件 ID 的对象,以及一个可选的
+ 设置。
可选的 `memory_limit` 设置。
- `string`
@@ -8628,17 +8630,17 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要对其运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定要在其上运行代码的文件 ID。
- `type: "auto"`
- Always `auto`.
+ 始终为 `auto`.
- `"auto"`
- `file_ids: optional array of string`
- 一个可选的已上传文件列表,供你的代码使用。
+ 可供代码使用的可选已上传文件列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -8678,13 +8680,13 @@
- `type: "programmatic_tool_calling"`
- 工具的类型。始终为 `programmatic_tool_calling`.
+ 该工具的类型。始终为 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ImageGeneration object { type, action, background, 9 more }`
- 使用 GPT 图像模型生成图像的工具。
+ 使用 GPT 图像模型生成图片的工具。
- `type: "image_generation"`
@@ -8694,7 +8696,7 @@
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图片还是编辑已有图片。默认值: `auto`.
- `"generate"`
@@ -8704,11 +8706,11 @@
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。透明背景适用于受支持的 GPT
- 图像模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持处于预览阶段。使用
- `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图片的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。支持
+ 的 GPT Image 模型可使用透明背景。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,此功能处于预览阶段。当使用
+ `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -8718,7 +8720,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所付出的努力程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持,不支持 `gpt-image-1-mini`。支持 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图片的风格和特征(尤其是面部特征)时所投入的精力。该参数仅 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持, `gpt-image-1-mini`。不支持。支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -8731,11 +8733,11 @@
- `file_id: optional string`
- 蒙版图像的文件 ID。
+ 蒙版图片的文件 ID。
- `image_url: optional string`
- Base64 编码的蒙版图像。
+ Base64 编码的掩码图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
@@ -8765,7 +8767,7 @@
- `moderation: optional "auto" or "low"`
- 生成图像的内容审核级别。默认值: `auto`.
+ 生成图像的审核级别。默认值: `auto`.
- `"auto"`
@@ -8788,7 +8790,7 @@
- `partial_images: optional number`
- 在流式模式下生成的部分图像数量,范围为 0(默认值)到 3。
+ 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -8805,13 +8807,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,以 `WIDTHxHEIGHT` 字符串形式表示,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 受到支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一: `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一: `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式传入任意分辨率,例如 `WIDTHxHEIGHT` 。 `1536x864`,宽和高都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动尺寸的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,以 `WIDTHxHEIGHT` 字符串形式表示,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 受到支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一: `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一: `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式传入任意分辨率,例如 `WIDTHxHEIGHT` 。 `1536x864`,宽和高都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动尺寸的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -8881,7 +8883,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -8901,7 +8903,7 @@
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 在工具调用中使用的命名空间名称(例如, `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
@@ -8925,19 +8927,19 @@
- `defer_loading: optional boolean`
- 是否应延迟此函数并通过工具搜索发现它。
+ 此函数是否应被延迟并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。此字段不描述 content 数组形式的输出。
+ 用于描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。这不描述内容数组(content-array)输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否启用严格的参数校验。如果省略,当 schema 兼容时 Responses 尝试使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在模式兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -8963,7 +8965,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -8975,23 +8977,23 @@
- `type: "namespace"`
- 工具的类型。始终为 `namespace`.
+ 该工具的类型。始终为 `namespace`.
- `"namespace"`
- `ToolSearch object { type, description, execution, parameters }`
- 用于延迟工具的托管或 BYOT 工具搜索配置。
+ 用于延迟工具的托管工具搜索或 BYOT 工具搜索配置。
- `type: "tool_search"`
- 工具的类型。始终为 `tool_search`.
+ 该工具的类型。始终为 `tool_search`.
- `"tool_search"`
- `description: optional string or null`
- 向模型展示的客户端执行工具搜索工具的描述。
+ 展示给模型的、用于客户端执行的工具搜索工具的描述。
- `execution: optional "server" or "client"`
@@ -9003,15 +9005,15 @@
- `parameters: optional unknown or null`
- 客户端执行工具搜索工具的参数 schema。
+ 客户端执行的工具搜索工具的参数 schema。
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具会在网页上搜索相关结果以用于回复中。详细了解 Responses API [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 此工具会搜索网页以获取在响应中使用的结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索 工具的类型。可选值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型。取以下值之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -9025,7 +9027,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级使用指导。可选值为 `low`, `medium`,或 `high`. `medium` 是默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。取以下值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -9061,11 +9063,11 @@
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用 unified diff 创建、删除或更新文件。
+ 允许助手使用统一差异来创建、删除或更新文件。
- `type: "apply_patch"`
- 工具的类型。始终为 `apply_patch`.
+ 该工具的类型。始终为 `apply_patch`.
- `"apply_patch"`
@@ -9085,13 +9087,13 @@
- `id: optional string or null`
- 此额外工具条目的唯一 ID。
+ 此额外工具项的唯一 ID。
- `Reasoning object { id, summary, type, 3 more }`
- 对推理模型在生成回复时所使用的思维链的描述。如果你手动管理上下文,请务必在后续对话轮次中将这些条目包含在提交给 响应接口 的
- 中。 `input` 请求里
- 。
+ 推理模型在生成响应时所使用的思维链的描述。如果你正在手动管理上下文,请务必在后续对话轮次中将这些项包含到你的
+ 调用中,以便将它们传入 `input` Responses API
+ ,用于后续对话轮次。如果你正在手动
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -9104,7 +9106,7 @@
- `text: string`
- 到目前为止模型推理输出的摘要。
+ 模型到目前为止的推理输出摘要。
- `type: "summary_text"`
@@ -9124,7 +9126,7 @@
- `text: string`
- 来自模型的推理文本。
+ 模型输出的推理文本。
- `type: "reasoning_text"`
@@ -9135,19 +9137,19 @@
- `encrypted_content: optional string or null`
推理条目的加密内容。默认情况下会填充
- 由 `POST /v1/responses` 和 WebSocket
+ 针对通过 `POST /v1/responses` 和 WebSocket
`response.create` 请求返回的推理条目。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 从 `response.output_item.done` 事件中
- 后续请求中获取。由于 `encrypted_content` 处于
- `response.output_item.added` 中的数据可能不完整。尤其是在
- important when `store` is `false` 或在使用 Zero Data Retention 时。
+ 在流式传输时,使用已完成的推理条目及其
+ `encrypted_content` 来自该 `response.output_item.done` 事件,在
+ 后续请求中使用 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这一点尤其
+ 重要,当 `store` 为 `false` 或使用零数据保留(Zero Data Retention)时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值为 `in_progress`, `completed`,或
- `incomplete`。之一。当通过 API 返回条目时填充。
+ 该条目的状态。取值之一: `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回项时填充。
- `"in_progress"`
@@ -9157,7 +9159,7 @@
- `Compaction object { encrypted_content, type, id }`
- 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -9165,7 +9167,7 @@
- `type: "compaction"`
- 该 item 的类型。始终为 `compaction`.
+ 该项的类型。始终为 `compaction`.
- `"compaction"`
@@ -9213,7 +9215,7 @@
- `code: string or null`
- 要运行的代码,若不可用则为 null。
+ 要运行的代码,如果不可用则为 null。
- `container_id: string`
@@ -9221,16 +9223,16 @@
- `outputs: array of object { logs, type } or object { type, url } or null`
- 代码解释器生成的输出,例如日志或图像。
- 若没有可用输出,可能为 null。
+ 由代码解释器生成的输出,例如日志或图像。
+ 如果没有可用的输出,可能为 null。
- `Logs object { logs, type }`
- 代码解释器输出的日志。
+ 由代码解释器输出的日志。
- `logs: string`
- 代码解释器输出的日志。
+ 由代码解释器输出的日志。
- `type: "logs"`
@@ -9240,7 +9242,7 @@
- `Image object { type, url }`
- 代码解释器输出的图像。
+ 由代码解释器输出的图像。
- `type: "image"`
@@ -9250,7 +9252,7 @@
- `url: string`
- 代码解释器输出图像的 URL。
+ 由代码解释器输出的图像 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -9290,7 +9292,7 @@
- `env: map[string]`
- 为命令设置的环境变量。
+ 为该命令设置的环境变量。
- `type: "exec"`
@@ -9300,15 +9302,15 @@
- `timeout_ms: optional number or null`
- 命令的可选超时时间(毫秒)。
+ 该命令的可选超时时间(毫秒)。
- `user: optional string or null`
- 运行命令时使用的可选用户。
+ 运行该命令时使用的可选用户。
- `working_directory: optional string or null`
- 运行命令时所在的可选工作目录。
+ 运行该命令时使用的可选工作目录。
- `call_id: string`
@@ -9350,7 +9352,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值为 `in_progress`, `completed`,或 `incomplete`.
+ 该条目的状态。取值之一: `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -9360,11 +9362,11 @@
- `ShellCall object { action, call_id, type, 4 more }`
- 表示请求执行一个或多个 shell 命令的工具。
+ 表示执行一个或多个 shell 命令请求的工具。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行该工具调用的 shell 命令及限制。
+ 描述如何运行该工具调用的 shell 命令和限制。
- `commands: array of string`
@@ -9372,25 +9374,25 @@
- `max_output_length: optional number or null`
- 从合并后的 stdout 和 stderr 输出中捕获的最大 UTF-8 字符数。
+ 从合并的 stdout 和 stderr 输出中捕获的最大 UTF-8 字符数。
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最长墙钟时间(毫秒)。
+ 允许 shell 命令运行的最大墙钟时间(毫秒)。
- `call_id: string`
- 由模型生成的 shell 工具调用的唯一 ID。
+ 模型生成的 shell 工具调用的唯一 ID。
- `type: "shell_call"`
- 该 item 的类型。始终为 `shell_call`.
+ 该项的类型。始终为 `shell_call`.
- `"shell_call"`
- `id: optional string or null`
- shell 工具调用的唯一 ID。在通过 API 返回此条目时填充。
+ shell 工具调用的唯一 ID。通过 API 返回该条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -9426,7 +9428,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态。可选值为 `in_progress`, `completed`,或 `incomplete`.
+ shell 调用的状态。取值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -9436,15 +9438,15 @@
- `ShellCallOutput object { call_id, output, type, 4 more }`
- shell 工具调用产生的流式输出条目。
+ 由 shell 工具调用流式输出的条目。
- `call_id: string`
- 由模型生成的 shell 工具调用的唯一 ID。
+ 模型生成的 shell 工具调用的唯一 ID。
- `output: array of ResponseFunctionShellCallOutputContent`
- 已捕获的 stdout 和 stderr 输出块及其关联的结果。
+ 捕获的 stdout 和 stderr 输出块及其关联的结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -9452,7 +9454,7 @@
- `Timeout object { type }`
- 表示该 shell 调用超出了其配置的时间限制。
+ 表示 shell 调用超过了其配置的时间限制。
- `type: "timeout"`
@@ -9462,11 +9464,11 @@
- `Exit object { exit_code, type }`
- 表示 shell 命令已结束并返回了退出码。
+ 表示 shell 命令已执行完毕并返回了退出码。
- `exit_code: number`
- 由 shell 进程返回的退出码。
+ shell 进程返回的退出码。
- `type: "exit"`
@@ -9484,13 +9486,13 @@
- `type: "shell_call_output"`
- 该 item 的类型。始终为 `shell_call_output`.
+ 该项的类型。始终为 `shell_call_output`.
- `"shell_call_output"`
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。在通过 API 返回此条目时填充。
+ shell 工具调用输出的唯一 ID。通过 API 返回该条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
@@ -9518,7 +9520,7 @@
- `max_output_length: optional number or null`
- 为该 shell 调用的合并输出捕获的最大 UTF-8 字符数。
+ 为此 shell 调用的合并输出捕获的最大 UTF-8 字符数。
- `status: optional "in_progress" or "completed" or "incomplete" or null`
@@ -9532,11 +9534,11 @@
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 一个表示使用 diff 补丁创建、删除或更新文件的工具调用。
+ 表示使用 diff 补丁来创建、删除或更新文件的工具调用。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
@@ -9548,11 +9550,11 @@
- `diff: string`
- 创建文件时要应用的 unified diff 内容。
+ 创建文件时应用的统一差异内容。
- `path: string`
- 相对于工作区根目录的要创建的文件的路径。
+ 相对于工作区根目录的待创建文件路径。
- `type: "create_file"`
@@ -9566,7 +9568,7 @@
- `path: string`
- 相对于工作区根目录的要删除的文件的路径。
+ 相对于工作区根目录的待删除文件路径。
- `type: "delete_file"`
@@ -9580,11 +9582,11 @@
- `diff: string`
- 要应用于现有文件的 unified diff 内容。
+ 应用于现有文件的统一差异内容。
- `path: string`
- 相对于工作区根目录的要更新的文件的路径。
+ 相对于工作区根目录的待更新文件路径。
- `type: "update_file"`
@@ -9602,7 +9604,7 @@
- `type: "apply_patch_call"`
- 该 item 的类型。始终为 `apply_patch_call`.
+ 该项的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -9636,11 +9638,11 @@
- `ApplyPatchCallOutput object { call_id, status, type, 3 more }`
- apply patch 工具调用发出的流式输出。
+ apply patch 工具调用产生的流式输出。
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
@@ -9652,7 +9654,7 @@
- `type: "apply_patch_call_output"`
- 该 item 的类型。始终为 `apply_patch_call_output`.
+ 该项的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -9686,15 +9688,15 @@
- `output: optional string or null`
- 来自 apply patch 工具的可选人类可读日志文本(例如补丁结果或错误)。
+ apply patch 工具返回的可选人类可读的日志文本(例如补丁结果或错误)。
- `McpListTools object { id, server_label, tools, 2 more }`
- MCP 服务器上可用的工具列表。
+ MCP 服务器上可用工具的列表。
- `id: string`
- 该列表的唯一 ID。
+ 此列表的唯一 ID。
- `server_label: string`
@@ -9714,25 +9716,25 @@
- `annotations: optional unknown or null`
- 有关该工具的其他注释。
+ 关于该工具的附加注释。
- `description: optional string or null`
- 工具的描述。
+ 该工具的描述。
- `type: "mcp_list_tools"`
- 该 item 的类型。始终为 `mcp_list_tools`.
+ 该项的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具,则返回错误消息。
+ 如果服务端无法列出工具,则返回错误消息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工审批某个工具调用。
+ 对工具调用的人工审批请求。
- `id: string`
@@ -9740,7 +9742,7 @@
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
@@ -9752,7 +9754,7 @@
- `type: "mcp_approval_request"`
- 该 item 的类型。始终为 `mcp_approval_request`.
+ 该项的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
@@ -9762,15 +9764,15 @@
- `approval_request_id: string`
- 正在应答的审批请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已被批准。
+ 请求是否已获批准。
- `type: "mcp_approval_response"`
- 该 item 的类型。始终为 `mcp_approval_response`.
+ 该项的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -9784,7 +9786,7 @@
- `McpCall object { id, arguments, name, 6 more }`
- 在 MCP 服务器上对工具的一次调用。
+ 对 MCP 服务器上工具的调用。
- `id: string`
@@ -9804,7 +9806,7 @@
- `type: "mcp_call"`
- 该 item 的类型。始终为 `mcp_call`.
+ 该项的类型。始终为 `mcp_call`.
- `"mcp_call"`
@@ -9851,7 +9853,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
+ 工具调用的状态。取值之一 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -9865,7 +9867,7 @@
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 来自你代码的自定义工具调用输出,正在发回给模型。
+ 来自你的代码的自定义工具调用输出,将被发送回模型。
- `call_id: string`
@@ -9882,7 +9884,7 @@
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 自定义工具调用的文本、图片或文件输出。
+ 自定义工具调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
@@ -9890,7 +9892,7 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
+ 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -9940,7 +9942,7 @@
- `input: string`
- 模型生成的自定义工具调用的输入。
+ 由模型生成的自定义工具调用的输入。
- `name: string`
@@ -9986,7 +9988,7 @@
- `type: "compaction_trigger"`
- 该 item 的类型。始终为 `compaction_trigger`.
+ 该项的类型。始终为 `compaction_trigger`.
- `"compaction_trigger"`
@@ -10000,11 +10002,11 @@
- `id: string`
- 要引用的条目的 ID。
+ 要引用的条目 ID。
- `type: optional "item_reference" or null`
- 要引用的条目的类型。始终为 `item_reference`.
+ 要引用的条目类型。始终为 `item_reference`.
- `"item_reference"`
@@ -10012,19 +10014,19 @@
- `id: string`
- 此程序条目的唯一 ID。
+ 此程序项的唯一 ID。
- `call_id: string`
- 程序条目的稳定调用 ID。
+ 程序项的稳定调用 ID。
- `code: string`
- 通过程序化工具调用执行的 JavaScript 源码。
+ 由程序化工具调用执行的 JavaScript 源代码。
- `fingerprint: string`
- 必须往返传输的不透明程序回放指纹。
+ 必须往返(round-trip)的不透明程序重放指纹。
- `type: "program"`
@@ -10036,15 +10038,15 @@
- `id: string`
- 此程序输出条目的唯一 ID。
+ 此程序输出项的唯一 ID。
- `call_id: string`
- 程序条目的调用 ID。
+ 程序项的调用 ID。
- `result: string`
- 由程序条目生成的结果。
+ 程序项生成的结果。
- `status: "completed" or "incomplete"`
@@ -10062,18 +10064,18 @@
- `metadata: Metadata or null`
- 可以附加到对象的 16 个键值对集合。可用于
- 以结构化格式存储有关对象的附加信息,并通过
- format,以及通过 API 或控制台查询对象。
+ 可附加到对象的 16 组键值对。可用于
+ 以结构化格式存储对象的附加信息,并通过
+ 格式,以及通过 API 或控制台查询对象。
- 键为字符串,最大长度为 64 个字符。值为字符串,
- 最大长度为 512 个字符。
+ 键为字符串,最大长度为 64 个字符。值为字符串
+ ,最大长度为 512 个字符。
- `model: ResponsesModel`
- 用于生成响应的模型 ID,如 `gpt-5.6-sol`。OpenAI
- 提供多种不同能力、性能
- 特征和价格的模型。请参阅 [模型指南](/docs/models)
+ 用于生成响应的模型 ID,例如 `gpt-5.6-sol`。OpenAI
+ 提供了众多具有不同能力、性能
+ 特征和价位的模型。请参阅 [模型指南](/docs/models)
以浏览和比较可用的模型。
- `string`
@@ -10296,20 +10298,20 @@
由模型生成的内容项数组。
- - 该数组中项的长度和顺序 `output` 数组取决于
- 模型的响应。
- - 与其直接访问 `output` 数组中的第一项并
- 假设它是 `assistant` 包含模型生成内容的
- 消息,你可以考虑使用该 `output_text` 属性,在支持该属性的
- SDK 中可用。
+ - 数组中项的长度和顺序取决于模型的响应。 `output` 数组中项的长度和顺序取决于模型的响应。
+ 数组中项的长度和顺序取决于模型的响应。
+ - 与其访问数组中的第一项并假设它是包含模型生成内容的消息, `output` 与其访问数组中的第一项并假设它是包含模型生成内容的消息,不如考虑使用在SDK中受支持的相关属性。
+ 与其访问数组中的第一项并假设它是包含模型生成内容的消息, `assistant` 与其访问数组中的第一项并假设它是包含模型生成内容的消息,不如考虑使用在开发工具包中受支持的相关属性。
+ 与其访问数组中的第一项并假设它是包含模型生成内容的消息,不如考虑使用在开发工具包中受支持的相关属性。 `output_text` 与其访问数组中的第一项并假设它是包含模型生成内容的消息,不如考虑使用在开发工具包中受支持的相关属性。
+ 与其访问数组中的第一项并假设它是包含模型生成内容的消息,不如考虑使用在开发工具包中受支持的相关属性。
- `ResponseOutputMessage object { id, content, role, 3 more }`
- 模型输出的消息。
+ 模型的输出消息。
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。参见
+ 文件搜索 工具调用的结果。请参阅
[文件搜索 指南](/docs/guides/tools-file-search) 了解更多信息。
- `id: string`
@@ -10318,11 +10320,11 @@
- `queries: array of string`
- 用于搜索文件的查询。
+ 用于搜索文件的查询语句。
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值为 `in_progress`,
+ 文件搜索 工具调用的状态。可选值为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -10347,11 +10349,11 @@
- `attributes: optional map[string or number or boolean] or null`
- 可以附加到对象的 16 个键值对集合。可用于
- 以结构化格式存储有关对象的附加信息,并通过
- API 或控制台查询对象。键为字符串
- 最大长度为 64 个字符。值是最大
- 长度为 512 个字符的字符串、布尔值或数字。
+ 可附加到对象的 16 组键值对。可用于
+ 以结构化格式存储对象的附加信息,并通过
+ API 或控制台查询对象。键为字符串,
+ 最大长度为 64 个字符。值为最大
+ 长度 512 个字符的字符串、布尔值或数字。
- `string`
@@ -10369,7 +10371,7 @@
- `score: optional number`
- 文件的相关性评分,介于 0 和 1 之间。
+ 文件的相关性得分——介于 0 和 1 之间的值。
- `text: optional string`
@@ -10390,7 +10392,7 @@
- `name: string`
- 要运行的函数名称。
+ 要运行的函数的名称。
- `type: "function_call"`
@@ -10428,8 +10430,8 @@
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值为 `in_progress`, `completed`,或
- `incomplete`。之一。当通过 API 返回条目时填充。
+ 该条目的状态。取值之一: `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回项时填充。
- `"in_progress"`
@@ -10445,7 +10447,7 @@
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 由你的代码生成的函数调用的输出。
+ 你的代码所生成函数调用的输出。
可以是字符串或输出内容列表。
- `StringOutput = string`
@@ -10454,7 +10456,7 @@
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
@@ -10462,7 +10464,7 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
+ 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -10470,8 +10472,8 @@
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值为 `in_progress`, `completed`,或
- `incomplete`。之一。当通过 API 返回条目时填充。
+ 该条目的状态。取值之一: `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回项时填充。
- `"in_progress"`
@@ -10515,33 +10517,33 @@
- `created_by: optional string`
- 创建该条目的参与者的标识符。
+ 创建该条目的角色的标识符。
- `name: optional string`
- 生成该输出的工具的名称。
+ 产生该输出的工具名称。
- `namespace: optional string`
- 生成该输出的工具的命名空间。
+ 产生该输出的工具命名空间。
- `WebSearchCall object { id, action, status, type }`
- 网页搜索 工具调用的结果。请参阅
- [网页搜索 指南](/docs/guides/tools-web-search) 了解更多信息。
+ 网页搜索工具调用的结果。请参阅
+ [网页搜索指南](/docs/guides/tools-web-search) 了解更多信息。
- `id: string`
- 网页搜索 工具调用的唯一 ID。
+ 网页搜索工具调用的唯一 ID。
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述本次 网页搜索 调用中所执行的具体操作的对象。
+ 描述此次 网页搜索调用中所执行具体操作的对象。
包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- 操作类型 "search" - 执行 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
@@ -10563,7 +10565,7 @@
- `type: "url"`
- 来源类型。始终为 `url`.
+ 来源的类型。始终为 `url`.
- `"url"`
@@ -10573,7 +10575,7 @@
- `OpenPage object { type, url }`
- 操作类型 "open_page" —— 从搜索结果中打开指定的 URL。
+ 操作类型 "open_page" - 打开搜索结果中的指定 URL。
- `type: "open_page"`
@@ -10587,11 +10589,11 @@
- `FindInPage object { pattern, type, url }`
- 操作类型 "find_in_page":在已加载的页面中搜索某个模式。
+ 操作类型 "find_in_page":在已加载的页面中搜索某个模式。
- `pattern: string`
- 要在页面中搜索的模式或文本。
+ 要在页面内搜索的模式或文本。
- `type: "find_in_page"`
@@ -10623,16 +10625,16 @@
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
- 对计算机使用工具的工具调用。参见
- [计算机使用指南](/docs/guides/tools-computer-use) 了解更多信息。
+ 对计算机使用工具的工具调用。请参阅
+ [computer use 指南](/docs/guides/tools-computer-use) 了解更多信息。
- `id: string`
- 计算机调用的唯一 ID。
+ 该计算机调用的唯一 ID。
- `call_id: string`
- 在向工具调用提供输出时使用的标识符。
+ 在用输出响应工具调用时使用的标识符。
- `pending_safety_checks: array of object { id, code, message }`
@@ -10648,12 +10650,12 @@
- `message: optional string or null`
- 有关待处理安全检查的详细信息。
+ 关于待处理安全检查的详细信息。
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值为 `in_progress`, `completed`,或
- `incomplete`。之一。当通过 API 返回条目时填充。
+ 该条目的状态。取值之一: `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回项时填充。
- `"in_progress"`
@@ -10663,18 +10665,18 @@
- `type: "computer_call"`
- 计算机调用的类型,恒为 `computer_call`.
+ 计算机调用的类型。始终为 `computer_call`.
- `"computer_call"`
- `action: optional ComputerAction`
- 点击动作。
+ 点击操作。
- `actions: optional ComputerActionList`
- 针对的扁平化批处理操作 `computer_use`。每个操作都包含一个
- `type` 判别字段以及操作特有的字段。
+ 针对 `computer_use`。展平后的批量操作。每个操作都包含一个
+ `type` 判别字段以及操作专属字段。
- `ComputerCallOutput object { id, call_id, output, 4 more }`
@@ -10684,7 +10686,7 @@
- `call_id: string`
- 生成该输出的计算机工具调用的 ID。
+ 产生该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
@@ -10692,8 +10694,8 @@
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值为 `in_progress`, `completed`,或
- `incomplete`。之一。通过 API 返回输入项时填充。
+ 消息输入的状态。可选值为 `in_progress`, `completed`,或
+ `incomplete`。之一。当通过 API 返回输入项时填充该字段。
- `"completed"`
@@ -10705,13 +10707,13 @@
- `type: "computer_call_output"`
- 计算机工具调用输出的类型。始终为 `computer_call_output`.
+ 计算机工具调用的输出类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由API报告的、已被
+ 由 API 报告的、已被
开发者确认的安全检查。
- `id: string`
@@ -10724,17 +10726,17 @@
- `message: optional string or null`
- 有关待处理安全检查的详细信息。
+ 关于待处理安全检查的详细信息。
- `created_by: optional string`
- 创建该条目的参与者的标识符。
+ 创建该条目的角色的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 对推理模型在生成回复时所使用的思维链的描述。如果你手动管理上下文,请务必在后续对话轮次中将这些条目包含在提交给 响应接口 的
- 中。 `input` 请求里
- 。
+ 推理模型在生成响应时所使用的思维链的描述。如果你正在手动管理上下文,请务必在后续对话轮次中将这些项包含到你的
+ 调用中,以便将它们传入 `input` Responses API
+ ,用于后续对话轮次。如果你正在手动
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -10747,7 +10749,7 @@
- `text: string`
- 到目前为止模型推理输出的摘要。
+ 模型到目前为止的推理输出摘要。
- `type: "summary_text"`
@@ -10765,7 +10767,7 @@
- `text: string`
- 来自模型的推理文本。
+ 模型输出的推理文本。
- `type: "reasoning_text"`
@@ -10776,19 +10778,19 @@
- `encrypted_content: optional string or null`
推理条目的加密内容。默认情况下会填充
- 由 `POST /v1/responses` 和 WebSocket
+ 针对通过 `POST /v1/responses` 和 WebSocket
`response.create` 请求返回的推理条目。
- 在流式传输时,请使用已完成的推理条目及其
- `encrypted_content` 从 `response.output_item.done` 事件中
- 后续请求中获取。由于 `encrypted_content` 处于
- `response.output_item.added` 中的数据可能不完整。尤其是在
- important when `store` is `false` 或在使用 Zero Data Retention 时。
+ 在流式传输时,使用已完成的推理条目及其
+ `encrypted_content` 来自该 `response.output_item.done` 事件,在
+ 后续请求中使用 `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这一点尤其
+ 重要,当 `store` 为 `false` 或使用零数据保留(Zero Data Retention)时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值为 `in_progress`, `completed`,或
- `incomplete`。之一。当通过 API 返回条目时填充。
+ 该条目的状态。取值之一: `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回项时填充。
- `"in_progress"`
@@ -10804,19 +10806,19 @@
- `call_id: string`
- 程序条目的稳定调用 ID。
+ 程序项的稳定调用 ID。
- `code: string`
- 通过程序化工具调用执行的 JavaScript 源码。
+ 由程序化工具调用执行的 JavaScript 源代码。
- `fingerprint: string`
- 必须往返传输的不透明程序回放指纹。
+ 必须往返(round-trip)的不透明程序重放指纹。
- `type: "program"`
- 该 item 的类型。始终为 `program`.
+ 该项的类型。始终为 `program`.
- `"program"`
@@ -10828,15 +10830,15 @@
- `call_id: string`
- 程序条目的调用 ID。
+ 程序项的调用 ID。
- `result: string`
- 由程序条目生成的结果。
+ 程序项生成的结果。
- `status: "completed" or "incomplete"`
- 程序输出条目的终态。
+ 程序输出条目的最终状态。
- `"completed"`
@@ -10844,7 +10846,7 @@
- `type: "program_output"`
- 该 item 的类型。始终为 `program_output`.
+ 该项的类型。始终为 `program_output`.
- `"program_output"`
@@ -10882,13 +10884,13 @@
- `type: "tool_search_call"`
- 该 item 的类型。始终为 `tool_search_call`.
+ 该项的类型。始终为 `tool_search_call`.
- `"tool_search_call"`
- `created_by: optional string`
- 创建该条目的参与者的标识符。
+ 创建该条目的角色的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -10928,7 +10930,7 @@
- `name: string`
- 要调用的函数的名称。
+ 要调用的函数名称。
- `parameters: map[unknown] or null`
@@ -10936,7 +10938,7 @@
- `strict: boolean or null`
- 是否对该函数工具强制执行严格参数验证。
+ 是否对该函数工具强制执行严格的参数校验。
- `type: "function"`
@@ -10954,45 +10956,45 @@
- `defer_loading: optional boolean`
- 此函数是否被延迟加载并通过工具搜索加载。
+ 此函数是否被延迟,并通过工具搜索加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 对该函数的描述。供模型用于判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 用于描述此函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 用于描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 用于从已上传文件中搜索相关内容文件搜索 tool [文件搜索 tool](https://platform.openai.com/docs/guides/tools-file-search).
+ 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索 tool 的类型。始终为 `file_search`.
+ 文件搜索工具的类型,始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库 ID。
+ 要搜索的向量存储的 ID 列表。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的过滤器。
+ 要应用的筛选条件。
- `ComparisonFilter object { key, type, value }`
- 用于将指定属性键与给定值按照定义的比较运算进行比较的过滤器。
+ 用于将指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
- `CompoundFilter object { filters, type }`
- 使用以下方式合并多个过滤器 `and` 或 `or`.
+ 使用以下方式组合多个筛选条件 `and` 或 `or`.
- `max_num_results: optional number`
- 返回的最大结果数。该数字应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -11000,15 +11002,15 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于控制互逆排序融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
+ 在启用混合搜索时,控制倒数排名融合中语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
- 在互逆排序融合中嵌入的权重。
+ 倒数排名融合中嵌入的权重。
- `text_weight: number`
- 在互逆排序融合中文本的权重。
+ 倒数排名融合中文本的权重。
- `ranker: optional "auto" or "default-2024-11-15"`
@@ -11020,11 +11022,11 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数字会尝试仅返回最相关的结果,但可能返回的结果更少。
+ 文件搜索的分数阈值,取值范围为 0 到 1。越接近 1 的数值会尝试仅返回最相关的结果,但返回的结果可能更少。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
@@ -11034,15 +11036,15 @@
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
- 计算机显示屏的高度。
+ 计算机显示器的高度。
- `display_width: number`
- 计算机显示屏的宽度。
+ 计算机显示器的宽度。
- `environment: "windows" or "mac" or "linux" or 2 more`
@@ -11066,12 +11068,12 @@
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示相关的来源。详细了解
+ 在互联网上搜索与提示相关来源。了解更多关于
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索 工具的类型。可选值为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型。取以下值之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -11079,7 +11081,7 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 进行实时互联网访问。若省略,默认值为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索实时访问互联网。省略时默认为 true。当为 false 时,网页搜索工具以离线/仅缓存模式运行,并且不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
@@ -11088,13 +11090,13 @@
- `allowed_domains: optional array of string or null`
搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 同时允许所提供域名的子域名。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级使用指导。可选值为 `low`, `medium`,或 `high`. `medium` 是默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。取以下值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -11130,12 +11132,12 @@
- `Mcp object { server_label, type, allowed_callers, 9 more }`
- 允许模型通过远程模型上下文协议
- (MCP)服务器访问其他工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
+ 通过远程 Model Context Protocol
+ (MCP) 服务器为模型提供对其他工具的访问权限。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 此 MCP 服务器的标签,用于在工具调用中识别它。
- `type: "mcp"`
@@ -11153,21 +11155,21 @@
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许使用的工具名称列表或筛选对象。
+ 允许使用的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许使用的工具名称字符串数组
+ 允许使用的工具名称的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -11175,17 +11177,17 @@
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,可以与自定义 MCP 服务器
- URL 或服务连接器一起使用。你的应用程序必须处理 OAuth 授权流
- 并在此处提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,既可
+ 与自定义 MCP 服务器 URL 一起使用,也可与服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并在此处提供令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的连接器。必须提供以下之一。详细
- `server_url`, `connector_id`,或 `tunnel_id` 了解关于服务连接器
- about service connectors [here](/docs/guides/tools-remote-mcp#connectors).
+ 服务连接器的标识符,例如 ChatGPT 中提供的那些。必须提供
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一。详细了解
+ 服务连接器 [here](/docs/guides/tools-remote-mcp#connectors).
- Currently supported `connector_id` values are:
+ 目前支持的 `connector_id` 值包括:
- Dropbox: `connector_dropbox`
- Gmail: `connector_gmail`
@@ -11214,32 +11216,32 @@
- `defer_loading: optional boolean`
- Whether this MCP tool is deferred and discovered via tool search.
+ 此 MCP 工具是否为延迟加载,并通过工具搜索发现。
- `headers: optional map[string] or null`
- Optional HTTP headers to send to the MCP server. Use for authentication
- or other purposes.
+ 发送到 MCP 服务器的可选 HTTP 标头。用于身份验证
+ 或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- Specify which of the MCP server's tools require approval.
+ 指定 MCP 服务器的哪些工具需要批准。
- `McpToolApprovalFilter object { always, never }`
- Specify which of the MCP server's tools require approval. Can be
- `always`, `never`, or a filter object associated with tools
- that require approval.
+ 指定 MCP 服务器的哪些工具需要批准。可以是
+ `always`, `never`,或与需要批准的工具相关联的筛选器对象
+ 。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -11247,13 +11249,13 @@
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -11261,9 +11263,9 @@
- `McpToolApprovalSetting = "always" or "never"`
- Specify a single approval policy for all tools. One of `always` 或
- `never`. When set to `always`, all tools will require approval. When
- set to `never`, all tools will not require approval.
+ 为所有工具指定一个统一的批准策略。可选值包括 `always` 或
+ `never`。当设置为 `always`,时,所有工具都需要批准。当
+ 设置为 `never`,时,所有工具都不需要批准。
- `"always"`
@@ -11271,26 +11273,26 @@
- `server_description: optional string`
- Optional description of the MCP server, used to provide more context.
+ MCP 服务器的可选描述,用于提供更多上下文。
- `server_url: optional string`
- MCP 服务器的 URL。必须提供以下之一: `server_url`, `connector_id`,或
- `tunnel_id` 必须提供其中之一。
+ MCP 服务器的 URL。必须提供以下其中一项: `server_url`, `connector_id`,或
+ `tunnel_id` 。
- `tunnel_id: optional string`
- 用于代替直接服务器 URL 的安全 MCP 隧道 ID。必须提供以下之一:
- `server_url`, `connector_id`,或 `tunnel_id` 必须提供其中之一。
+ 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供以下其中一项:
+ `server_url`, `connector_id`,或 `tunnel_id` 。
- `CodeInterpreter object { container, type, allowed_callers }`
- 一个运行 Python 代码以帮助生成提示词回复的工具。
+ 一个用于运行 Python 代码以帮助生成对提示词回复的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID,也可以是一个用于指定可供你代码使用的已上传文件 ID 的对象,并提供
- 指定可供代码使用的已上传文件 ID,以及一个可选的
+ 代码解释器容器。可以是容器 ID,也可以是用于指定可供代码使用的已上传文件 ID 的对象,以及一个可选的
+ 设置。
可选的 `memory_limit` 设置。
- `string`
@@ -11299,17 +11301,17 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要对其运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定要在其上运行代码的文件 ID。
- `type: "auto"`
- Always `auto`.
+ 始终为 `auto`.
- `"auto"`
- `file_ids: optional array of string`
- 一个可选的已上传文件列表,供你的代码使用。
+ 可供代码使用的可选已上传文件列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -11349,13 +11351,13 @@
- `type: "programmatic_tool_calling"`
- 工具的类型。始终为 `programmatic_tool_calling`.
+ 该工具的类型。始终为 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ImageGeneration object { type, action, background, 9 more }`
- 使用 GPT 图像模型生成图像的工具。
+ 使用 GPT 图像模型生成图片的工具。
- `type: "image_generation"`
@@ -11365,7 +11367,7 @@
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图片还是编辑已有图片。默认值: `auto`.
- `"generate"`
@@ -11375,11 +11377,11 @@
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。透明背景适用于受支持的 GPT
- 图像模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持处于预览阶段。使用
- `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图片的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。支持
+ 的 GPT Image 模型可使用透明背景。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,此功能处于预览阶段。当使用
+ `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -11389,7 +11391,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所付出的努力程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持,不支持 `gpt-image-1-mini`。支持 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图片的风格和特征(尤其是面部特征)时所投入的精力。该参数仅 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持, `gpt-image-1-mini`。不支持。支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -11402,11 +11404,11 @@
- `file_id: optional string`
- 蒙版图像的文件 ID。
+ 蒙版图片的文件 ID。
- `image_url: optional string`
- Base64 编码的蒙版图像。
+ Base64 编码的掩码图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
@@ -11436,7 +11438,7 @@
- `moderation: optional "auto" or "low"`
- 生成图像的内容审核级别。默认值: `auto`.
+ 生成图像的审核级别。默认值: `auto`.
- `"auto"`
@@ -11459,7 +11461,7 @@
- `partial_images: optional number`
- 在流式模式下生成的部分图像数量,范围为 0(默认值)到 3。
+ 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -11476,13 +11478,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,以 `WIDTHxHEIGHT` 字符串形式表示,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 受到支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一: `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一: `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式传入任意分辨率,例如 `WIDTHxHEIGHT` 。 `1536x864`,宽和高都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动尺寸的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,以 `WIDTHxHEIGHT` 字符串形式表示,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 受到支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一: `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一: `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式传入任意分辨率,例如 `WIDTHxHEIGHT` 。 `1536x864`,宽和高都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动尺寸的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -11552,7 +11554,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -11572,7 +11574,7 @@
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 在工具调用中使用的命名空间名称(例如, `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
@@ -11596,19 +11598,19 @@
- `defer_loading: optional boolean`
- 是否应延迟此函数并通过工具搜索发现它。
+ 此函数是否应被延迟并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。此字段不描述 content 数组形式的输出。
+ 用于描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。这不描述内容数组(content-array)输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否启用严格的参数校验。如果省略,当 schema 兼容时 Responses 尝试使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在模式兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -11634,7 +11636,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -11646,23 +11648,23 @@
- `type: "namespace"`
- 工具的类型。始终为 `namespace`.
+ 该工具的类型。始终为 `namespace`.
- `"namespace"`
- `ToolSearch object { type, description, execution, parameters }`
- 用于延迟工具的托管或 BYOT 工具搜索配置。
+ 用于延迟工具的托管工具搜索或 BYOT 工具搜索配置。
- `type: "tool_search"`
- 工具的类型。始终为 `tool_search`.
+ 该工具的类型。始终为 `tool_search`.
- `"tool_search"`
- `description: optional string or null`
- 向模型展示的客户端执行工具搜索工具的描述。
+ 展示给模型的、用于客户端执行的工具搜索工具的描述。
- `execution: optional "server" or "client"`
@@ -11674,15 +11676,15 @@
- `parameters: optional unknown or null`
- 客户端执行工具搜索工具的参数 schema。
+ 客户端执行的工具搜索工具的参数 schema。
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具会在网页上搜索相关结果以用于回复中。详细了解 Responses API [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 此工具会搜索网页以获取在响应中使用的结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索 工具的类型。可选值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型。取以下值之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -11696,7 +11698,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级使用指导。可选值为 `low`, `medium`,或 `high`. `medium` 是默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。取以下值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -11732,11 +11734,11 @@
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用 unified diff 创建、删除或更新文件。
+ 允许助手使用统一差异来创建、删除或更新文件。
- `type: "apply_patch"`
- 工具的类型。始终为 `apply_patch`.
+ 该工具的类型。始终为 `apply_patch`.
- `"apply_patch"`
@@ -11750,23 +11752,23 @@
- `type: "tool_search_output"`
- 该 item 的类型。始终为 `tool_search_output`.
+ 该项的类型。始终为 `tool_search_output`.
- `"tool_search_output"`
- `created_by: optional string`
- 创建该条目的参与者的标识符。
+ 创建该条目的角色的标识符。
- `AdditionalTools object { id, role, tools, type }`
- `id: string`
- 附加工具条目的唯一 ID。
+ 其他工具条目的唯一 ID。
- `role: "unknown" or "user" or "assistant" or 5 more`
- 提供附加工具的角色。
+ 提供其他工具的角色。
- `"unknown"`
@@ -11786,7 +11788,7 @@
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目处可用的附加工具定义。
+ 在该条目下提供的其他工具定义。
- `Function object { name, parameters, strict, 5 more }`
@@ -11794,7 +11796,7 @@
- `name: string`
- 要调用的函数的名称。
+ 要调用的函数名称。
- `parameters: map[unknown] or null`
@@ -11802,7 +11804,7 @@
- `strict: boolean or null`
- 是否对该函数工具强制执行严格参数验证。
+ 是否对该函数工具强制执行严格的参数校验。
- `type: "function"`
@@ -11820,45 +11822,45 @@
- `defer_loading: optional boolean`
- 此函数是否被延迟加载并通过工具搜索加载。
+ 此函数是否被延迟,并通过工具搜索加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 对该函数的描述。供模型用于判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 用于描述此函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 用于描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 用于从已上传文件中搜索相关内容文件搜索 tool [文件搜索 tool](https://platform.openai.com/docs/guides/tools-file-search).
+ 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索 tool 的类型。始终为 `file_search`.
+ 文件搜索工具的类型,始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库 ID。
+ 要搜索的向量存储的 ID 列表。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的过滤器。
+ 要应用的筛选条件。
- `ComparisonFilter object { key, type, value }`
- 用于将指定属性键与给定值按照定义的比较运算进行比较的过滤器。
+ 用于将指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
- `CompoundFilter object { filters, type }`
- 使用以下方式合并多个过滤器 `and` 或 `or`.
+ 使用以下方式组合多个筛选条件 `and` 或 `or`.
- `max_num_results: optional number`
- 返回的最大结果数。该数字应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -11866,15 +11868,15 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于控制互逆排序融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
+ 在启用混合搜索时,控制倒数排名融合中语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
- 在互逆排序融合中嵌入的权重。
+ 倒数排名融合中嵌入的权重。
- `text_weight: number`
- 在互逆排序融合中文本的权重。
+ 倒数排名融合中文本的权重。
- `ranker: optional "auto" or "default-2024-11-15"`
@@ -11886,11 +11888,11 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数字会尝试仅返回最相关的结果,但可能返回的结果更少。
+ 文件搜索的分数阈值,取值范围为 0 到 1。越接近 1 的数值会尝试仅返回最相关的结果,但返回的结果可能更少。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
@@ -11900,15 +11902,15 @@
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
- 计算机显示屏的高度。
+ 计算机显示器的高度。
- `display_width: number`
- 计算机显示屏的宽度。
+ 计算机显示器的宽度。
- `environment: "windows" or "mac" or "linux" or 2 more`
@@ -11932,12 +11934,12 @@
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示相关的来源。详细了解
+ 在互联网上搜索与提示相关来源。了解更多关于
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索 工具的类型。可选值为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型。取以下值之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -11945,7 +11947,7 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 进行实时互联网访问。若省略,默认值为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索实时访问互联网。省略时默认为 true。当为 false 时,网页搜索工具以离线/仅缓存模式运行,并且不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
@@ -11954,13 +11956,13 @@
- `allowed_domains: optional array of string or null`
搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 同时允许所提供域名的子域名。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级使用指导。可选值为 `low`, `medium`,或 `high`. `medium` 是默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。取以下值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -11996,12 +11998,12 @@
- `Mcp object { server_label, type, allowed_callers, 9 more }`
- 允许模型通过远程模型上下文协议
- (MCP)服务器访问其他工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
+ 通过远程 Model Context Protocol
+ (MCP) 服务器为模型提供对其他工具的访问权限。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 此 MCP 服务器的标签,用于在工具调用中识别它。
- `type: "mcp"`
@@ -12019,21 +12021,21 @@
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许使用的工具名称列表或筛选对象。
+ 允许使用的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许使用的工具名称字符串数组
+ 允许使用的工具名称的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -12041,17 +12043,17 @@
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,可以与自定义 MCP 服务器
- URL 或服务连接器一起使用。你的应用程序必须处理 OAuth 授权流
- 并在此处提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,既可
+ 与自定义 MCP 服务器 URL 一起使用,也可与服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并在此处提供令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的连接器。必须提供以下之一。详细
- `server_url`, `connector_id`,或 `tunnel_id` 了解关于服务连接器
- about service connectors [here](/docs/guides/tools-remote-mcp#connectors).
+ 服务连接器的标识符,例如 ChatGPT 中提供的那些。必须提供
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一。详细了解
+ 服务连接器 [here](/docs/guides/tools-remote-mcp#connectors).
- Currently supported `connector_id` values are:
+ 目前支持的 `connector_id` 值包括:
- Dropbox: `connector_dropbox`
- Gmail: `connector_gmail`
@@ -12080,32 +12082,32 @@
- `defer_loading: optional boolean`
- Whether this MCP tool is deferred and discovered via tool search.
+ 此 MCP 工具是否为延迟加载,并通过工具搜索发现。
- `headers: optional map[string] or null`
- Optional HTTP headers to send to the MCP server. Use for authentication
- or other purposes.
+ 发送到 MCP 服务器的可选 HTTP 标头。用于身份验证
+ 或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- Specify which of the MCP server's tools require approval.
+ 指定 MCP 服务器的哪些工具需要批准。
- `McpToolApprovalFilter object { always, never }`
- Specify which of the MCP server's tools require approval. Can be
- `always`, `never`, or a filter object associated with tools
- that require approval.
+ 指定 MCP 服务器的哪些工具需要批准。可以是
+ `always`, `never`,或与需要批准的工具相关联的筛选器对象
+ 。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -12113,13 +12115,13 @@
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -12127,9 +12129,9 @@
- `McpToolApprovalSetting = "always" or "never"`
- Specify a single approval policy for all tools. One of `always` 或
- `never`. When set to `always`, all tools will require approval. When
- set to `never`, all tools will not require approval.
+ 为所有工具指定一个统一的批准策略。可选值包括 `always` 或
+ `never`。当设置为 `always`,时,所有工具都需要批准。当
+ 设置为 `never`,时,所有工具都不需要批准。
- `"always"`
@@ -12137,26 +12139,26 @@
- `server_description: optional string`
- Optional description of the MCP server, used to provide more context.
+ MCP 服务器的可选描述,用于提供更多上下文。
- `server_url: optional string`
- MCP 服务器的 URL。必须提供以下之一: `server_url`, `connector_id`,或
- `tunnel_id` 必须提供其中之一。
+ MCP 服务器的 URL。必须提供以下其中一项: `server_url`, `connector_id`,或
+ `tunnel_id` 。
- `tunnel_id: optional string`
- 用于代替直接服务器 URL 的安全 MCP 隧道 ID。必须提供以下之一:
- `server_url`, `connector_id`,或 `tunnel_id` 必须提供其中之一。
+ 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供以下其中一项:
+ `server_url`, `connector_id`,或 `tunnel_id` 。
- `CodeInterpreter object { container, type, allowed_callers }`
- 一个运行 Python 代码以帮助生成提示词回复的工具。
+ 一个用于运行 Python 代码以帮助生成对提示词回复的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID,也可以是一个用于指定可供你代码使用的已上传文件 ID 的对象,并提供
- 指定可供代码使用的已上传文件 ID,以及一个可选的
+ 代码解释器容器。可以是容器 ID,也可以是用于指定可供代码使用的已上传文件 ID 的对象,以及一个可选的
+ 设置。
可选的 `memory_limit` 设置。
- `string`
@@ -12165,17 +12167,17 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要对其运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定要在其上运行代码的文件 ID。
- `type: "auto"`
- Always `auto`.
+ 始终为 `auto`.
- `"auto"`
- `file_ids: optional array of string`
- 一个可选的已上传文件列表,供你的代码使用。
+ 可供代码使用的可选已上传文件列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -12215,13 +12217,13 @@
- `type: "programmatic_tool_calling"`
- 工具的类型。始终为 `programmatic_tool_calling`.
+ 该工具的类型。始终为 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ImageGeneration object { type, action, background, 9 more }`
- 使用 GPT 图像模型生成图像的工具。
+ 使用 GPT 图像模型生成图片的工具。
- `type: "image_generation"`
@@ -12231,7 +12233,7 @@
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图片还是编辑已有图片。默认值: `auto`.
- `"generate"`
@@ -12241,11 +12243,11 @@
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。透明背景适用于受支持的 GPT
- 图像模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持处于预览阶段。使用
- `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图片的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。支持
+ 的 GPT Image 模型可使用透明背景。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,此功能处于预览阶段。当使用
+ `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -12255,7 +12257,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所付出的努力程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持,不支持 `gpt-image-1-mini`。支持 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图片的风格和特征(尤其是面部特征)时所投入的精力。该参数仅 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持, `gpt-image-1-mini`。不支持。支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -12268,11 +12270,11 @@
- `file_id: optional string`
- 蒙版图像的文件 ID。
+ 蒙版图片的文件 ID。
- `image_url: optional string`
- Base64 编码的蒙版图像。
+ Base64 编码的掩码图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
@@ -12302,7 +12304,7 @@
- `moderation: optional "auto" or "low"`
- 生成图像的内容审核级别。默认值: `auto`.
+ 生成图像的审核级别。默认值: `auto`.
- `"auto"`
@@ -12325,7 +12327,7 @@
- `partial_images: optional number`
- 在流式模式下生成的部分图像数量,范围为 0(默认值)到 3。
+ 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -12342,13 +12344,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,以 `WIDTHxHEIGHT` 字符串形式表示,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 受到支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一: `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一: `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式传入任意分辨率,例如 `WIDTHxHEIGHT` 。 `1536x864`,宽和高都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动尺寸的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,以 `WIDTHxHEIGHT` 字符串形式表示,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 受到支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一: `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一: `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式传入任意分辨率,例如 `WIDTHxHEIGHT` 。 `1536x864`,宽和高都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动尺寸的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -12418,7 +12420,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -12438,7 +12440,7 @@
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 在工具调用中使用的命名空间名称(例如, `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
@@ -12462,19 +12464,19 @@
- `defer_loading: optional boolean`
- 是否应延迟此函数并通过工具搜索发现它。
+ 此函数是否应被延迟并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。此字段不描述 content 数组形式的输出。
+ 用于描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。这不描述内容数组(content-array)输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否启用严格的参数校验。如果省略,当 schema 兼容时 Responses 尝试使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在模式兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -12500,7 +12502,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -12512,23 +12514,23 @@
- `type: "namespace"`
- 工具的类型。始终为 `namespace`.
+ 该工具的类型。始终为 `namespace`.
- `"namespace"`
- `ToolSearch object { type, description, execution, parameters }`
- 用于延迟工具的托管或 BYOT 工具搜索配置。
+ 用于延迟工具的托管工具搜索或 BYOT 工具搜索配置。
- `type: "tool_search"`
- 工具的类型。始终为 `tool_search`.
+ 该工具的类型。始终为 `tool_search`.
- `"tool_search"`
- `description: optional string or null`
- 向模型展示的客户端执行工具搜索工具的描述。
+ 展示给模型的、用于客户端执行的工具搜索工具的描述。
- `execution: optional "server" or "client"`
@@ -12540,15 +12542,15 @@
- `parameters: optional unknown or null`
- 客户端执行工具搜索工具的参数 schema。
+ 客户端执行的工具搜索工具的参数 schema。
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具会在网页上搜索相关结果以用于回复中。详细了解 Responses API [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 此工具会搜索网页以获取在响应中使用的结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索 工具的类型。可选值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型。取以下值之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -12562,7 +12564,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级使用指导。可选值为 `low`, `medium`,或 `high`. `medium` 是默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。取以下值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -12598,11 +12600,11 @@
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用 unified diff 创建、删除或更新文件。
+ 允许助手使用统一差异来创建、删除或更新文件。
- `type: "apply_patch"`
- 工具的类型。始终为 `apply_patch`.
+ 该工具的类型。始终为 `apply_patch`.
- `"apply_patch"`
@@ -12616,13 +12618,13 @@
- `type: "additional_tools"`
- 该 item 的类型。始终为 `additional_tools`.
+ 该项的类型。始终为 `additional_tools`.
- `"additional_tools"`
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩项 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -12630,17 +12632,17 @@
- `encrypted_content: string`
- 由压缩生成的加密内容。
+ 压缩后生成的内容经过加密。
- `type: "compaction"`
- 该 item 的类型。始终为 `compaction`.
+ 该项的类型。始终为 `compaction`.
- `"compaction"`
- `created_by: optional string`
- 创建该条目的参与者的标识符。
+ 创建该条目的角色的标识符。
- `ImageGenerationCall object { id, result, status, type }`
@@ -12682,7 +12684,7 @@
- `code: string or null`
- 要运行的代码,若不可用则为 null。
+ 要运行的代码,如果不可用则为 null。
- `container_id: string`
@@ -12690,16 +12692,16 @@
- `outputs: array of object { logs, type } or object { type, url } or null`
- 代码解释器生成的输出,例如日志或图像。
- 若没有可用输出,可能为 null。
+ 由代码解释器生成的输出,例如日志或图像。
+ 如果没有可用的输出,可能为 null。
- `Logs object { logs, type }`
- 代码解释器输出的日志。
+ 由代码解释器输出的日志。
- `logs: string`
- 代码解释器输出的日志。
+ 由代码解释器输出的日志。
- `type: "logs"`
@@ -12709,7 +12711,7 @@
- `Image object { type, url }`
- 代码解释器输出的图像。
+ 由代码解释器输出的图像。
- `type: "image"`
@@ -12719,7 +12721,7 @@
- `url: string`
- 代码解释器输出图像的 URL。
+ 由代码解释器输出的图像 URL。
- `status: "in_progress" or "completed" or "incomplete" or 2 more`
@@ -12759,7 +12761,7 @@
- `env: map[string]`
- 为命令设置的环境变量。
+ 为该命令设置的环境变量。
- `type: "exec"`
@@ -12769,15 +12771,15 @@
- `timeout_ms: optional number or null`
- 命令的可选超时时间(毫秒)。
+ 该命令的可选超时时间(毫秒)。
- `user: optional string or null`
- 运行命令时使用的可选用户。
+ 运行该命令时使用的可选用户。
- `working_directory: optional string or null`
- 运行命令时所在的可选工作目录。
+ 运行该命令时使用的可选工作目录。
- `call_id: string`
@@ -12819,7 +12821,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。取值为 `in_progress`, `completed`,或 `incomplete`.
+ 该条目的状态。取值之一: `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -12829,29 +12831,29 @@
- `ShellCall object { id, action, call_id, 5 more }`
- 在托管环境中执行一条或多条 shell 命令的工具调用。
+ 在托管环境中执行一个或多个 shell 命令的工具调用。
- `id: string`
- shell 工具调用的唯一 ID。在通过 API 返回此条目时填充。
+ shell 工具调用的唯一 ID。通过 API 返回该条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 描述如何运行该工具调用的 shell 命令及限制。
+ 描述如何运行该工具调用的 shell 命令和限制。
- `commands: array of string`
- `max_output_length: number or null`
- 可选的每个命令返回的最大字符数。
+ 每个命令最多返回的字符数,可选。
- `timeout_ms: number or null`
- 命令的可选超时时间(毫秒)。
+ 命令的可选超时时间,以毫秒为单位。
- `call_id: string`
- 由模型生成的 shell 工具调用的唯一 ID。
+ 模型生成的 shell 工具调用的唯一 ID。
- `environment: ResponseLocalEnvironment or ResponseContainerReference or null`
@@ -12869,7 +12871,7 @@
- `ResponseContainerReference object { container_id, type }`
- 表示通过 /v1/containers 创建的容器。
+ 表示使用 /v1/containers 创建的容器。
- `container_id: string`
@@ -12881,7 +12883,7 @@
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态。可选值为 `in_progress`, `completed`,或 `incomplete`.
+ shell 调用的状态。取值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -12891,7 +12893,7 @@
- `type: "shell_call"`
- 该 item 的类型。始终为 `shell_call`.
+ 该项的类型。始终为 `shell_call`.
- `"shell_call"`
@@ -12917,35 +12919,35 @@
- `created_by: optional string`
- 创建此工具调用的实体 ID。
+ 创建此工具调用的实体的 ID。
- `ShellCallOutput object { id, call_id, max_output_length, 5 more }`
- 已发出的 shell 工具调用的输出。
+ 已发出的 shell 工具调用输出。
- `id: string`
- shell 调用输出的唯一 ID。当通过 API 返回此项时填充。
+ shell 调用输出的唯一 ID。通过 API 返回此项目时填充。
- `call_id: string`
- 由模型生成的 shell 工具调用的唯一 ID。
+ 模型生成的 shell 工具调用的唯一 ID。
- `max_output_length: number or null`
- shell 命令输出的最大长度。这由模型生成,应与原始输出一起传回。
+ shell 命令输出的最大长度。此值由模型生成,应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
- shell 调用输出内容数组
+ shell 调用输出内容的数组
- `outcome: object { type } or object { exit_code, type }`
- 表示 shell 调用输出块的退出结果(带有退出码)或超时结果。
+ 表示 shell 调用输出块的退出结果(包含退出代码)或超时结果。
- `Timeout object { type }`
- 表示该 shell 调用超出了其配置的时间限制。
+ 表示 shell 调用超过了其配置的时间限制。
- `type: "timeout"`
@@ -12955,11 +12957,11 @@
- `Exit object { exit_code, type }`
- 表示 shell 命令已结束并返回了退出码。
+ 表示 shell 命令已执行完毕并返回了退出码。
- `exit_code: number`
- shell 进程的退出码。
+ shell 进程的退出代码。
- `type: "exit"`
@@ -12977,11 +12979,11 @@
- `created_by: optional string`
- 创建该条目的参与者的标识符。
+ 创建该条目的角色的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用输出的状态。取值之一 `in_progress`, `completed`,或 `incomplete`.
+ shell 调用输出的状态。以下之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -13017,7 +13019,7 @@
- `created_by: optional string`
- 创建该条目的参与者的标识符。
+ 创建该条目的角色的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -13029,15 +13031,15 @@
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
- 通过 apply_patch 工具创建文件的指令说明。
+ 描述如何通过 apply_patch 工具创建文件的指令。
- `diff: string`
@@ -13049,13 +13051,13 @@
- `type: "create_file"`
- 使用提供的差异创建一个新文件。
+ 使用提供的差异创建新文件。
- `"create_file"`
- `DeleteFile object { path, type }`
- 通过 apply_patch 工具删除文件的指令说明。
+ 描述如何通过 apply_patch 工具删除文件的指令。
- `path: string`
@@ -13069,7 +13071,7 @@
- `UpdateFile object { diff, path, type }`
- 通过 apply_patch 工具更新文件的指令说明。
+ 描述如何通过 apply_patch 工具更新文件的指令。
- `diff: string`
@@ -13095,7 +13097,7 @@
- `type: "apply_patch_call"`
- 该 item 的类型。始终为 `apply_patch_call`.
+ 该项的类型。始终为 `apply_patch_call`.
- `"apply_patch_call"`
@@ -13121,7 +13123,7 @@
- `created_by: optional string`
- 创建此工具调用的实体 ID。
+ 创建此工具调用的实体的 ID。
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
@@ -13133,7 +13135,7 @@
- `call_id: string`
- 由模型生成的 apply patch 工具调用的唯一 ID。
+ 模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
@@ -13145,7 +13147,7 @@
- `type: "apply_patch_call_output"`
- 该 item 的类型。始终为 `apply_patch_call_output`.
+ 该项的类型。始终为 `apply_patch_call_output`.
- `"apply_patch_call_output"`
@@ -13171,7 +13173,7 @@
- `created_by: optional string`
- 创建此工具调输出的实体的 ID。
+ 创建此工具调用输出的实体的 ID。
- `output: optional string or null`
@@ -13179,7 +13181,7 @@
- `McpCall object { id, arguments, name, 6 more }`
- 在 MCP 服务器上对工具的一次调用。
+ 对 MCP 服务器上工具的调用。
- `id: string`
@@ -13199,7 +13201,7 @@
- `type: "mcp_call"`
- 该 item 的类型。始终为 `mcp_call`.
+ 该项的类型。始终为 `mcp_call`.
- `"mcp_call"`
@@ -13218,7 +13220,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。取值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
+ 工具调用的状态。取值之一 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -13232,11 +13234,11 @@
- `McpListTools object { id, server_label, tools, 2 more }`
- MCP 服务器上可用的工具列表。
+ MCP 服务器上可用工具的列表。
- `id: string`
- 该列表的唯一 ID。
+ 此列表的唯一 ID。
- `server_label: string`
@@ -13256,25 +13258,25 @@
- `annotations: optional unknown or null`
- 有关该工具的其他注释。
+ 关于该工具的附加注释。
- `description: optional string or null`
- 工具的描述。
+ 该工具的描述。
- `type: "mcp_list_tools"`
- 该 item 的类型。始终为 `mcp_list_tools`.
+ 该项的类型。始终为 `mcp_list_tools`.
- `"mcp_list_tools"`
- `error: optional string or null`
- 如果服务器无法列出工具,则返回错误消息。
+ 如果服务端无法列出工具,则返回错误消息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 请求人工审批某个工具调用。
+ 对工具调用的人工审批请求。
- `id: string`
@@ -13282,7 +13284,7 @@
- `arguments: string`
- 工具参数的 JSON 字符串。
+ 该工具参数的 JSON 字符串。
- `name: string`
@@ -13294,7 +13296,7 @@
- `type: "mcp_approval_request"`
- 该 item 的类型。始终为 `mcp_approval_request`.
+ 该项的类型。始终为 `mcp_approval_request`.
- `"mcp_approval_request"`
@@ -13308,15 +13310,15 @@
- `approval_request_id: string`
- 正在应答的审批请求的 ID。
+ 正在回复的审批请求的 ID。
- `approve: boolean`
- 请求是否已被批准。
+ 请求是否已获批准。
- `type: "mcp_approval_response"`
- 该 item 的类型。始终为 `mcp_approval_response`.
+ 该项的类型。始终为 `mcp_approval_response`.
- `"mcp_approval_response"`
@@ -13334,7 +13336,7 @@
- `input: string`
- 模型生成的自定义工具调用的输入。
+ 由模型生成的自定义工具调用的输入。
- `name: string`
@@ -13395,7 +13397,7 @@
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 自定义工具调用的文本、图片或文件输出。
+ 自定义工具调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
@@ -13403,7 +13405,7 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
+ 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -13411,8 +13413,8 @@
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。取值为 `in_progress`, `completed`,或
- `incomplete`。之一。当通过 API 返回条目时填充。
+ 该条目的状态。取值之一: `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回项时填充。
- `"in_progress"`
@@ -13452,7 +13454,7 @@
- `created_by: optional string`
- 创建该条目的参与者的标识符。
+ 创建该条目的角色的标识符。
- `parallel_tool_calls: boolean`
@@ -13460,23 +13462,23 @@
- `temperature: number or null`
- 使用的采样温度,介于 0 和 2 之间。较高的值(例如 0.8)会使输出更加随机,而较低的值(例如 0.2)会使输出更加聚焦和确定性更强。
- 我们通常建议修改此参数或 `top_p` 但不能同时使用两者。
+ 使用的采样温度,介于 0 到 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使输出更加聚焦和确定性。
+ 我们通常建议修改此项或 `top_p` 但不能两者同时使用。
- `tool_choice: ToolChoiceOptions or ToolChoiceAllowed or ToolChoiceTypes or 6 more`
- 指定模型在生成响应时应如何选择使用哪个(或哪些)工具。
- 有关如何指定可调用工具的信息,请参阅 `tools` 参数。
- 模型可以调用的工具。
+ 在生成响应时,模型应如何选择要使用的工具(一个或多个)
+ 。请参阅 `tools` 参数了解如何指定模型可调用的工具
+ 。
- `ToolChoiceOptions = "none" or "auto" or "required"`
- 控制由模型调用哪个工具(如果有)。
+ 控制模型调用哪些工具(如果有)。
`none` 表示模型不会调用任何工具,而是生成一条消息。
- `auto` 表示模型可以在生成消息与调用一个或
- 多个工具之间进行选择。
+ `auto` 表示模型可以在生成消息或调用一个或
+ 多个工具之间选择。
`required` 表示模型必须调用一个或多个工具。
@@ -13488,16 +13490,16 @@
- `ToolChoiceAllowed object { mode, tools, type }`
- 将模型可使用的工具限制为一组预定义工具。
+ 将模型可用的工具限制为预定义的集合。
- `mode: "auto" or "required"`
- 将模型可使用的工具限制为一组预定义工具。
+ 将模型可用的工具限制为预定义的集合。
- `auto` 允许模型从允许的工具中进行选择并生成一条
+ `auto` 允许模型从允许的工具中挑选并生成一条
消息。
- `required` 要求模型调用允许的工具中的一个或多个。
+ `required` 要求模型调用一个或多个允许的工具。
- `"auto"`
@@ -13505,7 +13507,7 @@
- `tools: array of map[unknown]`
- 模型可以调用的工具定义列表。
+ 模型应被允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -13525,8 +13527,8 @@
- `ToolChoiceTypes object { type }`
- 指示模型应使用内置工具来生成响应。
- [详细了解内置工具](/docs/guides/tools).
+ 指示模型应使用内置工具生成响应。
+ [了解更多关于内置工具的信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
@@ -13561,11 +13563,11 @@
- `ToolChoiceFunction object { name, type }`
- 使用此选项可强制模型调用特定的函数。
+ 使用此选项以强制模型调用特定函数。
- `name: string`
- 要调用的函数的名称。
+ 要调用的函数名称。
- `type: "function"`
@@ -13575,7 +13577,7 @@
- `ToolChoiceMcp object { server_label, type, name }`
- 使用此选项可以强制模型调用远程 MCP 服务器上的特定工具。
+ 使用此选项以强制模型调用远程 MCP 服务器上的特定工具。
- `server_label: string`
@@ -13593,7 +13595,7 @@
- `ToolChoiceCustom object { name, type }`
- 使用此选项可以强制模型调用特定的自定义工具。
+ 使用此选项以强制模型调用特定的自定义工具。
- `name: string`
@@ -13609,27 +13611,27 @@
- `type: "programmatic_tool_calling"`
- 要调用的工具。始终为 `programmatic_tool_calling`.
+ 要调用的工具。始终 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ToolChoiceApplyPatch object { type }`
- 强制模型在执行工具调用时调用 apply_patch 工具。
+ 在执行工具调用时强制模型调用 apply_patch 工具。
- `type: "apply_patch"`
- 要调用的工具。始终为 `apply_patch`.
+ 要调用的工具。始终 `apply_patch`.
- `"apply_patch"`
- `ToolChoiceShell object { type }`
- 在需要工具调用时,强制模型调用 shell 工具。
+ 在需要工具调用时强制模型调用 shell 工具。
- `type: "shell"`
- 要调用的工具。始终为 `shell`.
+ 要调用的工具。始终 `shell`.
- `"shell"`
@@ -13640,17 +13642,17 @@
我们支持以下类别的工具:
- - **内置工具**: 由 OpenAI 提供的可扩展模型能力的工具,例如
- 模型的能力,例如 [网页搜索](/docs/guides/tools-web-search)
+ - **内置工具**: 由 OpenAI 提供的工具,用于扩展模型的
+ 能力,例如 [网页搜索](/docs/guides/tools-web-search)
或 [文件搜索](/docs/guides/tools-file-search)。了解更多关于
[内置工具](/docs/guides/tools).
- - **MCP Tools**: 通过自定义 MCP 服务器或预定义连接器(如 Google Drive 和 SharePoint)与第三方系统集成。了解更多关于
- 或 Google Drive 和 SharePoint 等预定义连接器与第三方系统集成。了解更多关于
- [MCP Tools](/docs/guides/tools-connectors-mcp).
+ - **MCP 工具**: 通过自定义 MCP 服务器与第三方系统集成,
+ 或使用 Google Drive 和 SharePoint 等预定义连接器。了解更多关于
+ [MCP 工具](/docs/guides/tools-connectors-mcp).
- **函数调用(自定义工具)**: 由你定义的函数,
- 使模型能够使用强类型参数和输出调用你自己的代码
+ 使模型能够使用强类型参数调用你自己的代码
和输出。了解更多关于
- [函数调用](/docs/guides/function-calling)。你也可以使用
+ [函数调用](/docs/guides/function-calling)。你还可以使用
自定义工具来调用你自己的代码。
- `Function object { name, parameters, strict, 5 more }`
@@ -13659,7 +13661,7 @@
- `name: string`
- 要调用的函数的名称。
+ 要调用的函数名称。
- `parameters: map[unknown] or null`
@@ -13667,7 +13669,7 @@
- `strict: boolean or null`
- 是否对该函数工具强制执行严格参数验证。
+ 是否对该函数工具强制执行严格的参数校验。
- `type: "function"`
@@ -13685,45 +13687,45 @@
- `defer_loading: optional boolean`
- 此函数是否被延迟加载并通过工具搜索加载。
+ 此函数是否被延迟,并通过工具搜索加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 对该函数的描述。供模型用于判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 用于描述此函数字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 用于描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 用于从已上传文件中搜索相关内容文件搜索 tool [文件搜索 tool](https://platform.openai.com/docs/guides/tools-file-search).
+ 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索 tool 的类型。始终为 `file_search`.
+ 文件搜索工具的类型,始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库 ID。
+ 要搜索的向量存储的 ID 列表。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的过滤器。
+ 要应用的筛选条件。
- `ComparisonFilter object { key, type, value }`
- 用于将指定属性键与给定值按照定义的比较运算进行比较的过滤器。
+ 用于将指定的属性键与给定值按定义的比较运算进行比较的筛选条件。
- `CompoundFilter object { filters, type }`
- 使用以下方式合并多个过滤器 `and` 或 `or`.
+ 使用以下方式组合多个筛选条件 `and` 或 `or`.
- `max_num_results: optional number`
- 返回的最大结果数。该数字应介于 1 到 50 之间(含两端)。
+ 返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -13731,15 +13733,15 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 在启用混合搜索时,用于控制互逆排序融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
+ 在启用混合搜索时,控制倒数排名融合中语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
- 在互逆排序融合中嵌入的权重。
+ 倒数排名融合中嵌入的权重。
- `text_weight: number`
- 在互逆排序融合中文本的权重。
+ 倒数排名融合中文本的权重。
- `ranker: optional "auto" or "default-2024-11-15"`
@@ -13751,11 +13753,11 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1 的数字会尝试仅返回最相关的结果,但可能返回的结果更少。
+ 文件搜索的分数阈值,取值范围为 0 到 1。越接近 1 的数值会尝试仅返回最相关的结果,但返回的结果可能更少。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
@@ -13765,15 +13767,15 @@
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [计算机工具](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。了解更多关于 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
- 计算机显示屏的高度。
+ 计算机显示器的高度。
- `display_width: number`
- 计算机显示屏的宽度。
+ 计算机显示器的宽度。
- `environment: "windows" or "mac" or "linux" or 2 more`
@@ -13797,12 +13799,12 @@
- `WebSearch object { type, external_web_access, filters, 2 more }`
- 在互联网上搜索与提示相关的来源。详细了解
+ 在互联网上搜索与提示相关来源。了解更多关于
[网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索 工具的类型。可选值为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型。取以下值之一 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -13810,7 +13812,7 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 进行实时互联网访问。若省略,默认值为 true。当为 false 时,网页搜索 工具以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索实时访问互联网。省略时默认为 true。当为 false 时,网页搜索工具以离线/仅缓存模式运行,并且不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
@@ -13819,13 +13821,13 @@
- `allowed_domains: optional array of string or null`
搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名也同样被允许。
+ 同时允许所提供域名的子域名。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级使用指导。可选值为 `low`, `medium`,或 `high`. `medium` 是默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。取以下值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -13861,12 +13863,12 @@
- `Mcp object { server_label, type, allowed_callers, 9 more }`
- 允许模型通过远程模型上下文协议
- (MCP)服务器访问其他工具。 [详细了解 MCP](/docs/guides/tools-remote-mcp).
+ 通过远程 Model Context Protocol
+ (MCP) 服务器为模型提供对其他工具的访问权限。 [了解更多关于 MCP 的信息](/docs/guides/tools-remote-mcp).
- `server_label: string`
- 此 MCP 服务器的标签,用于在工具调用中标识它。
+ 此 MCP 服务器的标签,用于在工具调用中识别它。
- `type: "mcp"`
@@ -13884,21 +13886,21 @@
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许使用的工具名称列表或筛选对象。
+ 允许使用的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许使用的工具名称字符串数组
+ 允许使用的工具名称的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -13906,17 +13908,17 @@
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,可以与自定义 MCP 服务器
- URL 或服务连接器一起使用。你的应用程序必须处理 OAuth 授权流
- 并在此处提供该令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,既可
+ 与自定义 MCP 服务器 URL 一起使用,也可与服务连接器一起使用。你的应用
+ 必须处理 OAuth 授权流程,并在此处提供令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的连接器。必须提供以下之一。详细
- `server_url`, `connector_id`,或 `tunnel_id` 了解关于服务连接器
- about service connectors [here](/docs/guides/tools-remote-mcp#connectors).
+ 服务连接器的标识符,例如 ChatGPT 中提供的那些。必须提供
+ `server_url`, `connector_id`,或 `tunnel_id` 其中之一。详细了解
+ 服务连接器 [here](/docs/guides/tools-remote-mcp#connectors).
- Currently supported `connector_id` values are:
+ 目前支持的 `connector_id` 值包括:
- Dropbox: `connector_dropbox`
- Gmail: `connector_gmail`
@@ -13945,32 +13947,32 @@
- `defer_loading: optional boolean`
- Whether this MCP tool is deferred and discovered via tool search.
+ 此 MCP 工具是否为延迟加载,并通过工具搜索发现。
- `headers: optional map[string] or null`
- Optional HTTP headers to send to the MCP server. Use for authentication
- or other purposes.
+ 发送到 MCP 服务器的可选 HTTP 标头。用于身份验证
+ 或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- Specify which of the MCP server's tools require approval.
+ 指定 MCP 服务器的哪些工具需要批准。
- `McpToolApprovalFilter object { always, never }`
- Specify which of the MCP server's tools require approval. Can be
- `always`, `never`, or a filter object associated with tools
- that require approval.
+ 指定 MCP 服务器的哪些工具需要批准。可以是
+ `always`, `never`,或与需要批准的工具相关联的筛选器对象
+ 。
- `always: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -13978,13 +13980,13 @@
- `never: optional object { read_only, tool_names }`
- 用于指定允许哪些工具的筛选对象。
+ 用于指定允许使用哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是修改数据还是只读。如果一个
+ 指示该工具是否会修改数据,还是仅用于读取。如果某个
MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- 标记,它将匹配此筛选器。
+ ,则会匹配此过滤器。
- `tool_names: optional array of string`
@@ -13992,9 +13994,9 @@
- `McpToolApprovalSetting = "always" or "never"`
- Specify a single approval policy for all tools. One of `always` 或
- `never`. When set to `always`, all tools will require approval. When
- set to `never`, all tools will not require approval.
+ 为所有工具指定一个统一的批准策略。可选值包括 `always` 或
+ `never`。当设置为 `always`,时,所有工具都需要批准。当
+ 设置为 `never`,时,所有工具都不需要批准。
- `"always"`
@@ -14002,26 +14004,26 @@
- `server_description: optional string`
- Optional description of the MCP server, used to provide more context.
+ MCP 服务器的可选描述,用于提供更多上下文。
- `server_url: optional string`
- MCP 服务器的 URL。必须提供以下之一: `server_url`, `connector_id`,或
- `tunnel_id` 必须提供其中之一。
+ MCP 服务器的 URL。必须提供以下其中一项: `server_url`, `connector_id`,或
+ `tunnel_id` 。
- `tunnel_id: optional string`
- 用于代替直接服务器 URL 的安全 MCP 隧道 ID。必须提供以下之一:
- `server_url`, `connector_id`,或 `tunnel_id` 必须提供其中之一。
+ 用于替代直接服务器 URL 的安全 MCP 隧道 ID。必须提供以下其中一项:
+ `server_url`, `connector_id`,或 `tunnel_id` 。
- `CodeInterpreter object { container, type, allowed_callers }`
- 一个运行 Python 代码以帮助生成提示词回复的工具。
+ 一个用于运行 Python 代码以帮助生成对提示词回复的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID,也可以是一个用于指定可供你代码使用的已上传文件 ID 的对象,并提供
- 指定可供代码使用的已上传文件 ID,以及一个可选的
+ 代码解释器容器。可以是容器 ID,也可以是用于指定可供代码使用的已上传文件 ID 的对象,以及一个可选的
+ 设置。
可选的 `memory_limit` 设置。
- `string`
@@ -14030,17 +14032,17 @@
- `CodeInterpreterToolAuto object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器的配置。可选择指定要对其运行代码的文件 ID。
+ 代码解释器容器的配置。可选择指定要在其上运行代码的文件 ID。
- `type: "auto"`
- Always `auto`.
+ 始终为 `auto`.
- `"auto"`
- `file_ids: optional array of string`
- 一个可选的已上传文件列表,供你的代码使用。
+ 可供代码使用的可选已上传文件列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -14080,13 +14082,13 @@
- `type: "programmatic_tool_calling"`
- 工具的类型。始终为 `programmatic_tool_calling`.
+ 该工具的类型。始终为 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
- `ImageGeneration object { type, action, background, 9 more }`
- 使用 GPT 图像模型生成图像的工具。
+ 使用 GPT 图像模型生成图片的工具。
- `type: "image_generation"`
@@ -14096,7 +14098,7 @@
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 是生成新图片还是编辑已有图片。默认值: `auto`.
- `"generate"`
@@ -14106,11 +14108,11 @@
- `background: optional "transparent" or "opaque" or "auto"`
- 设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。透明背景适用于受支持的 GPT
- 图像模型。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该支持处于预览阶段。使用
- `transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
+ 设置生成图片的背景。可选值为 `transparent`,
+ `opaque`,或 `auto`。之一。支持
+ 的 GPT Image 模型可使用透明背景。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,此功能处于预览阶段。当使用
+ `transparent`,时,请将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -14120,7 +14122,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所付出的努力程度。此参数仅受 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持,不支持 `gpt-image-1-mini`。支持 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图片的风格和特征(尤其是面部特征)时所投入的精力。该参数仅 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型支持, `gpt-image-1-mini`。不支持。支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -14133,11 +14135,11 @@
- `file_id: optional string`
- 蒙版图像的文件 ID。
+ 蒙版图片的文件 ID。
- `image_url: optional string`
- Base64 编码的蒙版图像。
+ Base64 编码的掩码图像。
- `model: optional string or "gpt-image-1" or "gpt-image-1-mini" or "gpt-image-1.5" or 2 more`
@@ -14167,7 +14169,7 @@
- `moderation: optional "auto" or "low"`
- 生成图像的内容审核级别。默认值: `auto`.
+ 生成图像的审核级别。默认值: `auto`.
- `"auto"`
@@ -14190,7 +14192,7 @@
- `partial_images: optional number`
- 在流式模式下生成的部分图像数量,范围为 0(默认值)到 3。
+ 在流式模式下要生成的中间图像数量,取值范围为 0(默认值)到 3。
- `quality: optional "low" or "medium" or "high" or "auto"`
@@ -14207,13 +14209,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,以 `WIDTHxHEIGHT` 字符串形式表示,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 受到支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一: `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一: `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式传入任意分辨率,例如 `WIDTHxHEIGHT` 。 `1536x864`,宽和高都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动尺寸的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持任意分辨率,以 `WIDTHxHEIGHT` 字符串形式表示,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性,最高支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 受到 GPT 图像模型的支持; `auto` 受到支持用于允许自动调整尺寸的模型。对于 `dall-e-2`,使用以下之一: `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一: `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式传入任意分辨率,例如 `WIDTHxHEIGHT` 。 `1536x864`,宽和高都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `2560x1440` 的分辨率为实验性功能,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边数限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 由允许自动尺寸的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -14283,7 +14285,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -14303,7 +14305,7 @@
- `name: string`
- 工具调用中使用的命名空间名称(例如, `crm`).
+ 在工具调用中使用的命名空间名称(例如, `crm`).
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
@@ -14327,19 +14329,19 @@
- `defer_loading: optional boolean`
- 是否应延迟此函数并通过工具搜索发现它。
+ 此函数是否应被延迟并通过工具搜索发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。此字段不描述 content 数组形式的输出。
+ 用于描述此函数工具的字符串输出中所编码 JSON 值的 JSON Schema。这不描述内容数组(content-array)输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否启用严格的参数校验。如果省略,当 schema 兼容时 Responses 尝试使用严格校验,否则回退到非严格校验。
+ 是否强制执行严格的参数校验。如果省略,响应接口 会在模式兼容时尝试使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -14365,7 +14367,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索发现它。
+ 此工具是否应被延迟并通过工具搜索发现。
- `description: optional string`
@@ -14377,23 +14379,23 @@
- `type: "namespace"`
- 工具的类型。始终为 `namespace`.
+ 该工具的类型。始终为 `namespace`.
- `"namespace"`
- `ToolSearch object { type, description, execution, parameters }`
- 用于延迟工具的托管或 BYOT 工具搜索配置。
+ 用于延迟工具的托管工具搜索或 BYOT 工具搜索配置。
- `type: "tool_search"`
- 工具的类型。始终为 `tool_search`.
+ 该工具的类型。始终为 `tool_search`.
- `"tool_search"`
- `description: optional string or null`
- 向模型展示的客户端执行工具搜索工具的描述。
+ 展示给模型的、用于客户端执行的工具搜索工具的描述。
- `execution: optional "server" or "client"`
@@ -14405,15 +14407,15 @@
- `parameters: optional unknown or null`
- 客户端执行工具搜索工具的参数 schema。
+ 客户端执行的工具搜索工具的参数 schema。
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具会在网页上搜索相关结果以用于回复中。详细了解 Responses API [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
+ 此工具会搜索网页以获取在响应中使用的结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索 工具的类型。可选值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型。取以下值之一 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -14427,7 +14429,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 用于搜索的上下文窗口空间的高级使用指导。可选值为 `low`, `medium`,或 `high`. `medium` 是默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。取以下值之一 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -14463,11 +14465,11 @@
- `ApplyPatch object { type, allowed_callers }`
- 允许助手使用 unified diff 创建、删除或更新文件。
+ 允许助手使用统一差异来创建、删除或更新文件。
- `type: "apply_patch"`
- 工具的类型。始终为 `apply_patch`.
+ 该工具的类型。始终为 `apply_patch`.
- `"apply_patch"`
@@ -14481,12 +14483,12 @@
- `top_p: number or null`
- 一种称为 nucleus 采样的温度采样替代方案,
- 模型在此考虑 top_p 概率对应的 token 结果
- 的位置。因此 0.1 表示仅考虑构成前 10% 概率质量的 token
+ 一种称为 nucleus 采样的温度采样替代方法,
+ 模型会考虑概率质量排名前 top_p 的 token 结果
+ 。因此 0.1 表示只考虑构成前 10% 概率质量的 token
。
- 我们通常建议修改此参数或 `temperature` 但不能同时使用两者。
+ 我们通常建议修改此项或 `temperature` 但不能两者同时使用。
- `background: optional boolean or null`
@@ -14500,11 +14502,11 @@
- `conversation: optional object { id } or null`
- 此 Response 所属的会话。此 Response 中的输入项和输出项已自动添加到此会话中。
+ 此响应所属的对话。此响应中的输入项和输出项已自动添加到此对话中。
- `id: string`
- 与此 Response 关联的会话的唯一 ID。
+ 与此响应关联的对话的唯一 ID。
- `max_output_tokens: optional number or null`
@@ -14512,15 +14514,15 @@
- `max_tool_calls: optional number or null`
- 单个响应中可处理的内置工具调用总次数上限。该上限适用于所有内置工具调用,而非单个工具。模型任何进一步的工具调用尝试都将被忽略。
+ 在一次响应中可处理的内置工具调用总次数上限。该上限适用于所有内置工具调用,而非按单个工具分别计数。模型后续对工具的任何调用尝试都将被忽略。
- `moderation: optional object { input, output } or null`
- Response 输入和输出的审核结果(如果请求了受审核的补全)。
+ 响应输入和输出的审核结果(如果请求了经审核的补全)。
- `input: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
- Response 输入的审核结果。
+ 对响应输入的审核。
- `ModerationResult object { categories, category_applied_input_types, category_scores, 3 more }`
@@ -14528,7 +14530,7 @@
- `categories: map[boolean]`
- 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则为 True。
+ 一个由内容审核类别映射到布尔值的字典,若输入被该类别标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
@@ -14540,11 +14542,11 @@
- `category_scores: map[number]`
- 从内容审核类别到分数的字典。
+ 一个由内容审核类别映射到分数的字典。
- `flagged: boolean`
- 指示内容是否被任意类别标记的布尔值。
+ 一个布尔值,指示内容是否被任何类别标记。
- `model: string`
@@ -14552,13 +14554,13 @@
- `type: "moderation_result"`
- 对象类型,对于成功的 `moderation_result` 内容审核结果始终为。
+ 对象类型,对于成功的 `moderation_result` 内容审核结果始终为该类型。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在尝试为响应输入或输出进行内容审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -14570,7 +14572,7 @@
- `type: "error"`
- 对象类型,对于成功的 `error` 失败时的对象类型。
+ 对象类型,对于成功的 `error` 表示内容审核失败。
- `"error"`
@@ -14584,7 +14586,7 @@
- `categories: map[boolean]`
- 从内容审核类别到布尔值的字典;若输入在该类别下被标记,则为 True。
+ 一个由内容审核类别映射到布尔值的字典,若输入被该类别标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
@@ -14596,11 +14598,11 @@
- `category_scores: map[number]`
- 从内容审核类别到分数的字典。
+ 一个由内容审核类别映射到分数的字典。
- `flagged: boolean`
- 指示内容是否被任意类别标记的布尔值。
+ 一个布尔值,指示内容是否被任何类别标记。
- `model: string`
@@ -14608,13 +14610,13 @@
- `type: "moderation_result"`
- 对象类型,对于成功的 `moderation_result` 内容审核结果始终为。
+ 对象类型,对于成功的 `moderation_result` 内容审核结果始终为该类型。
- `"moderation_result"`
- `Error object { code, message, type }`
- 在尝试为响应输入或输出进行内容审核时产生的错误。
+ 在为响应输入或输出执行内容审核时产生的错误。
- `code: string`
@@ -14626,19 +14628,19 @@
- `type: "error"`
- 对象类型,对于成功的 `error` 失败时的对象类型。
+ 对象类型,对于成功的 `error` 表示内容审核失败。
- `"error"`
- `output_text: optional string or null`
- 仅限 SDK 的便捷属性,包含汇总的文本输出,
- 来自 `output_text` 数组中的所有 `output` 项(若存在)。
- 支持 Python 和 JavaScript SDK。
+ SDK 专属的便捷属性,包含来自 output_text 数组中所有
+ 项的聚合文本 `output_text` 输出,如果数组中存在 `output` 任何项。
+ 在 Python 和 JavaScript SDK 中受支持。
- `previous_response_id: optional string or null`
- 上一次模型响应的唯一 ID。用它来
+ 上一次模型响应的唯一 ID。可使用此 ID
创建多轮对话。详细了解
[对话状态](/docs/guides/conversation-state)。不能与 `conversation`.
@@ -14649,13 +14651,13 @@
- `id: string`
- 要使用的提示词模板的唯一标识符。
+ 要使用的提示模板的唯一标识符。
- `variables: optional map[string or ResponseInputText or ResponseInputImage or ResponseInputFile] or null`
- 可选的映射,用于在你的
- 提示词中替换变量。替换值可以是字符串,也可以是其他
- Response 输入类型,例如图片或文件。
+ 用于替换你提示中变量的可选值映射。
+ 替换值可以是字符串,也可以是其他
+ Response 输入类型,例如图像或文件。
- `string`
@@ -14665,7 +14667,7 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解 [图像输入](/docs/guides/vision).
+ 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
@@ -14673,11 +14675,11 @@
- `version: optional string or null`
- 提示词模板的可选版本。
+ 提示模板的可选版本。
- `prompt_cache_key: optional string or null`
- 由 OpenAI 用于为相似请求缓存响应,从而优化你的缓存命中率。取代 `user` 字段。 [了解更多](/docs/guides/prompt-caching).
+ 由 OpenAI 用于缓存相似请求的响应,以优化你的缓存命中率。替换 prompt_cache_key `user` 字段。 [了解更多](/docs/guides/prompt-caching).
- `prompt_cache_options: optional object { mode, ttl }`
@@ -14693,7 +14695,7 @@
- `ttl: "30m"`
- 应用于每个缓存断点的最短生命周期。
+ 应用于每个缓存断点的最小生命周期。
- `"30m"`
@@ -14702,15 +14704,15 @@
已弃用。请使用 `prompt_cache_options.ttl` 代替。
提示缓存的保留策略。设置为 `24h` 以启用扩展提示缓存,使缓存的前缀保持更长时间的活跃状态,最长可达 24 小时。 [了解更多](/docs/guides/prompt-caching#prompt-cache-retention).
- 此字段表示最大保留策略,而
- `prompt_cache_options.ttl` 表示最小缓存生命周期。这两个
- 字段是独立的,互不影响。
- 对于 `gpt-5.5`, `gpt-5.5-pro`,以及未来的模型,仅 `24h` 。
+ 该字段表示最大保留策略,而
+ `prompt_cache_options.ttl` 表示最小缓存生命周期。两个
+ 字段相互独立,互不影响。
+ 对于 `gpt-5.5`, `gpt-5.5-pro`,及未来模型,仅支持 `24h` 。
- 对于同时支持两者的较旧模型 `in_memory` 和 `24h`,默认值取决于你所在组织的数据保留策略:
+ 对于同时支持 `in_memory` 和 `24h`,的较旧模型,默认值取决于你组织的数据保留策略:
- 未启用 ZDR 的组织默认为 `24h`.
- - 已启用 ZDR 的组织默认为 `in_memory` 当 `prompt_cache_retention` 未指定时。
+ - 启用 ZDR 的组织默认为 `in_memory` 当 `prompt_cache_retention` 未指定时。
- `"in_memory"`
@@ -14718,17 +14720,17 @@
- `reasoning: optional Reasoning or null`
- 针对
+ 的配置选项
[推理模型](https://platform.openai.com/docs/guides/reasoning).
- `context: optional "auto" or "current_turn" or "all_turns" or null`
- 控制在后续轮次中哪些推理项会被重新渲染回模型。
- 如果省略或设置为 `auto`,模型将自行决定上下文模式。
- `gpt-5.6` 模型系列默认为 `all_turns`;较早的模型默认为
+ 控制在后续回合中哪些推理项会被渲染回给模型。
+ 如果省略或设置为 `auto`,模型将决定上下文模式。该
+ `gpt-5.6` 模型系列默认为 `all_turns`;更早的模型默认为
`current_turn`.
- 在响应中返回时,这是该响应使用的有效推理上下文模式
+ 在响应中返回时,这是响应所使用的有效推理上下文模式
。
- `"auto"`
@@ -14739,13 +14741,13 @@
- `effort: optional ReasoningEffort or null`
- 约束推理模型的推理力度。当前支持
- 的取值有 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
- 降低推理力度可以让响应更快,并减少响应中用于推理的令牌数量。
- 并非所有推理模型都支持每个
- 取值。请参阅
+ 在推理模型上限制推理的 effort。目前支持
+ 的值为 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
+ 降低推理 effort 可以使响应更快,并减少响应中推理所使用的 token 数量。并非所有推理模型都支持每个
+ 值。
+ value。参见
[推理指南](https://platform.openai.com/docs/guides/reasoning)
- 了解特定模型的支持情况。
+ 以了解特定模型的支持情况。
- `"none"`
@@ -14763,11 +14765,11 @@
- `generate_summary: optional "auto" or "concise" or "detailed" or null`
- **已弃用:** 使用 `summary` 代替。
+ **已弃用:** 请使用 `summary` 代替。
- 模型执行的推理摘要。这对于调试和理解模型的推理过程
- 很有用。
- 取值之一 `auto`, `concise`,或 `detailed`.
+ 模型执行的推理摘要。这可以
+ 有助于调试和理解模型的推理过程。
+ 以下值之一 `auto`, `concise`,或 `detailed`.
- `"auto"`
@@ -14795,11 +14797,11 @@
- `summary: optional "auto" or "concise" or "detailed" or null`
- 模型执行的推理摘要。这对于调试和理解模型的推理过程
- 很有用。
- 取值之一 `auto`, `concise`,或 `detailed`.
+ 模型执行的推理摘要。这可以
+ 有助于调试和理解模型的推理过程。
+ 以下值之一 `auto`, `concise`,或 `detailed`.
- `concise` 支持以下模型和之后的 `computer-use-preview` 推理模型 `gpt-5`.
+ `concise` 支持于 `computer-use-preview` 模型以及之后的全部推理模型 `gpt-5`.
- `"auto"`
@@ -14809,21 +14811,21 @@
- `safety_identifier: optional string or null`
- 一个稳定的标识符,用于帮助识别可能违反 OpenAI 使用政策的应用用户。
- 这些 ID 应为能够唯一标识每位用户的字符串,最大长度为 64 个字符。我们建议对其用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份信息。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
+ 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用政策的应用用户。
+ 这些 ID 应为字符串,唯一标识每个用户,最大长度为 64 个字符。建议对其用户名或电子邮件地址进行哈希处理,以避免向我们发送任何可识别信息。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
- `service_tier: optional ServiceTier or null`
- 指定用于处理该请求的处理类型。
+ 指定用于处理请求的处理类型。
- - 如果设置为 'auto',则该请求将按照项目设置中配置的服务层级进行处理。除非另行配置,项目将使用 'default'。
- - 如果设置为 'default',则该请求将按照所选模型的标准定价和性能进行处理。
- - 如果设置为 '[flex](/docs/guides/flex-processing)',则该请求将使用 Flex Processing 服务层级进行处理。
- - 要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 请求中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
- - 如果设置为 'ultrafast',则该请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级返回的响应将显示 `service_tier=ultrafast`.
- - 未设置时,默认行为为 'auto'。
+ - 如果设置为 'auto',则请求将使用项目设置中配置的服务层级进行处理。除非另有配置,项目将使用 'default'。
+ - 如果设置为 'default',则请求将使用所选模型的标准定价和性能进行处理。
+ - 如果设置为 '[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。
+ - 如要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为 'ultrafast',则请求将使用受访问控制的 Ultrafast Processing 服务层级进行处理。此层级目前可用于 `gpt-5.6-sol`;通过它服务的响应将显示 `service_tier=ultrafast`.
+ - 当未设置时,默认行为为 'auto'。
- 当 `service_tier` 参数已设置,响应体将包含基于实际用于处理请求的 `service_tier` 处理模式所得到的值。该响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数已设置时,响应体将基于实际用于处理该请求的处理模式返回相应的 `service_tier` 取值。该响应值可能与参数中设置的值不同。
- `"auto"`
@@ -14841,7 +14843,7 @@
- `status: optional ResponseStatus`
- 响应生成的状态。取值为 `completed`, `failed`,
+ 响应生成的状态。取值之一 `completed`, `failed`,
`in_progress`, `cancelled`, `queued`,或 `incomplete`.
- `"completed"`
@@ -14858,27 +14860,27 @@
- `text: optional ResponseTextConfig`
- 用于配置模型返回的文本响应格式。可以是纯文本或结构化的 JSON 数据。了解更多:
- 文本或结构化 JSON 数据。了解更多:
+ 模型文本响应的配置选项。可以是纯
+ 文本,也可以是结构化的 JSON 数据。了解详情:
- [文本输入与输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
- `format: optional ResponseFormatTextConfig`
- 用于指定模型必须输出的格式的对象。
+ 一个用于指定模型必须输出的格式的对象。
配置 `{ "type": "json_schema" }` 可启用结构化输出,
- 从而确保模型的输出与你提供的 JSON schema 完全匹配。更多信息请参阅
+ 从而确保模型匹配你提供的 JSON schema。详细了解
[结构化输出指南](/docs/guides/structured-outputs).
- 默认格式为 `{ "type": "text" }` ,不包含额外选项。
+ 默认格式为 `{ "type": "text" }` ,且没有其他选项。
- **不推荐用于 gpt-4o 及更新的模型:**
+ **不推荐用于 gpt-4o 及更新模型:**
- 设置为 `{ "type": "json_object" }` 可启用旧的 JSON 模式,该模式
- 会确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
- 的模型,推荐使用结构化输出。
+ 设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
+ 确保模型生成的消息是合法的 JSON。对于支持 `json_schema`
+ 的模型,更推荐使用它。
- `ResponseFormatText object { type }`
@@ -14886,7 +14888,7 @@
- `type: "text"`
- 正在定义的响应格式类型。始终为 `text`.
+ 正在定义的响应格式的类型。始终为 `text`.
- `"text"`
@@ -14897,50 +14899,50 @@
- `name: string`
- 响应格式的名称。必须为 a-z、A-Z、0-9,或包含
- 下划线和短横线,最大长度为 64。
+ 响应格式的名称。必须由 a-z、A-Z、0-9 组成,或包含
+ 下划线和连字符,最大长度为 64。
- `schema: map[unknown]`
- 响应格式所对应的 schema,以 JSON Schema 对象形式描述。
+ 响应格式的 schema,以 JSON Schema 对象形式描述。
了解如何构建 JSON schema [here](https://json-schema.org/).
- `type: "json_schema"`
- 正在定义的响应格式类型。始终为 `json_schema`.
+ 正在定义的响应格式的类型。始终为 `json_schema`.
- `"json_schema"`
- `description: optional string`
- 对响应格式用途的描述,供模型用于
- 确定如何在该格式中作出响应。
+ 响应格式用途的描述,供模型用于
+ 确定如何按该格式进行响应。
- `strict: optional boolean or null`
- 是否在生成输出时启用严格的 schema 遵从。
- 若设为 true,模型将始终遵循在
- 字段中定义的精确 schema。仅支持部分 JSON Schema, `schema` 当
- `strict` is `true`。为 true 时。要了解更多信息,请参阅 [结构化输出
+ 是否在生成输出时启用严格的 schema 遵循。
+ 如果设置为 true,模型将始终遵循所定义的确切 schema
+ 在 `schema` 字段。当使用 structured outputs 时仅支持 JSON Schema 的一个子集
+ `strict` 为 `true`。有关详细信息,请阅读 [结构化输出
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON 对象响应格式。一种较老的生成 JSON 响应的方法。
- 建议使用 `json_schema` 以支持相关功能的模型。请注意,
- 模型在没有系统或用户消息指示的情况下不会生成 JSON,
- 指示它这样做。
+ JSON 对象响应格式。一种较旧的生成 JSON 响应的方法。
+ 推荐对支持的模型使用 `json_schema` 。请注意,如果没有系统或用户消息指示模型生成 JSON,
+ 模型将不会生成 JSON
+ 。
- `type: "json_object"`
- 正在定义的响应格式类型。始终为 `json_object`.
+ 正在定义的响应格式的类型。始终为 `json_object`.
- `"json_object"`
- `verbosity: optional "low" or "medium" or "high" or null`
- 限制模型响应的详细程度。较低的值会得到
- 更简洁的响应,而较高的值会得到更详细的响应。
+ 约束模型响应的详细程度。较低的值将产生更简洁的响应,而较高的值将产生更详细的响应。
+ 简洁的响应,而较高的值将产生更详细的响应。
当前支持的值包括 `low`, `medium`,和 `high`。默认值为
`medium`.
@@ -14952,19 +14954,19 @@
- `top_logprobs: optional number or null`
- 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的
- 最大可能性 token 数量,每个 token 都带有对应的对数
- 概率。在某些情况下,返回的 token 数量可能少于
- 请求的数量。
+ 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的最可能的
+ 最大 token 数,每个 token 都带有对应的 log
+ 概率。在某些情况下,返回的 token 数量可能会少于
+ 所请求的数量。
- `truncation: optional "auto" or "disabled" or null`
用于模型响应的截断策略。
- - `auto`:如果此 Response 的输入超过
- 模型的上下文窗口大小,模型将通过从对话开头丢弃内容来截断
- 响应以适配上下文窗口。
- - `disabled` (默认):如果输入大小将超过模型的上下文窗口
+ - `auto`:如果此 Response 的输入超出
+ 模型的上下文窗口大小,模型将通过从对话开头丢弃条目来截断
+ 响应以适应上下文窗口。
+ - `disabled` (默认):如果输入大小将超出模型的上下文窗口
大小,请求将失败并返回 400 错误。
- `"auto"`
@@ -14973,12 +14975,12 @@
- `usage: optional ResponseUsage`
- 表示 token 使用明细,包括输入 token、输出 token、
- 输出 token 的细分,以及使用的 token 总数。
+ 表示 token 使用详情,包括输入 token、输出 token,
+ 的细分以及所使用的 token 总数。
- `input_tokens: number`
- 输入 token 的数量。
+ 输入 token 数。
- `input_tokens_details: object { cache_write_tokens, cached_tokens }`
@@ -14986,16 +14988,16 @@
- `cache_write_tokens: number`
- 写入缓存的输入 token 数量。
+ 写入缓存的输入 token 数。
- `cached_tokens: number`
- 从缓存中检索到的 token 数量。
- [更多关于提示缓存的信息](/docs/guides/prompt-caching).
+ 从缓存中检索到的 token 数。
+ [详细了解提示缓存](/docs/guides/prompt-caching).
- `output_tokens: number`
- 输出 token 的数量。
+ 输出 token 数。
- `output_tokens_details: object { reasoning_tokens }`
@@ -15003,21 +15005,17 @@
- `reasoning_tokens: number`
- 推理 token 的数量。
+ 推理 token 数。
- `total_tokens: number`
使用的 token 总数。
- - `compute_units: optional number or null`
-
- 请求的计算单元。当可用时,当前为 null。
-
- `user: optional string`
- 此字段将被 `safety_identifier` 和 `prompt_cache_key`。取代。请使用 `prompt_cache_key` 以保持缓存优化效果。
- 为你的最终用户提供的一个稳定标识符。
- 用于通过更好地对相似请求进行分桶来提高缓存命中率,并帮助 OpenAI 检测和防止滥用。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
+ 此字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`,请使用 `prompt_cache_key` 以保持缓存优化效果。
+ 用于标识最终用户的稳定标识符。
+ 用于通过更好地对相似请求进行分桶来提高缓存命中率,并帮助 OpenAI 检测和防止滥用行为。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
### 示例
@@ -15201,8 +15199,7 @@ curl https://api.openai.com/v1/responses \
"output_tokens_details": {
"reasoning_tokens": 0
},
- "total_tokens": 0,
- "compute_units": 0
+ "total_tokens": 0
},
"user": "user-1234"
}
diff --git a/docs/zh/api/reference/resources/responses/methods/retrieve.md b/docs/zh/api/reference/resources/responses/methods/retrieve.md
index 3174387..4913a71 100644
--- a/docs/zh/api/reference/resources/responses/methods/retrieve.md
+++ b/docs/zh/api/reference/resources/responses/methods/retrieve.md
@@ -1,10 +1,10 @@
-> 如需完整的文档索引,请参阅 [llms.txt](/llms.txt)。在页面 URL 末尾添加 `.md` 即可获取该页面的 Markdown 版本。
+> 如需完整文档索引,请参阅 [llms.txt](/llms.txt)。在页面 URL 末尾添加以下后缀即可获取该页面的 Markdown 版本: `.md` 。
## 获取模型响应
-**获取** `/responses/{response_id}`
+**get** `/responses/{response_id}`
-根据给定 ID 检索模型响应。
+检索具有指定 ID 的模型响应。
### 路径参数
@@ -14,8 +14,8 @@
- `include: optional array of ResponseIncludable`
- 响应中要包含的其他字段。详见上方 `include`
- 参数中关于 Response 创建的说明。
+ 响应中要包含的其他字段。参见上方 `include`
+ 参数中 Response 创建部分以了解更多信息。
- `"file_search_call.results"`
@@ -35,28 +35,28 @@
- `include_obfuscation: optional boolean`
- 若设为 true,将启用流混淆。流混淆会向流式 delta 事件上的
- 字段添加随机字符 `obfuscation` 以规范化 payload 体积,
- 缓解特定的侧信道攻击。默认包含这些混淆字段,但会给数据流带来少量开销。
- 若你信任应用与 OpenAI API 之间的网络链路,
- 可以将该参数设为 false 以优化带宽。
- `include_obfuscation` 若你信任应用与
- the network links between your application and the 该公司 接口.
+ 为 true 时,将启用流混淆。流混淆会向流式 delta 事件上的
+ 字段添加随机字符 `obfuscation` ,以规范化负载大小,作为对某些侧信道
+ 攻击的缓解措施。默认会包含这些混淆字段,但会给数据流带来少量
+ 开销。如果你信任你的应用与 OpenAI API 之间的网络链路,可以将
+ 设为 false 以优化带宽。
+ `include_obfuscation` 设为 false 以优化带宽,前提是你信任你的应用与
+ 该公司 接口 之间的网络链路。
- `starting_after: optional number`
- 开始流式传输之前一个事件的序列号。
+ 开始流式输出之前所依据的事件序号。
- `stream: optional false`
- 若设为 true,模型响应数据将以流式方式通过
- 实时发送给客户端 [服务端发送事件](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
- 详见下文 [“Streaming”部分](/docs/api-reference/responses-streaming)
- 。
+ 若设为 true,模型响应数据将以
+ 的形式流式发送到客户端 [server-sent events](https://developer.mozilla.org/en-US/docs/Web/API/Server-sent_events/Using_server-sent_events#Event_stream_format).
+ 参见下方 [Streaming 部分](/docs/api-reference/responses-streaming)
+ 以了解更多信息。
- `false`
-### Returns
+### 返回
- `Response object { id, created_at, error, 32 more }`
@@ -70,7 +70,7 @@
- `error: ResponseError or null`
- 当模型未能生成 Response 时返回的错误对象。
+ 当模型无法生成 Response 时返回的错误对象。
- `code: "server_error" or "rate_limit_exceeded" or "invalid_prompt" or 17 more`
@@ -122,63 +122,65 @@
- `incomplete_details: object { reason } or null`
- 有关响应未完成原因的详细信息。
+ 关于响应为何不完整的详细信息。
- - `reason: optional "max_output_tokens" or "content_filter"`
+ - `reason: optional "max_output_tokens" or "max_messages" or "content_filter"`
- 响应未完成的原因。
+ 响应不完整的原因。
- `"max_output_tokens"`
+ - `"max_messages"`
+
- `"content_filter"`
- `instructions: string or array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more or null`
插入到模型上下文中的系统(或开发者)消息。
- 当与 `previous_response_id`,一起使用时,来自上一次响应的
- 指令不会延续到下一次响应。这便于在
- 新的响应中替换系统(或开发者)消息。
+ 与以下项一起使用时 `previous_response_id`,来自上一个响应的指令将
+ 不会被延续到下一个响应。这使得在新响应中替换系统(或开发者)消息变得简单
+ 。
- `string`
- 发送给模型的文本输入,等同于使用
+ 模型的文本输入,等同于使用以下
`developer` 角色的文本输入。
- `InputItemList = array of EasyInputMessage or object { content, role, status, type } or ResponseOutputMessage or 29 more`
- 发送给模型的一个或多个输入项的列表,包含
+ 包含一个或多个输入项的列表,这些输入项提供给模型,包含
不同的内容类型。
- `EasyInputMessage object { content, role, phase, type }`
- 发送给模型的消息输入,其角色指示指令的优先级
- 层级。使用 `developer` 或 `system` 角色提供的指令具有
- 优先于使用 `user` 角色给出的指令。带有
- `assistant` 角色的消息被假定为模型在之前的
- 交互中生成。
+ 提供给模型的消息输入,其角色指示指令优先级。使用以下角色给定的指令将
+ 覆盖先前 `developer` 或 `system` 角色提供的指令。
+ 优先于随 `user` 角色提供的说明。带有
+ `assistant` 角色的消息被视为模型在先前交互中生成的
+ 。
- `content: string or ResponseInputMessageContentList`
- 发送给模型的文本、图像或音频输入,用于生成响应。
+ 提供给模型的文本、图像或音频输入,用于生成响应。
也可以包含之前的助手响应。
- `TextInput = string`
- 发送给模型的文本输入。
+ 提供给模型的文本输入。
- `ResponseInputMessageContentList = array of ResponseInputContent`
- 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 提供给模型的一个或多个输入项的列表,包含不同的内容
类型。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- 发送给模型的文本输入。
+ 提供给模型的文本输入。
- `text: string`
- 发送给模型的文本输入。
+ 提供给模型的文本输入。
- `type: "input_text"`
@@ -188,7 +190,7 @@
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用提示词前缀的确切结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到令牌块。
- `mode: "explicit"`
@@ -198,11 +200,11 @@
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
+ 提供给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `detail: ImageDetail`
- 发送给模型的图像的详细程度。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
+ 发送给模型的图像的详细程度。以下之一: `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `"low"`
@@ -220,15 +222,15 @@
- `file_id: optional string or null`
- 发送给模型的文件的 ID。
+ 要发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完整 URL,也可以是 data URL 形式的 base64 编码图片。
+ 发送给模型的图片的 URL。完全限定的 URL 或以 data URL 形式进行 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用提示词前缀的确切结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到令牌块。
- `mode: "explicit"`
@@ -238,7 +240,7 @@
- `ResponseInputFile object { type, detail, file_data, 4 more }`
- 发送给模型的输入文件。
+ 发送到模型的输入文件。
- `type: "input_file"`
@@ -248,7 +250,7 @@
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的消耗。使用 `low` 可以降低渲染成本,使用 `high` 可以以更高质量渲染文件。默认为 `auto`.
+ 发送到模型的文件的细节等级。使用 `auto` 可以让系统自行选择细节等级;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会增加输入 token 消耗。使用 `low` 以降低渲染成本,或使用 `high` 以更高质量渲染该文件。默认为 `auto`.
- `"auto"`
@@ -262,7 +264,7 @@
- `file_id: optional string or null`
- 发送给模型的文件的 ID。
+ 要发送给模型的文件的 ID。
- `file_url: optional string`
@@ -274,7 +276,7 @@
- `prompt_cache_breakpoint: optional object { mode }`
- 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用提示词前缀的确切结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到令牌块。
- `mode: "explicit"`
@@ -284,7 +286,7 @@
- `role: "user" or "assistant" or "system" or "developer"`
- 消息输入的角色,取值为 `user`, `assistant`, `system`,或
+ 消息输入的角色。可选值为 `user`, `assistant`, `system`,或
`developer`.
- `"user"`
@@ -297,9 +299,9 @@
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间推理过程(`commentary`)或最终回答(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高的模型,在发送后续请求时,需保留并重新发送所有助手消息上的
- 阶段,去掉它可能会导致性能下降。不适用于用户消息。
+ 将某条 `assistant` 消息标记为中间推理内容(`commentary`)或最终答案(`final_answer`).
+ )。对于像 `gpt-5.3-codex` 及更高版本这样的模型,在发送后续请求时,请在所有助手消息上保留并重新发送
+ 阶段;省略该阶段可能会降低性能。用户消息不使用此字段。
- `"commentary"`
@@ -313,18 +315,18 @@
- `Message object { content, role, status, type }`
- 发送给模型的消息输入,其角色指示指令的优先级
- 层级。使用 `developer` 或 `system` 角色提供的指令具有
- 优先于使用 `user` 角色的文本输入。
+ 提供给模型的消息输入,其角色指示指令优先级。使用以下角色给定的指令将
+ 覆盖先前 `developer` 或 `system` 角色提供的指令。
+ 优先于随 `user` 角色的文本输入。
- `content: ResponseInputMessageContentList`
- 发送给模型的一个或多个输入项的列表,包含不同的内容
+ 提供给模型的一个或多个输入项的列表,包含不同的内容
类型。
- `role: "user" or "system" or "developer"`
- 消息输入的角色,取值为 `user`, `system`,或 `developer`.
+ 消息输入的角色。可选值为 `user`, `system`,或 `developer`.
- `"user"`
@@ -334,8 +336,8 @@
- `status: optional "in_progress" or "completed" or "incomplete"`
- 项目的状态,取值为 `in_progress`, `completed`,或
- `incomplete`。当通过 API 返回项目时会填充此字段。
+ 条目的状态。可选值为 `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回条目时会填充该字段。
- `"in_progress"`
@@ -351,7 +353,7 @@
- `ResponseOutputMessage object { id, content, role, 3 more }`
- 来自模型的输出消息。
+ 模型输出的一条消息。
- `id: string`
@@ -363,11 +365,11 @@
- `ResponseOutputText object { annotations, logprobs, text, type }`
- 来自模型的文本输出。
+ 模型输出的文本。
- `annotations: array of object { file_id, filename, index, type } or object { end_index, start_index, title, 2 more } or object { container_id, end_index, file_id, 3 more } or object { file_id, index, type }`
- 文本输出的注解。
+ 文本输出的注释。
- `FileCitation object { file_id, filename, index, type }`
@@ -383,7 +385,7 @@
- `index: number`
- 该文件在文件列表中的索引。
+ 文件在文件列表中的索引。
- `type: "file_citation"`
@@ -393,7 +395,7 @@
- `URLCitation object { end_index, start_index, title, 2 more }`
- 用于生成模型响应的网页资源引用。
+ 用于生成模型响应的网页资源的引用。
- `end_index: number`
@@ -419,7 +421,7 @@
- `ContainerFileCitation object { container_id, end_index, file_id, 3 more }`
- 用于生成模型响应的容器文件引用。
+ 用于生成模型响应的容器文件的引用。
- `container_id: string`
@@ -435,11 +437,11 @@
- `filename: string`
- 引用的容器文件的文件名。
+ 被引用容器文件的文件名。
- `start_index: number`
- 消息中容器文件引用起始字符的索引。
+ 消息中容器文件引用的起始字符索引。
- `type: "container_file_citation"`
@@ -457,7 +459,7 @@
- `index: number`
- 该文件在文件列表中的索引。
+ 文件在文件列表中的索引。
- `type: "file_path"`
@@ -493,11 +495,11 @@
- `ResponseOutputRefusal object { refusal, type }`
- 模型的拒绝。
+ 模型给出的拒绝。
- `refusal: string`
- 模型给出的拒绝原因说明。
+ 模型给出的拒绝说明。
- `type: "refusal"`
@@ -513,7 +515,7 @@
- `status: "in_progress" or "completed" or "incomplete"`
- 消息输入的状态。取值之一 `in_progress`, `completed`,或
+ 消息输入的状态。可选值为 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回输入项时填充。
- `"in_progress"`
@@ -530,9 +532,9 @@
- `phase: optional "commentary" or "final_answer" or null`
- 将 `assistant` 消息标记为中间推理过程(`commentary`)或最终回答(`final_answer`).
- 对于像 `gpt-5.3-codex` 及更高的模型,在发送后续请求时,需保留并重新发送所有助手消息上的
- 阶段,去掉它可能会导致性能下降。不适用于用户消息。
+ 将某条 `assistant` 消息标记为中间推理内容(`commentary`)或最终答案(`final_answer`).
+ )。对于像 `gpt-5.3-codex` 及更高版本这样的模型,在发送后续请求时,请在所有助手消息上保留并重新发送
+ 阶段;省略该阶段可能会降低性能。用户消息不使用此字段。
- `"commentary"`
@@ -540,8 +542,8 @@
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -553,7 +555,7 @@
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值之一 `in_progress`,
+ 文件搜索 工具调用的状态。可选值为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -578,11 +580,11 @@
- `attributes: optional map[string or number or boolean] or null`
- 可以附加到对象的 16 组键值对。这可以
- 用于以结构化格式存储关于对象的附加信息,
- 并通过API或仪表板查询对象。键是字符串,
- 最大长度为 64 个字符。值是最大长度为 512 个字符的字符串、
- 布尔值或数字。
+ 可附加到对象的 16 个键值对集合。可用于
+ 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。值为字符串,
+ 最大长度为 512 个字符,或为布尔值或数字。
+ 最大长度为 512 个字符,或为布尔值或数字。
- `string`
@@ -600,7 +602,7 @@
- `score: optional number`
- 文件的相关性评分,介于 0 和 1 之间。
+ 文件的相关性得分,取值介于 0 到 1 之间。
- `text: optional string`
@@ -608,8 +610,8 @@
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
- 对计算机使用工具的工具调用。参见
- [计算机使用指南](/docs/guides/tools-computer-use) 。
+ 对计算机使用工具的工具调用。请参阅
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -617,7 +619,7 @@
- `call_id: string`
- 在向工具调用提供输出响应时使用的标识符。
+ 使用输出响应工具调用时所用的标识符。
- `pending_safety_checks: array of object { id, code, message }`
@@ -633,12 +635,12 @@
- `message: optional string or null`
- 关于待处理安全检查的详细信息。
+ 待处理安全检查的详细信息。
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。其一为 `in_progress`, `completed`,或
- `incomplete`。当通过 API 返回项目时会填充此字段。
+ 条目的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回条目时会填充该字段。
- `"in_progress"`
@@ -654,15 +656,15 @@
- `action: optional ComputerAction`
- 一次点击动作。
+ 单击操作。
- `Click object { button, type, x, 2 more }`
- 一次点击动作。
+ 单击操作。
- `button: "left" or "right" or "wheel" or 2 more`
- 表示点击时按下的鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
+ 表示单击时按下的鼠标按键。可选值为 `left`, `right`, `wheel`, `back`,或 `forward`.
- `"left"`
@@ -676,25 +678,25 @@
- `type: "click"`
- 指定事件类型。对于点击动作,该属性始终为 `click`.
+ 指定事件类型。对于单击操作,此属性始终为 `click`.
- `"click"`
- `x: number`
- 点击发生位置的 x 坐标。
+ 单击发生位置的 x 坐标。
- `y: number`
- 点击发生位置的 y 坐标。
+ 单击发生位置的 y 坐标。
- `keys: optional array of string or null`
- 点击时按住的按键。
+ 单击时按住的按键。
- `DoubleClick object { keys, type, x, y }`
- 一次双击动作。
+ 双击操作。
- `keys: array of string or null`
@@ -702,7 +704,7 @@
- `type: "double_click"`
- 指定事件类型。对于双击动作,该属性始终设置为 `double_click`.
+ 指定事件类型。对于双击操作,此属性始终设置为 `double_click`.
- `"double_click"`
@@ -716,11 +718,11 @@
- `Drag object { path, type, keys }`
- 一次拖动动作。
+ 拖动操作。
- `path: array of object { x, y }`
- 一个坐标数组,表示拖动动作的路径。坐标将以对象数组的形式呈现,例如
+ 表示拖动操作路径的坐标数组。坐标以对象数组形式呈现,例如
```
[
@@ -739,7 +741,7 @@
- `type: "drag"`
- 指定事件类型。对于拖动动作,该属性始终设置为 `drag`.
+ 指定事件类型。对于拖动操作,此属性始终设置为 `drag`.
- `"drag"`
@@ -749,53 +751,53 @@
- `Keypress object { keys, type }`
- 模型希望执行的按键操作的集合。
+ 模型希望执行的一组按键操作。
- `keys: array of string`
- 模型请求按下的按键组合。这是一个字符串数组,每个字符串表示一个按键。
+ 模型请求按下的按键组合。这是一个字符串数组,每个字符串代表一个按键。
- `type: "keypress"`
- 指定事件类型。对于按键动作,该属性始终设置为 `keypress`.
+ 指定事件类型。对于按键操作,此属性始终设置为 `keypress`.
- `"keypress"`
- `Move object { type, x, y, keys }`
- 鼠标移动动作。
+ 鼠标移动操作。
- `type: "move"`
- 指定事件类型。对于 move 动作,此属性始终设置为 `move`.
+ 指定事件类型。对于移动操作,此属性始终设置为 `move`.
- `"move"`
- `x: number`
- 要移动到的 x 坐标。
+ 要移至的 x 坐标。
- `y: number`
- 要移动到的 y 坐标。
+ 要移至的 y 坐标。
- `keys: optional array of string or null`
- 移动鼠标时按住的键。
+ 移动鼠标时按住的按键。
- `Screenshot object { type }`
- 截图动作。
+ 截图操作。
- `type: "screenshot"`
- 指定事件类型。对于 screenshot 动作,此属性始终设置为 `screenshot`.
+ 指定事件类型。对于截图操作,此属性始终设置为 `screenshot`.
- `"screenshot"`
- `Scroll object { scroll_x, scroll_y, type, 3 more }`
- 滚动动作。
+ 滚动操作。
- `scroll_x: number`
@@ -807,7 +809,7 @@
- `type: "scroll"`
- 指定事件类型。对于 scroll 动作,此属性始终设置为 `scroll`.
+ 指定事件类型。对于滚动操作,此属性始终设置为 `scroll`.
- `"scroll"`
@@ -821,11 +823,11 @@
- `keys: optional array of string or null`
- 滚动时按住的键。
+ 滚动时按住的按键。
- `Type object { text, type }`
- 输入文本的动作。
+ 用于输入文本的操作。
- `text: string`
@@ -833,77 +835,77 @@
- `type: "type"`
- 指定事件类型。对于 type 动作,此属性始终设置为 `type`.
+ 指定事件类型。对于 type 操作,此属性始终设置为 `type`.
- `"type"`
- `Wait object { type }`
- 等待动作。
+ 等待操作。
- `type: "wait"`
- 指定事件类型。对于 wait 动作,此属性始终设置为 `wait`.
+ 指定事件类型。对于等待操作,此属性始终设置为 `wait`.
- `"wait"`
- `actions: optional ComputerActionList`
- 针对的扁平化批量动作 `computer_use`. 每个 action 包含一个
- `type` 判别字段和 action 特定的字段。
+ 针对以下对象的扁平化批量操作 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作专属字段。
- `Click object { button, type, x, 2 more }`
- 一次点击动作。
+ 单击操作。
- `DoubleClick object { keys, type, x, y }`
- 一次双击动作。
+ 双击操作。
- `Drag object { path, type, keys }`
- 一次拖动动作。
+ 拖动操作。
- `Keypress object { keys, type }`
- 模型希望执行的按键操作的集合。
+ 模型希望执行的一组按键操作。
- `Move object { type, x, y, keys }`
- 鼠标移动动作。
+ 鼠标移动操作。
- `Screenshot object { type }`
- 截图动作。
+ 截图操作。
- `Scroll object { scroll_x, scroll_y, type, 3 more }`
- 滚动动作。
+ 滚动操作。
- `Type object { text, type }`
- 输入文本的动作。
+ 用于输入文本的操作。
- `Wait object { type }`
- 等待动作。
+ 等待操作。
- `ComputerCallOutput object { call_id, output, type, 3 more }`
- 一次 computer 工具调用的输出。
+ 计算机工具调用的输出。
- `call_id: string`
- 生成该输出的 computer 工具调用的 ID。
+ 生成该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具配合使用的电脑截图。
+ 与计算机使用工具配合使用的计算机截图图像。
- `type: "computer_screenshot"`
- 指定事件类型。对于电脑截图,此属性始终
- 设置为 `computer_screenshot`.
+ 指定事件类型。对于计算机截图,此属性
+ 始终设置为 `computer_screenshot`.
- `"computer_screenshot"`
@@ -913,21 +915,21 @@
- `image_url: optional string`
- 截图的 URL。
+ 截图图像的 URL。
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `id: optional string or null`
- computer 工具调用输出的 ID。
+ 计算机工具调用输出的 ID。
- `acknowledged_safety_checks: optional array of object { id, code, message } or null`
- 由开发者确认的 API 上报的安全检查项。
+ 开发者已确认的、由 API 报告的安全检查结果。
- `id: string`
@@ -939,11 +941,11 @@
- `message: optional string or null`
- 关于待处理安全检查的详细信息。
+ 待处理安全检查的详细信息。
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 消息输入的状态。取值之一 `in_progress`, `completed`,或 `incomplete`。当通过 API 返回输入项时填充。
+ 消息输入的状态。可选值为 `in_progress`, `completed`,或 `incomplete`。当通过 API 返回输入项时填充。
- `"in_progress"`
@@ -953,25 +955,25 @@
- `WebSearchCall object { id, action, status, type }`
- 一次 网页搜索 工具调用的结果。请参阅
- [网页搜索 指南](/docs/guides/tools-web-search) 。
+ 网页搜索工具调用的结果。请参阅
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
- 网页搜索 工具调用的唯一 ID。
+ 网页搜索工具调用的唯一 ID。
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述本次 网页搜索 调用中所执行具体操作的对象。
- 包含模型使用网络的方式的详细信息(search、open_page、find_in_page)。
+ 描述本次 网页搜索调用中所执行具体操作的对象。
+ 包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- Action 类型 "search" —— 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
- action 类型。
+ 操作类型。
- `"search"`
@@ -981,7 +983,7 @@
- `query: optional string`
- 搜索查询语句。
+ 搜索查询。
- `sources: optional array of object { type, url }`
@@ -999,11 +1001,11 @@
- `OpenPage object { type, url }`
- 操作类型 "open_page" - 从搜索结果中打开指定的 URL。
+ 操作类型 "open_page" - 从搜索结果中打开一个特定的 URL。
- `type: "open_page"`
- action 类型。
+ 操作类型。
- `"open_page"`
@@ -1017,21 +1019,21 @@
- `pattern: string`
- 要在页面中搜索的模式或文本。
+ 要在页面内搜索的模式或文本。
- `type: "find_in_page"`
- action 类型。
+ 操作类型。
- `"find_in_page"`
- `url: string`
- 在其中搜索该模式的页面的 URL。
+ 搜索模式的页面 URL。
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -1043,14 +1045,14 @@
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [function calling guide](/docs/guides/function-calling) 。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -1058,7 +1060,7 @@
- `call_id: string`
- 模型生成的函数工具调用的唯一 ID。
+ 由模型生成的函数工具调用的唯一 ID。
- `name: string`
@@ -1076,7 +1078,7 @@
- `caller: optional object { type } or object { caller_id, type } or null`
- 产生此工具调用的执行上下文。
+ 生成此工具调用的执行上下文。
- `Direct object { type }`
@@ -1088,7 +1090,7 @@
- `caller_id: string`
- 产生此工具调用的程序项的调用 ID。
+ 生成此工具调用的程序项的调用 ID。
- `type: "program"`
@@ -1100,8 +1102,8 @@
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。其一为 `in_progress`, `completed`,或
- `incomplete`。当通过 API 返回项目时会填充此字段。
+ 条目的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回条目时会填充该字段。
- `"in_progress"`
@@ -1127,11 +1129,11 @@
- `ResponseInputTextContent object { text, type, prompt_cache_breakpoint }`
- 发送给模型的文本输入。
+ 提供给模型的文本输入。
- `text: string`
- 发送给模型的文本输入。
+ 提供给模型的文本输入。
- `type: "input_text"`
@@ -1141,7 +1143,7 @@
- `prompt_cache_breakpoint: optional object { mode } or null`
- 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用提示词前缀的确切结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到令牌块。
- `mode: "explicit"`
@@ -1151,7 +1153,7 @@
- `ResponseInputImageContent object { type, detail, file_id, 2 more }`
- 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision)
+ 提供给模型的图像输入。了解 [图像输入](/docs/guides/vision)
- `type: "input_image"`
@@ -1161,19 +1163,19 @@
- `detail: optional ImageDetail or null`
- 发送给模型的图像的详细程度。可选值为 `high`, `low`, `auto`,或 `original`。默认为 `auto`.
+ 发送给模型的图像的详细程度。以下之一: `high`, `low`, `auto`,或 `original`。默认为 `auto`.
- `file_id: optional string or null`
- 发送给模型的文件的 ID。
+ 要发送给模型的文件的 ID。
- `image_url: optional string or null`
- 发送给模型的图片的 URL。可以是完整 URL,也可以是 data URL 形式的 base64 编码图片。
+ 发送给模型的图片的 URL。完全限定的 URL 或以 data URL 形式进行 base64 编码的图片。
- `prompt_cache_breakpoint: optional object { mode } or null`
- 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用提示词前缀的确切结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到令牌块。
- `mode: "explicit"`
@@ -1183,7 +1185,7 @@
- `ResponseInputFileContent object { type, detail, file_data, 4 more }`
- 发送给模型的输入文件。
+ 发送到模型的输入文件。
- `type: "input_file"`
@@ -1193,7 +1195,7 @@
- `detail: optional "auto" or "low" or "high"`
- 发送给模型的文件的细节级别。使用 `auto` 可让系统自动选择细节级别;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,可能会增加输入 token 的消耗。使用 `low` 可以降低渲染成本,使用 `high` 可以以更高质量渲染文件。默认为 `auto`.
+ 发送到模型的文件的细节等级。使用 `auto` 可以让系统自行选择细节等级;对于 GPT-5.6 及更高版本的模型, `auto` 使用高质量渲染,这可能会增加输入 token 消耗。使用 `low` 以降低渲染成本,或使用 `high` 以更高质量渲染该文件。默认为 `auto`.
- `"auto"`
@@ -1207,7 +1209,7 @@
- `file_id: optional string or null`
- 发送给模型的文件的 ID。
+ 要发送给模型的文件的 ID。
- `file_url: optional string or null`
@@ -1219,7 +1221,7 @@
- `prompt_cache_breakpoint: optional object { mode } or null`
- 标记可复用提示前缀的精确结束位置。该断点继承请求的 `prompt_cache_options.ttl`;的 TTL;边界不会对齐到 token 块。
+ 标记可复用提示词前缀的确切结束位置。该断点继承请求的 `prompt_cache_options.ttl`;边界不会取整到令牌块。
- `mode: "explicit"`
@@ -1235,15 +1237,15 @@
- `id: optional string or null`
- 函数工具调用输出的唯一 ID。当此条目通过 API 返回时填充。
+ 函数工具调用输出的唯一 ID。当通过 API 返回此条目时填充。
- `call_id: optional string or null`
- 模型生成的函数工具调用的唯一 ID。
+ 由模型生成的函数工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
- 产生此工具调用的执行上下文。
+ 生成此工具调用的执行上下文。
- `Direct object { type }`
@@ -1257,7 +1259,7 @@
- `caller_id: string`
- 产生此工具调用的程序项的调用 ID。
+ 生成此工具调用的程序项的调用 ID。
- `type: "program"`
@@ -1275,7 +1277,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。其一为 `in_progress`, `completed`,或 `incomplete`。当通过 API 返回项目时会填充此字段。
+ 条目的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`。当通过 API 返回条目时会填充该字段。
- `"in_progress"`
@@ -1301,7 +1303,7 @@
- `call_id: optional string or null`
- 模型生成的工具搜索调用的唯一 ID。
+ 由模型生成的工具搜索调用的唯一 ID。
- `execution: optional "server" or "client"`
@@ -1329,19 +1331,19 @@
- `Function object { name, parameters, strict, 5 more }`
- 在你自己的代码中定义一个可供模型选择的函数。详细了解 [函数调用](https://platform.openai.com/docs/guides/function-calling).
+ 在你自己的代码中定义一个模型可以选择调用的函数。了解更多关于 [函数调用](https://platform.openai.com/docs/guides/function-calling).
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `parameters: map[unknown] or null`
- 描述函数参数的 JSON schema 对象。
+ 描述该函数参数的 JSON schema 对象。
- `strict: boolean or null`
- 是否对此函数工具强制执行严格的参数校验。
+ 是否对该函数工具强制执行严格的参数校验。
- `type: "function"`
@@ -1351,7 +1353,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -1359,41 +1361,41 @@
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过 tool search 加载。
+ 该函数是否被延迟加载,并通过工具搜索加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 对该函数的描述。由模型用于判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述此函数的字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。详细了解文件搜索 tool [文件搜索 tool](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的过滤器。
+ 要应用的筛选条件。
- `ComparisonFilter object { key, type, value }`
- 用于在指定的属性键与给定值之间使用定义的比较运算进行比较的过滤器。
+ 用于将指定属性键与给定值按定义比较运算进行比较的筛选条件。
- `key: string`
- 用于与值进行比较的键。
+ 要与值进行比较的键。
- `type: "eq" or "ne" or "gt" or 5 more`
@@ -1403,10 +1405,10 @@
- `ne`: 不等于
- `gt`: 大于
- `gte`: 大于或等于
- - `lt`: 小于
- - `lte`: 小于或等于
- - `in`: 包含
- - `nin`: 不包含
+ - `lt`:小于
+ - `lte`:小于等于
+ - `in`:包含于
+ - `nin`:不包含于
- `"eq"`
@@ -1442,15 +1444,15 @@
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个过滤器 `and` 或 `or`.
+ 使用以下方式组合多个筛选条件 `and` 或 `or`.
- `filters: array of ComparisonFilter or unknown`
- 要组合的过滤器数组。项可以是 `ComparisonFilter` 或 `CompoundFilter`.
+ 用于组合的筛选条件数组。数组项可以是 `ComparisonFilter` 或 `CompoundFilter`.
- `ComparisonFilter object { key, type, value }`
- 用于在指定的属性键与给定值之间使用定义的比较运算进行比较的过滤器。
+ 用于将指定属性键与给定值按定义比较运算进行比较的筛选条件。
- `unknown`
@@ -1464,7 +1466,7 @@
- `max_num_results: optional number`
- 返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
+ 要返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -1472,7 +1474,7 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 用于在启用混合搜索时,控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -1492,11 +1494,11 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1,尝试仅返回最相关的结果,但可能会返回更少的结果。
+ 文件搜索的评分阈值,介于 0 到 1 之间的一个数字。越接近 1 的数值会尝试仅返回最具相关性的结果,但返回的结果数量可能会更少。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。详细了解 [computer 工具](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
@@ -1506,7 +1508,7 @@
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。详细了解 [computer 工具](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -1532,18 +1534,18 @@
- `type: "computer_use_preview"`
- 计算机使用工具的类型。始终为 `computer_use_preview`.
+ computer use 工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
在互联网上搜索与提示相关的来源。详细了解
- [网页搜索 tool](/docs/guides/tools-web-search).
+ [网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索 工具的类型。可选值为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型。可选值为 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -1551,22 +1553,22 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 进行实时互联网访问。省略时默认为 true。当设置为 false 时,网页搜索 工具将以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索访问实时互联网。省略时默认为 true。当设为 false 时,网页搜索工具以离线/仅缓存模式运行,不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的过滤条件。
+ 搜索的筛选条件。
- `allowed_domains: optional array of string or null`
搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名同样允许。
+ 同时也允许所提供域名的子域名。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指引。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -1584,7 +1586,7 @@
- `country: optional string or null`
- 两个字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 用户的两字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
- `region: optional string or null`
@@ -1596,7 +1598,7 @@
- `type: optional "approximate"`
- 位置近似类型。始终为 `approximate`.
+ 位置近似的类型。始终为 `approximate`.
- `"approximate"`
@@ -1607,7 +1609,7 @@
- `server_label: string`
- 该 MCP 服务器的标签,用于在工具调用中识别它。
+ 此 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -1617,7 +1619,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -1625,48 +1627,48 @@
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许使用的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许使用的工具名称组成的字符串数组
+ 允许的工具名称的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许使用哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否为修改数据还是只读。如果某
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则将匹配此过滤器。
- `tool_names: optional array of string`
- 允许使用的工具名称列表。
+ 允许的工具名称列表。
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,可配合自定义
- MCP 服务器 URL 或服务连接器使用。你的应用程序
- 必须处理 OAuth 授权流程,并在此处提供令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,可以是
+ 配合自定义 MCP 服务器 URL 或服务连接器使用。你的应用
+ 必须处理 OAuth 授权流程并在此处提供令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的连接器。
- `server_url`, `connector_id`,或 `tunnel_id` 中的一个必须提供。了解更多
- 关于服务连接器的信息 [此处](/docs/guides/tools-remote-mcp#connectors).
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些。其中之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。了解更多
+ 关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
- 目前支持 `connector_id` 的值为:
+ 当前支持 `connector_id` 的值为:
- - Dropbox: `connector_dropbox`
- - Gmail: `connector_gmail`
- - Google Calendar: `connector_googlecalendar`
- - Google Drive: `connector_googledrive`
- - Microsoft Teams: `connector_microsoftteams`
- - Outlook Calendar: `connector_outlookcalendar`
- - Outlook Email: `connector_outlookemail`
- - SharePoint: `connector_sharepoint`
+ - Dropbox: `connector_dropbox`
+ - Gmail: `connector_gmail`
+ - Google Calendar: `connector_googlecalendar`
+ - Google Drive: `connector_googledrive`
+ - Microsoft Teams: `connector_microsoftteams`
+ - Outlook Calendar: `connector_outlookcalendar`
+ - Outlook Email: `connector_outlookemail`
+ - SharePoint: `connector_sharepoint`
- `"connector_dropbox"`
@@ -1686,56 +1688,56 @@
- `defer_loading: optional boolean`
- 此 MCP 工具是否为延迟加载并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务器的可选 HTTP 标头。用于身份验证
+ 发送到 MCP 服务端的可选 HTTP 标头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务器中哪些工具需要审批。
+ 指定 MCP 服务端的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务器中哪些工具需要审批。可以是
- `always`, `never`,也可以是与工具关联的过滤器对象
- 这些工具需要审批。
+ 指定 MCP 服务端的哪些工具需要审批。可以是
+ `always`, `never`,或与需要审批的工具关联的过滤器对象
+ 。
- `always: optional object { read_only, tool_names }`
- 用于指定允许使用哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否为修改数据还是只读。如果某
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则将匹配此过滤器。
- `tool_names: optional array of string`
- 允许使用的工具名称列表。
+ 允许的工具名称列表。
- `never: optional object { read_only, tool_names }`
- 用于指定允许使用哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否为修改数据还是只读。如果某
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则将匹配此过滤器。
- `tool_names: optional array of string`
- 允许使用的工具名称列表。
+ 允许的工具名称列表。
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值之一为 `always` 或
- `never`。当设置为 `always`,所有工具都将需要审批。当
- 设置为 `never`,所有工具都将不需要审批。
+ 为所有工具指定统一的审批策略。可选值为 `always` 或
+ `never`。当设置为 `always`,所有工具都需要审批。当
+ 设置为 `never`,所有工具都不需要审批。
- `"always"`
@@ -1747,22 +1749,22 @@
- `server_url: optional string`
- MCP 服务器的 URL。需要提供以下其中一项 `server_url`, `connector_id`,或
- `tunnel_id` 。
+ MCP 服务器的 URL。以下之一 `server_url`, `connector_id`,或
+ `tunnel_id` 必须提供。
- `tunnel_id: optional string`
- 用于代替直接服务器 URL 的安全 MCP 隧道 ID。需要提供以下其中一项
- `server_url`, `connector_id`,或 `tunnel_id` 。
+ 用于替代直接服务器 URL 的安全 MCP 隧道 ID。以下之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示的响应的工具。
+ 运行 Python 代码以帮助生成提示响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID 或指定可上传到你的代码中的文件 ID 以及
- 指定可提供给代码的上传文件 ID,以及
+ 代码解释器容器。可以是容器 ID 或指定
+ 可供代码使用的已上传文件 ID 以及
可选的 `memory_limit` 设置的对象。
- `string`
@@ -1781,7 +1783,7 @@
- `file_ids: optional array of string`
- 提供给代码的可选上传文件列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -1811,17 +1813,17 @@
- `allowed_domains: array of string`
- 当 type 为 `allowlist`.
+ 当类型为时的允许域名列表 `allowlist`.
- `type: "allowlist"`
- 仅允许对指定域进行出站网络访问。固定为 `allowlist`.
+ 仅允许向指定域进行出站网络访问。始终为 `allowlist`.
- `"allowlist"`
- `domain_secrets: optional array of ContainerNetworkPolicyDomainSecret`
- 允许列表中域的可选域作用域密钥。
+ 允许列表中各域的可选域作用域密钥。
- `domain: string`
@@ -1829,21 +1831,21 @@
- `name: string`
- 为该域注入的密钥名称。
+ 要为该域注入的密钥名称。
- `value: string`
- 为该域注入的密钥值。
+ 要为该域注入的密钥值。
- `type: "code_interpreter"`
- 代码解释器工具的类型。固定为 `code_interpreter`.
+ 代码解释器工具的类型。始终为 `code_interpreter`.
- `"code_interpreter"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -1853,7 +1855,7 @@
- `type: "programmatic_tool_calling"`
- 工具的类型。固定为 `programmatic_tool_calling`.
+ 工具的类型。始终为 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
@@ -1863,13 +1865,13 @@
- `type: "image_generation"`
- 图像生成工具的类型。固定为 `image_generation`.
+ 图像生成工具的类型。始终为 `image_generation`.
- `"image_generation"`
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 生成新图像还是编辑现有图像。默认值: `auto`.
- `"generate"`
@@ -1880,9 +1882,9 @@
- `background: optional "transparent" or "opaque" or "auto"`
设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。之一。支持透明背景的
- GPT 图像模型可用。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该功能处于预览阶段。使用
+ `opaque`,或 `auto`。之一。透明背景可用于受支持的
+ GPT 图像模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
`transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -1893,7 +1895,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。仅 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不支持 `gpt-image-1-mini`。支持 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需付出的努力程度。此参数仅在 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型中受支持,在 `gpt-image-1-mini`。中不受支持。支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -1901,7 +1903,7 @@
- `input_image_mask: optional object { file_id, image_url }`
- 可选的修复蒙版。包含 `image_url`
+ 用于修复的可选蒙版。包含 `image_url`
(string, optional) 和 `file_id` (string, optional)。
- `file_id: optional string`
@@ -1980,13 +1982,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定的任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 支持用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。关于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式表示的任意分辨率,例如 `WIDTHxHEIGHT` 宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `1536x864`。属于实验性功能,且最大支持的分辨率为 `2560x1440` 。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `3840x2160`。受 GPT image 模型支持; `1024x1024`, `1536x1024`,和 `1024x1536` 受允许自动调整大小的模型支持。对于; `auto` ,受允许自动调整大小的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定的任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 支持用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。关于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式表示的任意分辨率,例如 `WIDTHxHEIGHT` 宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `1536x864`。属于实验性功能,且最大支持的分辨率为 `2560x1440` 。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `3840x2160`。受 GPT image 模型支持; `1024x1024`, `1536x1024`,和 `1024x1536` 受允许自动调整大小的模型支持。对于; `auto` ,受允许自动调整大小的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -2018,7 +2020,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -2030,13 +2032,13 @@
- `type: "container_auto"`
- 自动为本次请求创建一个容器
+ 自动为此请求创建一个容器
- `"container_auto"`
- `file_ids: optional array of string`
- 提供给代码的可选上传文件列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -2090,7 +2092,7 @@
- `source: InlineSkillSource`
- 内联技能载荷
+ 内联技能负载
- `data: string`
@@ -2098,19 +2100,19 @@
- `media_type: "application/zip"`
- 内联技能载荷的媒体类型。必须为 `application/zip`.
+ 内联技能负载的媒体类型。必须为 `application/zip`.
- `"application/zip"`
- `type: "base64"`
- 内联技能来源的类型。必须为 `base64`.
+ 内联技能源的类型。必须为 `base64`.
- `"base64"`
- `type: "inline"`
- 为本次请求定义一个内联技能。
+ 为此请求定义一个内联技能。
- `"inline"`
@@ -2136,7 +2138,7 @@
- `path: string`
- 包含技能的目录路径。
+ 包含该技能的目录路径。
- `ContainerReference object { container_id, type }`
@@ -2160,13 +2162,13 @@
- `type: "custom"`
- 自定义工具的类型。始终为 `custom`.
+ 自定义工具的类型,始终为 `custom`.
- `"custom"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -2174,7 +2176,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索来发现它。
+ 此工具是否应该被延迟并通过工具搜索发现。
- `description: optional string`
@@ -2182,21 +2184,21 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `Text object { type }`
- 不受约束的自由格式文本。
+ 无约束的自由格式文本。
- `type: "text"`
- 不受约束的文本格式。始终为 `text`.
+ 无约束文本格式,始终为 `text`.
- `"text"`
- `Grammar object { definition, syntax, type }`
- 用户定义的语法。
+ 由用户定义的语法。
- `definition: string`
@@ -2204,7 +2206,7 @@
- `syntax: "lark" or "regex"`
- 语法定义的语法格式。可选值为 `lark` 或 `regex`.
+ 语法定义的语法格式。取值为 `lark` 或 `regex`.
- `"lark"`
@@ -2212,7 +2214,7 @@
- `type: "grammar"`
- 语法格式。始终为 `grammar`.
+ 语法格式,始终为 `grammar`.
- `"grammar"`
@@ -2230,7 +2232,7 @@
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的 function/custom 工具。
+ 此命名空间内可用的 function/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -2242,7 +2244,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -2250,19 +2252,19 @@
- `defer_loading: optional boolean`
- 该 function 是否应被延迟并通过工具搜索发现。
+ 此 function 是否应被延迟并通过 tool search 发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 描述该 function 工具的字符串输出中所编码 JSON 值的 JSON Schema。这并不描述 content 数组形式的输出。
+ 描述此 function 工具的字符串输出中所编码的 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。若未指定,Responses 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制启用严格的参数校验。若省略,Responses 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -2274,13 +2276,13 @@
- `type: "custom"`
- 自定义工具的类型。始终为 `custom`.
+ 自定义工具的类型,始终为 `custom`.
- `"custom"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -2288,7 +2290,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索来发现它。
+ 此工具是否应该被延迟并通过工具搜索发现。
- `description: optional string`
@@ -2296,31 +2298,31 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `type: "namespace"`
- 工具的类型。固定为 `namespace`.
+ 工具的类型。始终为 `namespace`.
- `"namespace"`
- `ToolSearch object { type, description, execution, parameters }`
- 延迟工具的托管或 BYOT 工具搜索配置。
+ 用于延迟工具的 hosted 或 BYOT tool search 配置。
- `type: "tool_search"`
- 工具的类型。固定为 `tool_search`.
+ 工具的类型。始终为 `tool_search`.
- `"tool_search"`
- `description: optional string or null`
- 向模型展示的、用于客户端执行的工具搜索工具的描述。
+ 展示给模型的、针对客户端执行的 tool search 工具的描述。
- `execution: optional "server" or "client"`
- 工具搜索是由服务端执行还是由客户端执行。
+ tool search 由服务端执行还是由客户端执行。
- `"server"`
@@ -2328,15 +2330,15 @@
- `parameters: optional unknown or null`
- 客户端执行的工具搜索工具的参数 schema。
+ 针对客户端执行的 tool search 工具的参数 schema。
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具会搜索网页以获取用于回复的相关结果。了解更多关于 [网页搜索 tool](https://platform.openai.com/docs/guides/tools-web-search).
+ 此工具会在网络上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索 工具的类型。可选值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型。可选值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -2350,7 +2352,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指引。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -2364,7 +2366,7 @@
- `type: "approximate"`
- 位置近似类型。始终为 `approximate`.
+ 位置近似的类型。始终为 `approximate`.
- `"approximate"`
@@ -2374,7 +2376,7 @@
- `country: optional string or null`
- 两个字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 用户的两字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
- `region: optional string or null`
@@ -2390,13 +2392,13 @@
- `type: "apply_patch"`
- 工具的类型。固定为 `apply_patch`.
+ 工具的类型。始终为 `apply_patch`.
- `"apply_patch"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -2410,11 +2412,11 @@
- `id: optional string or null`
- 此工具搜索输出的唯一 ID。
+ 此 tool search 输出的唯一 ID。
- `call_id: optional string or null`
- 模型生成的工具搜索调用的唯一 ID。
+ 由模型生成的工具搜索调用的唯一 ID。
- `execution: optional "server" or "client"`
@@ -2426,7 +2428,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 工具搜索输出的状态。
+ tool search 输出的状态。
- `"in_progress"`
@@ -2444,23 +2446,23 @@
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目中提供的额外工具列表。
+ 在此项中可用的额外工具列表。
- `Function object { name, parameters, strict, 5 more }`
- 在你自己的代码中定义一个可供模型选择的函数。详细了解 [函数调用](https://platform.openai.com/docs/guides/function-calling).
+ 在你自己的代码中定义一个模型可以选择调用的函数。了解更多关于 [函数调用](https://platform.openai.com/docs/guides/function-calling).
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `parameters: map[unknown] or null`
- 描述函数参数的 JSON schema 对象。
+ 描述该函数参数的 JSON schema 对象。
- `strict: boolean or null`
- 是否对此函数工具强制执行严格的参数校验。
+ 是否对该函数工具强制执行严格的参数校验。
- `type: "function"`
@@ -2470,7 +2472,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -2478,45 +2480,45 @@
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过 tool search 加载。
+ 该函数是否被延迟加载,并通过工具搜索加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 对该函数的描述。由模型用于判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述此函数的字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。详细了解文件搜索 tool [文件搜索 tool](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的过滤器。
+ 要应用的筛选条件。
- `ComparisonFilter object { key, type, value }`
- 用于在指定的属性键与给定值之间使用定义的比较运算进行比较的过滤器。
+ 用于将指定属性键与给定值按定义比较运算进行比较的筛选条件。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个过滤器 `and` 或 `or`.
+ 使用以下方式组合多个筛选条件 `and` 或 `or`.
- `max_num_results: optional number`
- 返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
+ 要返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -2524,7 +2526,7 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 用于在启用混合搜索时,控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -2544,11 +2546,11 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1,尝试仅返回最相关的结果,但可能会返回更少的结果。
+ 文件搜索的评分阈值,介于 0 到 1 之间的一个数字。越接近 1 的数值会尝试仅返回最具相关性的结果,但返回的结果数量可能会更少。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。详细了解 [computer 工具](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
@@ -2558,7 +2560,7 @@
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。详细了解 [computer 工具](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -2584,18 +2586,18 @@
- `type: "computer_use_preview"`
- 计算机使用工具的类型。始终为 `computer_use_preview`.
+ computer use 工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
在互联网上搜索与提示相关的来源。详细了解
- [网页搜索 tool](/docs/guides/tools-web-search).
+ [网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索 工具的类型。可选值为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型。可选值为 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -2603,22 +2605,22 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 进行实时互联网访问。省略时默认为 true。当设置为 false 时,网页搜索 工具将以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索访问实时互联网。省略时默认为 true。当设为 false 时,网页搜索工具以离线/仅缓存模式运行,不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的过滤条件。
+ 搜索的筛选条件。
- `allowed_domains: optional array of string or null`
搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名同样允许。
+ 同时也允许所提供域名的子域名。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指引。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -2636,7 +2638,7 @@
- `country: optional string or null`
- 两个字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 用户的两字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
- `region: optional string or null`
@@ -2648,7 +2650,7 @@
- `type: optional "approximate"`
- 位置近似类型。始终为 `approximate`.
+ 位置近似的类型。始终为 `approximate`.
- `"approximate"`
@@ -2659,7 +2661,7 @@
- `server_label: string`
- 该 MCP 服务器的标签,用于在工具调用中识别它。
+ 此 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -2669,7 +2671,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -2677,48 +2679,48 @@
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许使用的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许使用的工具名称组成的字符串数组
+ 允许的工具名称的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许使用哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否为修改数据还是只读。如果某
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则将匹配此过滤器。
- `tool_names: optional array of string`
- 允许使用的工具名称列表。
+ 允许的工具名称列表。
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,可配合自定义
- MCP 服务器 URL 或服务连接器使用。你的应用程序
- 必须处理 OAuth 授权流程,并在此处提供令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,可以是
+ 配合自定义 MCP 服务器 URL 或服务连接器使用。你的应用
+ 必须处理 OAuth 授权流程并在此处提供令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的连接器。
- `server_url`, `connector_id`,或 `tunnel_id` 中的一个必须提供。了解更多
- 关于服务连接器的信息 [此处](/docs/guides/tools-remote-mcp#connectors).
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些。其中之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。了解更多
+ 关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
- 目前支持 `connector_id` 的值为:
+ 当前支持 `connector_id` 的值为:
- - Dropbox: `connector_dropbox`
- - Gmail: `connector_gmail`
- - Google Calendar: `connector_googlecalendar`
- - Google Drive: `connector_googledrive`
- - Microsoft Teams: `connector_microsoftteams`
- - Outlook Calendar: `connector_outlookcalendar`
- - Outlook Email: `connector_outlookemail`
- - SharePoint: `connector_sharepoint`
+ - Dropbox: `connector_dropbox`
+ - Gmail: `connector_gmail`
+ - Google Calendar: `connector_googlecalendar`
+ - Google Drive: `connector_googledrive`
+ - Microsoft Teams: `connector_microsoftteams`
+ - Outlook Calendar: `connector_outlookcalendar`
+ - Outlook Email: `connector_outlookemail`
+ - SharePoint: `connector_sharepoint`
- `"connector_dropbox"`
@@ -2738,56 +2740,56 @@
- `defer_loading: optional boolean`
- 此 MCP 工具是否为延迟加载并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务器的可选 HTTP 标头。用于身份验证
+ 发送到 MCP 服务端的可选 HTTP 标头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务器中哪些工具需要审批。
+ 指定 MCP 服务端的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务器中哪些工具需要审批。可以是
- `always`, `never`,也可以是与工具关联的过滤器对象
- 这些工具需要审批。
+ 指定 MCP 服务端的哪些工具需要审批。可以是
+ `always`, `never`,或与需要审批的工具关联的过滤器对象
+ 。
- `always: optional object { read_only, tool_names }`
- 用于指定允许使用哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否为修改数据还是只读。如果某
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则将匹配此过滤器。
- `tool_names: optional array of string`
- 允许使用的工具名称列表。
+ 允许的工具名称列表。
- `never: optional object { read_only, tool_names }`
- 用于指定允许使用哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否为修改数据还是只读。如果某
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则将匹配此过滤器。
- `tool_names: optional array of string`
- 允许使用的工具名称列表。
+ 允许的工具名称列表。
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值之一为 `always` 或
- `never`。当设置为 `always`,所有工具都将需要审批。当
- 设置为 `never`,所有工具都将不需要审批。
+ 为所有工具指定统一的审批策略。可选值为 `always` 或
+ `never`。当设置为 `always`,所有工具都需要审批。当
+ 设置为 `never`,所有工具都不需要审批。
- `"always"`
@@ -2799,22 +2801,22 @@
- `server_url: optional string`
- MCP 服务器的 URL。需要提供以下其中一项 `server_url`, `connector_id`,或
- `tunnel_id` 。
+ MCP 服务器的 URL。以下之一 `server_url`, `connector_id`,或
+ `tunnel_id` 必须提供。
- `tunnel_id: optional string`
- 用于代替直接服务器 URL 的安全 MCP 隧道 ID。需要提供以下其中一项
- `server_url`, `connector_id`,或 `tunnel_id` 。
+ 用于替代直接服务器 URL 的安全 MCP 隧道 ID。以下之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示的响应的工具。
+ 运行 Python 代码以帮助生成提示响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID 或指定可上传到你的代码中的文件 ID 以及
- 指定可提供给代码的上传文件 ID,以及
+ 代码解释器容器。可以是容器 ID 或指定
+ 可供代码使用的已上传文件 ID 以及
可选的 `memory_limit` 设置的对象。
- `string`
@@ -2833,7 +2835,7 @@
- `file_ids: optional array of string`
- 提供给代码的可选上传文件列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -2857,13 +2859,13 @@
- `type: "code_interpreter"`
- 代码解释器工具的类型。固定为 `code_interpreter`.
+ 代码解释器工具的类型。始终为 `code_interpreter`.
- `"code_interpreter"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -2873,7 +2875,7 @@
- `type: "programmatic_tool_calling"`
- 工具的类型。固定为 `programmatic_tool_calling`.
+ 工具的类型。始终为 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
@@ -2883,13 +2885,13 @@
- `type: "image_generation"`
- 图像生成工具的类型。固定为 `image_generation`.
+ 图像生成工具的类型。始终为 `image_generation`.
- `"image_generation"`
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 生成新图像还是编辑现有图像。默认值: `auto`.
- `"generate"`
@@ -2900,9 +2902,9 @@
- `background: optional "transparent" or "opaque" or "auto"`
设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。之一。支持透明背景的
- GPT 图像模型可用。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该功能处于预览阶段。使用
+ `opaque`,或 `auto`。之一。透明背景可用于受支持的
+ GPT 图像模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
`transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -2913,7 +2915,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。仅 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不支持 `gpt-image-1-mini`。支持 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需付出的努力程度。此参数仅在 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型中受支持,在 `gpt-image-1-mini`。中不受支持。支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -2921,7 +2923,7 @@
- `input_image_mask: optional object { file_id, image_url }`
- 可选的修复蒙版。包含 `image_url`
+ 用于修复的可选蒙版。包含 `image_url`
(string, optional) 和 `file_id` (string, optional)。
- `file_id: optional string`
@@ -3000,13 +3002,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定的任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 支持用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。关于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式表示的任意分辨率,例如 `WIDTHxHEIGHT` 宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `1536x864`。属于实验性功能,且最大支持的分辨率为 `2560x1440` 。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `3840x2160`。受 GPT image 模型支持; `1024x1024`, `1536x1024`,和 `1024x1536` 受允许自动调整大小的模型支持。对于; `auto` ,受允许自动调整大小的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定的任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 支持用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。关于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式表示的任意分辨率,例如 `WIDTHxHEIGHT` 宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `1536x864`。属于实验性功能,且最大支持的分辨率为 `2560x1440` 。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `3840x2160`。受 GPT image 模型支持; `1024x1024`, `1536x1024`,和 `1024x1536` 受允许自动调整大小的模型支持。对于; `auto` ,受允许自动调整大小的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -3038,7 +3040,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -3062,13 +3064,13 @@
- `type: "custom"`
- 自定义工具的类型。始终为 `custom`.
+ 自定义工具的类型,始终为 `custom`.
- `"custom"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -3076,7 +3078,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索来发现它。
+ 此工具是否应该被延迟并通过工具搜索发现。
- `description: optional string`
@@ -3084,7 +3086,7 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `Namespace object { description, name, tools, type }`
@@ -3100,7 +3102,7 @@
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的 function/custom 工具。
+ 此命名空间内可用的 function/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -3112,7 +3114,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -3120,19 +3122,19 @@
- `defer_loading: optional boolean`
- 该 function 是否应被延迟并通过工具搜索发现。
+ 此 function 是否应被延迟并通过 tool search 发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 描述该 function 工具的字符串输出中所编码 JSON 值的 JSON Schema。这并不描述 content 数组形式的输出。
+ 描述此 function 工具的字符串输出中所编码的 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。若未指定,Responses 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制启用严格的参数校验。若省略,Responses 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -3144,13 +3146,13 @@
- `type: "custom"`
- 自定义工具的类型。始终为 `custom`.
+ 自定义工具的类型,始终为 `custom`.
- `"custom"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -3158,7 +3160,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索来发现它。
+ 此工具是否应该被延迟并通过工具搜索发现。
- `description: optional string`
@@ -3166,31 +3168,31 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `type: "namespace"`
- 工具的类型。固定为 `namespace`.
+ 工具的类型。始终为 `namespace`.
- `"namespace"`
- `ToolSearch object { type, description, execution, parameters }`
- 延迟工具的托管或 BYOT 工具搜索配置。
+ 用于延迟工具的 hosted 或 BYOT tool search 配置。
- `type: "tool_search"`
- 工具的类型。固定为 `tool_search`.
+ 工具的类型。始终为 `tool_search`.
- `"tool_search"`
- `description: optional string or null`
- 向模型展示的、用于客户端执行的工具搜索工具的描述。
+ 展示给模型的、针对客户端执行的 tool search 工具的描述。
- `execution: optional "server" or "client"`
- 工具搜索是由服务端执行还是由客户端执行。
+ tool search 由服务端执行还是由客户端执行。
- `"server"`
@@ -3198,15 +3200,15 @@
- `parameters: optional unknown or null`
- 客户端执行的工具搜索工具的参数 schema。
+ 针对客户端执行的 tool search 工具的参数 schema。
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具会搜索网页以获取用于回复的相关结果。了解更多关于 [网页搜索 tool](https://platform.openai.com/docs/guides/tools-web-search).
+ 此工具会在网络上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索 工具的类型。可选值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型。可选值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -3220,7 +3222,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指引。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -3234,7 +3236,7 @@
- `type: "approximate"`
- 位置近似类型。始终为 `approximate`.
+ 位置近似的类型。始终为 `approximate`.
- `"approximate"`
@@ -3244,7 +3246,7 @@
- `country: optional string or null`
- 两个字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 用户的两字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
- `region: optional string or null`
@@ -3260,13 +3262,13 @@
- `type: "apply_patch"`
- 工具的类型。固定为 `apply_patch`.
+ 工具的类型。始终为 `apply_patch`.
- `"apply_patch"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -3284,9 +3286,9 @@
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成回复时所用思维链的描述。请务必在向
- 发送的请求中包含这些条目 `input` :Responses API
- 如果你需要手动管理上下文,用于对话的后续轮次
+ 对推理模型在生成
+ 回复时所使用的思维链的描述。请务必将这些条目包含在你的 `input` 请求中并发送给 Responses API
+ 用于对话的后续轮次,如果你正在手动
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -3299,7 +3301,7 @@
- `text: string`
- 模型到目前为止的推理输出摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -3319,7 +3321,7 @@
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -3329,20 +3331,20 @@
- `encrypted_content: optional string or null`
- 推理项的加密内容。默认情况下会填充此字段
- 针对由以下接口返回的推理项 `POST /v1/responses` 和 WebSocket
+ 推理项的加密内容。默认情况下会填充该字段
+ 适用于由以下方式返回的推理项 `POST /v1/responses` 和 WebSocket
`response.create` 请求。
- 流式传输时,使用已完成的推理项及其
- `encrypted_content` 来自 `response.output_item.done` 事件,于
- 后续请求中使用。其中 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。这在以下情况下尤为重要:
- 当 `store` 时 `false` 或在使用 Zero Data Retention 时。
+ 流式传输时,请在后续请求中使用已完成的推理项及其
+ `encrypted_content` 中的 `response.output_item.done` 事件
+ 。在后续请求中, `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在以下情况时尤其重要
+ 当 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。其一为 `in_progress`, `completed`,或
- `incomplete`。当通过 API 返回项目时会填充此字段。
+ 条目的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回条目时会填充该字段。
- `"in_progress"`
@@ -3352,7 +3354,7 @@
- `Compaction object { encrypted_content, type, id }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `encrypted_content: string`
@@ -3417,7 +3419,7 @@
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果没有可用输出,可能为 null。
+ 如果没有可用的输出,可以为 null。
- `Logs object { logs, type }`
@@ -3469,7 +3471,7 @@
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -3495,19 +3497,19 @@
- `timeout_ms: optional number or null`
- 命令的可选超时(毫秒)。
+ 命令的可选超时时间(毫秒)。
- `user: optional string or null`
- 运行命令时使用的可选用户。
+ 用于运行命令的可选用户。
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 由模型生成的本地 shell 工具调用的唯一 ID。
+ 模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -3531,7 +3533,7 @@
- `id: string`
- 由模型生成的本地 shell 工具调用的唯一 ID。
+ 模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -3545,7 +3547,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。其一为 `in_progress`, `completed`,或 `incomplete`.
+ 条目的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -3555,23 +3557,23 @@
- `ShellCall object { action, call_id, type, 4 more }`
- 表示执行一个或多个 shell 命令请求的工具。
+ 表示执行一条或多条 shell 命令请求的工具。
- `action: object { commands, max_output_length, timeout_ms }`
- 用于描述如何运行该工具调用的 shell 命令和限制。
+ 描述如何运行该工具调用的 shell 命令和限制。
- `commands: array of string`
- 执行环境要按顺序运行的 shell 命令。
+ 供执行环境运行的 shell 命令序列。
- `max_output_length: optional number or null`
- 从合并后的 stdout 和 stderr 输出中捕获的最大 UTF-8 字符数。
+ 从合并的 stdout 和 stderr 输出中捕获的最大 UTF-8 字符数。
- `timeout_ms: optional number or null`
- 允许 shell 命令运行的最长墙上时钟时间(毫秒)。
+ 允许 shell 命令运行的最大挂钟时间(毫秒)。
- `call_id: string`
@@ -3585,11 +3587,11 @@
- `id: optional string or null`
- shell 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
+ shell 工具调用的唯一 ID。通过 API 返回该条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
- 产生此工具调用的执行上下文。
+ 生成此工具调用的执行上下文。
- `Direct object { type }`
@@ -3603,7 +3605,7 @@
- `caller_id: string`
- 产生此工具调用的程序项的调用 ID。
+ 生成此工具调用的程序项的调用 ID。
- `type: "program"`
@@ -3613,7 +3615,7 @@
- `environment: optional LocalEnvironment or ContainerReference or null`
- 用于执行 shell 命令的环境。
+ 执行 shell 命令的环境。
- `LocalEnvironment object { type, skills }`
@@ -3621,7 +3623,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- shell 调用的状态。值为 `in_progress`, `completed`,或 `incomplete`.
+ shell 调用的状态。取值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -3631,7 +3633,7 @@
- `ShellCallOutput object { call_id, output, type, 4 more }`
- 由 shell 工具调用发出的流式输出 item。
+ shell 工具调用发出的流式输出项。
- `call_id: string`
@@ -3639,7 +3641,7 @@
- `output: array of ResponseFunctionShellCallOutputContent`
- 已捕获的 stdout 和 stderr 输出块及其关联的结果。
+ 捕获的 stdout 和 stderr 输出块及其相关结果。
- `outcome: object { type } or object { exit_code, type }`
@@ -3647,7 +3649,7 @@
- `Timeout object { type }`
- 表示 shell 调用超出了其配置的时间限制。
+ 表示 shell 调用超过了其配置的时间限制。
- `type: "timeout"`
@@ -3657,7 +3659,7 @@
- `Exit object { exit_code, type }`
- 表示 shell 命令已执行完毕并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -3671,11 +3673,11 @@
- `stderr: string`
- 为该 shell 调用捕获的 stderr 输出。
+ 为该 shell 调用捕获的 stderr。
- `stdout: string`
- 为该 shell 调用捕获的 stdout 输出。
+ 为该 shell 调用捕获的 stdout。
- `type: "shell_call_output"`
@@ -3685,11 +3687,11 @@
- `id: optional string or null`
- shell 工具调用输出的唯一 ID。当此 item 通过 API 返回时填充。
+ shell 工具调用输出的唯一 ID。通过 API 返回该条目时填充。
- `caller: optional object { type } or object { caller_id, type } or null`
- 产生此工具调用的执行上下文。
+ 生成此工具调用的执行上下文。
- `Direct object { type }`
@@ -3703,7 +3705,7 @@
- `caller_id: string`
- 产生此工具调用的程序项的调用 ID。
+ 生成此工具调用的程序项的调用 ID。
- `type: "program"`
@@ -3713,7 +3715,7 @@
- `max_output_length: optional number or null`
- 为该 shell 调用合并输出所捕获的最大 UTF-8 字符数。
+ 为该 shell 调用合并输出捕获的最大 UTF-8 字符数。
- `status: optional "in_progress" or "completed" or "incomplete" or null`
@@ -3727,11 +3729,11 @@
- `ApplyPatchCall object { call_id, operation, status, 3 more }`
- 表示通过差异补丁创建、删除或更新文件的工具调用。
+ 一个工具调用,表示通过 diff 补丁创建、删除或更新文件的请求。
- `call_id: string`
- 模型生成的 apply patch 工具调用的唯一 ID。
+ 由模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
@@ -3743,7 +3745,7 @@
- `diff: string`
- 创建文件时要应用的统一差异内容。
+ 创建文件时要应用的 unified diff 内容。
- `path: string`
@@ -3775,7 +3777,7 @@
- `diff: string`
- 要对现有文件应用的统一差异内容。
+ 要应用到现有文件的 unified diff 内容。
- `path: string`
@@ -3789,7 +3791,7 @@
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。可选值为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取以下值之一: `in_progress` 或 `completed`.
- `"in_progress"`
@@ -3807,7 +3809,7 @@
- `caller: optional object { type } or object { caller_id, type } or null`
- 产生此工具调用的执行上下文。
+ 生成此工具调用的执行上下文。
- `Direct object { type }`
@@ -3821,7 +3823,7 @@
- `caller_id: string`
- 产生此工具调用的程序项的调用 ID。
+ 生成此工具调用的程序项的调用 ID。
- `type: "program"`
@@ -3831,15 +3833,15 @@
- `ApplyPatchCallOutput object { call_id, status, type, 3 more }`
- apply patch 工具调用发出的流式输出。
+ 由 apply patch 工具调用产生的流式输出。
- `call_id: string`
- 模型生成的 apply patch 工具调用的唯一 ID。
+ 由模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。可选值为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取以下值之一: `completed` 或 `failed`.
- `"completed"`
@@ -3857,7 +3859,7 @@
- `caller: optional object { type } or object { caller_id, type } or null`
- 产生此工具调用的执行上下文。
+ 生成此工具调用的执行上下文。
- `Direct object { type }`
@@ -3871,7 +3873,7 @@
- `caller_id: string`
- 产生此工具调用的程序项的调用 ID。
+ 生成此工具调用的程序项的调用 ID。
- `type: "program"`
@@ -3881,11 +3883,11 @@
- `output: optional string or null`
- apply patch 工具的可读日志文本(例如补丁结果或错误)。
+ apply patch 工具返回的可选人类可读日志文本(例如补丁结果或错误)。
- `McpListTools object { id, server_label, tools, 2 more }`
- MCP 服务器上可用工具的列表。
+ MCP 服务器上可用的工具列表。
- `id: string`
@@ -3909,7 +3911,7 @@
- `annotations: optional unknown or null`
- 关于该工具的附加注释。
+ 有关该工具的其他注解。
- `description: optional string or null`
@@ -3923,11 +3925,11 @@
- `error: optional string or null`
- 如果服务器无法列出工具,则返回错误消息。
+ 当服务器无法列出工具时的错误消息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 对工具调用的人工审批请求。
+ 对一次工具调用的人工审批请求。
- `id: string`
@@ -3935,7 +3937,7 @@
- `arguments: string`
- 该工具参数的 JSON 字符串。
+ 传给该工具的参数,JSON 字符串形式。
- `name: string`
@@ -3953,7 +3955,7 @@
- `McpApprovalResponse object { approval_request_id, approve, type, 2 more }`
- 对 MCP 审批请求的响应。
+ 对一次 MCP 审批请求的响应。
- `approval_request_id: string`
@@ -3961,7 +3963,7 @@
- `approve: boolean`
- 请求是否已批准。
+ 该请求是否已批准。
- `type: "mcp_approval_response"`
@@ -3979,15 +3981,15 @@
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对一次工具的调用。
- `id: string`
- 工具调用的唯一 ID。
+ 该工具调用的唯一 ID。
- `arguments: string`
- 传递给该工具的参数的 JSON 字符串。
+ 传给该工具的参数,JSON 字符串形式。
- `name: string`
@@ -4046,7 +4048,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
+ 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -4060,11 +4062,11 @@
- `CustomToolCallOutput object { call_id, output, type, 2 more }`
- 由你的代码生成的自定义工具调用输出,将发送回模型。
+ 由你的代码生成的自定义工具调用输出,将被发回给模型。
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用的输出映射到相应的自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -4073,23 +4075,23 @@
- `StringOutput = string`
- 自定义工具调用的输出字符串。
+ 自定义工具调用输出的字符串。
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 自定义工具调用的文本、图片或文件输出。
+ 自定义工具调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- 发送给模型的文本输入。
+ 提供给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
+ 提供给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
- 发送给模型的输入文件。
+ 发送到模型的输入文件。
- `type: "custom_tool_call_output"`
@@ -4099,11 +4101,11 @@
- `id: optional string`
- 在 OpenAI 平台中该自定义工具调用输出的唯一 ID。
+ 在 OpenAI 平台上自定义工具调用输出的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
- 产生此工具调用的执行上下文。
+ 生成此工具调用的执行上下文。
- `Direct object { type }`
@@ -4117,7 +4119,7 @@
- `caller_id: string`
- 产生此工具调用的程序项的调用 ID。
+ 生成此工具调用的程序项的调用 ID。
- `type: "program"`
@@ -4127,7 +4129,7 @@
- `CustomToolCall object { call_id, input, name, 4 more }`
- 由模型创建的对自定义工具的调用。
+ 对模型创建的自定义工具的调用。
- `call_id: string`
@@ -4139,7 +4141,7 @@
- `name: string`
- 正在调用的自定义工具的名称。
+ 被调用的自定义工具的名称。
- `type: "custom_tool_call"`
@@ -4149,11 +4151,11 @@
- `id: optional string`
- 该自定义工具调用在 OpenAI 平台上的唯一 ID。
+ OpenAI 平台上此自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
- 产生此工具调用的执行上下文。
+ 生成此工具调用的执行上下文。
- `Direct object { type }`
@@ -4165,7 +4167,7 @@
- `caller_id: string`
- 产生此工具调用的程序项的调用 ID。
+ 生成此工具调用的程序项的调用 ID。
- `type: "program"`
@@ -4177,7 +4179,7 @@
- `CompactionTrigger object { type, id }`
- 压缩当前上下文。必须是最后一个输入项。
+ 压缩当前上下文。必须是最后一项输入项。
- `type: "compaction_trigger"`
@@ -4191,15 +4193,15 @@
- `ItemReference object { id, type }`
- 用于引用某个项目的内部标识符。
+ 用于引用某个条目的内部标识符。
- `id: string`
- 要引用的项目的 ID。
+ 要引用的条目的 ID。
- `type: optional "item_reference" or null`
- 要引用的项目类型。始终为 `item_reference`.
+ 要引用的条目的类型。始终为 `item_reference`.
- `"item_reference"`
@@ -4207,11 +4209,11 @@
- `id: string`
- 该程序项的唯一 ID。
+ 此程序项的唯一 ID。
- `call_id: string`
- 该程序项的稳定调用 ID。
+ 程序项的稳定调用 ID。
- `code: string`
@@ -4231,19 +4233,19 @@
- `id: string`
- 该程序输出项的唯一 ID。
+ 此程序输出项的唯一 ID。
- `call_id: string`
- 该程序项的调用 ID。
+ 程序项的调用 ID。
- `result: string`
- 由该程序项生成的结果。
+ 由程序项产生的结果。
- `status: "completed" or "incomplete"`
- 该程序输出的最终状态。
+ 程序输出的终止状态。
- `"completed"`
@@ -4257,18 +4259,18 @@
- `metadata: Metadata or null`
- 可以附加到对象的 16 组键值对。这可以
- 用于以结构化格式存储关于对象的附加信息,
+ 可附加到对象的 16 个键值对集合。可用于
+ 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
格式,以及通过 API 或控制台查询对象。
- 键是字符串,最大长度为 64 个字符。值是字符串
- 最大长度为 512 个字符。
+ 键为字符串,最长 64 个字符。值为字符串
+ 最长 512 个字符。
- `model: ResponsesModel`
用于生成响应的模型 ID,例如 `gpt-5.6-sol`. OpenAI
- 提供多种模型,这些模型在能力、性能
- 特征和价格上各不相同。请参阅 [模型指南](/docs/models)
+ 提供多种模型,具有不同的能力、性能
+ 特征和价格点。请参阅 [模型指南](/docs/models)
以浏览和比较可用的模型。
- `string`
@@ -4483,7 +4485,7 @@
- `object: "response"`
- 此资源的对象类型 - 始终设置为 `response`.
+ 此资源的对象类型——始终设置为 `response`.
- `"response"`
@@ -4491,21 +4493,21 @@
模型生成的内容项数组。
- - 该数组中项的长度和顺序取决于 `output` 数组取决于
+ - 该数组中项的长度和顺序取决于 `output` 模型的响应。
模型的响应。
- - 与其访问该数组的第一项并 `output` 假设它是
- 包含模型生成内容的 `assistant` 消息,不如考虑使用
- 属性(在支持的 `output_text` 属性,其中
- 在 SDK 中受支持)。
+ - 你可以考虑不直接访问数组中的第一项, `output` 并假设它是一
+ 条包含模型生成内容的 `assistant` 消息,而是使用 开发工具包 中支持的
+ 属性(如该属性在 `output_text` 开发工具包 中受支持)
+ 。SDKs.
- `ResponseOutputMessage object { id, content, role, 3 more }`
- 来自模型的输出消息。
+ 模型输出的一条消息。
- `FileSearchCall object { id, queries, status, 2 more }`
- 文件搜索 工具调用的结果。请参阅
- [文件搜索 指南](/docs/guides/tools-file-search) 。
+ 文件搜索 工具调用的结果。详见
+ [文件搜索 指南](/docs/guides/tools-file-search) 以了解更多信息。
- `id: string`
@@ -4517,7 +4519,7 @@
- `status: "in_progress" or "searching" or "completed" or 2 more`
- 文件搜索 工具调用的状态。取值之一 `in_progress`,
+ 文件搜索 工具调用的状态。可选值为 `in_progress`,
`searching`, `incomplete` 或 `failed`,
- `"in_progress"`
@@ -4542,11 +4544,11 @@
- `attributes: optional map[string or number or boolean] or null`
- 可以附加到对象的 16 组键值对。这可以
- 用于以结构化格式存储关于对象的附加信息,
- 并通过API或仪表板查询对象。键是字符串,
- 最大长度为 64 个字符。值是最大长度为 512 个字符的字符串、
- 布尔值或数字。
+ 可附加到对象的 16 个键值对集合。可用于
+ 以结构化格式存储有关对象的附加信息,并通过 API 或仪表板查询对象。键为字符串,
+ 最大长度为 64 个字符。值为字符串,
+ 最大长度为 512 个字符,或为布尔值或数字。
+ 最大长度为 512 个字符,或为布尔值或数字。
- `string`
@@ -4564,7 +4566,7 @@
- `score: optional number`
- 文件的相关性评分,介于 0 和 1 之间。
+ 文件的相关性得分,取值介于 0 到 1 之间。
- `text: optional string`
@@ -4573,7 +4575,7 @@
- `FunctionCall object { arguments, call_id, name, 5 more }`
用于运行函数的工具调用。请参阅
- [function calling guide](/docs/guides/function-calling) 。
+ [函数调用指南](/docs/guides/function-calling) 以了解更多信息。
- `arguments: string`
@@ -4581,7 +4583,7 @@
- `call_id: string`
- 模型生成的函数工具调用的唯一 ID。
+ 由模型生成的函数工具调用的唯一 ID。
- `name: string`
@@ -4599,7 +4601,7 @@
- `caller: optional object { type } or object { caller_id, type } or null`
- 产生此工具调用的执行上下文。
+ 生成此工具调用的执行上下文。
- `Direct object { type }`
@@ -4611,7 +4613,7 @@
- `caller_id: string`
- 产生此工具调用的程序项的调用 ID。
+ 生成此工具调用的程序项的调用 ID。
- `type: "program"`
@@ -4623,8 +4625,8 @@
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。其一为 `in_progress`, `completed`,或
- `incomplete`。当通过 API 返回项目时会填充此字段。
+ 条目的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回条目时会填充该字段。
- `"in_progress"`
@@ -4640,33 +4642,33 @@
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 由你的代码生成的函数调用的输出。
+ 由你的代码生成的函数调用输出。
可以是字符串或输出内容的列表。
- `StringOutput = string`
- 函数调用输出的字符串。
+ 表示函数调用输出的字符串。
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 函数调用的文本、图片或文件输出。
+ 函数调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- 发送给模型的文本输入。
+ 提供给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
+ 提供给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
- 发送给模型的输入文件。
+ 发送到模型的输入文件。
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。其一为 `in_progress`, `completed`,或
- `incomplete`。当通过 API 返回项目时会填充此字段。
+ 条目的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回条目时会填充该字段。
- `"in_progress"`
@@ -4682,11 +4684,11 @@
- `call_id: optional string`
- 模型生成的函数工具调用的唯一 ID。
+ 由模型生成的函数工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
- 产生此工具调用的执行上下文。
+ 生成此工具调用的执行上下文。
- `Direct object { type }`
@@ -4700,7 +4702,7 @@
- `caller_id: string`
- 产生此工具调用的程序项的调用 ID。
+ 生成此工具调用的程序项的调用 ID。
- `type: "program"`
@@ -4710,7 +4712,7 @@
- `created_by: optional string`
- 创建该条目的执行者的标识符。
+ 创建该条目的参与方的标识符。
- `name: optional string`
@@ -4722,25 +4724,25 @@
- `WebSearchCall object { id, action, status, type }`
- 一次 网页搜索 工具调用的结果。请参阅
- [网页搜索 指南](/docs/guides/tools-web-search) 。
+ 网页搜索工具调用的结果。请参阅
+ [网页搜索指南](/docs/guides/tools-web-search) 以了解更多信息。
- `id: string`
- 网页搜索 工具调用的唯一 ID。
+ 网页搜索工具调用的唯一 ID。
- `action: object { type, queries, query, sources } or object { type, url } or object { pattern, type, url }`
- 描述本次 网页搜索 调用中所执行具体操作的对象。
- 包含模型使用网络的方式的详细信息(search、open_page、find_in_page)。
+ 描述本次 网页搜索调用中所执行具体操作的对象。
+ 包含模型如何使用网页的详细信息(search、open_page、find_in_page)。
- `Search object { type, queries, query, sources }`
- Action 类型 "search" —— 执行一次 网页搜索 查询。
+ 操作类型 "search" - 执行 网页搜索查询。
- `type: "search"`
- action 类型。
+ 操作类型。
- `"search"`
@@ -4750,7 +4752,7 @@
- `query: optional string`
- 搜索查询语句。
+ 搜索查询。
- `sources: optional array of object { type, url }`
@@ -4768,11 +4770,11 @@
- `OpenPage object { type, url }`
- 操作类型 "open_page" - 从搜索结果中打开指定的 URL。
+ 操作类型 "open_page" - 从搜索结果中打开一个特定的 URL。
- `type: "open_page"`
- action 类型。
+ 操作类型。
- `"open_page"`
@@ -4786,21 +4788,21 @@
- `pattern: string`
- 要在页面中搜索的模式或文本。
+ 要在页面内搜索的模式或文本。
- `type: "find_in_page"`
- action 类型。
+ 操作类型。
- `"find_in_page"`
- `url: string`
- 在其中搜索该模式的页面的 URL。
+ 搜索模式的页面 URL。
- `status: "in_progress" or "searching" or "completed" or "failed"`
- 网页搜索 工具调用的状态。
+ 网页搜索工具调用的状态。
- `"in_progress"`
@@ -4812,14 +4814,14 @@
- `type: "web_search_call"`
- 网页搜索 工具调用的类型。始终为 `web_search_call`.
+ 网页搜索工具调用的类型。始终为 `web_search_call`.
- `"web_search_call"`
- `ComputerCall object { id, call_id, pending_safety_checks, 4 more }`
- 对计算机使用工具的工具调用。参见
- [计算机使用指南](/docs/guides/tools-computer-use) 。
+ 对计算机使用工具的工具调用。请参阅
+ [计算机使用指南](/docs/guides/tools-computer-use) 以了解更多信息。
- `id: string`
@@ -4827,7 +4829,7 @@
- `call_id: string`
- 在向工具调用提供输出响应时使用的标识符。
+ 使用输出响应工具调用时所用的标识符。
- `pending_safety_checks: array of object { id, code, message }`
@@ -4843,12 +4845,12 @@
- `message: optional string or null`
- 关于待处理安全检查的详细信息。
+ 待处理安全检查的详细信息。
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。其一为 `in_progress`, `completed`,或
- `incomplete`。当通过 API 返回项目时会填充此字段。
+ 条目的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回条目时会填充该字段。
- `"in_progress"`
@@ -4864,12 +4866,12 @@
- `action: optional ComputerAction`
- 一次点击动作。
+ 单击操作。
- `actions: optional ComputerActionList`
- 针对的扁平化批量动作 `computer_use`. 每个 action 包含一个
- `type` 判别字段和 action 特定的字段。
+ 针对以下对象的扁平化批量操作 `computer_use`。每个操作都包含一个
+ `type` 判别字段和操作专属字段。
- `ComputerCallOutput object { id, call_id, output, 4 more }`
@@ -4879,15 +4881,15 @@
- `call_id: string`
- 生成该输出的 computer 工具调用的 ID。
+ 生成该输出的计算机工具调用的 ID。
- `output: ResponseComputerToolCallOutputScreenshot`
- 与 computer use 工具配合使用的电脑截图。
+ 与计算机使用工具配合使用的计算机截图图像。
- `status: "completed" or "incomplete" or "failed" or "in_progress"`
- 消息输入的状态。取值之一 `in_progress`, `completed`,或
+ 消息输入的状态。可选值为 `in_progress`, `completed`,或
`incomplete`。当通过 API 返回输入项时填充。
- `"completed"`
@@ -4900,13 +4902,13 @@
- `type: "computer_call_output"`
- computer 工具调用输出的类型。始终 `computer_call_output`.
+ 计算机工具调用输出的类型。始终为 `computer_call_output`.
- `"computer_call_output"`
- `acknowledged_safety_checks: optional array of object { id, code, message }`
- 由 API 报告且已被
+ 由 API 报告的、已被开发者确认的安全检查。
开发者确认的安全检查。
- `id: string`
@@ -4919,17 +4921,17 @@
- `message: optional string or null`
- 关于待处理安全检查的详细信息。
+ 待处理安全检查的详细信息。
- `created_by: optional string`
- 创建该条目的执行者的标识符。
+ 创建该条目的参与方的标识符。
- `Reasoning object { id, summary, type, 3 more }`
- 推理模型在生成回复时所用思维链的描述。请务必在向
- 发送的请求中包含这些条目 `input` :Responses API
- 如果你需要手动管理上下文,用于对话的后续轮次
+ 对推理模型在生成
+ 回复时所使用的思维链的描述。请务必将这些条目包含在你的 `input` 请求中并发送给 Responses API
+ 用于对话的后续轮次,如果你正在手动
[管理上下文](/docs/guides/conversation-state).
- `id: string`
@@ -4942,7 +4944,7 @@
- `text: string`
- 模型到目前为止的推理输出摘要。
+ 到目前为止模型推理输出的摘要。
- `type: "summary_text"`
@@ -4960,7 +4962,7 @@
- `text: string`
- 模型输出的推理文本。
+ 模型生成的推理文本。
- `type: "reasoning_text"`
@@ -4970,20 +4972,20 @@
- `encrypted_content: optional string or null`
- 推理项的加密内容。默认情况下会填充此字段
- 针对由以下接口返回的推理项 `POST /v1/responses` 和 WebSocket
+ 推理项的加密内容。默认情况下会填充该字段
+ 适用于由以下方式返回的推理项 `POST /v1/responses` 和 WebSocket
`response.create` 请求。
- 流式传输时,使用已完成的推理项及其
- `encrypted_content` 来自 `response.output_item.done` 事件,于
- 后续请求中使用。其中 `encrypted_content` 中的
- `response.output_item.added` 可能不完整。这在以下情况下尤为重要:
- 当 `store` 时 `false` 或在使用 Zero Data Retention 时。
+ 流式传输时,请在后续请求中使用已完成的推理项及其
+ `encrypted_content` 中的 `response.output_item.done` 事件
+ 。在后续请求中, `encrypted_content` 中的
+ `response.output_item.added` 可能不完整。这在以下情况时尤其重要
+ 当 `store` 是 `false` 或在使用 Zero Data Retention 时。
- `status: optional "in_progress" or "completed" or "incomplete"`
- 条目的状态。其一为 `in_progress`, `completed`,或
- `incomplete`。当通过 API 返回项目时会填充此字段。
+ 条目的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回条目时会填充该字段。
- `"in_progress"`
@@ -4995,11 +4997,11 @@
- `id: string`
- 该程序条目的唯一 ID。
+ 程序条目的唯一 ID。
- `call_id: string`
- 该程序项的稳定调用 ID。
+ 程序项的稳定调用 ID。
- `code: string`
@@ -5023,15 +5025,15 @@
- `call_id: string`
- 该程序项的调用 ID。
+ 程序项的调用 ID。
- `result: string`
- 由该程序项生成的结果。
+ 由程序项产生的结果。
- `status: "completed" or "incomplete"`
- 程序输出条目的最终状态。
+ 程序输出条目的终态。
- `"completed"`
@@ -5055,7 +5057,7 @@
- `call_id: string or null`
- 模型生成的工具搜索调用的唯一 ID。
+ 由模型生成的工具搜索调用的唯一 ID。
- `execution: "server" or "client"`
@@ -5083,7 +5085,7 @@
- `created_by: optional string`
- 创建该条目的执行者的标识符。
+ 创建该条目的参与方的标识符。
- `ToolSearchOutput object { id, call_id, execution, 4 more }`
@@ -5093,7 +5095,7 @@
- `call_id: string or null`
- 模型生成的工具搜索调用的唯一 ID。
+ 由模型生成的工具搜索调用的唯一 ID。
- `execution: "server" or "client"`
@@ -5119,19 +5121,19 @@
- `Function object { name, parameters, strict, 5 more }`
- 在你自己的代码中定义一个可供模型选择的函数。详细了解 [函数调用](https://platform.openai.com/docs/guides/function-calling).
+ 在你自己的代码中定义一个模型可以选择调用的函数。了解更多关于 [函数调用](https://platform.openai.com/docs/guides/function-calling).
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `parameters: map[unknown] or null`
- 描述函数参数的 JSON schema 对象。
+ 描述该函数参数的 JSON schema 对象。
- `strict: boolean or null`
- 是否对此函数工具强制执行严格的参数校验。
+ 是否对该函数工具强制执行严格的参数校验。
- `type: "function"`
@@ -5141,7 +5143,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -5149,45 +5151,45 @@
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过 tool search 加载。
+ 该函数是否被延迟加载,并通过工具搜索加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 对该函数的描述。由模型用于判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述此函数的字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。详细了解文件搜索 tool [文件搜索 tool](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的过滤器。
+ 要应用的筛选条件。
- `ComparisonFilter object { key, type, value }`
- 用于在指定的属性键与给定值之间使用定义的比较运算进行比较的过滤器。
+ 用于将指定属性键与给定值按定义比较运算进行比较的筛选条件。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个过滤器 `and` 或 `or`.
+ 使用以下方式组合多个筛选条件 `and` 或 `or`.
- `max_num_results: optional number`
- 返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
+ 要返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -5195,7 +5197,7 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 用于在启用混合搜索时,控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -5215,11 +5217,11 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1,尝试仅返回最相关的结果,但可能会返回更少的结果。
+ 文件搜索的评分阈值,介于 0 到 1 之间的一个数字。越接近 1 的数值会尝试仅返回最具相关性的结果,但返回的结果数量可能会更少。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。详细了解 [computer 工具](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
@@ -5229,7 +5231,7 @@
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。详细了解 [computer 工具](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -5255,18 +5257,18 @@
- `type: "computer_use_preview"`
- 计算机使用工具的类型。始终为 `computer_use_preview`.
+ computer use 工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
在互联网上搜索与提示相关的来源。详细了解
- [网页搜索 tool](/docs/guides/tools-web-search).
+ [网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索 工具的类型。可选值为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型。可选值为 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -5274,22 +5276,22 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 进行实时互联网访问。省略时默认为 true。当设置为 false 时,网页搜索 工具将以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索访问实时互联网。省略时默认为 true。当设为 false 时,网页搜索工具以离线/仅缓存模式运行,不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的过滤条件。
+ 搜索的筛选条件。
- `allowed_domains: optional array of string or null`
搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名同样允许。
+ 同时也允许所提供域名的子域名。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指引。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -5307,7 +5309,7 @@
- `country: optional string or null`
- 两个字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 用户的两字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
- `region: optional string or null`
@@ -5319,7 +5321,7 @@
- `type: optional "approximate"`
- 位置近似类型。始终为 `approximate`.
+ 位置近似的类型。始终为 `approximate`.
- `"approximate"`
@@ -5330,7 +5332,7 @@
- `server_label: string`
- 该 MCP 服务器的标签,用于在工具调用中识别它。
+ 此 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -5340,7 +5342,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -5348,48 +5350,48 @@
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许使用的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许使用的工具名称组成的字符串数组
+ 允许的工具名称的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许使用哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否为修改数据还是只读。如果某
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则将匹配此过滤器。
- `tool_names: optional array of string`
- 允许使用的工具名称列表。
+ 允许的工具名称列表。
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,可配合自定义
- MCP 服务器 URL 或服务连接器使用。你的应用程序
- 必须处理 OAuth 授权流程,并在此处提供令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,可以是
+ 配合自定义 MCP 服务器 URL 或服务连接器使用。你的应用
+ 必须处理 OAuth 授权流程并在此处提供令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的连接器。
- `server_url`, `connector_id`,或 `tunnel_id` 中的一个必须提供。了解更多
- 关于服务连接器的信息 [此处](/docs/guides/tools-remote-mcp#connectors).
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些。其中之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。了解更多
+ 关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
- 目前支持 `connector_id` 的值为:
+ 当前支持 `connector_id` 的值为:
- - Dropbox: `connector_dropbox`
- - Gmail: `connector_gmail`
- - Google Calendar: `connector_googlecalendar`
- - Google Drive: `connector_googledrive`
- - Microsoft Teams: `connector_microsoftteams`
- - Outlook Calendar: `connector_outlookcalendar`
- - Outlook Email: `connector_outlookemail`
- - SharePoint: `connector_sharepoint`
+ - Dropbox: `connector_dropbox`
+ - Gmail: `connector_gmail`
+ - Google Calendar: `connector_googlecalendar`
+ - Google Drive: `connector_googledrive`
+ - Microsoft Teams: `connector_microsoftteams`
+ - Outlook Calendar: `connector_outlookcalendar`
+ - Outlook Email: `connector_outlookemail`
+ - SharePoint: `connector_sharepoint`
- `"connector_dropbox"`
@@ -5409,56 +5411,56 @@
- `defer_loading: optional boolean`
- 此 MCP 工具是否为延迟加载并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务器的可选 HTTP 标头。用于身份验证
+ 发送到 MCP 服务端的可选 HTTP 标头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务器中哪些工具需要审批。
+ 指定 MCP 服务端的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务器中哪些工具需要审批。可以是
- `always`, `never`,也可以是与工具关联的过滤器对象
- 这些工具需要审批。
+ 指定 MCP 服务端的哪些工具需要审批。可以是
+ `always`, `never`,或与需要审批的工具关联的过滤器对象
+ 。
- `always: optional object { read_only, tool_names }`
- 用于指定允许使用哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否为修改数据还是只读。如果某
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则将匹配此过滤器。
- `tool_names: optional array of string`
- 允许使用的工具名称列表。
+ 允许的工具名称列表。
- `never: optional object { read_only, tool_names }`
- 用于指定允许使用哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否为修改数据还是只读。如果某
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则将匹配此过滤器。
- `tool_names: optional array of string`
- 允许使用的工具名称列表。
+ 允许的工具名称列表。
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值之一为 `always` 或
- `never`。当设置为 `always`,所有工具都将需要审批。当
- 设置为 `never`,所有工具都将不需要审批。
+ 为所有工具指定统一的审批策略。可选值为 `always` 或
+ `never`。当设置为 `always`,所有工具都需要审批。当
+ 设置为 `never`,所有工具都不需要审批。
- `"always"`
@@ -5470,22 +5472,22 @@
- `server_url: optional string`
- MCP 服务器的 URL。需要提供以下其中一项 `server_url`, `connector_id`,或
- `tunnel_id` 。
+ MCP 服务器的 URL。以下之一 `server_url`, `connector_id`,或
+ `tunnel_id` 必须提供。
- `tunnel_id: optional string`
- 用于代替直接服务器 URL 的安全 MCP 隧道 ID。需要提供以下其中一项
- `server_url`, `connector_id`,或 `tunnel_id` 。
+ 用于替代直接服务器 URL 的安全 MCP 隧道 ID。以下之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示的响应的工具。
+ 运行 Python 代码以帮助生成提示响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID 或指定可上传到你的代码中的文件 ID 以及
- 指定可提供给代码的上传文件 ID,以及
+ 代码解释器容器。可以是容器 ID 或指定
+ 可供代码使用的已上传文件 ID 以及
可选的 `memory_limit` 设置的对象。
- `string`
@@ -5504,7 +5506,7 @@
- `file_ids: optional array of string`
- 提供给代码的可选上传文件列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -5528,13 +5530,13 @@
- `type: "code_interpreter"`
- 代码解释器工具的类型。固定为 `code_interpreter`.
+ 代码解释器工具的类型。始终为 `code_interpreter`.
- `"code_interpreter"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -5544,7 +5546,7 @@
- `type: "programmatic_tool_calling"`
- 工具的类型。固定为 `programmatic_tool_calling`.
+ 工具的类型。始终为 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
@@ -5554,13 +5556,13 @@
- `type: "image_generation"`
- 图像生成工具的类型。固定为 `image_generation`.
+ 图像生成工具的类型。始终为 `image_generation`.
- `"image_generation"`
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 生成新图像还是编辑现有图像。默认值: `auto`.
- `"generate"`
@@ -5571,9 +5573,9 @@
- `background: optional "transparent" or "opaque" or "auto"`
设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。之一。支持透明背景的
- GPT 图像模型可用。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该功能处于预览阶段。使用
+ `opaque`,或 `auto`。之一。透明背景可用于受支持的
+ GPT 图像模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
`transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -5584,7 +5586,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。仅 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不支持 `gpt-image-1-mini`。支持 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需付出的努力程度。此参数仅在 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型中受支持,在 `gpt-image-1-mini`。中不受支持。支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -5592,7 +5594,7 @@
- `input_image_mask: optional object { file_id, image_url }`
- 可选的修复蒙版。包含 `image_url`
+ 用于修复的可选蒙版。包含 `image_url`
(string, optional) 和 `file_id` (string, optional)。
- `file_id: optional string`
@@ -5671,13 +5673,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定的任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 支持用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。关于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式表示的任意分辨率,例如 `WIDTHxHEIGHT` 宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `1536x864`。属于实验性功能,且最大支持的分辨率为 `2560x1440` 。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `3840x2160`。受 GPT image 模型支持; `1024x1024`, `1536x1024`,和 `1024x1536` 受允许自动调整大小的模型支持。对于; `auto` ,受允许自动调整大小的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定的任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 支持用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。关于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式表示的任意分辨率,例如 `WIDTHxHEIGHT` 宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `1536x864`。属于实验性功能,且最大支持的分辨率为 `2560x1440` 。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `3840x2160`。受 GPT image 模型支持; `1024x1024`, `1536x1024`,和 `1024x1536` 受允许自动调整大小的模型支持。对于; `auto` ,受允许自动调整大小的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -5709,7 +5711,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -5733,13 +5735,13 @@
- `type: "custom"`
- 自定义工具的类型。始终为 `custom`.
+ 自定义工具的类型,始终为 `custom`.
- `"custom"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -5747,7 +5749,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索来发现它。
+ 此工具是否应该被延迟并通过工具搜索发现。
- `description: optional string`
@@ -5755,7 +5757,7 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `Namespace object { description, name, tools, type }`
@@ -5771,7 +5773,7 @@
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的 function/custom 工具。
+ 此命名空间内可用的 function/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -5783,7 +5785,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -5791,19 +5793,19 @@
- `defer_loading: optional boolean`
- 该 function 是否应被延迟并通过工具搜索发现。
+ 此 function 是否应被延迟并通过 tool search 发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 描述该 function 工具的字符串输出中所编码 JSON 值的 JSON Schema。这并不描述 content 数组形式的输出。
+ 描述此 function 工具的字符串输出中所编码的 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。若未指定,Responses 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制启用严格的参数校验。若省略,Responses 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -5815,13 +5817,13 @@
- `type: "custom"`
- 自定义工具的类型。始终为 `custom`.
+ 自定义工具的类型,始终为 `custom`.
- `"custom"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -5829,7 +5831,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索来发现它。
+ 此工具是否应该被延迟并通过工具搜索发现。
- `description: optional string`
@@ -5837,31 +5839,31 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `type: "namespace"`
- 工具的类型。固定为 `namespace`.
+ 工具的类型。始终为 `namespace`.
- `"namespace"`
- `ToolSearch object { type, description, execution, parameters }`
- 延迟工具的托管或 BYOT 工具搜索配置。
+ 用于延迟工具的 hosted 或 BYOT tool search 配置。
- `type: "tool_search"`
- 工具的类型。固定为 `tool_search`.
+ 工具的类型。始终为 `tool_search`.
- `"tool_search"`
- `description: optional string or null`
- 向模型展示的、用于客户端执行的工具搜索工具的描述。
+ 展示给模型的、针对客户端执行的 tool search 工具的描述。
- `execution: optional "server" or "client"`
- 工具搜索是由服务端执行还是由客户端执行。
+ tool search 由服务端执行还是由客户端执行。
- `"server"`
@@ -5869,15 +5871,15 @@
- `parameters: optional unknown or null`
- 客户端执行的工具搜索工具的参数 schema。
+ 针对客户端执行的 tool search 工具的参数 schema。
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具会搜索网页以获取用于回复的相关结果。了解更多关于 [网页搜索 tool](https://platform.openai.com/docs/guides/tools-web-search).
+ 此工具会在网络上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索 工具的类型。可选值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型。可选值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -5891,7 +5893,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指引。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -5905,7 +5907,7 @@
- `type: "approximate"`
- 位置近似类型。始终为 `approximate`.
+ 位置近似的类型。始终为 `approximate`.
- `"approximate"`
@@ -5915,7 +5917,7 @@
- `country: optional string or null`
- 两个字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 用户的两字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
- `region: optional string or null`
@@ -5931,13 +5933,13 @@
- `type: "apply_patch"`
- 工具的类型。固定为 `apply_patch`.
+ 工具的类型。始终为 `apply_patch`.
- `"apply_patch"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -5951,7 +5953,7 @@
- `created_by: optional string`
- 创建该条目的执行者的标识符。
+ 创建该条目的参与方的标识符。
- `AdditionalTools object { id, role, tools, type }`
@@ -5981,23 +5983,23 @@
- `tools: array of object { name, parameters, strict, 5 more } or object { type, vector_store_ids, filters, 2 more } or object { type } or 13 more`
- 在此条目中可用的附加工具定义。
+ 在该条目处可用的附加工具定义。
- `Function object { name, parameters, strict, 5 more }`
- 在你自己的代码中定义一个可供模型选择的函数。详细了解 [函数调用](https://platform.openai.com/docs/guides/function-calling).
+ 在你自己的代码中定义一个模型可以选择调用的函数。了解更多关于 [函数调用](https://platform.openai.com/docs/guides/function-calling).
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `parameters: map[unknown] or null`
- 描述函数参数的 JSON schema 对象。
+ 描述该函数参数的 JSON schema 对象。
- `strict: boolean or null`
- 是否对此函数工具强制执行严格的参数校验。
+ 是否对该函数工具强制执行严格的参数校验。
- `type: "function"`
@@ -6007,7 +6009,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -6015,45 +6017,45 @@
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过 tool search 加载。
+ 该函数是否被延迟加载,并通过工具搜索加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 对该函数的描述。由模型用于判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述此函数的字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。详细了解文件搜索 tool [文件搜索 tool](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的过滤器。
+ 要应用的筛选条件。
- `ComparisonFilter object { key, type, value }`
- 用于在指定的属性键与给定值之间使用定义的比较运算进行比较的过滤器。
+ 用于将指定属性键与给定值按定义比较运算进行比较的筛选条件。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个过滤器 `and` 或 `or`.
+ 使用以下方式组合多个筛选条件 `and` 或 `or`.
- `max_num_results: optional number`
- 返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
+ 要返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -6061,7 +6063,7 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 用于在启用混合搜索时,控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -6081,11 +6083,11 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1,尝试仅返回最相关的结果,但可能会返回更少的结果。
+ 文件搜索的评分阈值,介于 0 到 1 之间的一个数字。越接近 1 的数值会尝试仅返回最具相关性的结果,但返回的结果数量可能会更少。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。详细了解 [computer 工具](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
@@ -6095,7 +6097,7 @@
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。详细了解 [computer 工具](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -6121,18 +6123,18 @@
- `type: "computer_use_preview"`
- 计算机使用工具的类型。始终为 `computer_use_preview`.
+ computer use 工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
在互联网上搜索与提示相关的来源。详细了解
- [网页搜索 tool](/docs/guides/tools-web-search).
+ [网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索 工具的类型。可选值为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型。可选值为 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -6140,22 +6142,22 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 进行实时互联网访问。省略时默认为 true。当设置为 false 时,网页搜索 工具将以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索访问实时互联网。省略时默认为 true。当设为 false 时,网页搜索工具以离线/仅缓存模式运行,不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的过滤条件。
+ 搜索的筛选条件。
- `allowed_domains: optional array of string or null`
搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名同样允许。
+ 同时也允许所提供域名的子域名。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指引。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -6173,7 +6175,7 @@
- `country: optional string or null`
- 两个字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 用户的两字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
- `region: optional string or null`
@@ -6185,7 +6187,7 @@
- `type: optional "approximate"`
- 位置近似类型。始终为 `approximate`.
+ 位置近似的类型。始终为 `approximate`.
- `"approximate"`
@@ -6196,7 +6198,7 @@
- `server_label: string`
- 该 MCP 服务器的标签,用于在工具调用中识别它。
+ 此 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -6206,7 +6208,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -6214,48 +6216,48 @@
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许使用的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许使用的工具名称组成的字符串数组
+ 允许的工具名称的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许使用哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否为修改数据还是只读。如果某
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则将匹配此过滤器。
- `tool_names: optional array of string`
- 允许使用的工具名称列表。
+ 允许的工具名称列表。
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,可配合自定义
- MCP 服务器 URL 或服务连接器使用。你的应用程序
- 必须处理 OAuth 授权流程,并在此处提供令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,可以是
+ 配合自定义 MCP 服务器 URL 或服务连接器使用。你的应用
+ 必须处理 OAuth 授权流程并在此处提供令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的连接器。
- `server_url`, `connector_id`,或 `tunnel_id` 中的一个必须提供。了解更多
- 关于服务连接器的信息 [此处](/docs/guides/tools-remote-mcp#connectors).
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些。其中之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。了解更多
+ 关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
- 目前支持 `connector_id` 的值为:
+ 当前支持 `connector_id` 的值为:
- - Dropbox: `connector_dropbox`
- - Gmail: `connector_gmail`
- - Google Calendar: `connector_googlecalendar`
- - Google Drive: `connector_googledrive`
- - Microsoft Teams: `connector_microsoftteams`
- - Outlook Calendar: `connector_outlookcalendar`
- - Outlook Email: `connector_outlookemail`
- - SharePoint: `connector_sharepoint`
+ - Dropbox: `connector_dropbox`
+ - Gmail: `connector_gmail`
+ - Google Calendar: `connector_googlecalendar`
+ - Google Drive: `connector_googledrive`
+ - Microsoft Teams: `connector_microsoftteams`
+ - Outlook Calendar: `connector_outlookcalendar`
+ - Outlook Email: `connector_outlookemail`
+ - SharePoint: `connector_sharepoint`
- `"connector_dropbox"`
@@ -6275,56 +6277,56 @@
- `defer_loading: optional boolean`
- 此 MCP 工具是否为延迟加载并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务器的可选 HTTP 标头。用于身份验证
+ 发送到 MCP 服务端的可选 HTTP 标头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务器中哪些工具需要审批。
+ 指定 MCP 服务端的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务器中哪些工具需要审批。可以是
- `always`, `never`,也可以是与工具关联的过滤器对象
- 这些工具需要审批。
+ 指定 MCP 服务端的哪些工具需要审批。可以是
+ `always`, `never`,或与需要审批的工具关联的过滤器对象
+ 。
- `always: optional object { read_only, tool_names }`
- 用于指定允许使用哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否为修改数据还是只读。如果某
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则将匹配此过滤器。
- `tool_names: optional array of string`
- 允许使用的工具名称列表。
+ 允许的工具名称列表。
- `never: optional object { read_only, tool_names }`
- 用于指定允许使用哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否为修改数据还是只读。如果某
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则将匹配此过滤器。
- `tool_names: optional array of string`
- 允许使用的工具名称列表。
+ 允许的工具名称列表。
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值之一为 `always` 或
- `never`。当设置为 `always`,所有工具都将需要审批。当
- 设置为 `never`,所有工具都将不需要审批。
+ 为所有工具指定统一的审批策略。可选值为 `always` 或
+ `never`。当设置为 `always`,所有工具都需要审批。当
+ 设置为 `never`,所有工具都不需要审批。
- `"always"`
@@ -6336,22 +6338,22 @@
- `server_url: optional string`
- MCP 服务器的 URL。需要提供以下其中一项 `server_url`, `connector_id`,或
- `tunnel_id` 。
+ MCP 服务器的 URL。以下之一 `server_url`, `connector_id`,或
+ `tunnel_id` 必须提供。
- `tunnel_id: optional string`
- 用于代替直接服务器 URL 的安全 MCP 隧道 ID。需要提供以下其中一项
- `server_url`, `connector_id`,或 `tunnel_id` 。
+ 用于替代直接服务器 URL 的安全 MCP 隧道 ID。以下之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示的响应的工具。
+ 运行 Python 代码以帮助生成提示响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID 或指定可上传到你的代码中的文件 ID 以及
- 指定可提供给代码的上传文件 ID,以及
+ 代码解释器容器。可以是容器 ID 或指定
+ 可供代码使用的已上传文件 ID 以及
可选的 `memory_limit` 设置的对象。
- `string`
@@ -6370,7 +6372,7 @@
- `file_ids: optional array of string`
- 提供给代码的可选上传文件列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -6394,13 +6396,13 @@
- `type: "code_interpreter"`
- 代码解释器工具的类型。固定为 `code_interpreter`.
+ 代码解释器工具的类型。始终为 `code_interpreter`.
- `"code_interpreter"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -6410,7 +6412,7 @@
- `type: "programmatic_tool_calling"`
- 工具的类型。固定为 `programmatic_tool_calling`.
+ 工具的类型。始终为 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
@@ -6420,13 +6422,13 @@
- `type: "image_generation"`
- 图像生成工具的类型。固定为 `image_generation`.
+ 图像生成工具的类型。始终为 `image_generation`.
- `"image_generation"`
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 生成新图像还是编辑现有图像。默认值: `auto`.
- `"generate"`
@@ -6437,9 +6439,9 @@
- `background: optional "transparent" or "opaque" or "auto"`
设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。之一。支持透明背景的
- GPT 图像模型可用。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该功能处于预览阶段。使用
+ `opaque`,或 `auto`。之一。透明背景可用于受支持的
+ GPT 图像模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
`transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -6450,7 +6452,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。仅 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不支持 `gpt-image-1-mini`。支持 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需付出的努力程度。此参数仅在 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型中受支持,在 `gpt-image-1-mini`。中不受支持。支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -6458,7 +6460,7 @@
- `input_image_mask: optional object { file_id, image_url }`
- 可选的修复蒙版。包含 `image_url`
+ 用于修复的可选蒙版。包含 `image_url`
(string, optional) 和 `file_id` (string, optional)。
- `file_id: optional string`
@@ -6537,13 +6539,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定的任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 支持用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。关于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式表示的任意分辨率,例如 `WIDTHxHEIGHT` 宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `1536x864`。属于实验性功能,且最大支持的分辨率为 `2560x1440` 。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `3840x2160`。受 GPT image 模型支持; `1024x1024`, `1536x1024`,和 `1024x1536` 受允许自动调整大小的模型支持。对于; `auto` ,受允许自动调整大小的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定的任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 支持用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。关于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式表示的任意分辨率,例如 `WIDTHxHEIGHT` 宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `1536x864`。属于实验性功能,且最大支持的分辨率为 `2560x1440` 。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `3840x2160`。受 GPT image 模型支持; `1024x1024`, `1536x1024`,和 `1024x1536` 受允许自动调整大小的模型支持。对于; `auto` ,受允许自动调整大小的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -6575,7 +6577,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -6599,13 +6601,13 @@
- `type: "custom"`
- 自定义工具的类型。始终为 `custom`.
+ 自定义工具的类型,始终为 `custom`.
- `"custom"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -6613,7 +6615,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索来发现它。
+ 此工具是否应该被延迟并通过工具搜索发现。
- `description: optional string`
@@ -6621,7 +6623,7 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `Namespace object { description, name, tools, type }`
@@ -6637,7 +6639,7 @@
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的 function/custom 工具。
+ 此命名空间内可用的 function/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -6649,7 +6651,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -6657,19 +6659,19 @@
- `defer_loading: optional boolean`
- 该 function 是否应被延迟并通过工具搜索发现。
+ 此 function 是否应被延迟并通过 tool search 发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 描述该 function 工具的字符串输出中所编码 JSON 值的 JSON Schema。这并不描述 content 数组形式的输出。
+ 描述此 function 工具的字符串输出中所编码的 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。若未指定,Responses 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制启用严格的参数校验。若省略,Responses 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -6681,13 +6683,13 @@
- `type: "custom"`
- 自定义工具的类型。始终为 `custom`.
+ 自定义工具的类型,始终为 `custom`.
- `"custom"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -6695,7 +6697,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索来发现它。
+ 此工具是否应该被延迟并通过工具搜索发现。
- `description: optional string`
@@ -6703,31 +6705,31 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `type: "namespace"`
- 工具的类型。固定为 `namespace`.
+ 工具的类型。始终为 `namespace`.
- `"namespace"`
- `ToolSearch object { type, description, execution, parameters }`
- 延迟工具的托管或 BYOT 工具搜索配置。
+ 用于延迟工具的 hosted 或 BYOT tool search 配置。
- `type: "tool_search"`
- 工具的类型。固定为 `tool_search`.
+ 工具的类型。始终为 `tool_search`.
- `"tool_search"`
- `description: optional string or null`
- 向模型展示的、用于客户端执行的工具搜索工具的描述。
+ 展示给模型的、针对客户端执行的 tool search 工具的描述。
- `execution: optional "server" or "client"`
- 工具搜索是由服务端执行还是由客户端执行。
+ tool search 由服务端执行还是由客户端执行。
- `"server"`
@@ -6735,15 +6737,15 @@
- `parameters: optional unknown or null`
- 客户端执行的工具搜索工具的参数 schema。
+ 针对客户端执行的 tool search 工具的参数 schema。
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具会搜索网页以获取用于回复的相关结果。了解更多关于 [网页搜索 tool](https://platform.openai.com/docs/guides/tools-web-search).
+ 此工具会在网络上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索 工具的类型。可选值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型。可选值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -6757,7 +6759,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指引。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -6771,7 +6773,7 @@
- `type: "approximate"`
- 位置近似类型。始终为 `approximate`.
+ 位置近似的类型。始终为 `approximate`.
- `"approximate"`
@@ -6781,7 +6783,7 @@
- `country: optional string or null`
- 两个字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 用户的两字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
- `region: optional string or null`
@@ -6797,13 +6799,13 @@
- `type: "apply_patch"`
- 工具的类型。固定为 `apply_patch`.
+ 工具的类型。始终为 `apply_patch`.
- `"apply_patch"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -6817,7 +6819,7 @@
- `Compaction object { id, encrypted_content, type, created_by }`
- 由以下接口生成的压缩条目 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
+ 由 [`v1/responses/compact` API](/docs/api-reference/responses/compact).
- `id: string`
@@ -6835,7 +6837,7 @@
- `created_by: optional string`
- 创建该条目的执行者的标识符。
+ 创建该条目的参与方的标识符。
- `ImageGenerationCall object { id, result, status, type }`
@@ -6886,7 +6888,7 @@
- `outputs: array of object { logs, type } or object { type, url } or null`
代码解释器生成的输出,例如日志或图像。
- 如果没有可用输出,可能为 null。
+ 如果没有可用的输出,可以为 null。
- `Logs object { logs, type }`
@@ -6938,7 +6940,7 @@
- `LocalShellCall object { id, action, call_id, 2 more }`
- 用于在本地 shell 上运行命令的工具调用。
+ 在本地 shell 上运行命令的工具调用。
- `id: string`
@@ -6964,19 +6966,19 @@
- `timeout_ms: optional number or null`
- 命令的可选超时(毫秒)。
+ 命令的可选超时时间(毫秒)。
- `user: optional string or null`
- 运行命令时使用的可选用户。
+ 用于运行命令的可选用户。
- `working_directory: optional string or null`
- 运行命令时使用的可选工作目录。
+ 运行命令的可选工作目录。
- `call_id: string`
- 由模型生成的本地 shell 工具调用的唯一 ID。
+ 模型生成的本地 shell 工具调用的唯一 ID。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -7000,7 +7002,7 @@
- `id: string`
- 由模型生成的本地 shell 工具调用的唯一 ID。
+ 模型生成的本地 shell 工具调用的唯一 ID。
- `output: string`
@@ -7014,7 +7016,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or null`
- 条目的状态。其一为 `in_progress`, `completed`,或 `incomplete`.
+ 条目的状态。取值之一为 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -7028,11 +7030,11 @@
- `id: string`
- shell 工具调用的唯一 ID。当此 item 通过 API 返回时填充。
+ shell 工具调用的唯一 ID。通过 API 返回该条目时填充。
- `action: object { commands, max_output_length, timeout_ms }`
- 用于描述如何运行该工具调用的 shell 命令和限制。
+ 描述如何运行该工具调用的 shell 命令和限制。
- `commands: array of string`
@@ -7042,7 +7044,7 @@
- `timeout_ms: number or null`
- 命令的可选超时时间,以毫秒为单位。
+ 命令的可选超时时间(毫秒)。
- `call_id: string`
@@ -7064,7 +7066,7 @@
- `ResponseContainerReference object { container_id, type }`
- 表示通过 /v1/containers 创建的容器。
+ 表示使用 /v1/containers 创建的容器。
- `container_id: string`
@@ -7076,7 +7078,7 @@
- `status: "in_progress" or "completed" or "incomplete"`
- shell 调用的状态。值为 `in_progress`, `completed`,或 `incomplete`.
+ shell 调用的状态。取值之一 `in_progress`, `completed`,或 `incomplete`.
- `"in_progress"`
@@ -7092,7 +7094,7 @@
- `caller: optional object { type } or object { caller_id, type } or null`
- 产生此工具调用的执行上下文。
+ 生成此工具调用的执行上下文。
- `Direct object { type }`
@@ -7104,7 +7106,7 @@
- `caller_id: string`
- 产生此工具调用的程序项的调用 ID。
+ 生成此工具调用的程序项的调用 ID。
- `type: "program"`
@@ -7116,11 +7118,11 @@
- `ShellCallOutput object { id, call_id, max_output_length, 5 more }`
- 已发出的 shell 工具调用的输出。
+ 已发出的 shell 工具调用输出。
- `id: string`
- shell 调用输出的唯一 ID。通过 API 返回此条目时填充。
+ shell 调用输出的唯一 ID。当此条目通过 API 返回时填充。
- `call_id: string`
@@ -7128,7 +7130,7 @@
- `max_output_length: number or null`
- shell 命令输出的最大长度。这由模型生成,应与原始输出一起传回。
+ shell 命令输出的最大长度。该值由模型生成,应与原始输出一起传回。
- `output: array of object { outcome, stderr, stdout, created_by }`
@@ -7140,7 +7142,7 @@
- `Timeout object { type }`
- 表示 shell 调用超出了其配置的时间限制。
+ 表示 shell 调用超过了其配置的时间限制。
- `type: "timeout"`
@@ -7150,7 +7152,7 @@
- `Exit object { exit_code, type }`
- 表示 shell 命令已执行完毕并返回了退出码。
+ 表示 shell 命令已结束并返回了退出码。
- `exit_code: number`
@@ -7172,7 +7174,7 @@
- `created_by: optional string`
- 创建该条目的执行者的标识符。
+ 创建该条目的参与方的标识符。
- `status: "in_progress" or "completed" or "incomplete"`
@@ -7192,7 +7194,7 @@
- `caller: optional object { type } or object { caller_id, type } or null`
- 产生此工具调用的执行上下文。
+ 生成此工具调用的执行上下文。
- `Direct object { type }`
@@ -7204,7 +7206,7 @@
- `caller_id: string`
- 产生此工具调用的程序项的调用 ID。
+ 生成此工具调用的程序项的调用 ID。
- `type: "program"`
@@ -7212,7 +7214,7 @@
- `created_by: optional string`
- 创建该条目的执行者的标识符。
+ 创建该条目的参与方的标识符。
- `ApplyPatchCall object { id, call_id, operation, 4 more }`
@@ -7224,11 +7226,11 @@
- `call_id: string`
- 模型生成的 apply patch 工具调用的唯一 ID。
+ 由模型生成的 apply patch 工具调用的唯一 ID。
- `operation: object { diff, path, type } or object { path, type } or object { diff, path, type }`
- 通过 apply_patch 应用的 create_file、delete_file 或 update_file 操作之一。
+ 通过 apply_patch 执行的 create_file、delete_file 或 update_file 操作之一。
- `CreateFile object { diff, path, type }`
@@ -7244,7 +7246,7 @@
- `type: "create_file"`
- 使用提供的差异创建新文件。
+ 使用提供的差异创建一个新文件。
- `"create_file"`
@@ -7282,7 +7284,7 @@
- `status: "in_progress" or "completed"`
- apply patch 工具调用的状态。可选值为 `in_progress` 或 `completed`.
+ apply patch 工具调用的状态。取以下值之一: `in_progress` 或 `completed`.
- `"in_progress"`
@@ -7296,7 +7298,7 @@
- `caller: optional object { type } or object { caller_id, type } or null`
- 产生此工具调用的执行上下文。
+ 生成此工具调用的执行上下文。
- `Direct object { type }`
@@ -7308,7 +7310,7 @@
- `caller_id: string`
- 产生此工具调用的程序项的调用 ID。
+ 生成此工具调用的程序项的调用 ID。
- `type: "program"`
@@ -7320,7 +7322,7 @@
- `ApplyPatchCallOutput object { id, call_id, status, 4 more }`
- apply_patch 工具调用所发出的输出。
+ apply patch 工具调用发出的输出。
- `id: string`
@@ -7328,11 +7330,11 @@
- `call_id: string`
- 模型生成的 apply patch 工具调用的唯一 ID。
+ 由模型生成的 apply patch 工具调用的唯一 ID。
- `status: "completed" or "failed"`
- apply patch 工具调用输出的状态。可选值为 `completed` 或 `failed`.
+ apply patch 工具调用输出的状态。取以下值之一: `completed` 或 `failed`.
- `"completed"`
@@ -7346,7 +7348,7 @@
- `caller: optional object { type } or object { caller_id, type } or null`
- 产生此工具调用的执行上下文。
+ 生成此工具调用的执行上下文。
- `Direct object { type }`
@@ -7358,7 +7360,7 @@
- `caller_id: string`
- 产生此工具调用的程序项的调用 ID。
+ 生成此工具调用的程序项的调用 ID。
- `type: "program"`
@@ -7366,23 +7368,23 @@
- `created_by: optional string`
- 创建此工具调用输出的实体的 ID。
+ 创建此工具调用输出的实体 ID。
- `output: optional string or null`
- apply_patch 工具返回的可选文本输出。
+ apply patch 工具返回的可选文本输出。
- `McpCall object { id, arguments, name, 6 more }`
- 对 MCP 服务器上某个工具的调用。
+ 在 MCP 服务器上对一次工具的调用。
- `id: string`
- 工具调用的唯一 ID。
+ 该工具调用的唯一 ID。
- `arguments: string`
- 传递给该工具的参数的 JSON 字符串。
+ 传给该工具的参数,JSON 字符串形式。
- `name: string`
@@ -7413,7 +7415,7 @@
- `status: optional "in_progress" or "completed" or "incomplete" or 2 more`
- 工具调用的状态。可选值为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
+ 工具调用的状态。取值之一为 `in_progress`, `completed`, `incomplete`, `calling`,或 `failed`.
- `"in_progress"`
@@ -7427,7 +7429,7 @@
- `McpListTools object { id, server_label, tools, 2 more }`
- MCP 服务器上可用工具的列表。
+ MCP 服务器上可用的工具列表。
- `id: string`
@@ -7451,7 +7453,7 @@
- `annotations: optional unknown or null`
- 关于该工具的附加注释。
+ 有关该工具的其他注解。
- `description: optional string or null`
@@ -7465,11 +7467,11 @@
- `error: optional string or null`
- 如果服务器无法列出工具,则返回错误消息。
+ 当服务器无法列出工具时的错误消息。
- `McpApprovalRequest object { id, arguments, name, 2 more }`
- 对工具调用的人工审批请求。
+ 对一次工具调用的人工审批请求。
- `id: string`
@@ -7477,7 +7479,7 @@
- `arguments: string`
- 该工具参数的 JSON 字符串。
+ 传给该工具的参数,JSON 字符串形式。
- `name: string`
@@ -7495,7 +7497,7 @@
- `McpApprovalResponse object { id, approval_request_id, approve, 2 more }`
- 对 MCP 审批请求的响应。
+ 对一次 MCP 审批请求的响应。
- `id: string`
@@ -7507,7 +7509,7 @@
- `approve: boolean`
- 请求是否已批准。
+ 该请求是否已批准。
- `type: "mcp_approval_response"`
@@ -7521,7 +7523,7 @@
- `CustomToolCall object { call_id, input, name, 4 more }`
- 由模型创建的对自定义工具的调用。
+ 对模型创建的自定义工具的调用。
- `call_id: string`
@@ -7533,7 +7535,7 @@
- `name: string`
- 正在调用的自定义工具的名称。
+ 被调用的自定义工具的名称。
- `type: "custom_tool_call"`
@@ -7543,11 +7545,11 @@
- `id: optional string`
- 该自定义工具调用在 OpenAI 平台上的唯一 ID。
+ OpenAI 平台上此自定义工具调用的唯一 ID。
- `caller: optional object { type } or object { caller_id, type } or null`
- 产生此工具调用的执行上下文。
+ 生成此工具调用的执行上下文。
- `Direct object { type }`
@@ -7559,7 +7561,7 @@
- `caller_id: string`
- 产生此工具调用的程序项的调用 ID。
+ 生成此工具调用的程序项的调用 ID。
- `type: "program"`
@@ -7577,7 +7579,7 @@
- `call_id: string`
- 调用 ID,用于将此自定义工具调用输出映射到对应的自定义工具调用。
+ 调用 ID,用于将此自定义工具调用的输出映射到相应的自定义工具调用。
- `output: string or array of ResponseInputText or ResponseInputImage or ResponseInputFile`
@@ -7586,28 +7588,28 @@
- `StringOutput = string`
- 自定义工具调用的输出字符串。
+ 自定义工具调用输出的字符串。
- `OutputContentList = array of ResponseInputText or ResponseInputImage or ResponseInputFile`
- 自定义工具调用的文本、图片或文件输出。
+ 自定义工具调用的文本、图像或文件输出。
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- 发送给模型的文本输入。
+ 提供给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
+ 提供给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
- 发送给模型的输入文件。
+ 发送到模型的输入文件。
- `status: "in_progress" or "completed" or "incomplete"`
- 条目的状态。其一为 `in_progress`, `completed`,或
- `incomplete`。当通过 API 返回项目时会填充此字段。
+ 条目的状态。取值之一为 `in_progress`, `completed`,或
+ `incomplete`。当通过 API 返回条目时会填充该字段。
- `"in_progress"`
@@ -7623,7 +7625,7 @@
- `caller: optional object { type } or object { caller_id, type } or null`
- 产生此工具调用的执行上下文。
+ 生成此工具调用的执行上下文。
- `Direct object { type }`
@@ -7637,7 +7639,7 @@
- `caller_id: string`
- 产生此工具调用的程序项的调用 ID。
+ 生成此工具调用的程序项的调用 ID。
- `type: "program"`
@@ -7647,7 +7649,7 @@
- `created_by: optional string`
- 创建该条目的执行者的标识符。
+ 创建该条目的参与方的标识符。
- `parallel_tool_calls: boolean`
@@ -7655,22 +7657,22 @@
- `temperature: number or null`
- 使用的采样温度,介于 0 和 2 之间。较高的值(如 0.8)会使输出更加随机,而较低的值(如 0.2)会使其更加聚焦和确定。
- 我们通常建议修改此项或 `top_p` ,但不要同时修改两者。
+ 使用的采样温度,介于 0 到 2 之间。较高的值(例如 0.8)会使输出更加随机,而较低的值(例如 0.2)会使输出更加聚焦和确定。
+ 我们通常建议修改此项或 `top_p` 但不要同时修改两者。
- `tool_choice: ToolChoiceOptions or ToolChoiceAllowed or ToolChoiceTypes or 6 more`
- 模型在生成
- 响应时应如何选择要使用的工具(或多个工具)。请参阅 `tools` 参数以了解如何指定模型可以调用的工具
+ 模型在生成响应时应如何选择使用哪个(或哪些)工具
+ 。请参阅 `tools` 参数,了解如何指定模型可以调用的工具
。
- `ToolChoiceOptions = "none" or "auto" or "required"`
- 控制模型调用哪个工具(如果有)。
+ 控制模型调用哪个工具(若有)。
`none` 表示模型不会调用任何工具,而是生成一条消息。
- `auto` 表示模型可以在生成一条消息或调用一个或
+ `auto` 表示模型可以在生成消息或调用一个或
多个工具之间进行选择。
`required` 表示模型必须调用一个或多个工具。
@@ -7683,11 +7685,11 @@
- `ToolChoiceAllowed object { mode, tools, type }`
- 将模型可用的工具限制为预定义集合。
+ 将模型可用的工具限制为预定义的集合。
- `mode: "auto" or "required"`
- 将模型可用的工具限制为预定义集合。
+ 将模型可用的工具限制为预定义的集合。
`auto` 允许模型从允许的工具中进行选择并生成一条
消息。
@@ -7700,7 +7702,7 @@
- `tools: array of map[unknown]`
- 模型应被允许调用的工具定义列表。
+ 模型应允许调用的工具定义列表。
对于 Responses API,工具定义列表可能如下所示:
@@ -7720,7 +7722,7 @@
- `ToolChoiceTypes object { type }`
- 指示模型应使用内置工具生成响应。
+ 指示模型应使用内置工具来生成响应。
[了解更多关于内置工具的信息](/docs/guides/tools).
- `type: "file_search" or "web_search_preview" or "computer" or 5 more`
@@ -7756,11 +7758,11 @@
- `ToolChoiceFunction object { name, type }`
- 使用此选项可强制模型调用特定函数。
+ 使用此选项可强制模型调用特定的函数。
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `type: "function"`
@@ -7774,21 +7776,21 @@
- `server_label: string`
- 要使用的 MCP 服务器的标签。
+ 要使用的 MCP 服务器的名称。
- `type: "mcp"`
- 对于 MCP 工具,类型始终为 `mcp`.
+ 对于 MCP 工具,type 始终为 `mcp`.
- `"mcp"`
- `name: optional string or null`
- 要在服务器上调用的工具名称。
+ 要在服务器上调用的工具的名称。
- `ToolChoiceCustom object { name, type }`
- 使用此选项可强制模型调用特定的自定义工具。
+ 使用此选项可以强制模型调用特定的自定义工具。
- `name: string`
@@ -7796,7 +7798,7 @@
- `type: "custom"`
- 对于自定义工具调用,类型始终为 `custom`.
+ 对于自定义工具调用,type 始终为 `custom`.
- `"custom"`
@@ -7810,7 +7812,7 @@
- `ToolChoiceApplyPatch object { type }`
- 在执行工具调用时,强制模型调用 apply_patch 工具。
+ 在执行工具调用时强制模型调用 apply_patch 工具。
- `type: "apply_patch"`
@@ -7820,7 +7822,7 @@
- `ToolChoiceShell object { type }`
- 当需要工具调用时,强制模型调用 shell 工具。
+ 在需要工具调用时强制模型调用 shell 工具。
- `type: "shell"`
@@ -7840,29 +7842,29 @@
或 [文件搜索](/docs/guides/tools-file-search)。了解更多关于
[内置工具](/docs/guides/tools).
- **MCP 工具**: 通过自定义 MCP 服务器与第三方系统集成
- 或预定义连接器(如 Google Drive 和 SharePoint)。了解有关
+ 或 Google Drive 和 SharePoint 等预定义连接器。了解更多关于
[MCP 工具](/docs/guides/tools-connectors-mcp).
- **函数调用(自定义工具)**: 由你定义的函数,
- 使模型能够以强类型参数和返回值调用你自己的代码
- 。了解有关
+ 使模型能够使用强类型参数调用你自己的代码
+ 和输出。了解更多关于
[函数调用](/docs/guides/function-calling)。你也可以使用
- 自定义工具来调用你自己的代码。
+ 自定义工具调用你自己的代码。
- `Function object { name, parameters, strict, 5 more }`
- 在你自己的代码中定义一个可供模型选择的函数。详细了解 [函数调用](https://platform.openai.com/docs/guides/function-calling).
+ 在你自己的代码中定义一个模型可以选择调用的函数。了解更多关于 [函数调用](https://platform.openai.com/docs/guides/function-calling).
- `name: string`
- 要调用的函数名称。
+ 要调用的函数的名称。
- `parameters: map[unknown] or null`
- 描述函数参数的 JSON schema 对象。
+ 描述该函数参数的 JSON schema 对象。
- `strict: boolean or null`
- 是否对此函数工具强制执行严格的参数校验。
+ 是否对该函数工具强制执行严格的参数校验。
- `type: "function"`
@@ -7872,7 +7874,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -7880,45 +7882,45 @@
- `defer_loading: optional boolean`
- 此函数是否延迟加载并通过 tool search 加载。
+ 该函数是否被延迟加载,并通过工具搜索加载。
- `description: optional string or null`
- 函数的描述。供模型用于判断是否调用该函数。
+ 对该函数的描述。由模型用于判断是否调用该函数。
- `output_schema: optional map[unknown] or null`
- 描述此函数的字符串输出中所编码 JSON 值的 JSON schema 对象。
+ 描述该函数字符串输出中所编码 JSON 值的 JSON schema 对象。
- `FileSearch object { type, vector_store_ids, filters, 2 more }`
- 用于从已上传文件中搜索相关内容的工具。详细了解 [文件搜索工具](https://platform.openai.com/docs/guides/tools-file-search).
+ 从已上传文件中搜索相关内容的工具。详细了解文件搜索 tool [文件搜索 tool](https://platform.openai.com/docs/guides/tools-file-search).
- `type: "file_search"`
- 文件搜索工具的类型。始终为 `file_search`.
+ 文件搜索 工具的类型。始终为 `file_search`.
- `"file_search"`
- `vector_store_ids: array of string`
- 要搜索的向量存储库 ID。
+ 要搜索的向量存储的 ID。
- `filters: optional ComparisonFilter or CompoundFilter or null`
- 要应用的过滤器。
+ 要应用的筛选条件。
- `ComparisonFilter object { key, type, value }`
- 用于在指定的属性键与给定值之间使用定义的比较运算进行比较的过滤器。
+ 用于将指定属性键与给定值按定义比较运算进行比较的筛选条件。
- `CompoundFilter object { filters, type }`
- 使用以下方式组合多个过滤器 `and` 或 `or`.
+ 使用以下方式组合多个筛选条件 `and` 或 `or`.
- `max_num_results: optional number`
- 返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
+ 要返回的最大结果数。该数值应介于 1 到 50 之间(含两端)。
- `ranking_options: optional object { hybrid_search, ranker, score_threshold }`
@@ -7926,7 +7928,7 @@
- `hybrid_search: optional object { embedding_weight, text_weight }`
- 用于在启用混合搜索时,控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
+ 在启用混合搜索时,用于控制倒数排名融合在语义嵌入匹配与稀疏关键词匹配之间平衡的权重。
- `embedding_weight: number`
@@ -7946,11 +7948,11 @@
- `score_threshold: optional number`
- 文件搜索的分数阈值,介于 0 到 1 之间的数字。越接近 1,尝试仅返回最相关的结果,但可能会返回更少的结果。
+ 文件搜索的评分阈值,介于 0 到 1 之间的一个数字。越接近 1 的数值会尝试仅返回最具相关性的结果,但返回的结果数量可能会更少。
- `Computer object { type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。详细了解 [computer 工具](https://platform.openai.com/docs/guides/tools-computer-use).
- `type: "computer"`
@@ -7960,7 +7962,7 @@
- `ComputerUsePreview object { display_height, display_width, environment, type }`
- 用于控制虚拟计算机的工具。详细了解 [computer tool](https://platform.openai.com/docs/guides/tools-computer-use).
+ 用于控制虚拟计算机的工具。详细了解 [computer 工具](https://platform.openai.com/docs/guides/tools-computer-use).
- `display_height: number`
@@ -7986,18 +7988,18 @@
- `type: "computer_use_preview"`
- 计算机使用工具的类型。始终为 `computer_use_preview`.
+ computer use 工具的类型。始终为 `computer_use_preview`.
- `"computer_use_preview"`
- `WebSearch object { type, external_web_access, filters, 2 more }`
在互联网上搜索与提示相关的来源。详细了解
- [网页搜索 tool](/docs/guides/tools-web-search).
+ [网页搜索工具](/docs/guides/tools-web-search).
- `type: "web_search" or "web_search_2025_08_26"`
- 网页搜索 工具的类型。可选值为 `web_search` 或 `web_search_2025_08_26`.
+ 网页搜索工具的类型。可选值为 `web_search` 或 `web_search_2025_08_26`.
- `"web_search"`
@@ -8005,22 +8007,22 @@
- `external_web_access: optional boolean`
- 允许 网页搜索 进行实时互联网访问。省略时默认为 true。当设置为 false 时,网页搜索 工具将以离线/仅缓存模式运行,不会获取新的外部内容。
+ 允许 网页搜索访问实时互联网。省略时默认为 true。当设为 false 时,网页搜索工具以离线/仅缓存模式运行,不会获取新的外部内容。
- `filters: optional object { allowed_domains } or null`
- 搜索的过滤条件。
+ 搜索的筛选条件。
- `allowed_domains: optional array of string or null`
搜索允许的域名。如果未提供,则允许所有域名。
- 所提供域名的子域名同样允许。
+ 同时也允许所提供域名的子域名。
示例: `["pubmed.ncbi.nlm.nih.gov"]`
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指引。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -8038,7 +8040,7 @@
- `country: optional string or null`
- 两个字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 用户的两字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
- `region: optional string or null`
@@ -8050,7 +8052,7 @@
- `type: optional "approximate"`
- 位置近似类型。始终为 `approximate`.
+ 位置近似的类型。始终为 `approximate`.
- `"approximate"`
@@ -8061,7 +8063,7 @@
- `server_label: string`
- 该 MCP 服务器的标签,用于在工具调用中识别它。
+ 此 MCP 服务器的标签,用于在工具调用中标识它。
- `type: "mcp"`
@@ -8071,7 +8073,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -8079,48 +8081,48 @@
- `allowed_tools: optional array of string or object { read_only, tool_names } or null`
- 允许使用的工具名称列表或筛选器对象。
+ 允许的工具名称列表或过滤对象。
- `McpAllowedTools = array of string`
- 允许使用的工具名称组成的字符串数组
+ 允许的工具名称的字符串数组
- `McpToolFilter object { read_only, tool_names }`
- 用于指定允许使用哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否为修改数据还是只读。如果某
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则将匹配此过滤器。
- `tool_names: optional array of string`
- 允许使用的工具名称列表。
+ 允许的工具名称列表。
- `authorization: optional string`
- 可用于远程 MCP 服务器的 OAuth 访问令牌,可配合自定义
- MCP 服务器 URL 或服务连接器使用。你的应用程序
- 必须处理 OAuth 授权流程,并在此处提供令牌。
+ 可用于远程 MCP 服务器的 OAuth 访问令牌,可以是
+ 配合自定义 MCP 服务器 URL 或服务连接器使用。你的应用
+ 必须处理 OAuth 授权流程并在此处提供令牌。
- `connector_id: optional "connector_dropbox" or "connector_gmail" or "connector_googlecalendar" or 5 more`
- 服务连接器的标识符,例如 ChatGPT 中可用的连接器。
- `server_url`, `connector_id`,或 `tunnel_id` 中的一个必须提供。了解更多
- 关于服务连接器的信息 [此处](/docs/guides/tools-remote-mcp#connectors).
+ 服务连接器的标识符,例如 ChatGPT 中可用的那些。其中之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。了解更多
+ 关于服务连接器 [此处](/docs/guides/tools-remote-mcp#connectors).
- 目前支持 `connector_id` 的值为:
+ 当前支持 `connector_id` 的值为:
- - Dropbox: `connector_dropbox`
- - Gmail: `connector_gmail`
- - Google Calendar: `connector_googlecalendar`
- - Google Drive: `connector_googledrive`
- - Microsoft Teams: `connector_microsoftteams`
- - Outlook Calendar: `connector_outlookcalendar`
- - Outlook Email: `connector_outlookemail`
- - SharePoint: `connector_sharepoint`
+ - Dropbox: `connector_dropbox`
+ - Gmail: `connector_gmail`
+ - Google Calendar: `connector_googlecalendar`
+ - Google Drive: `connector_googledrive`
+ - Microsoft Teams: `connector_microsoftteams`
+ - Outlook Calendar: `connector_outlookcalendar`
+ - Outlook Email: `connector_outlookemail`
+ - SharePoint: `connector_sharepoint`
- `"connector_dropbox"`
@@ -8140,56 +8142,56 @@
- `defer_loading: optional boolean`
- 此 MCP 工具是否为延迟加载并通过工具搜索发现。
+ 此 MCP 工具是否被延迟,并通过工具搜索发现。
- `headers: optional map[string] or null`
- 发送到 MCP 服务器的可选 HTTP 标头。用于身份验证
+ 发送到 MCP 服务端的可选 HTTP 标头。用于身份验证
或其他用途。
- `require_approval: optional object { always, never } or "always" or "never" or null`
- 指定 MCP 服务器中哪些工具需要审批。
+ 指定 MCP 服务端的哪些工具需要审批。
- `McpToolApprovalFilter object { always, never }`
- 指定 MCP 服务器中哪些工具需要审批。可以是
- `always`, `never`,也可以是与工具关联的过滤器对象
- 这些工具需要审批。
+ 指定 MCP 服务端的哪些工具需要审批。可以是
+ `always`, `never`,或与需要审批的工具关联的过滤器对象
+ 。
- `always: optional object { read_only, tool_names }`
- 用于指定允许使用哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否为修改数据还是只读。如果某
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则将匹配此过滤器。
- `tool_names: optional array of string`
- 允许使用的工具名称列表。
+ 允许的工具名称列表。
- `never: optional object { read_only, tool_names }`
- 用于指定允许使用哪些工具的筛选器对象。
+ 用于指定允许哪些工具的过滤对象。
- `read_only: optional boolean`
- 指示工具是否为修改数据还是只读。如果某
- MCP 服务器被 [annotated with `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
- ,它将匹配此筛选器。
+ 指示工具是否会修改数据或是只读的。如果某个
+ MCP 服务器被 [标注为 `readOnlyHint`](https://modelcontextprotocol.io/specification/2025-06-18/schema#toolannotations-readonlyhint),
+ ,则将匹配此过滤器。
- `tool_names: optional array of string`
- 允许使用的工具名称列表。
+ 允许的工具名称列表。
- `McpToolApprovalSetting = "always" or "never"`
- 为所有工具指定统一的审批策略。可选值之一为 `always` 或
- `never`。当设置为 `always`,所有工具都将需要审批。当
- 设置为 `never`,所有工具都将不需要审批。
+ 为所有工具指定统一的审批策略。可选值为 `always` 或
+ `never`。当设置为 `always`,所有工具都需要审批。当
+ 设置为 `never`,所有工具都不需要审批。
- `"always"`
@@ -8201,22 +8203,22 @@
- `server_url: optional string`
- MCP 服务器的 URL。需要提供以下其中一项 `server_url`, `connector_id`,或
- `tunnel_id` 。
+ MCP 服务器的 URL。以下之一 `server_url`, `connector_id`,或
+ `tunnel_id` 必须提供。
- `tunnel_id: optional string`
- 用于代替直接服务器 URL 的安全 MCP 隧道 ID。需要提供以下其中一项
- `server_url`, `connector_id`,或 `tunnel_id` 。
+ 用于替代直接服务器 URL 的安全 MCP 隧道 ID。以下之一
+ `server_url`, `connector_id`,或 `tunnel_id` 必须提供。
- `CodeInterpreter object { container, type, allowed_callers }`
- 运行 Python 代码以帮助生成对提示的响应的工具。
+ 运行 Python 代码以帮助生成提示响应的工具。
- `container: string or object { type, file_ids, memory_limit, network_policy }`
- 代码解释器容器。可以是容器 ID 或指定可上传到你的代码中的文件 ID 以及
- 指定可提供给代码的上传文件 ID,以及
+ 代码解释器容器。可以是容器 ID 或指定
+ 可供代码使用的已上传文件 ID 以及
可选的 `memory_limit` 设置的对象。
- `string`
@@ -8235,7 +8237,7 @@
- `file_ids: optional array of string`
- 提供给代码的可选上传文件列表。
+ 可供代码使用的已上传文件的可选列表。
- `memory_limit: optional "1g" or "4g" or "16g" or "64g" or null`
@@ -8259,13 +8261,13 @@
- `type: "code_interpreter"`
- 代码解释器工具的类型。固定为 `code_interpreter`.
+ 代码解释器工具的类型。始终为 `code_interpreter`.
- `"code_interpreter"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -8275,7 +8277,7 @@
- `type: "programmatic_tool_calling"`
- 工具的类型。固定为 `programmatic_tool_calling`.
+ 工具的类型。始终为 `programmatic_tool_calling`.
- `"programmatic_tool_calling"`
@@ -8285,13 +8287,13 @@
- `type: "image_generation"`
- 图像生成工具的类型。固定为 `image_generation`.
+ 图像生成工具的类型。始终为 `image_generation`.
- `"image_generation"`
- `action: optional "generate" or "edit" or "auto"`
- 是生成新图像还是编辑现有图像。默认值: `auto`.
+ 生成新图像还是编辑现有图像。默认值: `auto`.
- `"generate"`
@@ -8302,9 +8304,9 @@
- `background: optional "transparent" or "opaque" or "auto"`
设置生成图像的背景。可选值为 `transparent`,
- `opaque`,或 `auto`。之一。支持透明背景的
- GPT 图像模型可用。对于 `gpt-image-2` 和
- `gpt-image-2-2026-04-21`,该功能处于预览阶段。使用
+ `opaque`,或 `auto`。之一。透明背景可用于受支持的
+ GPT 图像模型。对于 `gpt-image-2` 和
+ `gpt-image-2-2026-04-21`,该支持处于预览阶段。当使用
`transparent`,时,将输出格式设置为 `png` 或 `webp`。默认值: `auto`.
- `"transparent"`
@@ -8315,7 +8317,7 @@
- `input_fidelity: optional "high" or "low" or null`
- 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所投入的精力。仅 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本模型支持,不支持 `gpt-image-1-mini`。支持 `high` 和 `low`。默认为 `low`.
+ 控制模型在匹配输入图像的风格和特征(尤其是面部特征)时所需付出的努力程度。此参数仅在 `gpt-image-1` 和 `gpt-image-1.5` 及更高版本的模型中受支持,在 `gpt-image-1-mini`。中不受支持。支持 `high` 和 `low`。默认为 `low`.
- `"high"`
@@ -8323,7 +8325,7 @@
- `input_image_mask: optional object { file_id, image_url }`
- 可选的修复蒙版。包含 `image_url`
+ 用于修复的可选蒙版。包含 `image_url`
(string, optional) 和 `file_id` (string, optional)。
- `file_id: optional string`
@@ -8402,13 +8404,13 @@
- `size: optional string or "1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定的任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 支持用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。关于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式表示的任意分辨率,例如 `WIDTHxHEIGHT` 宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `1536x864`。属于实验性功能,且最大支持的分辨率为 `2560x1440` 。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `3840x2160`。受 GPT image 模型支持; `1024x1024`, `1536x1024`,和 `1024x1536` 受允许自动调整大小的模型支持。对于; `auto` ,受允许自动调整大小的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `string`
- `"1024x1024" or "1024x1536" or "1536x1024" or "auto"`
- 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式指定的任意分辨率,例如 `WIDTHxHEIGHT` 字符串,例如 `1536x864`。宽度和高度都必须能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。超过 `2560x1440` 的分辨率为实验性,最大支持的分辨率为 `3840x2160`。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `1024x1024`, `1536x1024`,和 `1024x1536` 由 GPT 图像模型支持; `auto` 支持用于允许自动调整大小的模型。对于 `dall-e-2`,请使用以下其中之一 `256x256`, `512x512`,或 `1024x1024`。关于 `dall-e-3`,请使用以下其中之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
+ 生成图像的尺寸。对于 `gpt-image-2` 和 `gpt-image-2-2026-04-21`,支持以字符串形式表示的任意分辨率,例如 `WIDTHxHEIGHT` 宽度和高度必须都能被 16 整除,且请求的宽高比必须在 1:3 到 3:1 之间。高于 `1536x864`。属于实验性功能,且最大支持的分辨率为 `2560x1440` 。请求的尺寸还必须满足模型当前的像素和边长限制。标准尺寸 `3840x2160`。受 GPT image 模型支持; `1024x1024`, `1536x1024`,和 `1024x1536` 受允许自动调整大小的模型支持。对于; `auto` ,受允许自动调整大小的模型支持。对于 `dall-e-2`,使用以下之一 `256x256`, `512x512`,或 `1024x1024`。对于 `dall-e-3`,使用以下之一 `1024x1024`, `1792x1024`,或 `1024x1792`.
- `"1024x1024"`
@@ -8440,7 +8442,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -8464,13 +8466,13 @@
- `type: "custom"`
- 自定义工具的类型。始终为 `custom`.
+ 自定义工具的类型,始终为 `custom`.
- `"custom"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -8478,7 +8480,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索来发现它。
+ 此工具是否应该被延迟并通过工具搜索发现。
- `description: optional string`
@@ -8486,7 +8488,7 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `Namespace object { description, name, tools, type }`
@@ -8502,7 +8504,7 @@
- `tools: array of object { name, type, allowed_callers, 5 more } or object { name, type, allowed_callers, 3 more }`
- 此命名空间内可用的 function/custom 工具。
+ 此命名空间内可用的 function/自定义工具。
- `Function object { name, type, allowed_callers, 5 more }`
@@ -8514,7 +8516,7 @@
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -8522,19 +8524,19 @@
- `defer_loading: optional boolean`
- 该 function 是否应被延迟并通过工具搜索发现。
+ 此 function 是否应被延迟并通过 tool search 发现。
- `description: optional string or null`
- `output_schema: optional map[unknown] or null`
- 描述该 function 工具的字符串输出中所编码 JSON 值的 JSON Schema。这并不描述 content 数组形式的输出。
+ 描述此 function 工具的字符串输出中所编码的 JSON 值的 JSON Schema。该字段不描述 content 数组形式的输出。
- `parameters: optional unknown or null`
- `strict: optional boolean or null`
- 是否强制执行严格的参数校验。若未指定,Responses 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
+ 是否强制启用严格的参数校验。若省略,Responses 会尝试在 schema 兼容时使用严格校验,否则回退到非严格校验。
- `Custom object { name, type, allowed_callers, 3 more }`
@@ -8546,13 +8548,13 @@
- `type: "custom"`
- 自定义工具的类型。始终为 `custom`.
+ 自定义工具的类型,始终为 `custom`.
- `"custom"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -8560,7 +8562,7 @@
- `defer_loading: optional boolean`
- 是否应延迟此工具并通过工具搜索来发现它。
+ 此工具是否应该被延迟并通过工具搜索发现。
- `description: optional string`
@@ -8568,31 +8570,31 @@
- `format: optional CustomToolInputFormat`
- 自定义工具的输入格式。默认是不受约束的文本。
+ 自定义工具的输入格式。默认为无约束文本。
- `type: "namespace"`
- 工具的类型。固定为 `namespace`.
+ 工具的类型。始终为 `namespace`.
- `"namespace"`
- `ToolSearch object { type, description, execution, parameters }`
- 延迟工具的托管或 BYOT 工具搜索配置。
+ 用于延迟工具的 hosted 或 BYOT tool search 配置。
- `type: "tool_search"`
- 工具的类型。固定为 `tool_search`.
+ 工具的类型。始终为 `tool_search`.
- `"tool_search"`
- `description: optional string or null`
- 向模型展示的、用于客户端执行的工具搜索工具的描述。
+ 展示给模型的、针对客户端执行的 tool search 工具的描述。
- `execution: optional "server" or "client"`
- 工具搜索是由服务端执行还是由客户端执行。
+ tool search 由服务端执行还是由客户端执行。
- `"server"`
@@ -8600,15 +8602,15 @@
- `parameters: optional unknown or null`
- 客户端执行的工具搜索工具的参数 schema。
+ 针对客户端执行的 tool search 工具的参数 schema。
- `WebSearchPreview object { type, search_content_types, search_context_size, user_location }`
- 此工具会搜索网页以获取用于回复的相关结果。了解更多关于 [网页搜索 tool](https://platform.openai.com/docs/guides/tools-web-search).
+ 此工具会在网络上搜索可用于回复的相关结果。详细了解 [网页搜索工具](https://platform.openai.com/docs/guides/tools-web-search).
- `type: "web_search_preview" or "web_search_preview_2025_03_11"`
- 网页搜索 工具的类型。可选值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
+ 网页搜索工具的类型。可选值为 `web_search_preview` 或 `web_search_preview_2025_03_11`.
- `"web_search_preview"`
@@ -8622,7 +8624,7 @@
- `search_context_size: optional "low" or "medium" or "high"`
- 搜索使用的上下文窗口空间的高级指引。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
+ 用于搜索的上下文窗口空间使用量的高级指导。可选值为 `low`, `medium`,或 `high`. `medium` 为默认值。
- `"low"`
@@ -8636,7 +8638,7 @@
- `type: "approximate"`
- 位置近似类型。始终为 `approximate`.
+ 位置近似的类型。始终为 `approximate`.
- `"approximate"`
@@ -8646,7 +8648,7 @@
- `country: optional string or null`
- 两个字母的 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
+ 用户的两字母 [ISO 国家代码](https://en.wikipedia.org/wiki/ISO_3166-1) ,例如。 `US`.
- `region: optional string or null`
@@ -8662,13 +8664,13 @@
- `type: "apply_patch"`
- 工具的类型。固定为 `apply_patch`.
+ 工具的类型。始终为 `apply_patch`.
- `"apply_patch"`
- `allowed_callers: optional array of "direct" or "programmatic" or null`
- 工具调用上下文。
+ 工具调用的上下文。
- `"direct"`
@@ -8676,12 +8678,12 @@
- `top_p: number or null`
- 另一种使用 temperature 的采样方式,称为核采样(nucleus sampling),
- 模型会考虑具有 top_p 概率质量的标记的结果
- 。因此 0.1 表示仅考虑构成前 10% 概率质量的标记
- 会被纳入考虑。
+ 一种温度采样的替代方法,称为核采样,
+ 模型仅考虑概率质量排名前 top_p 的 token 结果
+ 。因此 0.1 表示仅考虑构成前 10% 概率质量的 token
+ 。
- 我们通常建议修改此项或 `temperature` ,但不要同时修改两者。
+ 我们通常建议修改此项或 `temperature` 但不要同时修改两者。
- `background: optional boolean or null`
@@ -8690,28 +8692,28 @@
- `completed_at: optional number or null`
- 此响应完成时的 Unix 时间戳(以秒为单位)。
- 仅当状态为 `completed`.
+ 该 Response 完成时的 Unix 时间戳(以秒为单位)。
+ 仅在状态为 `completed`.
- `conversation: optional object { id } or null`
- 此响应所属的对话。此响应中的输入项和输出项已自动添加到此对话中。
+ 该响应所属的对话。此响应中的输入项和输出项已自动添加到此对话中。
- `id: string`
- 与此响应关联的对话的唯一 ID。
+ 该响应所关联对话的唯一 ID。
- `max_output_tokens: optional number or null`
- 响应可生成的标记数上限,包括可见输出标记和 [推理 tokens](/docs/guides/reasoning).
+ 响应可生成 token 数量的上限,包括可见输出 token 和 [推理 tokens](/docs/guides/reasoning).
- `max_tool_calls: optional number or null`
- 在一次响应中可处理的内置工具调用总次数上限。此上限适用于所有内置工具调用,而非单个工具。模型后续对工具的任何调用尝试都将被忽略。
+ 在一次响应中可以处理的内置工具的最大调用总数。该上限适用于所有内置工具调用,而不是针对单个工具。模型对工具的任何后续调用尝试都将被忽略。
- `moderation: optional object { input, output } or null`
- 响应输入和输出的审核结果(如果请求了已审核的补全)。
+ 响应输入和输出的审核结果,前提是请求了已审核的补全。
- `input: object { categories, category_applied_input_types, category_scores, 3 more } or object { code, message, type }`
@@ -8723,11 +8725,11 @@
- `categories: map[boolean]`
- 审核类别到布尔值的字典,若输入被标记为属于该类别,则为 True。
+ 以审核类别为键、布尔值为值的字典,如果输入在该类别下被标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的得分所反映的输入模态。
- `"text"`
@@ -8735,7 +8737,7 @@
- `category_scores: map[number]`
- 审核类别到分数的字典。
+ 以审核类别为键、得分为值的字典。
- `flagged: boolean`
@@ -8747,7 +8749,7 @@
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果始终为 `moderation_result` 。
+ 对象类型,始终为 `moderation_result` (用于成功的审核结果)。
- `"moderation_result"`
@@ -8765,7 +8767,7 @@
- `type: "error"`
- 对象类型,对于成功的审核结果始终为 `error` (针对审核失败)。
+ 对象类型,始终为 `error` (用于审核失败)。
- `"error"`
@@ -8779,11 +8781,11 @@
- `categories: map[boolean]`
- 审核类别到布尔值的字典,若输入被标记为属于该类别,则为 True。
+ 以审核类别为键、布尔值为值的字典,如果输入在该类别下被标记则为 True。
- `category_applied_input_types: map[array of "text" or "image"]`
- 每个类别的分数所对应的输入模态。
+ 每个类别的得分所反映的输入模态。
- `"text"`
@@ -8791,7 +8793,7 @@
- `category_scores: map[number]`
- 审核类别到分数的字典。
+ 以审核类别为键、得分为值的字典。
- `flagged: boolean`
@@ -8803,7 +8805,7 @@
- `type: "moderation_result"`
- 对象类型,对于成功的审核结果始终为 `moderation_result` 。
+ 对象类型,始终为 `moderation_result` (用于成功的审核结果)。
- `"moderation_result"`
@@ -8821,19 +8823,19 @@
- `type: "error"`
- 对象类型,对于成功的审核结果始终为 `error` (针对审核失败)。
+ 对象类型,始终为 `error` (用于审核失败)。
- `"error"`
- `output_text: optional string or null`
- 仅SDK可用的便捷属性,包含所有
- 项聚合而成的 `output_text` 文本输出 `output` 数组(如有)。
+ SDK 专属的便捷属性,包含所有
+ 条目的 `output_text` 聚合文本输出 `output` 数组(如有)。
在 Python 和 JavaScript SDK 中受支持。
- `previous_response_id: optional string or null`
- 发给模型的上一条响应的唯一 ID。使用它来
+ 模型上一个响应的唯一 ID。使用它来
创建多轮对话。详细了解
[对话状态](/docs/guides/conversation-state)。不能与 `conversation`.
@@ -8848,23 +8850,23 @@
- `variables: optional map[string or ResponseInputText or ResponseInputImage or ResponseInputFile] or null`
- 用于在你的提示中替换变量的可选值映射。
- 替换值可以是字符串,也可以是其他
- Response 输入类型,例如图像或文件。
+ 可选的键值对,用于替换你的
+ 提示中的变量。替换值可以是字符串,也可以是其他
+ 响应输入类型,如图像或文件。
- `string`
- `ResponseInputText object { text, type, prompt_cache_breakpoint }`
- 发送给模型的文本输入。
+ 提供给模型的文本输入。
- `ResponseInputImage object { detail, type, file_id, 2 more }`
- 发送给模型的图像输入。了解有关 [图像输入](/docs/guides/vision).
+ 提供给模型的图像输入。了解 [图像输入](/docs/guides/vision).
- `ResponseInputFile object { type, detail, file_data, 4 more }`
- 发送给模型的输入文件。
+ 发送到模型的输入文件。
- `version: optional string or null`
@@ -8876,7 +8878,7 @@
- `prompt_cache_options: optional object { mode, ttl }`
- 应用于该响应的提示缓存选项。支持 `gpt-5.6` 及更高版本的模型。
+ 应用于该响应的提示缓存选项。受以下模型支持: `gpt-5.6` 及更高版本的模型。
- `mode: "implicit" or "explicit"`
@@ -8894,18 +8896,18 @@
- `prompt_cache_retention: optional "in_memory" or "24h" or null`
- 已弃用。请使用 `prompt_cache_options.ttl` 代替。
+ 已弃用。请使用 `prompt_cache_options.ttl` 替代。
- 提示缓存的保留策略。设置为 `24h` 以启用扩展的提示缓存,它会将缓存前缀保持更长时间,最长可达 24 小时。 [了解更多](/docs/guides/prompt-caching#prompt-cache-retention).
+ 提示缓存的保留策略。设置为 `24h` 可启用扩展提示缓存,使缓存前缀保持更长时间,最长可达 24 小时。 [了解更多](/docs/guides/prompt-caching#prompt-cache-retention).
该字段表示最大保留策略,而
- `prompt_cache_options.ttl` 表示最短缓存生命周期。这两个字段
- 彼此独立,互不影响。
+ `prompt_cache_options.ttl` 表示最短缓存生命周期。这两个
+ 字段相互独立,不会相互影响。
对于 `gpt-5.5`, `gpt-5.5-pro`,以及未来模型,仅 `24h` 。
- 对于同时支持两者的较旧模型 `in_memory` 和 `24h`,默认值取决于你组织的数据保留策略:
+ 对于同时支持两者的旧模型, `in_memory` 和 `24h`,默认值取决于你所在组织的数据保留策略:
- - 未启用 ZDR 的组织默认使用 `24h`.
- - 已启用 ZDR 的组织默认使用 `in_memory` 当 `prompt_cache_retention` 未指定时。
+ - 未启用 ZDR 的组织默认值为 `24h`.
+ - 已启用 ZDR 的组织默认值为 `in_memory` 当 `prompt_cache_retention` 未指定时。
- `"in_memory"`
@@ -8918,13 +8920,13 @@
- `context: optional "auto" or "current_turn" or "all_turns" or null`
- 控制在后续轮次中将哪些推理项渲染回模型。
- 如果省略或设置为 `auto`,则由模型决定上下文模式。
- `gpt-5.6` 模型系列默认采用 `all_turns`;较早的模型默认采用
+ 控制在后续轮次中哪些推理项会被重新渲染回模型。
+ 如果省略或设置为 `auto`,由模型决定上下文模式。
+ `gpt-5.6` 模型系列默认值为 `all_turns`;更早的模型默认值为
`current_turn`.
- 在响应中返回时,这是生效的推理上下文模式
- 用于该响应。
+ 当在响应中返回时,这是该响应所使用的有效推理上下文模式
+ 。
- `"auto"`
@@ -8934,12 +8936,12 @@
- `effort: optional ReasoningEffort or null`
- 对推理模型的推理力度进行约束。目前支持
+ 对推理模型在推理上的投入程度进行约束。当前支持
的取值包括 `none`, `minimal`, `low`, `medium`, `high`, `xhigh`,和 `max`.
- 降低推理力度可以带来更快的响应,并在响应中减少
- 用于推理的 token 数量。并非所有推理模型都支持每
- 个取值。请参阅
- [推理指南](https://platform.openai.com/docs/guides/reasoning)
+ 降低推理投入可以带来更快的响应,并在响应中消耗更少的
+ 推理 tokens。并非所有推理模型都支持每个
+ 取值。请参阅
+ [reasoning guide](https://platform.openai.com/docs/guides/reasoning)
以了解特定模型的支持情况。
- `"none"`
@@ -8958,11 +8960,11 @@
- `generate_summary: optional "auto" or "concise" or "detailed" or null`
- **已弃用:** 请使用 `summary` 代替。
+ **已弃用:** use `summary` 替代。
- 对模型执行的推理的摘要。这可以
- 有助于调试和理解模型的推理过程。
- 其取值为 `auto`, `concise`,或 `detailed`.
+ 模型所执行推理的摘要。
+ 这有助于调试和理解模型的推理过程。
+ 之一 `auto`, `concise`,或 `detailed`.
- `"auto"`
@@ -8974,7 +8976,7 @@
控制请求的推理执行模式。
- 在响应中返回时,这是生效的执行模式。
+ 在响应中返回时,表示实际生效的执行模式。
- `string`
@@ -8982,7 +8984,7 @@
控制请求的推理执行模式。
- 在响应中返回时,这是生效的执行模式。
+ 在响应中返回时,表示实际生效的执行模式。
- `"standard"`
@@ -8990,11 +8992,11 @@
- `summary: optional "auto" or "concise" or "detailed" or null`
- 对模型执行的推理的摘要。这可以
- 有助于调试和理解模型的推理过程。
- 其取值为 `auto`, `concise`,或 `detailed`.
+ 模型所执行推理的摘要。
+ 这有助于调试和理解模型的推理过程。
+ 之一 `auto`, `concise`,或 `detailed`.
- `concise` 受支持的模型包括 `computer-use-preview` 模型以及之后的所有推理模型 `gpt-5`.
+ `concise` 受支持 `computer-use-preview` 模型以及之后的所有推理模型 `gpt-5`.
- `"auto"`
@@ -9004,21 +9006,21 @@
- `safety_identifier: optional string or null`
- 一个稳定的标识符,用于帮助检测可能违反 OpenAI 使用政策的应用用户。
- 该 ID 应为一个字符串,用于唯一标识每个用户,最大长度为 64 个字符。我们建议对其用户名或电子邮件地址进行哈希处理,以避免向我们发送任何可识别信息。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
+ 一个稳定的标识符,用于帮助检测可能违反OpenAI使用政策的应用程序用户。
+ 该 ID 应为能够唯一标识每个用户的字符串,最大长度为 64 个字符。建议对其用户名或电子邮件地址进行哈希处理,以避免向我们发送任何身份识别信息。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
- `service_tier: optional ServiceTier or null`
指定用于处理请求的处理类型。
- - 如果设置为 'auto',则请求将使用在 Project 设置中配置的服务层级进行处理。除非另行配置,否则 Project 将使用 'default'。
- - 如果设置为 'default',则请求将以所选模型的标准定价和性能进行处理。
+ - 如果设置为 'auto',则请求将使用项目设置中配置的服务层级进行处理。除非另有配置,否则项目将使用 'default'。
+ - 如果设置为 'default',则请求将使用所选模型的标准定价和性能进行处理。
- 如果设置为 '[flex](/docs/guides/flex-processing)',则请求将使用 Flex Processing 服务层级进行处理。
- - 若要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中传入相应的 `service_tier=fast` 或 `service_tier=priority` 参数。响应中会显示相应的处理层级, `service_tier=priority` 无论你在请求中是否指定 `service_tier=fast` 或 `priority` 。
- - 如果设置为 'ultrafast',则请求将使用访问受控的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过它返回的响应将显示 `service_tier=ultrafast`.
- - 当未设置时,默认行为为 'auto'。
+ - 要在请求级别启用 [Fast mode](/api/docs/guides/fast-mode) ,请在 Responses 或 Chat Completions 中包含 `service_tier=fast` 或 `service_tier=priority` 参数。响应中将显示 `service_tier=priority` ,无论你是否在请求中指定 `service_tier=fast` 或 `priority` 。
+ - 如果设置为 'ultrafast',则请求将使用访问受控的 Ultrafast Processing 服务层级进行处理。该层级目前可用于 `gpt-5.6-sol`;通过该层级服务的响应将显示 `service_tier=ultrafast`.
+ - 未设置时,默认行为为 'auto'。
- 当设置了 `service_tier` 参数时,响应正文将包含基于实际用于处理请求的处理模式所得到的 `service_tier` 值。该响应值可能与参数中设置的值不同。
+ 当 `service_tier` 参数被设置时,响应体中将包含基于实际用于处理该请求的处理模式所得到的 `service_tier` 值。该响应值可能与参数中设置的值不同。
- `"auto"`
@@ -9036,7 +9038,7 @@
- `status: optional ResponseStatus`
- 响应生成的状态。取值为 `completed`, `failed`,
+ 响应生成的状态。取值之一为 `completed`, `failed`,
`in_progress`, `cancelled`, `queued`,或 `incomplete`.
- `"completed"`
@@ -9053,31 +9055,31 @@
- `text: optional ResponseTextConfig`
- 模型文本响应的配置选项。可以是纯文本或
+ 模型文本响应的配置选项。可以是纯
文本或结构化 JSON 数据。了解更多:
- - [文本输入与输出](/docs/guides/text)
+ - [文本输入和输出](/docs/guides/text)
- [结构化输出](/docs/guides/structured-outputs)
- `format: optional ResponseFormatTextConfig`
- 用于指定模型必须输出的格式的对象。
+ 指定模型必须输出的格式的对象。
- 配置 `{ "type": "json_schema" }` 启用结构化输出,
- 这将确保模型与你提供的 JSON schema 保持一致。更多信息请参阅
- [结构化输出指南](/docs/guides/structured-outputs).
+ 配置 `{ "type": "json_schema" }` 可启用 Structured Outputs,
+ 从而确保模型的输出与你提供的 JSON schema 相匹配。详见
+ [Structured Outputs 指南](/docs/guides/structured-outputs).
默认格式为 `{ "type": "text" }` ,不包含其他选项。
**不建议用于 gpt-4o 及更新的模型:**
设置为 `{ "type": "json_object" }` 会启用旧的 JSON 模式,该模式
- 可确保模型生成的消息是有效的 JSON。对于支持 `json_schema`
- 的模型,建议优先使用。
+ 可确保模型生成的消息是合法的 JSON。对支持的模型,推荐使用 `json_schema`
+ 。
- `ResponseFormatText object { type }`
- 默认响应格式。用于生成文本响应。
+ 默认的响应格式。用于生成文本响应。
- `type: "text"`
@@ -9087,18 +9089,18 @@
- `ResponseFormatTextJSONSchemaConfig object { name, schema, type, 2 more }`
- JSON Schema 响应格式。用于生成结构化 JSON 响应。
- 详细了解 [结构化输出](/docs/guides/structured-outputs).
+ 用于生成结构化 JSON 响应的 JSON Schema 响应格式。
+ 了解更多关于 [Structured Outputs](/docs/guides/structured-outputs).
- `name: string`
- 响应格式的名称。必须为 a-z、A-Z、0-9,或包含
- 下划线和短横线,且最大长度为 64。
+ 响应格式的名称。只能包含 a-z、A-Z、0-9,或者包含
+ 下划线和短横线,最长 64 个字符。
- `schema: map[unknown]`
- 响应格式的架构,以 JSON Schema 对象形式描述。
- 了解如何构建 JSON Schema [此处](https://json-schema.org/).
+ 响应格式的架构,以 JSON Schema 对象的形式描述。
+ 了解如何构建 JSON 架构 [此处](https://json-schema.org/).
- `type: "json_schema"`
@@ -9108,22 +9110,22 @@
- `description: optional string`
- 响应格式用途的说明,由模型用于
+ 对响应格式用途的描述,供模型用来
确定如何按该格式进行响应。
- `strict: optional boolean or null`
- 生成输出时是否启用严格的架构遵循。
- 如果设置为 true,模型将始终遵循中定义的精确架构
- 字段。仅支持 JSON Schema 的子集,当 `schema` field. Only a subset of JSON Schema is supported when
- `strict` 时 `true`。如需了解更多信息,请阅读 [结构化输出
+ 是否在生成输出时启用严格的架构遵循。
+ 如果设置为 true,模型将始终遵循 字段中定义的
+ 确切架构。 `schema` 仅支持 JSON Schema 的一个子集,当
+ `strict` 是 `true`。要了解更多信息,请参阅 [Structured Outputs
指南](/docs/guides/structured-outputs).
- `ResponseFormatJSONObject object { type }`
- JSON object 响应格式。一种较旧的生成 JSON 响应的方法。
- 建议对支持它的模型使用 `json_schema` 。请注意,
- 模型在没有系统或用户消息指示的情况下不会生成 JSON
+ JSON 对象响应格式。一种较旧的生成 JSON 响应的方法。
+ 建议对支持它的模型使用 `json_schema` 。注意,如果没有系统或用户消息指示模型生成 JSON,
+ 模型将不会生成 JSON
。
- `type: "json_object"`
@@ -9134,9 +9136,9 @@
- `verbosity: optional "low" or "medium" or "high" or null`
- 限制模型响应的详细程度。较低的值会生成
- 更简洁的响应,而较高的值会生成更详细的响应。
- 当前支持的值包括 `low`, `medium`,和 `high`. 默认值为
+ 限制模型响应的详细程度。较低的值将生成
+ 更简洁的响应,较高的值将生成更详细的响应。
+ 目前支持的值包括 `low`, `medium`,和 `high`. 默认值为
`medium`.
- `"low"`
@@ -9147,19 +9149,19 @@
- `top_logprobs: optional number or null`
- 一个介于 0 到 20 之间的整数,用于指定在每个 token 位置返回的最可能的
- token 的最大数量,每个 token 都有一个对应的对数
- 概率。在某些情况下,返回的 token 数量可能会少于
- 所请求的数量。
+ 介于 0 到 20 之间的整数,指定在每个 token 位置返回的最可能的
+ token 最大数量,每个 token 附带相应的对数
+ 概率。在某些情况下,返回的 token 数量可能少于
+ 请求的数量。
- `truncation: optional "auto" or "disabled" or null`
用于模型响应的截断策略。
- `auto`: 如果此 Response 的输入超过
- 模型的上下文窗口大小,模型将通过从对话
- 开头丢弃条目来截断响应以适应上下文窗口。
- - `disabled` (默认): 如果输入大小将超过模型的上下文窗口
+ 模型的上下文窗口大小,模型将通过从对话开头丢弃条目来截断
+ 响应,以适配上下文窗口。
+ - `disabled` (默认):如果输入大小将超过模型的上下文窗口
大小,请求将失败并返回 400 错误。
- `"auto"`
@@ -9169,11 +9171,11 @@
- `usage: optional ResponseUsage`
表示 token 使用详情,包括输入 token、输出 token、
- 输出 token 的细分以及所使用的 token 总数。
+ 输出 token 的细分,以及使用的 token 总数。
- `input_tokens: number`
- 输入 token 的数量。
+ 输入 token 数量。
- `input_tokens_details: object { cache_write_tokens, cached_tokens }`
@@ -9186,11 +9188,11 @@
- `cached_tokens: number`
从缓存中检索到的 token 数量。
- [详细了解提示词缓存](/docs/guides/prompt-caching).
+ [详细了解提示缓存](/docs/guides/prompt-caching).
- `output_tokens: number`
- 输出 token 的数量。
+ 输出 token 数量。
- `output_tokens_details: object { reasoning_tokens }`
@@ -9204,15 +9206,11 @@
使用的 token 总数。
- - `compute_units: optional number or null`
-
- 请求的计算单元。当前可用时为 null。
-
- `user: optional string`
- 此字段正在被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以保持缓存优化。
- 用于标识最终用户的稳定标识符。
- 通过更好地对相似请求进行分桶来提升缓存命中率,并帮助 OpenAI 检测和防止滥用。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
+ 此字段正被替换为 `safety_identifier` 和 `prompt_cache_key`。请改用 `prompt_cache_key` 以维持缓存优化效果。
+ 面向终端用户的稳定标识符。
+ 通过更好地对相似请求进行分桶来提升缓存命中率,并帮助OpenAI检测和防止滥用行为。 [了解更多](/docs/guides/safety-best-practices#safety-identifiers).
### 示例
@@ -9387,8 +9385,7 @@ curl https://api.openai.com/v1/responses/$RESPONSE_ID \
"output_tokens_details": {
"reasoning_tokens": 0
},
- "total_tokens": 0,
- "compute_units": 0
+ "total_tokens": 0
},
"user": "user-1234"
}
diff --git a/docs/zh/api/reference/resources/responses/streaming-events.md b/docs/zh/api/reference/resources/responses/streaming-events.md
index 52c374e..7419047 100644
--- a/docs/zh/api/reference/resources/responses/streaming-events.md
+++ b/docs/zh/api/reference/resources/responses/streaming-events.md
@@ -1,17 +1,17 @@
# Responses 流式事件
-> 如需完整文档索引,请参阅 [llms.txt](/llms.txt)。可通过在页面 URL 后追加 `.md` 获取文档页面的 Markdown 版本。
+> 如需完整的文档索引,请参阅 [llms.txt](/llms.txt)。通过在页面 URL 后追加 `.md` 可获取文档页面的 Markdown 版本。
-当你 [创建 Response](https://developers.openai.com/docs/api-reference/responses/create) 时,设置
-`stream` 为 `true`,服务端会向
-客户端发送服务器发送事件(server-sent events),这些事件在 Response 生成过程中发出。本节列出了服务端发出的事件。
-服务端所发出的事件。
+当你 [create a Response](https://developers.openai.com/docs/api-reference/responses/create) 时设置
+`stream` 为 `true`, the server will emit server-sent events to the
+client as the Response is generated. 本节列出了服务器发出的事件。
+这些事件由服务器发出。
-[了解更多关于流式 Response 的信息](https://developers.openai.com/docs/guides/streaming-responses?api-mode=responses).
+[Learn more about streaming responses](https://developers.openai.com/docs/guides/streaming-responses?api-mode=responses).
## response.created
-在响应创建时发出的事件。
+在创建响应时发出的事件。
### Schema
@@ -1917,8 +1917,7 @@ Schema name: `ResponseCreatedEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response > (schema) > (property) user": {
@@ -2267,6 +2266,10 @@ Schema name: `ResponseCreatedEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -2279,7 +2282,8 @@ Schema name: `ResponseCreatedEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) responses > (model) response > (schema) > (property) instructions > (variant) 0": {
@@ -7495,23 +7499,6 @@ Schema name: `ResponseCreatedEvent`
"schemaType": "integer",
"children": []
},
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/ResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) responses > (model) response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/ResponseUsage",
@@ -7534,9 +7521,6 @@ Schema name: `ResponseCreatedEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -7546,8 +7530,7 @@ Schema name: `ResponseCreatedEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response_error > (schema) > (property) code > (member) 0": {
@@ -7698,6 +7681,13 @@ Schema name: `ResponseCreatedEvent`
}
},
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -54336,7 +54326,7 @@ Schema name: `ResponseCreatedEvent`
## response.in_progress
-当响应正在进行时发出。
+在响应进行中时发出。
### Schema
@@ -56242,8 +56232,7 @@ Schema name: `ResponseInProgressEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response > (schema) > (property) user": {
@@ -56592,6 +56581,10 @@ Schema name: `ResponseInProgressEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -56604,7 +56597,8 @@ Schema name: `ResponseInProgressEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) responses > (model) response > (schema) > (property) instructions > (variant) 0": {
@@ -61820,23 +61814,6 @@ Schema name: `ResponseInProgressEvent`
"schemaType": "integer",
"children": []
},
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/ResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) responses > (model) response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/ResponseUsage",
@@ -61859,9 +61836,6 @@ Schema name: `ResponseInProgressEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -61871,8 +61845,7 @@ Schema name: `ResponseInProgressEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response_error > (schema) > (property) code > (member) 0": {
@@ -62023,6 +61996,13 @@ Schema name: `ResponseInProgressEvent`
}
},
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -110567,8 +110547,7 @@ Schema name: `ResponseCompletedEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response > (schema) > (property) user": {
@@ -110917,6 +110896,10 @@ Schema name: `ResponseCompletedEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -110929,7 +110912,8 @@ Schema name: `ResponseCompletedEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) responses > (model) response > (schema) > (property) instructions > (variant) 0": {
@@ -116145,23 +116129,6 @@ Schema name: `ResponseCompletedEvent`
"schemaType": "integer",
"children": []
},
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/ResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) responses > (model) response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/ResponseUsage",
@@ -116184,9 +116151,6 @@ Schema name: `ResponseCompletedEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -116196,8 +116160,7 @@ Schema name: `ResponseCompletedEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response_error > (schema) > (property) code > (member) 0": {
@@ -116348,6 +116311,13 @@ Schema name: `ResponseCompletedEvent`
}
},
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -163003,7 +162973,7 @@ Schema name: `ResponseCompletedEvent`
## response.failed
-响应失败时发出的事件。
+当响应失败时发出的事件。
### Schema
@@ -164909,8 +164879,7 @@ Schema name: `ResponseFailedEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response > (schema) > (property) user": {
@@ -165259,6 +165228,10 @@ Schema name: `ResponseFailedEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -165271,7 +165244,8 @@ Schema name: `ResponseFailedEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) responses > (model) response > (schema) > (property) instructions > (variant) 0": {
@@ -170487,23 +170461,6 @@ Schema name: `ResponseFailedEvent`
"schemaType": "integer",
"children": []
},
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/ResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) responses > (model) response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/ResponseUsage",
@@ -170526,9 +170483,6 @@ Schema name: `ResponseFailedEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -170538,8 +170492,7 @@ Schema name: `ResponseFailedEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response_error > (schema) > (property) code > (member) 0": {
@@ -170690,6 +170643,13 @@ Schema name: `ResponseFailedEvent`
}
},
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -217326,7 +217286,7 @@ Schema name: `ResponseFailedEvent`
## response.incomplete
-当响应以未完成状态结束时触发的事件。
+当响应未完成结束时发出的事件。
### Schema
@@ -219232,8 +219192,7 @@ Schema name: `ResponseIncompleteEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response > (schema) > (property) user": {
@@ -219582,6 +219541,10 @@ Schema name: `ResponseIncompleteEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -219594,7 +219557,8 @@ Schema name: `ResponseIncompleteEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) responses > (model) response > (schema) > (property) instructions > (variant) 0": {
@@ -224810,23 +224774,6 @@ Schema name: `ResponseIncompleteEvent`
"schemaType": "integer",
"children": []
},
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/ResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) responses > (model) response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/ResponseUsage",
@@ -224849,9 +224796,6 @@ Schema name: `ResponseIncompleteEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -224861,8 +224805,7 @@ Schema name: `ResponseIncompleteEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response_error > (schema) > (property) code > (member) 0": {
@@ -225013,6 +224956,13 @@ Schema name: `ResponseIncompleteEvent`
}
},
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -271649,7 +271599,7 @@ Schema name: `ResponseIncompleteEvent`
## response.output_item.added
-当添加新的输出项时触发。
+当添加新的输出项时发出。
### Schema
@@ -295150,7 +295100,7 @@ Schema name: `ResponseOutputItemAddedEvent`
## response.output_item.done
-当输出项被标记为完成时发出。
+当某个输出项被标记为完成时发出。
### Schema
@@ -318657,7 +318607,7 @@ Schema name: `ResponseOutputItemDoneEvent`
## response.content_part.added
-当添加新的内容部分时触发。
+当新增一个内容部分时发出。
### Schema
@@ -319806,7 +319756,7 @@ Schema name: `ResponseContentPartAddedEvent`
## response.content_part.done
-内容部分完成时发出。
+在内容片段完成时发出。
### Schema
@@ -320955,7 +320905,7 @@ Schema name: `ResponseContentPartDoneEvent`
## response.output_text.delta
-在出现额外的文本增量时发出。
+当存在额外的文本增量时发出。
### Schema
@@ -321244,7 +321194,7 @@ Schema name: `ResponseTextDeltaEvent`
## response.output_text.done
-在文本内容完成时发出。
+当文本内容完成时发出。
### Schema
@@ -321533,7 +321483,7 @@ Schema name: `ResponseTextDoneEvent`
## response.refusal.delta
-当存在部分拒绝文本时触发。
+在出现部分拒绝文本时发出。
### Schema
@@ -321863,7 +321813,7 @@ Schema name: `ResponseRefusalDoneEvent`
## response.function_call_arguments.delta
-当存在函数调用参数的部分增量时发出。
+当存在部分函数调用参数的增量时发出。
### Schema
@@ -322009,7 +321959,7 @@ Schema name: `ResponseFunctionCallArgumentsDeltaEvent`
## response.function_call_arguments.done
-在函数调用参数最终确定时发出。
+当函数调用参数最终确定时触发。
### Schema
@@ -322173,7 +322123,7 @@ Schema name: `ResponseFunctionCallArgumentsDoneEvent`
## response.file_search_call.in_progress
-当发起一次文件搜索调用时发出。
+在发起 文件搜索 调用时发出。
### Schema
@@ -322300,7 +322250,7 @@ Schema name: `ResponseFileSearchCallInProgressEvent`
## response.file_search_call.searching
-当 文件搜索 正在执行搜索时发出。
+当 文件搜索正在执行搜索时发出。
### Schema
@@ -322427,7 +322377,7 @@ Schema name: `ResponseFileSearchCallSearchingEvent`
## response.file_search_call.completed
-当一次文件搜索调用完成(已找到结果)时发出。
+当 文件搜索 调用完成时发出(已找到结果)。
### Schema
@@ -322554,7 +322504,7 @@ Schema name: `ResponseFileSearchCallCompletedEvent`
## response.web_search_call.in_progress
-在发起 网页搜索 调用时发出。
+在发起网页搜索调用时发出。
### Schema
@@ -322681,7 +322631,7 @@ Schema name: `ResponseWebSearchCallInProgressEvent`
## response.web_search_call.searching
-当 网页搜索 调用正在执行时发出。
+当一次网页搜索调用正在执行时发出。
### Schema
@@ -322808,7 +322758,7 @@ Schema name: `ResponseWebSearchCallSearchingEvent`
## response.web_search_call.completed
-当一次网页搜索调用完成时发出。
+在 网页搜索 调用完成时发出。
### Schema
@@ -322935,7 +322885,7 @@ Schema name: `ResponseWebSearchCallCompletedEvent`
## response.reasoning_summary_part.added
-当新增的推理摘要分片被添加时触发。
+当添加新的推理总结部分时发出。
### Schema
@@ -323160,7 +323110,7 @@ Schema name: `ResponseReasoningSummaryPartAddedEvent`
## response.reasoning_summary_part.done
-当推理摘要部分完成时触发。
+在某个推理摘要部分完成时发出。
### Schema
@@ -323420,7 +323370,7 @@ Schema name: `ResponseReasoningSummaryPartDoneEvent`
## response.reasoning_summary_text.delta
-当向推理摘要文本添加增量时触发。
+当向推理摘要文本添加增量时发出。
### Schema
@@ -323750,7 +323700,7 @@ Schema name: `ResponseReasoningSummaryTextDoneEvent`
## response.reasoning_text.delta
-当向推理文本添加增量时触发。
+当向推理文本添加增量时发出。
### Schema
@@ -323915,7 +323865,7 @@ Schema name: `ResponseReasoningTextDeltaEvent`
## response.reasoning_text.done
-当一段推理文本完成时发出。
+当推理文本完成时触发。
### Schema
@@ -324080,7 +324030,7 @@ Schema name: `ResponseReasoningTextDoneEvent`
## response.image_generation_call.completed
-当图像生成工具调用已完成且最终图像可用时发出。
+当图像生成工具调用完成且最终图像可用时发出。
### Schema
@@ -324207,7 +324157,7 @@ Schema name: `ResponseImageGenCallCompletedEvent`
## response.image_generation_call.generating
-当图像生成工具调用正在主动生成图像(中间状态)时发出。
+当图像生成工具调用正在主动生成图像时发出(中间状态)。
### Schema
@@ -324461,7 +324411,7 @@ Schema name: `ResponseImageGenCallInProgressEvent`
## response.image_generation_call.partial_image
-在图像生成流式传输期间,当有部分图像可用时发出。
+在图像生成流式传输过程中,当有部分图像可用时发出。
### Schema
@@ -324698,7 +324648,7 @@ Schema name: `ResponseImageGenCallPartialImageEvent`
## response.mcp_call_arguments.delta
-在 MCP 工具调用的参数有增量(部分更新)时发出。
+当 MCP 工具调用的参数存在增量(部分更新)时发出。
### Schema
@@ -324844,7 +324794,7 @@ Schema name: `ResponseMCPCallArgumentsDeltaEvent`
## response.mcp_call_arguments.done
-在 MCP 工具调用的参数确定后发出。
+当 MCP 工具调用的参数最终确定时发出。
### Schema
@@ -324990,7 +324940,7 @@ Schema name: `ResponseMCPCallArgumentsDoneEvent`
## response.mcp_call.completed
-当 MCP 工具调用成功完成时发出。
+MCP 工具调用成功完成时发出。
### Schema
@@ -325244,7 +325194,7 @@ Schema name: `ResponseMCPCallFailedEvent`
## response.mcp_call.in_progress
-在 MCP 工具调用进行中时发出。
+当 MCP 工具调用进行中时发出。
### Schema
@@ -325371,7 +325321,7 @@ Schema name: `ResponseMCPCallInProgressEvent`
## response.mcp_list_tools.completed
-当可用 MCP 工具列表成功获取后发出。
+在可用 MCP 工具列表成功被检索到时发出。
### Schema
@@ -325625,7 +325575,7 @@ Schema name: `ResponseMCPListToolsFailedEvent`
## response.mcp_list_tools.in_progress
-在系统正在检索可用 MCP 工具列表时发出。
+当系统正在检索可用的 MCP 工具列表时发出。
### Schema
@@ -325879,7 +325829,7 @@ Schema name: `ResponseCodeInterpreterCallInProgressEvent`
## response.code_interpreter_call.interpreting
-当代码解释器正在主动解释代码片段时发出。
+当代码解释器正在主动解释代码片段时触发。
### Schema
@@ -326006,7 +325956,7 @@ Schema name: `ResponseCodeInterpreterCallInterpretingEvent`
## response.code_interpreter_call.completed
-在代码解释器调用完成时发出。
+当代码解释器调用完成时发出。
### Schema
@@ -326279,7 +326229,7 @@ Schema name: `ResponseCodeInterpreterCallCodeDeltaEvent`
## response.code_interpreter_call_code.done
-当代码片段由代码解释器完成最终处理时触发。
+当代码片段被代码解释器完成时触发。
### Schema
@@ -326425,7 +326375,7 @@ Schema name: `ResponseCodeInterpreterCallCodeDoneEvent`
## response.output_text.annotation.added
-当向输出文本内容添加标注时发出。
+当向输出文本内容添加注释时触发。
### Schema
@@ -327151,7 +327101,7 @@ Schema name: `ResponseOutputTextAnnotationAddedEvent`
## response.queued
-当响应被排入队列并等待处理时触发。
+当响应已排队并等待处理时发出。
### Schema
@@ -329057,8 +329007,7 @@ Schema name: `ResponseQueuedEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response > (schema) > (property) user": {
@@ -329407,6 +329356,10 @@ Schema name: `ResponseQueuedEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -329419,7 +329372,8 @@ Schema name: `ResponseQueuedEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) responses > (model) response > (schema) > (property) instructions > (variant) 0": {
@@ -334635,23 +334589,6 @@ Schema name: `ResponseQueuedEvent`
"schemaType": "integer",
"children": []
},
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/ResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) responses > (model) response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/ResponseUsage",
@@ -334674,9 +334611,6 @@ Schema name: `ResponseQueuedEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -334686,8 +334620,7 @@ Schema name: `ResponseQueuedEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response_error > (schema) > (property) code > (member) 0": {
@@ -334838,6 +334771,13 @@ Schema name: `ResponseQueuedEvent`
}
},
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -381594,7 +381534,7 @@ Schema name: `ResponseCustomToolCallInputDeltaEvent`
## response.custom_tool_call_input.done
-表示自定义工具调用的输入已完整的事件。
+表示自定义工具调用的输入已完成的 Event。
### Schema
@@ -381885,7 +381825,7 @@ Schema name: `ResponseErrorEvent`
## response.audio.delta
-当存在部分音频响应时发出。
+当存在部分音频响应时触发。
### Schema
@@ -381994,7 +381934,7 @@ Schema name: `ResponseAudioDeltaEvent`
## response.audio.done
-当音频响应完成时发出。
+当音频响应完成时触发。
### Schema
@@ -382084,7 +382024,7 @@ Schema name: `ResponseAudioDoneEvent`
## response.audio.transcript.delta
-在出现音频的部分转写时触发。
+当存在音频的部分转录文本时发出。
### Schema
@@ -382283,7 +382223,7 @@ Schema name: `ResponseAudioTranscriptDoneEvent`
## response.shell_call_command.added
-指示某条 shell 命令已添加到工具调用的流事件。
+表示某个 shell 命令已添加到工具调用的流式事件。
### Schema
@@ -382596,7 +382536,7 @@ Schema name: `ResponseShellCallCommandDeltaStreamingEvent`
## response.shell_call_command.done
-指示 shell 命令已完成的流式事件。
+表示 shell 命令已完成的流式事件。
### Schema
@@ -382743,7 +382683,7 @@ Schema name: `ResponseShellCallCommandDoneStreamingEvent`
## response.shell_call_output_content.delta
-一个流式事件,用于表示 shell 调用输出被增量添加。
+一个流式事件,用于指示 shell 调用输出被增量添加。
### Schema
diff --git a/docs/zh/api/reference/resources/responses/websocket-events.md b/docs/zh/api/reference/resources/responses/websocket-events.md
index d0cd8e7..45d96c7 100644
--- a/docs/zh/api/reference/resources/responses/websocket-events.md
+++ b/docs/zh/api/reference/resources/responses/websocket-events.md
@@ -1,8 +1,8 @@
# WebSocket 事件
-> 如需查看完整文档索引,请参阅 [llms.txt](/llms.txt)。可通过在页面 URL 末尾追加 `.md` 来获取文档页面的 Markdown 版本。
+> 完整的文档索引请参阅 [llms.txt](/llms.txt)。可通过在页面 URL 后追加 `.md` 来获取文档页面的 Markdown 版本。
-通过持久 Responses API WebSocket 连接发送客户端事件并接收服务端事件。 [了解有关 WebSocket 模式的更多信息。](https://developers.openai.com/api/docs/guides/websocket-mode)
+通过持久的 Responses API WebSocket 连接发送客户端事件并接收服务端事件。 [了解有关 WebSocket 模式的更多信息。](https://developers.openai.com/api/docs/guides/websocket-mode)
## 客户端事件
@@ -11,13 +11,13 @@
### response.create
通过持久 WebSocket 连接创建响应的客户端事件。
-该载荷使用与 `POST /v1/responses`,相同的顶层字段,外加
-WebSocket 专属的信封元数据。
+此负载使用与 `POST /v1/responses`,相同的顶层字段,外加
+仅适用于 WebSocket 的信封元数据。
备注:
- `stream` 在 WebSocket 上是隐式的,不应发送。
- `background` 在 WebSocket 上不支持。
-- `stream_id` 仅限 WebSocket,不属于 `POST /v1/responses`.
+- `stream_id` 仅适用于 WebSocket,不属于 `POST /v1/responses`.
#### Schema
@@ -34753,11 +34753,11 @@ Schema name: `ResponsesClientEventResponseCreate`
## 服务端事件(仅 WebSocket)
-仅通过 Responses API WebSocket 连接发出事件。
+仅通过 Responses API WebSocket 连接发出的事件。
### error
-在处理 Responses WebSocket 请求时发生错误时触发。
+在处理 Responses WebSocket 请求过程中发生错误时触发。
#### Schema
@@ -36958,8 +36958,7 @@ Schema name: `ResponseCreatedEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response > (schema) > (property) user": {
@@ -37308,6 +37307,10 @@ Schema name: `ResponseCreatedEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -37320,7 +37323,8 @@ Schema name: `ResponseCreatedEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) responses > (model) response > (schema) > (property) instructions > (variant) 0": {
@@ -42536,23 +42540,6 @@ Schema name: `ResponseCreatedEvent`
"schemaType": "integer",
"children": []
},
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/ResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) responses > (model) response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/ResponseUsage",
@@ -42575,9 +42562,6 @@ Schema name: `ResponseCreatedEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -42587,8 +42571,7 @@ Schema name: `ResponseCreatedEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response_error > (schema) > (property) code > (member) 0": {
@@ -42739,6 +42722,13 @@ Schema name: `ResponseCreatedEvent`
}
},
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -91318,8 +91308,7 @@ Schema name: `ResponseInProgressEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response > (schema) > (property) user": {
@@ -91668,6 +91657,10 @@ Schema name: `ResponseInProgressEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -91680,7 +91673,8 @@ Schema name: `ResponseInProgressEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) responses > (model) response > (schema) > (property) instructions > (variant) 0": {
@@ -96896,23 +96890,6 @@ Schema name: `ResponseInProgressEvent`
"schemaType": "integer",
"children": []
},
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/ResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) responses > (model) response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/ResponseUsage",
@@ -96935,9 +96912,6 @@ Schema name: `ResponseInProgressEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -96947,8 +96921,7 @@ Schema name: `ResponseInProgressEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response_error > (schema) > (property) code > (member) 0": {
@@ -97099,6 +97072,13 @@ Schema name: `ResponseInProgressEvent`
}
},
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -143737,7 +143717,7 @@ Schema name: `ResponseInProgressEvent`
### response.completed
-当模型响应完成时触发。
+当模型响应完成时发出。
#### Schema
@@ -145678,8 +145658,7 @@ Schema name: `ResponseCompletedEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response > (schema) > (property) user": {
@@ -146028,6 +146007,10 @@ Schema name: `ResponseCompletedEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -146040,7 +146023,8 @@ Schema name: `ResponseCompletedEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) responses > (model) response > (schema) > (property) instructions > (variant) 0": {
@@ -151256,23 +151240,6 @@ Schema name: `ResponseCompletedEvent`
"schemaType": "integer",
"children": []
},
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/ResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) responses > (model) response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/ResponseUsage",
@@ -151295,9 +151262,6 @@ Schema name: `ResponseCompletedEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -151307,8 +151271,7 @@ Schema name: `ResponseCompletedEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response_error > (schema) > (property) code > (member) 0": {
@@ -151459,6 +151422,13 @@ Schema name: `ResponseCompletedEvent`
}
},
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -198114,7 +198084,7 @@ Schema name: `ResponseCompletedEvent`
### response.failed
-当响应失败时触发的事件。
+当响应失败时发出的事件。
#### Schema
@@ -200055,8 +200025,7 @@ Schema name: `ResponseFailedEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response > (schema) > (property) user": {
@@ -200405,6 +200374,10 @@ Schema name: `ResponseFailedEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -200417,7 +200390,8 @@ Schema name: `ResponseFailedEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) responses > (model) response > (schema) > (property) instructions > (variant) 0": {
@@ -205633,23 +205607,6 @@ Schema name: `ResponseFailedEvent`
"schemaType": "integer",
"children": []
},
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/ResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) responses > (model) response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/ResponseUsage",
@@ -205672,9 +205629,6 @@ Schema name: `ResponseFailedEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -205684,8 +205638,7 @@ Schema name: `ResponseFailedEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response_error > (schema) > (property) code > (member) 0": {
@@ -205836,6 +205789,13 @@ Schema name: `ResponseFailedEvent`
}
},
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -252472,7 +252432,7 @@ Schema name: `ResponseFailedEvent`
### response.incomplete
-当响应以未完成状态结束时发出的事件。
+当响应因未完成而结束时发出的事件。
#### Schema
@@ -254413,8 +254373,7 @@ Schema name: `ResponseIncompleteEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response > (schema) > (property) user": {
@@ -254763,6 +254722,10 @@ Schema name: `ResponseIncompleteEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -254775,7 +254738,8 @@ Schema name: `ResponseIncompleteEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) responses > (model) response > (schema) > (property) instructions > (variant) 0": {
@@ -259991,23 +259955,6 @@ Schema name: `ResponseIncompleteEvent`
"schemaType": "integer",
"children": []
},
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/ResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) responses > (model) response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/ResponseUsage",
@@ -260030,9 +259977,6 @@ Schema name: `ResponseIncompleteEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -260042,8 +259986,7 @@ Schema name: `ResponseIncompleteEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response_error > (schema) > (property) code > (member) 0": {
@@ -260194,6 +260137,13 @@ Schema name: `ResponseIncompleteEvent`
}
},
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -306830,7 +306780,7 @@ Schema name: `ResponseIncompleteEvent`
### response.output_item.added
-当新增输出项时触发。
+当新增一个输出条目时触发。
#### Schema
@@ -330366,7 +330316,7 @@ Schema name: `ResponseOutputItemAddedEvent`
### response.output_item.done
-当输出项被标记为完成时触发。
+当某个输出项被标记为完成时发出。
#### Schema
@@ -353908,7 +353858,7 @@ Schema name: `ResponseOutputItemDoneEvent`
### response.content_part.added
-当添加新的内容部分时发出。
+在新增内容片段时发出。
#### Schema
@@ -355092,7 +355042,7 @@ Schema name: `ResponseContentPartAddedEvent`
### response.content_part.done
-当某个内容部分完成时发出。
+当一个内容部分完成时发出。
#### Schema
@@ -356600,7 +356550,7 @@ Schema name: `ResponseTextDeltaEvent`
### response.output_text.done
-当文本内容被最终确定时发出。
+在文本内容最终确定时发出。
#### Schema
@@ -356924,7 +356874,7 @@ Schema name: `ResponseTextDoneEvent`
### response.refusal.delta
-当存在部分拒答文本时触发。
+当存在部分拒绝文本时发出。
#### Schema
@@ -357124,7 +357074,7 @@ Schema name: `ResponseRefusalDeltaEvent`
### response.refusal.done
-在 refusal 文本最终确定时发出。
+在拒绝文本最终确定时触发。
#### Schema
@@ -357324,7 +357274,7 @@ Schema name: `ResponseRefusalDoneEvent`
### response.function_call_arguments.delta
-当存在部分函数调用参数的增量时发出。
+当存在部分函数调用参数增量时发出。
#### Schema
@@ -357505,7 +357455,7 @@ Schema name: `ResponseFunctionCallArgumentsDeltaEvent`
### response.function_call_arguments.done
-当函数调用参数最终确定时触发。
+在函数调用参数最终确定时发出。
#### Schema
@@ -357704,7 +357654,7 @@ Schema name: `ResponseFunctionCallArgumentsDoneEvent`
### response.file_search_call.in_progress
-在发起 文件搜索 调用时发出。
+在发起文件搜索调用时发出。
#### Schema
@@ -357866,7 +357816,7 @@ Schema name: `ResponseFileSearchCallInProgressEvent`
### response.file_search_call.searching
-在 文件搜索 正在搜索时发出。
+当 文件搜索正在进行搜索时发出。
#### Schema
@@ -358028,7 +357978,7 @@ Schema name: `ResponseFileSearchCallSearchingEvent`
### response.file_search_call.completed
-当文件搜索调用完成(已找到结果)时发出。
+当 文件搜索 调用完成时发出(已找到结果)。
#### Schema
@@ -358352,7 +358302,7 @@ Schema name: `ResponseWebSearchCallInProgressEvent`
### response.web_search_call.searching
-当一次网页搜索调用正在执行时发出。
+当网页搜索调用执行时发出。
#### Schema
@@ -358676,7 +358626,7 @@ Schema name: `ResponseWebSearchCallCompletedEvent`
### response.reasoning_summary_part.added
-当新增一条推理摘要分块时触发。
+当新增一个推理摘要片段时触发。
#### Schema
@@ -358936,7 +358886,7 @@ Schema name: `ResponseReasoningSummaryPartAddedEvent`
### response.reasoning_summary_part.done
-当推理摘要部分完成时发出。
+在推理摘要部分完成时发出。
#### Schema
@@ -359231,7 +359181,7 @@ Schema name: `ResponseReasoningSummaryPartDoneEvent`
### response.reasoning_summary_text.delta
-当向推理摘要文本添加增量时触发。
+当向推理摘要文本添加增量时发出。
#### Schema
@@ -359431,7 +359381,7 @@ Schema name: `ResponseReasoningSummaryTextDeltaEvent`
### response.reasoning_summary_text.done
-当推理摘要文本完成时发出。
+在推理摘要文本完成时发出。
#### Schema
@@ -359631,7 +359581,7 @@ Schema name: `ResponseReasoningSummaryTextDoneEvent`
### response.reasoning_text.delta
-在向推理文本添加增量时发出。
+当增量添加到推理文本时发出。
#### Schema
@@ -359831,7 +359781,7 @@ Schema name: `ResponseReasoningTextDeltaEvent`
### response.reasoning_text.done
-当推理文本完成时发出。
+在推理文本完成时发出。
#### Schema
@@ -360193,7 +360143,7 @@ Schema name: `ResponseImageGenCallCompletedEvent`
### response.image_generation_call.generating
-当一个图像生成工具调用正在主动生成图像时触发(中间状态)。
+当图像生成工具调用正在主动生成图像时发出(中间状态)。
#### Schema
@@ -360517,7 +360467,7 @@ Schema name: `ResponseImageGenCallInProgressEvent`
### response.image_generation_call.partial_image
-在图像生成流式传输过程中,当有部分图像可用时发出。
+在图像生成流式传输期间,当有部分图像可用时发出。
#### Schema
@@ -360789,7 +360739,7 @@ Schema name: `ResponseImageGenCallPartialImageEvent`
### response.mcp_call_arguments.delta
-在 MCP 工具调用的参数产生增量(部分更新)时发出。
+当 MCP 工具调用的参数存在增量(部分更新)时发出。
#### Schema
@@ -360970,7 +360920,7 @@ Schema name: `ResponseMCPCallArgumentsDeltaEvent`
### response.mcp_call_arguments.done
-在 MCP 工具调用的参数最终确定时发出。
+当 MCP 工具调用的参数被最终确定时触发。
#### Schema
@@ -361151,7 +361101,7 @@ Schema name: `ResponseMCPCallArgumentsDoneEvent`
### response.mcp_call.completed
-当 MCP 工具调用成功完成时发出。
+当 MCP 工具调用成功完成时触发。
#### Schema
@@ -361313,7 +361263,7 @@ Schema name: `ResponseMCPCallCompletedEvent`
### response.mcp_call.failed
-当 MCP 工具调用失败时发出。
+在 MCP 工具调用失败时发出。
#### Schema
@@ -361475,7 +361425,7 @@ Schema name: `ResponseMCPCallFailedEvent`
### response.mcp_call.in_progress
-当 MCP 工具调用进行中时发出。
+当 MCP 工具调用正在进行时发出。
#### Schema
@@ -361637,7 +361587,7 @@ Schema name: `ResponseMCPCallInProgressEvent`
### response.mcp_list_tools.completed
-在成功获取可用的 MCP 工具列表时发出。
+在可用 MCP 工具列表成功获取后发出。
#### Schema
@@ -361799,7 +361749,7 @@ Schema name: `ResponseMCPListToolsCompletedEvent`
### response.mcp_list_tools.failed
-在尝试列出可用的 MCP 工具失败时发出。
+当列出可用 MCP 工具的尝试失败时发出。
#### Schema
@@ -361961,7 +361911,7 @@ Schema name: `ResponseMCPListToolsFailedEvent`
### response.mcp_list_tools.in_progress
-当系统正在检索可用的 MCP 工具列表时发出。
+系统在检索可用 MCP 工具列表时发出。
#### Schema
@@ -362123,7 +362073,7 @@ Schema name: `ResponseMCPListToolsInProgressEvent`
### response.code_interpreter_call.in_progress
-在代码解释器调用进行中时发出。
+当代码解释器调用正在进行时发出。
#### Schema
@@ -362285,7 +362235,7 @@ Schema name: `ResponseCodeInterpreterCallInProgressEvent`
### response.code_interpreter_call.interpreting
-当代码解释器正在主动解释代码片段时发出。
+当代码解释器正在主动解释代码片段时触发。
#### Schema
@@ -362609,7 +362559,7 @@ Schema name: `ResponseCodeInterpreterCallCompletedEvent`
### response.code_interpreter_call_code.delta
-当代码解释器流式传输部分代码片段时触发。
+当代码解释器流式输出部分代码片段时触发。
#### Schema
@@ -362790,7 +362740,7 @@ Schema name: `ResponseCodeInterpreterCallCodeDeltaEvent`
### response.code_interpreter_call_code.done
-当代码片段由代码解释器最终确定时发出。
+当代码片段由代码解释器最终化时触发。
#### Schema
@@ -362971,7 +362921,7 @@ Schema name: `ResponseCodeInterpreterCallCodeDoneEvent`
### response.output_text.annotation.added
-当向输出文本内容添加注解时发出。
+当注解被添加到输出文本内容时发出。
#### Schema
@@ -363732,7 +363682,7 @@ Schema name: `ResponseOutputTextAnnotationAddedEvent`
### response.queued
-当响应已排队并等待处理时发出。
+在响应被加入队列并等待处理时发出。
#### Schema
@@ -365673,8 +365623,7 @@ Schema name: `ResponseQueuedEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response > (schema) > (property) user": {
@@ -366023,6 +365972,10 @@ Schema name: `ResponseQueuedEvent`
"kind": "HttpTypeLiteral",
"literal": "max_output_tokens"
},
+ {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ },
{
"kind": "HttpTypeLiteral",
"literal": "content_filter"
@@ -366035,7 +365988,8 @@ Schema name: `ResponseQueuedEvent`
"childrenParentSchema": "enum",
"children": [
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 0",
- "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1"
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1",
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2"
]
},
"(resource) responses > (model) response > (schema) > (property) instructions > (variant) 0": {
@@ -371251,23 +371205,6 @@ Schema name: `ResponseQueuedEvent`
"schemaType": "integer",
"children": []
},
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units": {
- "kind": "HttpDeclProperty",
- "oasRef": "#/components/schemas/ResponseUsage/properties/compute_units",
- "deprecated": false,
- "key": "compute_units",
- "docstring": "Compute units for the request. Currently null when available.\n",
- "type": {
- "kind": "HttpTypeNumber"
- },
- "constraints": {
- "minimum": 0
- },
- "optional": true,
- "nullable": true,
- "schemaType": "integer",
- "children": []
- },
"(resource) responses > (model) response_usage > (schema)": {
"kind": "HttpDeclTypeAlias",
"oasRef": "#/components/schemas/ResponseUsage",
@@ -371290,9 +371227,6 @@ Schema name: `ResponseQueuedEvent`
},
{
"ident": "total_tokens"
- },
- {
- "ident": "compute_units"
}
]
},
@@ -371302,8 +371236,7 @@ Schema name: `ResponseQueuedEvent`
"(resource) responses > (model) response_usage > (schema) > (property) input_tokens_details",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens",
"(resource) responses > (model) response_usage > (schema) > (property) output_tokens_details",
- "(resource) responses > (model) response_usage > (schema) > (property) total_tokens",
- "(resource) responses > (model) response_usage > (schema) > (property) compute_units"
+ "(resource) responses > (model) response_usage > (schema) > (property) total_tokens"
]
},
"(resource) responses > (model) response_error > (schema) > (property) code > (member) 0": {
@@ -371454,6 +371387,13 @@ Schema name: `ResponseQueuedEvent`
}
},
"(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 1": {
+ "kind": "HttpDeclReference",
+ "type": {
+ "kind": "HttpTypeLiteral",
+ "literal": "max_messages"
+ }
+ },
+ "(resource) responses > (model) response > (schema) > (property) incomplete_details > (property) reason > (member) 2": {
"kind": "HttpDeclReference",
"type": {
"kind": "HttpTypeLiteral",
@@ -418065,7 +418005,7 @@ Schema name: `ResponseQueuedEvent`
### response.custom_tool_call_input.delta
-表示对自定义工具调用的输入进行增量(部分更新)的事件。
+表示对自定义工具调用输入的增量(部分更新)的事件。
#### Schema
@@ -418245,7 +418185,7 @@ Schema name: `ResponseCustomToolCallInputDeltaEvent`
### response.custom_tool_call_input.done
-表示自定义工具调用的输入已完整的事件。
+表示自定义工具调用的输入已完成的事件。
#### Schema
@@ -418694,7 +418634,7 @@ Schema name: `ResponseAudioDoneEvent`
### response.audio.transcript.delta
-当存在音频的部分转录文本时发出。
+当存在音频的部分转录文本时触发。
#### Schema
@@ -418838,7 +418778,7 @@ Schema name: `ResponseAudioTranscriptDeltaEvent`
### response.audio.transcript.done
-当完整音频转录完成时发出。
+当完整的音频转写完成时触发。
#### Schema
@@ -418963,7 +418903,7 @@ Schema name: `ResponseAudioTranscriptDoneEvent`
### response.shell_call_command.added
-表示 shell 命令已添加到工具调用的流事件。
+表示 shell 命令被添加到工具调用的流式事件。
#### Schema
@@ -419145,7 +419085,7 @@ Schema name: `ResponseShellCallCommandAddedStreamingEvent`
### response.shell_call_command.delta
-指示 shell 命令被增量更新的流事件。
+表示 shell 命令被增量更新的流式事件。
#### Schema
@@ -419346,7 +419286,7 @@ Schema name: `ResponseShellCallCommandDeltaStreamingEvent`
### response.shell_call_command.done
-指示 shell 命令已完成的流式事件。
+一个流式事件,指示 shell 命令已完成。
#### Schema
@@ -419528,7 +419468,7 @@ Schema name: `ResponseShellCallCommandDoneStreamingEvent`
### response.shell_call_output_content.delta
-一个流式事件,指示 shell 调用输出被增量添加。
+一个流式事件,用于指示 shell 调用输出被增量添加。
#### Schema
@@ -419773,7 +419713,7 @@ Schema name: `ResponseShellCallOutputContentDeltaStreamingEvent`
### response.shell_call_output_content.done
-表示 shell 调用输出已完成的流式事件。
+指示 shell 调用输出已完成的流式事件。
#### Schema