Quick start guides you through the basic verification process of Confidential-AI, which includes the following steps:
- Deploying Trustee as a user-controlled component that stores sensitive data.
- Encrypting the model file, uploading the encrypted model to Trustee, and saving the encryption key in Trustee.
- Deploying Trustiflux as a trusted component in the cloud.
- Verifying the cloud environment through remote attestation, obtaining the encryption key and the encrypted model from Trustee, and decrypting the model to mount in a trusted environment.
According to the threat model, the first two steps occur on the user side, while the last two steps happen in the cloud. However, for the sake of demonstration, the process shown in this document is based on the same Alibaba Cloud TDX ECS and utilizes a local network.
- Alibaba Cloud TDX ECS: Refer to the “Creating TDX Instances” section in TDX Confidential Computing Environment guide and it's recommended to create it via the console.
- Download the Confidential-AI code.
git clone https://github.com/inclavare-containers/Confidential-AI.git- (Optional) Configure the
Confidential-AI/.envfile. Non-empty fields must match the Trustiflux-side configuration.
MODEL_TYPE: Model type, currently supportsQwen3-0.6B|DeepSeek-R1-Chat|Qwen-7B-Instruct;GOCRYPTFS_PASSWORD: Encryption key string;KBS_KEY_PATH: Path to the encrypted key in Trustee;ENCRYPT_MODEL_IP: IP address of the file web service on Trustee side;ENCRYPT_MODEL_PORT: Port of the file web service on Trustee side;TRUSTEE_ADDRESS: Service address of Trustee;TRUSTEE_AS_ADDR: Service address of Trustee AS.
- Navigate to the Trustee folder and run the
run.shfile.
cd Confidential-AI/Trustee
./run.sh- Download the Confidential-AI code.
git clone https://github.com/inclavare-containers/Confidential-AI.git- (Optional) Configure the
Confidential-AI/.envfile. Non-empty fields must match the Trustee-side configuration.
MODEL_TYPE: Model type, currently supportsQwen3-0.6B|DeepSeek-R1-Chat|Qwen-7B-Instruct;GOCRYPTFS_PASSWORD: Leave empty; it will be obtained from Trustee via remote attestation;KBS_KEY_PATH: Path to the encrypted key in Trustee;ENCRYPT_MODEL_IP: IP address of the file web service on Trustee side;ENCRYPT_MODEL_PORT: Port of the file web service on Trustee side;TRUSTEE_ADDRESS: Service address of Trustee;TRUSTEE_AS_ADDR: Service address of Trustee AS.
- Navigate to the Trustiflux folder and run the
run.shfile.
cd Confidential-AI/Trustiflux
./run.shOn the Trustee side, access the following URL to send a request to Trustiflux via the TNG trusted channel and access the inference web service:
http://127.0.0.1:9001/The inference web service deployed on the Trustiflux side will be accessible if the CAI deployment is successful.
- Image Pulling is Slow or Fails
Configure image acceleration based on Alibaba Cloud ACR. Refer to the official image acceleration documentation.
- Failed to Run run.sh
First run the clean.sh file in the same directory, then run run.sh.
- Execution fails in CSV environment
Please refer to CSV Virtual Machine Confidential_AI to ensure the CSV environment is configured correctly.