0
0
Prompt Engineering / GenAIml~12 mins

Emerging trends (smaller models, edge AI) in Prompt Engineering / GenAI - Model Pipeline Trace

Choose your learning style9 modes available
Model Pipeline - Emerging trends (smaller models, edge AI)

This pipeline shows how smaller AI models are trained and deployed on edge devices. It highlights data preparation, model training with fewer parameters, and running predictions locally on devices like phones or sensors.

Data Flow - 6 Stages
1Raw Data Collection
10000 rows x 20 columnsCollect sensor readings and user inputs10000 rows x 20 columns
Temperature, humidity, motion, and user activity logs
2Data Preprocessing
10000 rows x 20 columnsClean missing values, normalize features10000 rows x 20 columns
Normalized temperature values between 0 and 1
3Feature Engineering
10000 rows x 20 columnsSelect important features, reduce dimensions10000 rows x 10 columns
Selected key features like motion intensity and temperature trend
4Model Training
8000 rows x 10 columnsTrain small neural network with 2 layers and 5000 parametersModel with 5000 parameters
Model learns to classify user activity as walking, sitting, or running
5Model Deployment to Edge
Model with 5000 parametersCompress and deploy model to mobile deviceModel running on device with limited memory
Model size reduced to 2MB for phone deployment
6Local Prediction
1 sample x 10 featuresRun prediction on device without internet1 prediction output
Predicted activity: walking with 85% confidence
Training Trace - Epoch by Epoch

Loss
0.8 |****
0.6 |*** 
0.4 |**  
0.2 |*   
0.0 +----
     1 5 10 15 Epochs
EpochLoss ↓Accuracy ↑Observation
10.750.55Model starts learning basic patterns
50.450.75Accuracy improves as model learns features
100.300.85Model converges with good accuracy
150.250.88Slight improvement, training stabilizes
Prediction Trace - 4 Layers
Layer 1: Input Layer
Layer 2: Hidden Layer 1 (ReLU)
Layer 3: Output Layer (Softmax)
Layer 4: Prediction
Model Quiz - 3 Questions
Test your understanding
Why do smaller models work well on edge devices?
AThey require more internet bandwidth
BThey have more layers than big models
CThey use less memory and compute power
DThey always have higher accuracy
Key Insight
Smaller AI models trained with careful feature selection can run efficiently on edge devices, enabling fast local predictions without internet. This trend helps bring AI closer to users with limited resources.