<span id="模型推理"></span>

# Model inference

Choose an API for the resource you need to operate on, then prepare the identity, IDs, and parameters listed on its action page.

<span id="选择任务"></span>

## Choose a task

| Task | Page | Description |
| --- | --- | --- |
| Invoke a workspace chat model | [Invoke a workspace chat model](chat-completion.md) | Generate responses through workspace models and routing, with ordinary JSON or SSE streaming responses. |
| Invoke a workspace embedding model | [Invoke a workspace embedding model](invoke-embedding.md) | Convert text or model-supported input into vectors through a workspace embedding model. Large inputs may require multiple upstream calls. |
| Workspace inference request fields | [Workspace inference request fields](request-fields.md) | The current gateway does not fully validate messages' roles/content. The type table does not guarantee provider acceptance. |
| Workspace inference results and streaming protocol | [Workspace inference results and streaming protocol](responses-and-streams.md) | This is a compatibility shape. Raw providers and adapters may return extra fields; examples are not a universal complete required schema. |
| Product model invocation common objects | [Product model invocation common objects](objects.md) | In-product model invocation uses workspace and product identity. |

```{toctree}
:hidden:
:maxdepth: 1

Invoke a workspace chat model <chat-completion>
Invoke a workspace embedding model <invoke-embedding>
Workspace inference request fields <request-fields>
Workspace inference results and streaming protocol <responses-and-streams>
Product model invocation common objects <objects>
```
