Document Models - Get Model
詳細なドキュメント モデル情報を取得します。
GET {endpoint}/documentintelligence/documentModels/{modelId}?api-version=2024-02-29-preview
URI パラメーター
名前 | / | 必須 | 型 | 説明 |
---|---|---|---|---|
endpoint
|
path | True |
string |
ドキュメント インテリジェンス サービス エンドポイント。 |
model
|
path | True |
string |
一意のドキュメント モデル名。 Regex pattern: |
api-version
|
query | True |
string |
この操作に使用する API バージョン。 |
要求ヘッダー
名前 | 必須 | 型 | 説明 |
---|---|---|---|
x-ms-client-request-id |
string uuid |
要求の不透明でグローバルに一意のクライアントによって生成された文字列識別子。 |
応答
名前 | 型 | 説明 |
---|---|---|
200 OK |
要求は成功しました。 Headers x-ms-client-request-id: string |
|
Other Status Codes |
予期しないエラー応答。 |
セキュリティ
Ocp-Apim-Subscription-Key
Type:
apiKey
In:
header
OAuth2Auth
Type:
oauth2
Flow:
accessCode
Authorization URL:
https://login.microsoftonline.com/common/oauth2/authorize
Token URL:
https://login.microsoftonline.com/common/oauth2/token
Scopes
名前 | 説明 |
---|---|
https://cognitiveservices.azure.com/.default |
例
Get Custom Document Model |
Get Prebuilt Document Model |
Get Custom Document Model
Sample Request
GET https://myendpoint.cognitiveservices.azure.com/documentintelligence/documentModels/myCustomModel?api-version=2024-02-29-preview
Sample Response
{
"modelId": "myCustomModel",
"description": "Custom model description",
"createdDateTime": "2021-09-24T12:54:35Z",
"expirationDateTime": "2023-01-01T00:00:00Z",
"apiVersion": "2024-02-29-preview",
"docTypes": {
"myForm": {
"fieldSchema": {
"Name": {
"type": "string"
},
"Date": {
"type": "date"
},
"Amount": {
"type": "number"
}
},
"buildMode": "template",
"fieldConfidence": {
"Name": 0.9,
"Date": 0.95,
"Amount": 0.93
}
}
},
"tags": {
"createdBy": "myUserId"
}
}
Get Prebuilt Document Model
Sample Request
GET https://myendpoint.cognitiveservices.azure.com/documentintelligence/documentModels/prebuilt-invoice?api-version=2024-02-29-preview
Sample Response
{
"modelId": "prebuilt-invoice",
"description": "Prebuilt model to extract key information from English invoices, including customer, vendor, invoice ID, due date, total, and more.",
"createdDateTime": "2021-07-30T00:00:00Z",
"apiVersion": "2024-02-29-preview",
"docTypes": {
"prebuilt:invoice": {
"fieldSchema": {
"CustomerName": {
"type": "string"
},
"CustomerId": {
"type": "string"
},
"PurchaseOrder": {
"type": "string"
},
"InvoiceId": {
"type": "string"
},
"InvoiceDate": {
"type": "date"
},
"DueDate": {
"type": "date"
},
"VendorName": {
"type": "string"
},
"VendorAddress": {
"type": "string"
},
"VendorAddressRecipient": {
"type": "string"
},
"CustomerAddress": {
"type": "string"
},
"CustomerAddressRecipient": {
"type": "string"
},
"BillingAddress": {
"type": "string"
},
"BillingAddressRecipient": {
"type": "string"
},
"ShippingAddress": {
"type": "string"
},
"ShippingAddressRecipient": {
"type": "string"
},
"SubTotal": {
"type": "number"
},
"TotalTax": {
"type": "number"
},
"InvoiceTotal": {
"type": "number"
},
"AmountDue": {
"type": "number"
},
"PreviousUnpaidBalance": {
"type": "number"
},
"RemittanceAddress": {
"type": "string"
},
"RemittanceAddressRecipient": {
"type": "string"
},
"ServiceAddress": {
"type": "string"
},
"ServiceAddressRecipient": {
"type": "string"
},
"ServiceStartDate": {
"type": "date"
},
"ServiceEndDate": {
"type": "date"
},
"Items": {
"type": "array",
"items": {
"type": "object",
"properties": {
"Amount": {
"type": "number"
},
"Date": {
"type": "date"
},
"Description": {
"type": "string"
},
"Quantity": {
"type": "number"
},
"ProductCode": {
"type": "string"
},
"Tax": {
"type": "number"
},
"Unit": {
"type": "string"
},
"UnitPrice": {
"type": "number"
}
}
}
}
}
}
},
"tags": {}
}
定義
名前 | 説明 |
---|---|
Azure |
コンテンツをAzure Blob Storageします。 |
Azure |
Azure Blob Storage内のファイルの一覧。 |
Document |
カスタム ドキュメント モデルのビルド モード。 |
Document |
JSON スキーマ スタイル構文を使用したフィールド セマンティック スキーマの説明。 |
Document |
フィールド値のセマンティック データ型。 |
Document |
ドキュメント モデル情報。 |
Document |
ドキュメントの種類の情報。 |
Error |
error オブジェクト。 |
Error |
エラー応答オブジェクト。 |
Inner |
エラーに関するより具体的な情報を含むオブジェクト。 |
Warning |
error オブジェクト。 |
AzureBlobContentSource
コンテンツをAzure Blob Storageします。
名前 | 型 | 説明 |
---|---|---|
containerUrl |
string |
コンテナー URL をAzure Blob Storageします。 |
prefix |
string |
BLOB 名プレフィックス。 |
AzureBlobFileListContentSource
Azure Blob Storage内のファイルの一覧。
名前 | 型 | 説明 |
---|---|---|
containerUrl |
string |
コンテナー URL をAzure Blob Storageします。 |
fileList |
string |
ドキュメントのサブセットを指定するコンテナー内の JSONL ファイルへのパス。 |
DocumentBuildMode
カスタム ドキュメント モデルのビルド モード。
名前 | 型 | 説明 |
---|---|---|
neural |
string |
多様なビジュアル テンプレートを使用してドキュメントをサポートします。 |
template |
string |
類似のビジュアル テンプレートを使用してドキュメントをターゲットに設定します。 |
DocumentFieldSchema
JSON スキーマ スタイル構文を使用したフィールド セマンティック スキーマの説明。
名前 | 型 | 説明 |
---|---|---|
description |
string |
フィールドの説明。 |
example |
string |
フィールドコンテンツの例。 |
items |
各配列要素のフィールド型スキーマ。 |
|
properties |
<string,
Document |
オブジェクト フィールドの名前付きサブフィールド。 |
type |
フィールド値のセマンティック データ型。 |
DocumentFieldType
フィールド値のセマンティック データ型。
名前 | 型 | 説明 |
---|---|---|
address |
string |
解析されたアドレス。 |
array |
string |
同じ型のサブフィールドの一覧。 |
boolean |
string |
true または false に正規化されたブール値。 |
countryRegion |
string |
ISO 3166-1 alpha-3 形式 (米国など) に正規化された国/地域。 |
currency |
string |
通貨記号と単位を省略可能な通貨金額。 |
date |
string |
ISO 8601 (YYYY-MM-DD) 形式に正規化された日付。 |
integer |
string |
64 ビット符号付き整数に正規化された整数。 |
number |
string |
倍精度浮動小数点に正規化された浮動小数点数。 |
object |
string |
異なる可能性がある型のサブフィールドの名前付きリスト。 |
phoneNumber |
string |
E.164 (+{CountryCode}{SubscriberNumber}) 形式に正規化された電話番号。 |
selectionGroup |
string |
選択した文字列値の配列。 |
selectionMark |
string |
フィールドは選択されていますか? |
signature |
string |
署名は存在しますか? |
string |
string |
プレーンテキスト。 |
time |
string |
ISO 8601 (hh:mm:ss) 形式に正規化された時間。 |
DocumentModelDetails
ドキュメント モデル情報。
名前 | 型 | 説明 |
---|---|---|
apiVersion |
string |
このドキュメント モデルの作成に使用される API バージョン。 |
azureBlobFileListSource |
Azure Blob Storageトレーニング データを指定するファイル一覧です。 azureBlobSource または azureBlobFileListSource を指定する必要があります。 |
|
azureBlobSource |
トレーニング データAzure Blob Storage含む場所。 azureBlobSource または azureBlobFileListSource を指定する必要があります。 |
|
buildMode |
カスタム ドキュメント モデルのビルド モード。 |
|
createdDateTime |
string |
ドキュメント モデルが作成された日時 (UTC)。 |
description |
string |
ドキュメント モデルの説明。 |
docTypes |
<string,
Document |
サポートされているドキュメントの種類。 |
expirationDateTime |
string |
ドキュメント モデルの有効期限が切れる日時 (UTC)。 |
modelId |
string |
一意のドキュメント モデル名。 |
tags |
object |
ドキュメント モデルに関連付けられているキーと値のタグ属性の一覧。 |
warnings |
Warning[] |
モデルの構築中に発生した警告の一覧。 |
DocumentTypeDetails
ドキュメントの種類の情報。
名前 | 型 | 説明 |
---|---|---|
buildMode |
カスタム ドキュメント モデルのビルド モード。 |
|
description |
string |
ドキュメント モデルの説明。 |
fieldConfidence |
object |
各フィールドの推定信頼度。 |
fieldSchema |
<string,
Document |
JSON スキーマ スタイル構文を使用したドキュメント セマンティック スキーマの説明。 |
Error
error オブジェクト。
名前 | 型 | 説明 |
---|---|---|
code |
string |
サーバー定義のエラー コードのセットの 1 つ。 |
details |
Error[] |
この報告されたエラーの原因となった特定のエラーに関する詳細の配列。 |
innererror |
エラーに関する現在のオブジェクトよりも具体的な情報を含む オブジェクト。 |
|
message |
string |
エラーの人間が判読できる表現。 |
target |
string |
エラーのターゲット。 |
ErrorResponse
エラー応答オブジェクト。
名前 | 型 | 説明 |
---|---|---|
error |
エラー情報。 |
InnerError
エラーに関するより具体的な情報を含むオブジェクト。
名前 | 型 | 説明 |
---|---|---|
code |
string |
サーバー定義のエラー コードのセットの 1 つ。 |
innererror |
内部エラー。 |
|
message |
string |
エラーの人間が判読できる表現。 |
Warning
error オブジェクト。
名前 | 型 | 説明 |
---|---|---|
code |
string |
サーバー定義の警告コードのセットの 1 つ。 |
message |
string |
警告の人間が判読できる表現。 |
target |
string |
エラーのターゲット。 |