Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
7 changes: 7 additions & 0 deletions english/python-net/aspose.words.ai/aimodel/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,13 @@ url: /python-net/aspose.words.ai/aimodel/
An abstract class representing the integration with various AI models within the Aspose.Words.


### Properties

| Name | Description |
| --- | --- |
| [timeout](./timeout/) | Gets or sets the number of milliseconds to wait before the request to AI model times out. The default value is 100,000 milliseconds (100 seconds). |
| [url](./url/) | Gets or sets a URL of the model. The default value is specific for the model. |

### Methods

| Name | Description |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ articleTitle: as_anthropic_ai_model method
second_title: Aspose.Words for Python
description: "AiModel.as_anthropic_ai_model method. Cast AiModel to [AnthropicAiModel](../../anthropicaimodel/)."
type: docs
weight: 10
weight: 30
url: /python-net/aspose.words.ai/aimodel/as_anthropic_ai_model/
---

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ articleTitle: as_google_ai_model method
second_title: Aspose.Words for Python
description: "AiModel.as_google_ai_model method. Cast AiModel to [GoogleAiModel](../../googleaimodel/)."
type: docs
weight: 20
weight: 40
url: /python-net/aspose.words.ai/aimodel/as_google_ai_model/
---

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ articleTitle: as_open_ai_model method
second_title: Aspose.Words for Python
description: "AiModel.as_open_ai_model method. Cast AiModel to [OpenAiModel](../../openaimodel/)."
type: docs
weight: 30
weight: 50
url: /python-net/aspose.words.ai/aimodel/as_open_ai_model/
---

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ articleTitle: check_grammar method
second_title: Aspose.Words for Python
description: "AiModel.check_grammar method. Checks grammar of the provided document"
type: docs
weight: 40
weight: 60
url: /python-net/aspose.words.ai/aimodel/check_grammar/
---

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ articleTitle: create method
second_title: Aspose.Words for Python
description: "AiModel.create method. Creates a new instance of [AiModel](../) class."
type: docs
weight: 50
weight: 70
url: /python-net/aspose.words.ai/aimodel/create/
---

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ articleTitle: summarize method
second_title: Aspose.Words for Python
description: "aspose.words.ai.AiModel.summarize method"
type: docs
weight: 60
weight: 80
url: /python-net/aspose.words.ai/aimodel/summarize/
---

Expand Down
44 changes: 44 additions & 0 deletions english/python-net/aspose.words.ai/aimodel/timeout/_index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
---
title: AiModel.timeout property
linktitle: timeout property
articleTitle: timeout property
second_title: Aspose.Words for Python
description: "AiModel.timeout property. Gets or sets the number of milliseconds to wait before the request to AI model times out"
type: docs
weight: 10
url: /python-net/aspose.words.ai/aimodel/timeout/
---

## AiModel.timeout property

Gets or sets the number of milliseconds to wait before the request to AI model times out.
The default value is 100,000 milliseconds (100 seconds).


```python
@property
def timeout(self) -> int:
...

@timeout.setter
def timeout(self, value: int):
...

```

### Examples

Shows how to change model default timeout.

```python
api_key = system_helper.environment.Environment.get_environment_variable('API_KEY')
model = aw.ai.AiModel.create(aw.ai.AiModelType.GPT_4O_MINI).with_api_key(api_key)
# Default value 100000ms.
model.timeout = 250000
```

### See Also

* module [aspose.words.ai](../../)
* class [AiModel](../)

Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ articleTitle: translate method
second_title: Aspose.Words for Python
description: "AiModel.translate method. Translates the provided document into the specified target language"
type: docs
weight: 70
weight: 90
url: /python-net/aspose.words.ai/aimodel/translate/
---

Expand Down
57 changes: 57 additions & 0 deletions english/python-net/aspose.words.ai/aimodel/url/_index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
---
title: AiModel.url property
linktitle: url property
articleTitle: url property
second_title: Aspose.Words for Python
description: "AiModel.url property. Gets or sets a URL of the model"
type: docs
weight: 20
url: /python-net/aspose.words.ai/aimodel/url/
---

## AiModel.url property

Gets or sets a URL of the model.
The default value is specific for the model.


```python
@property
def url(self) -> str:
...

@url.setter
def url(self, value: str):
...

```

### Examples

Shows how to check the grammar of a document.

```python
doc = aw.Document(file_name=MY_DIR + 'Big document.docx')
api_key = system_helper.environment.Environment.get_environment_variable('API_KEY')
# Use OpenAI generative language models.
model = aw.ai.AiModel.create(aw.ai.AiModelType.GPT_4O_MINI).with_api_key(api_key)
grammar_options = aw.ai.CheckGrammarOptions()
grammar_options.improve_stylistics = True
proofed_doc = model.check_grammar(doc, grammar_options)
proofed_doc.save(file_name=ARTIFACTS_DIR + 'AI.AiGrammar.docx')
```

Shows how to change model default url.

```python
api_key = system_helper.environment.Environment.get_environment_variable('API_KEY')
model = aw.ai.AiModel.create(aw.ai.AiModelType.GPT_4O_MINI).with_api_key(api_key)
# Default value "https:#api.openai.com/".
model.url = 'https://my.a.com/'
```

### See Also

* module [aspose.words.ai](../../)
* class [AiModel](../)

Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ articleTitle: with_api_key method
second_title: Aspose.Words for Python
description: "AiModel.with_api_key method. Sets a specified API key to the model."
type: docs
weight: 80
weight: 100
url: /python-net/aspose.words.ai/aimodel/with_api_key/
---

Expand Down
7 changes: 7 additions & 0 deletions english/python-net/aspose.words.ai/anthropicaimodel/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,13 @@ An abstract class representing the integration with Anthropic’s AI models with

**Interfaces:** [IAiModelText](../iaimodeltext/)

### Properties

| Name | Description |
| --- | --- |
| [timeout](../aimodel/timeout/) | Gets or sets the number of milliseconds to wait before the request to AI model times out. The default value is 100,000 milliseconds (100 seconds).<br>(Inherited from [AiModel](../aimodel/)) |
| [url](./url/) | Gets or sets a URL of the model. The default value is "https://api.anthropic.com/". |

### Methods

| Name | Description |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ articleTitle: summarize method
second_title: Aspose.Words for Python
description: "aspose.words.ai.AnthropicAiModel.summarize method"
type: docs
weight: 10
weight: 20
url: /python-net/aspose.words.ai/anthropicaimodel/summarize/
---

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ articleTitle: translate method
second_title: Aspose.Words for Python
description: "AnthropicAiModel.translate method. Translates the provided document into the specified target language"
type: docs
weight: 20
weight: 30
url: /python-net/aspose.words.ai/anthropicaimodel/translate/
---

Expand Down
33 changes: 33 additions & 0 deletions english/python-net/aspose.words.ai/anthropicaimodel/url/_index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
---
title: AnthropicAiModel.url property
linktitle: url property
articleTitle: url property
second_title: Aspose.Words for Python
description: "AnthropicAiModel.url property. Gets or sets a URL of the model"
type: docs
weight: 10
url: /python-net/aspose.words.ai/anthropicaimodel/url/
---

## AnthropicAiModel.url property

Gets or sets a URL of the model.
The default value is "https://api.anthropic.com/".


```python
@property
def url(self) -> str:
...

@url.setter
def url(self, value: str):
...

```

### See Also

* module [aspose.words.ai](../../)
* class [AnthropicAiModel](../)

7 changes: 7 additions & 0 deletions english/python-net/aspose.words.ai/googleaimodel/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,13 @@ An abstract class representing the integration with Google’s AI models within

**Interfaces:** [IAiModelText](../iaimodeltext/)

### Properties

| Name | Description |
| --- | --- |
| [timeout](../aimodel/timeout/) | Gets or sets the number of milliseconds to wait before the request to AI model times out. The default value is 100,000 milliseconds (100 seconds).<br>(Inherited from [AiModel](../aimodel/)) |
| [url](./url/) | Gets or sets a URL of the model. The default value is "https://generativelanguage.googleapis.com/v1beta/models/". |

### Methods

| Name | Description |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ articleTitle: summarize method
second_title: Aspose.Words for Python
description: "aspose.words.ai.GoogleAiModel.summarize method"
type: docs
weight: 10
weight: 20
url: /python-net/aspose.words.ai/googleaimodel/summarize/
---

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ articleTitle: translate method
second_title: Aspose.Words for Python
description: "GoogleAiModel.translate method. Translates a specified document."
type: docs
weight: 20
weight: 30
url: /python-net/aspose.words.ai/googleaimodel/translate/
---

Expand Down
33 changes: 33 additions & 0 deletions english/python-net/aspose.words.ai/googleaimodel/url/_index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
---
title: GoogleAiModel.url property
linktitle: url property
articleTitle: url property
second_title: Aspose.Words for Python
description: "GoogleAiModel.url property. Gets or sets a URL of the model"
type: docs
weight: 10
url: /python-net/aspose.words.ai/googleaimodel/url/
---

## GoogleAiModel.url property

Gets or sets a URL of the model.
The default value is "https://generativelanguage.googleapis.com/v1beta/models/".


```python
@property
def url(self) -> str:
...

@url.setter
def url(self, value: str):
...

```

### See Also

* module [aspose.words.ai](../../)
* class [GoogleAiModel](../)

7 changes: 7 additions & 0 deletions english/python-net/aspose.words.ai/openaimodel/_index.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,13 @@ An abstract class representing the integration with OpenAI's large language mode

**Interfaces:** [IAiModelText](../iaimodeltext/)

### Properties

| Name | Description |
| --- | --- |
| [timeout](../aimodel/timeout/) | Gets or sets the number of milliseconds to wait before the request to AI model times out. The default value is 100,000 milliseconds (100 seconds).<br>(Inherited from [AiModel](../aimodel/)) |
| [url](./url/) | Gets or sets a URL of the model. The default value is "https://api.openai.com/". |

### Methods

| Name | Description |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ articleTitle: summarize method
second_title: Aspose.Words for Python
description: "aspose.words.ai.OpenAiModel.summarize method"
type: docs
weight: 10
weight: 20
url: /python-net/aspose.words.ai/openaimodel/summarize/
---

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ articleTitle: translate method
second_title: Aspose.Words for Python
description: "OpenAiModel.translate method. Translates the provided document into the specified target language"
type: docs
weight: 20
weight: 30
url: /python-net/aspose.words.ai/openaimodel/translate/
---

Expand Down
33 changes: 33 additions & 0 deletions english/python-net/aspose.words.ai/openaimodel/url/_index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
---
title: OpenAiModel.url property
linktitle: url property
articleTitle: url property
second_title: Aspose.Words for Python
description: "OpenAiModel.url property. Gets or sets a URL of the model"
type: docs
weight: 10
url: /python-net/aspose.words.ai/openaimodel/url/
---

## OpenAiModel.url property

Gets or sets a URL of the model.
The default value is "https://api.openai.com/".


```python
@property
def url(self) -> str:
...

@url.setter
def url(self, value: str):
...

```

### See Also

* module [aspose.words.ai](../../)
* class [OpenAiModel](../)

Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ articleTitle: with_organization method
second_title: Aspose.Words for Python
description: "OpenAiModel.with_organization method. Sets a specified Organization to the model."
type: docs
weight: 30
weight: 40
url: /python-net/aspose.words.ai/openaimodel/with_organization/
---

Expand Down
Loading