Deploy, fine-tune, evaluate, and process data for LLMs on PAI. Use Model Gallery for one-click deployment, DSW and DLC for custom training, or Lingjun for distributed training at scale.
Deploy models
PAI offers multiple deployment paths: Model Gallery for one-click deployment of open-source models, or Elastic Algorithm Service (EAS) for custom deployment with accelerated inference and auto-scaling.
Model Gallery: one-click deployment
Model Gallery deploys models with built-in inference optimization. Each tutorial below covers the full workflow from deployment to API invocation.
-
Quick start: Deploy, fine-tune, and evaluate Qwen3 models - Deploy with SGLang, vLLM, or BladeLLM. Includes debugging and API examples.
-
QuickStart: Deploy, fine-tune, and evaluate QwQ-32B - Reasoning model optimized for math, coding, and scientific tasks.
-
Quick start: Fine-tune, evaluate, and deploy Qwen2.5 models - Available in 0.5B–72B sizes with improved coding, math, and structured data handling.
-
Quickstart: Train and deploy Qwen2.5-Coder - Specialized for code generation, completion, and reasoning. Supports training, quantization, and deployment.
-
Quickstart: Train and deploy DistilQwen2 - Smaller models that preserve performance through knowledge distillation.
-
Quickstart: Deploy and fine-tune Llama 3 series models - Meta's open-source models (15T+ tokens). Supports SFT and DPO fine-tuning.
-
Quick start: Deploy and fine-tune the Mixtral-8x7B MoE model - Sparse MoE model that activates 2 of 8 experts per token for efficient inference.
EAS: custom deployment
-
Quickly deploy LLMs in EAS - Deploy open-source LLMs via EAS with standard or accelerated inference. Supports WebUI and API access.
Lingjun: distributed serving at scale
-
Fully managed Qwen on Lingjun - Distributed training, three-stage instruction tuning, offline inference, and online deployment of Qwen (7B–72B) on serverless GPU clusters.
Fine-tune and train models
Adapt pre-trained LLMs to your domain or task. Model Gallery provides no-code fine-tuning. For more control, use DSW for PEFT or DLC for distributed full-parameter training.
Model Gallery: no-code fine-tuning
The deployment tutorials above also cover fine-tuning for each model.
DSW and DLC: custom training
-
DSW: Fine-tuning Llama3-8B - Apply PEFT in a DSW notebook for cost-effective domain adaptation.
Advanced training techniques
-
Continued pre-training for LLMs - Extend a model's domain knowledge using unlabeled text through unsupervised continued pre-training, as opposed to supervised fine-tuning.
-
Data augmentation and model distillation for LLMs - Transfer knowledge from large teacher models to smaller student models through data augmentation, instruction refinement, and distillation.
Evaluate models
Compare foundation models, fine-tuned variants, and quantized versions. PAI supports automated evaluation with custom or public benchmarks (MMLU, C-Eval).
-
Best practices for LLM evaluation - Run evaluation tasks with 10+ NLP metrics across custom and public benchmarks. Compare model variants side by side.
Process training data
Machine Learning Designer provides algorithms for processing text, video, and image data. Built-in templates are available and extensible.
Text data
-
Data Processing for LLM (Github Code) - Deduplicate, filter, and transform raw GitHub repository data into clean training samples.
-
LLM data processing: Wikipedia - Process Wikipedia dumps for pre-training: extract, clean, and deduplicate web-crawled text.
-
LLM data processing: arXiv - Clean and prepare academic papers from arXiv for scientific domain pre-training.
-
LLM Data Processing: Alpaca-CoT (SFT Data) - Process instruction-following datasets in Alpaca format for supervised fine-tuning.
-
Processing Alpaca-CoT SFT data with DLC components - Run the Alpaca-CoT SFT data pipeline on DLC for large-scale distributed processing.
-
LLM data processing: GitHub code (DLC) - Run the GitHub code data pipeline on DLC for large-scale distributed processing.
Image and video data
-
Image-text filtering - Automatically filter low-quality images and generate captions for multimodal model training.
-
Video data filtering and labeling - Clean, filter, and label video data with metadata extraction for video understanding model training.
Build LLM applications
Apply fine-tuned LLMs to production use cases with end-to-end workflows from data preparation through deployment.
-
Develop an LLM-based intent recognition solution - Build intent recognition for voice assistants or chatbots. Covers data labeling (iTAG), Qwen1.5 fine-tuning, evaluation, and deployment.