TranslatedTextAlignment Class
Alignment information object.
All required parameters must be populated in order to send to Azure.
- Inheritance
-
azure.ai.translation.text._model_base.ModelTranslatedTextAlignment
Constructor
TranslatedTextAlignment(*args: Any, **kwargs: Any)
Variables
Name | Description |
---|---|
proj
|
Maps input text to translated text. The alignment information is only provided when the request parameter includeAlignment is true. Alignment is returned as a string value of the following format: [[SourceTextStartIndex]:[SourceTextEndIndex]–[TgtTextStartIndex]:[TgtTextEndIndex]]. The colon separates start and end index, the dash separates the languages, and space separates the words. One word may align with zero, one, or multiple words in the other language, and the aligned words may be non-contiguous. When no alignment information is available, the alignment element will be empty. Required. |
Methods
clear | |
copy | |
get | |
items | |
keys | |
pop | |
popitem | |
setdefault | |
update | |
values |
clear
clear() -> None
copy
copy() -> Model
get
get(key: str, default: Any = None) -> Any
Parameters
Name | Description |
---|---|
key
Required
|
|
default
|
Default value: None
|
items
items() -> ItemsView[str, Any]
keys
keys() -> KeysView[str]
pop
pop(key: str, default: ~typing.Any = <object object>) -> Any
Parameters
Name | Description |
---|---|
key
Required
|
|
default
|
|
popitem
popitem() -> Tuple[str, Any]
setdefault
setdefault(key: str, default: ~typing.Any = <object object>) -> Any
Parameters
Name | Description |
---|---|
key
Required
|
|
default
|
|
update
update(*args: Any, **kwargs: Any) -> None
values
values() -> ValuesView[Any]
Attributes
proj
Maps input text to translated text. The alignment information is only provided when the request parameter includeAlignment is true. Alignment is returned as a string value of the following format: [[SourceTextStartIndex]:[SourceTextEndIndex]–[TgtTextStartIndex]:[TgtTextEndIndex]]. The colon separates start and end index, the dash separates the languages, and space separates the words. One word may align with zero, one, or multiple words in the other language, and the aligned words may be non-contiguous. When no alignment information is available, the alignment element will be empty. Required.
proj: str
Azure SDK for Python