Model Studio confidential inference is built on hardware-based confidential computing technology for high-security scenarios. Data stays encrypted throughout transmission, computing, and storage, protecting the privacy and security of user prompts during cloud inference.
1 Introduction to confidential inference
Confidential inference is built on TEE (Trusted Execution Environment) hardware-based confidential computing technology and can effectively defend against multi-layer security threats, including privileged attacks. Its core security features include:
- End-to-end encryption: An application-layer encrypted channel is established on top of HTTPS, covering the entire path from the client to the confidential inference node. Each node randomly generates a root private key for session key negotiation, and each session independently derives ephemeral keys; all keys reside only in encrypted volatile memory, are never written to disk or persisted, and are destroyed when the session ends.
- Hardening and measurement: With both chip-level hardware isolation and software hardening, the boot chain and runtime environment are measured end to end; at the block storage level, the root partition relies on a Merkle Tree mechanism for integrity, and data partitions are encrypted with one-time keys for confidentiality.
- Software and hardware transparency: The client directly accesses the TEE vendor to verify the authenticity of the remote attestation report generated by the hardware, and checks the transparency log service to confirm the integrity of the server-side software artifacts.
2 Advantages of confidential inference
- Defense in depth: From chip-level hardware isolation and end-to-end encrypted transmission to client-verifiable remote attestation, a multi-layer protection system spanning hardware, transmission, and software is established. The platform does not retain plaintext prompts, model outputs, or encryption keys; keys and content remain in the hands of the user.
- Low-intrusion integration: Compatible with existing invocation methods; no business code refactoring is required—only replace the invocation endpoint and the client SDK. Confidential and non-confidential paths can coexist under the same account. For invocation details, see Invoke after deployment.
3 Billing
Confidential inference deployments are billed at the token list price, covering three items: input, output, and context cache (implicit) hits.
Supported models: cmaas-qwen3.8-flash, cmaas-glm-5.3, cmaas-deepseek-v4.1-flash, cmaas-deepseek-v4-pro-0813.
- North China 2 (Beijing)
- Qwen
- GLM
- DeepSeek
Model code | Input $ per million tokens | Output $ per million tokens | Cache hit $ per million tokens |
|---|---|---|---|
| 0.452 | 1.413 | 0.057 |
4 Activation and deployment
To activate confidential inference, you must meet the following prerequisites:
- Activation: Contact Alibaba Cloud sales to apply for access.
- Region: The China (Beijing) region is currently supported.
- Compliance agreement: Before deployment, you must sign the Alibaba Cloud Model Studio Confidential Inference Service Special Terms.
Create a deployment
Before deployment, confirm that the models used on the business side are supported by confidential inference (see Billing).
Deployment steps:
- Log on to the Model Studio console. In the left-side navigation pane, choose Model inference > Confidential inference to go to the confidential inference page (this page displays a list of existing deployments, including information such as model code, billing method, rate limit details, creation time, and operations), and click Create confidential inference.
- In the dialog box, configure the deployment parameters: select a model from the Select Model drop-down list (models that have been deployed are marked as "Deployed"); the Billing Method is fixed to "Pay by Token"; in Rate Limit Configuration, TPM/RPM are automatically set to the upper limit values after you select a model and require no editing.
- Click Confirm Create. After the deployment is complete, a new record is added to the list.
| Parameter | Description and value |
|---|---|
| Select model | For supported models, see Billing |
| Billing method | Billed at the token list price (three items: input/output/cache hit) |
| TPM (tokens per minute) | Upper limit of the token rate limit per minute. It is set to the upper limit value by default (500000 if no increase has been requested); requests are throttled as the limit is approached; |
RPM (requests per minute)Key negotiation requests are also counted toward the RPM quota, so the inference RPM actually available may be slightly lower than the configured value. | Upper limit of the request rate limit per minute. It is set to the upper limit value by default (300 if no increase has been requested); |
Metric name | Description | Normal range | Recommended action on anomaly |
|---|---|---|---|
Token usage | Input, output, and cache hit token consumption per unit of time | Below the configured TPM rate limit | If usage spikes, check the business request volume and prompt length; evaluate scaling up or optimizing the prompt structure if necessary |
Cache hit rate | Proportion of requests served from cache out of the total requests | The higher, the more cost saved (no fixed threshold) | If the hit rate is low, optimize the prompt structure to improve reuse and increase the per-unit overall cost advantage |
Resource pool usage | Capacity utilization of the dedicated resource pool | No overflow (the dedicated resource pool never overflows) | No action required |
5 Invoke after deployment
After the model is deployed, you can invoke it through the confidential inference SDK.
{WorkspaceId} in the invocation examples is the workspace ID: click the current workspace (such as "Default Workspace") in the top bar of the console to expand the drop-down list, click "Manage Workspaces", and view the ID (in the format ws-xxxxxxxxxxxxxxx) in the "Workspace ID" column on the workspace management page. The public endpoint in the "API Host" column is the domain name used for invocation.
SDK installation and build
Prerequisites:
- The Go development environment is installed. For more information, see Install Go.
- The make build tool is installed.
make command in the SDK root directory to build the confidential inference sample CLI program cmaas-client and the local API conversion proxy tools openai-proxy/anthropic-proxy in the bin directory. You can also refer to the README in the SDK directory to develop and build confidential inference tools that fit your business scenarios.
- Using the confidential inference CLI tool cmaas-client
- openai-proxy (OpenAI-compatible interface)
- anthropic-proxy (Anthropic-compatible Messages interface)
Viewing local transparency reports
You can view the transparency reports of confidential inference requests in the following local directories:
- macOS
- Linux
- Windows
~/Library/Application\ Support/dashscope-confidential-maas/transparency-reports--no-prompt-in-transparency-report parameter when starting openai-proxy or anthropic-proxy. After the feature is disabled, other audit materials such as remote attestation are still retained.
For authentication methods and error codes, see the SDK call responses.
6 Application scenarios
Confidential inference targets scenarios where the business needs to call cloud-based large models, but at least one of customer data, business data, or model weights is subject to a hard constraint that "the plaintext must not be exposed to the other party".
Financial risk control and anti-fraud inference
- Applicable to: credit review, fraud detection, and risk control decision support
- Advantages: data/model double blindness; aligned with the JR/T 0197 C3/C4 requirements for financial data encryption and access control
- Applicable to: internal knowledge retrieval, decision support, and intelligent Q&A
- Advantages: sensitive documents uploaded as ciphertext, inference in hardware-protected areas, and encrypted return transmission
- AI diagnosis of medical images/records (subject to the Personal Information Protection Law and HIPAA)
- Intelligent legal/contract review (contract plaintext processed in a secure environment)
- Smart cockpits and in-vehicle assistants (compliant with the Several Provisions on Automotive Data Security Management)
- Intelligent customer service and after-sales tickets (involving sensitive information such as ID card numbers and partial bank card numbers)
- Restricted data egress (typical in finance, healthcare, government, and automotive)
- Data/model double blindness (typical in finance and legal)