What are the basic components of AI and show the data flow
Core components of AI (neural network model)1. Input dataRaw information such as:
- images, text, audio, sensor readings
Converted into numeric form (vectors/tensors)
2. Parameters (weights + biases)- Weights: control strength of connections
- Biases: shift outputs
These are the “learned memory” of the model.
3. Layers (transformations)Each layer computes:
output = activation(Wx + b)They progressively transform raw input into useful representations.
4. Activation functionAdds non-linearity:
- ReLU, sigmoid, tanh
Without it, the model becomes just a linear function.
5. Loss functionMeasures error:
- difference between prediction and truth
Outputs a single number representing “how wrong” the model is.
6. OptimiserUpdates weights to reduce error:
- gradient descent / Adam
It performs learning.
---
Data flow (forward + learning loop)Forward passInput
↓
Layer 1 (Wx + b + activation)
↓
Layer 2
↓
...
↓
Output (prediction)
Loss calculationPrediction + True label → Loss → Error value
Backward pass (backpropagation)Error
↓
Compute gradients (credit assignment)
↓
Propagate backwards through layers
Parameter updateWeights = Weights - learning_rate × gradient
---
Full AI training loopInput → Forward pass → Prediction
↓
Loss
↓
Backpropagation
↓
Update parameters
↓
Repeat many times
---
Key ideaAI is not rules or logic.
It is a feedback loop that tunes a large mathematical function until its outputs match data.
Generated by ChatGPT.