AI Engineering Tools

Generative AI Engineering

AI Fine-Tuning and Alignment Terms

Learn fine-tuning, continued pre-training, instruction tuning, SFT, PEFT, LoRA, QLoRA, preference data, RLHF, DPO, GRPO, regression evaluation, data rights, privacy, versioning, and rollback.

54 matching terms

Fine-tuning overview

Fine-tuning

Fine-tuning

Meaning

Continuing training from a pre-trained model to adapt its behavior to a narrower task, domain, format, or preference.

When to use it

Use it when prompting and retrieval alone cannot provide sufficiently consistent learned behavior.

Practical example

Fine-tune the approved base model on reviewed support responses, then compare it with the unchanged baseline.

Fine-tuning overview

Downstream task

Downstream task

Meaning

A specific application task performed using a general pre-trained model.

When to use it

Define it precisely before collecting fine-tuning data and selecting metrics.

Practical example

Downstream task: classify Korean support requests into the approved routing taxonomy.

Fine-tuning overview

Domain adaptation

Domain adaptation

Meaning

Adapting a model to language, patterns, or distributions found in a particular field or environment.

When to use it

Use it when the target domain differs materially from the model's general training distribution.

Practical example

Adapt the model to authorized semiconductor maintenance documents and evaluate on unseen manuals.

Fine-tuning overview

Continued pre-training

Continued pre-training

Meaning

Further pre-training a base model on additional unlabeled or self-supervised domain data before task-specific tuning.

When to use it

Use it for broad domain language adaptation when a small set of instruction examples is insufficient.

Practical example

Continue pre-training on the licensed domain corpus, then run supervised instruction tuning.

Fine-tuning overview

Instruction tuning

Instruction tuning

Meaning

Fine-tuning on instructions and desired responses so a model follows varied natural-language tasks more reliably.

When to use it

Use diverse, reviewed instructions that reflect target users, tasks, languages, and safety boundaries.

Practical example

Train on instruction-response examples covering summarization, extraction, refusal, and clarification.

Fine-tuning overview

Post-training

Post-training

Meaning

Training performed after broad pre-training to improve task following, preferences, safety, or deployment behavior.

When to use it

Use it as an umbrella term for supervised tuning, preference optimization, reward modeling, and related alignment work.

Practical example

Document each post-training stage, its data, objective, checkpoint, and evaluation gate.

Fine-tuning overview

Supervised fine-tuning (SFT)

Supervised fine-tuning (SFT)

Meaning

Fine-tuning that learns from inputs paired with reviewed target responses or labels.

When to use it

Use it to teach response format, task procedure, tone, and examples of desired behavior.

Practical example

SFT example: user request, approved assistant response, metadata, and data-rights record.

Fine-tuning overview

Model alignment

Model alignment

Meaning

The effort to make model behavior better follow defined human intentions, policies, preferences, and safety requirements.

When to use it

Use it as the broad goal behind instruction tuning, preference optimization, safety training, and behavioral evaluation.

Practical example

Define the alignment objectives, unacceptable behaviors, evaluation cases, and human approval gates.

Fine-tuning overview

Behavior adaptation

Behavior adaptation

Meaning

Changing how a model responds, formats output, follows procedures, or handles uncertainty without assuming that it gains current factual knowledge.

When to use it

Use it when the desired change concerns stable response patterns rather than frequently changing information.

Practical example

Adapt the model to request clarification when required account evidence is missing.

Methods and adapters

Full fine-tuning

Full fine-tuning

Meaning

Fine-tuning that updates all or most parameters of the base model.

When to use it

Use it only when the expected benefit justifies substantial memory, compute, storage, and evaluation cost.

Practical example

Compare full fine-tuning against a PEFT baseline under the same data and evaluation set.

Methods and adapters

Parameter-efficient fine-tuning (PEFT)

Parameter-efficient fine-tuning (PEFT)

Meaning

A family of methods that adapts a model while training a relatively small portion of parameters.

When to use it

Use it to reduce training memory, storage, and per-task checkpoint size.

Practical example

Train a separate PEFT adapter for each approved domain while keeping the base weights fixed.

Methods and adapters

Adapter

Adapter

Meaning

A small set of additional or modified parameters attached to a base model for a particular adaptation.

When to use it

Use adapters to separate task-specific changes from shared base weights.

Practical example

Load the finance adapter only for authorized finance workflows.

Methods and adapters

Low-rank adaptation (LoRA)

Low-rank adaptation (LoRA)

Meaning

A PEFT method that learns low-rank update matrices for selected model modules while keeping base weights frozen.

When to use it

Use it when smaller trainable states and reusable adapters fit the deployment design.

Practical example

Apply LoRA to selected attention projections and record rank, alpha, dropout, and target modules.

Methods and adapters

QLoRA

QLoRA

Meaning

A fine-tuning approach that trains LoRA adapters while the base model is loaded in a quantized representation.

When to use it

Use it to reduce base-model memory while validating numerical stability and quality against an appropriate baseline.

Practical example

Load the approved base model in the supported quantization format and train only the LoRA adapter.

Methods and adapters

Quantization

Quantization

Meaning

Representing model values with lower-precision formats to reduce memory, storage, or compute requirements.

When to use it

Use it when the supported method and hardware can preserve acceptable quality and numerical behavior.

Practical example

Evaluate the quantized base model before QLoRA and record format, bit width, library, and compute dtype.

Methods and adapters

LoRA rank

LoRA rank

Meaning

The dimensionality of the low-rank update matrices used by a LoRA adapter.

When to use it

Tune it as a capacity and resource tradeoff rather than assuming a larger rank is always better.

Practical example

Compare rank 8 and rank 16 with the same seed, data, steps, and evaluation suite.

Methods and adapters

LoRA alpha

LoRA alpha

Meaning

A scaling configuration that influences the contribution of learned LoRA updates.

When to use it

Record it together with rank and implementation details because interpretation can depend on the library.

Practical example

Store rank, alpha, dropout, target modules, and library version in the adapter manifest.

Methods and adapters

Target modules

Target modules

Meaning

The model layers or projections selected to receive adapter updates.

When to use it

Choose them according to model architecture, method support, and measured quality.

Practical example

Target the supported query and value projections, then verify the number of trainable parameters.

Methods and adapters

Trainable parameters

Trainable parameters

Meaning

The subset of model parameters that optimization is allowed to update.

When to use it

Report both the count and percentage so full and parameter-efficient runs can be compared.

Practical example

Log trainable parameters, total parameters, percentage, and adapter checkpoint size.

Methods and adapters

Adapter merge

Adapter merge

Meaning

Combining learned adapter updates into base weights or another adapter representation for deployment.

When to use it

Use it only after compatibility, license, precision, quality, and rollback checks.

Practical example

Evaluate the merged artifact against the unmerged base-plus-adapter configuration before release.

Training formats

Prompt-completion pair

Prompt-completion pair

Meaning

A training example containing an input prompt and the desired completion.

When to use it

Use a consistent schema and ensure completions demonstrate the exact target behavior.

Practical example

{"prompt":"Classify the request","completion":"billing_refund"}

Training formats

Instruction-response pair

Instruction-response pair

Meaning

A supervised example pairing a natural-language instruction or conversation with the reviewed response the model should learn to produce.

When to use it

Use it for SFT and retain source, rights, review, and quality metadata alongside each example.

Practical example

{"messages":[{"role":"user","content":"배송 취소 방법을 알려줘"},{"role":"assistant","content":"주문 내역에서 취소할 주문을 선택하세요."}]}

Training formats

Chat template

Chat template

Meaning

A formatting rule that converts system, user, assistant, and tool messages into the token sequence expected by a chat model.

When to use it

Use the tokenizer and template compatible with the selected base model during both training and inference.

Practical example

Render the same approved chat template in dataset preprocessing and production inference.

Training formats

System, user, and assistant roles

System, user, and assistant roles

Meaning

Message-role labels that distinguish durable instructions, user inputs, and model responses in conversational training data.

When to use it

Use only roles and ordering supported by the selected model's chat template.

Practical example

System: policy and role; user: request; assistant: reviewed target response.

Training formats

Response masking

Response masking

Meaning

Excluding selected input tokens from loss calculation so training focuses on intended response tokens.

When to use it

Use it when the objective should learn assistant outputs without treating every prompt token as a target.

Practical example

Mask system and user tokens from the loss and verify assistant boundaries after tokenization.

Training formats

Sequence packing

Sequence packing

Meaning

Combining multiple shorter examples into longer training sequences to reduce padding and improve utilization.

When to use it

Use it only when example boundaries, attention behavior, labels, and end tokens remain correct.

Practical example

Pack short dialogs up to the context limit and test that one example cannot leak into the next.

Training formats

Fine-tuning context length

Fine-tuning context length

Meaning

The maximum token length used for each training sequence after formatting and tokenization.

When to use it

Set it according to the base model, target task, memory budget, truncation risk, and production request pattern.

Practical example

Measure token-length distribution and choose a limit that preserves critical content without excessive padding.

Training formats

Preference dataset

Preference dataset

Meaning

A dataset that records comparative judgments or rewards for alternative model outputs.

When to use it

Use it for reward modeling or preference optimization with documented labeling rules and reviewer quality checks.

Practical example

Store prompt, candidate responses, preference result, rationale policy, reviewer group, and consent status.

Training formats

Chosen and rejected response pair

Chosen and rejected response pair

Meaning

Two candidate responses labeled to indicate which one better satisfies the defined preference criteria.

When to use it

Use pairs that differ meaningfully and apply a consistent rubric instead of personal taste alone.

Practical example

Chosen: cites the supplied policy and states uncertainty. Rejected: invents an unsupported deadline.

Preference alignment

Human feedback

Human feedback

Meaning

Structured judgments, labels, demonstrations, or corrections supplied by people to guide model behavior.

When to use it

Define reviewer qualification, instructions, disagreement handling, privacy, compensation, and quality assurance.

Practical example

Use calibrated reviewers and adjudicate high-impact disagreements before training.

Preference alignment

Reinforcement learning from human feedback (RLHF)

Reinforcement learning from human feedback (RLHF)

Meaning

A family of post-training approaches that uses human preference signals and reinforcement-learning techniques to shape model behavior.

When to use it

Use it only with a clear reward design, stable training setup, safety evaluation, and strong data governance.

Practical example

Train and validate a reward signal, optimize the policy conservatively, and compare against the SFT baseline.

Preference alignment

Reward model

Reward model

Meaning

A model that scores candidate outputs according to learned preference or quality signals.

When to use it

Use it when a training or selection process needs a scalable approximation of documented preferences.

Practical example

Evaluate reward-model accuracy, calibration, subgroup behavior, and exploitability on held-out comparisons.

Preference alignment

Preference optimization

Preference optimization

Meaning

Post-training that updates model behavior using comparative preferences, rewards, or related feedback signals.

When to use it

Use it as a broad category that includes direct-preference and reinforcement-learning approaches.

Practical example

Define the preference rubric, reference behavior, optimization method, and retention evaluations.

Preference alignment

Reinforcement learning from AI feedback (RLAIF)

Reinforcement learning from AI feedback (RLAIF)

Meaning

A family of reinforcement-learning approaches that uses feedback produced or assisted by AI systems instead of relying only on direct human judgments.

When to use it

Use it only with validated feedback criteria, human oversight, bias checks, and safeguards against self-reinforcing errors.

Practical example

Calibrate AI feedback against a held-out set of expert human judgments before policy optimization.

Preference alignment

Reinforcement fine-tuning

Reinforcement fine-tuning

Meaning

Fine-tuning that optimizes model behavior from reward signals produced by graders, environments, rules, or feedback models.

When to use it

Use it when outcomes can be scored reliably and the training system can monitor reward hacking, stability, and capability retention.

Practical example

Score verifiable task outcomes, optimize conservatively, and compare against the unchanged and SFT baselines.

Preference alignment

Direct preference optimization (DPO)

Direct preference optimization (DPO)

Meaning

A preference-training method that directly uses chosen and rejected responses to update a policy relative to a reference behavior.

When to use it

Use it when suitable preference pairs and a compatible training implementation are available.

Practical example

Train DPO from the approved SFT checkpoint and compare helpfulness, safety, and capability retention.

Preference alignment

Proximal policy optimization (PPO)

Proximal policy optimization (PPO)

Meaning

A policy-optimization algorithm that constrains the size of updates while optimizing a reward signal.

When to use it

Use it in reinforcement-learning pipelines that can support reward, value, rollout, and stability monitoring.

Practical example

Track reward, divergence from the reference model, response length, and safety metrics during PPO.

Preference alignment

Group relative policy optimization (GRPO)

Group relative policy optimization (GRPO)

Meaning

A reinforcement-learning method that compares rewards among multiple sampled outputs for the same prompt to estimate relative advantage.

When to use it

Use it only when group sampling, reward quality, training stability, and compute cost fit the task.

Practical example

Sample several solutions per problem, score them with verified checks, and optimize from group-relative rewards.

Evaluation and regression

Fine-tuning validation loss

Fine-tuning validation loss

Meaning

Loss measured on held-out fine-tuning examples without updating the model from those examples.

When to use it

Use it with task, safety, and behavior metrics because lower loss alone does not prove better production behavior.

Practical example

Select candidate checkpoints using validation loss and the fixed production-style evaluation suite.

Evaluation and regression

Holdout evaluation

Holdout evaluation

Meaning

Evaluation on examples deliberately excluded from training and model-selection feedback.

When to use it

Use it for a less-biased estimate of performance on unseen cases and protect the set from repeated tuning.

Practical example

Run the locked holdout suite only after selecting the candidate checkpoint.

Evaluation and regression

Checkpoint selection

Checkpoint selection

Meaning

Choosing which saved training state should advance based on predefined quality, safety, cost, and regression criteria.

When to use it

Use a fixed evaluation suite and avoid selecting from training loss alone.

Practical example

Promote the checkpoint that passes task, safety, multilingual, latency, and memorization gates.

Evaluation and regression

Base-model comparison

Base-model comparison

Meaning

A controlled evaluation comparing the fine-tuned model with the unchanged base model.

When to use it

Use identical prompts, retrieval, decoding, and datasets to attribute changes to fine-tuning.

Practical example

Report wins, ties, regressions, latency, and cost for base and tuned candidates.

Evaluation and regression

Catastrophic forgetting

Catastrophic forgetting

Meaning

A loss of previously learned capability after training strongly on new data or objectives.

When to use it

Test retained general capabilities, languages, safety behavior, and out-of-domain tasks after tuning.

Practical example

Run the baseline capability suite before and after fine-tuning and block material regressions.

Evaluation and regression

Capability regression

Capability regression

Meaning

A measurable decline in an existing model capability after fine-tuning or deployment changes.

When to use it

Define regression thresholds for important tasks before training and release.

Practical example

Fail the release if multilingual extraction accuracy drops beyond the approved threshold.

Evaluation and regression

Safety regression

Safety regression

Meaning

A decline in refusal, privacy, fairness, or harmful-content behavior after adaptation.

When to use it

Run targeted adversarial and policy evaluations for every candidate checkpoint.

Practical example

Compare jailbreak, PII disclosure, bias, and unsafe-completion rates with the approved baseline.

Evaluation and regression

Training-data memorization

Training-data memorization

Meaning

A model's retention and possible reproduction of specific training examples beyond desired generalization.

When to use it

Test for unusual phrase reproduction, secrets, personal data, and near-verbatim outputs before release.

Practical example

Probe held-out prefixes and block release if the model reproduces sensitive continuations.

Evaluation and regression

Fine-tuning versus RAG

Fine-tuning versus RAG

Meaning

A design decision between changing model behavior through training and supplying external knowledge at request time.

When to use it

Prefer retrieval for current or frequently changing facts and fine-tuning for stable behavior, format, or task patterns, then evaluate a combined approach if needed.

Caution

Fine-tuning does not automatically make frequently changing facts current or provide source citations.

Practical example

Use RAG for current policies and SFT for the approved response structure.

Rights and operations

Fine-tuning data rights

Fine-tuning data rights

Meaning

The licenses, permissions, contractual terms, and other authority required to use data for model adaptation.

When to use it

Verify rights at source and example level and retain provenance, restrictions, and removal procedures.

Caution

Online availability, API access, or possession of a file does not by itself grant fine-tuning rights.

Practical example

Record source, rights holder, license or permission, allowed training use, territory, term, and deletion contact.

Rights and operations

Personal data in fine-tuning

Personal data in fine-tuning

Meaning

Information in adaptation data that identifies or can be linked to an individual.

When to use it

Minimize, redact, obtain proper authority, restrict access, and define retention and deletion before training.

Practical example

Replace names and account identifiers with controlled placeholders and verify the transformed dataset.

Rights and operations

Model registry

Model registry

Meaning

A controlled catalog of model, adapter, checkpoint, evaluation, approval, and deployment metadata.

When to use it

Use it to track which artifact is approved, deployed, deprecated, or eligible for rollback.

Practical example

Register model digest, base version, adapter, dataset, evaluations, owner, approval, and deployment stage.

Rights and operations

Adapter serving

Adapter serving

Meaning

Serving one base model with selectable task- or domain-specific adapters at inference time.

When to use it

Use it when the runtime can isolate adapters, authorize selection, manage memory, and preserve version compatibility.

Practical example

Route approved finance requests to the finance adapter and log the exact base-plus-adapter version.

Rights and operations

Fine-tuning provider data policy

Fine-tuning provider data policy

Meaning

A service provider's terms and controls for uploaded training data, retention, deletion, model access, geographic processing, and secondary use.

When to use it

Review the current contract and product documentation before uploading any dataset, and record the approved configuration.

Caution

Provider policies can change; recheck them before each material training program and never assume API access grants data-use rights.

Practical example

Verify retention period, deletion process, training-use setting, access roles, region, encryption, and incident procedure.

Rights and operations

Fine-tuned model versioning

Fine-tuned model versioning

Meaning

Tracking the exact base model, adapter or checkpoint, data, code, and configuration that produced a tuned model.

When to use it

Use immutable identifiers so evaluations, incidents, rollbacks, and audits refer to the same artifact.

Practical example

Version = base model digest + adapter digest + dataset hash + code commit + training config.

Rights and operations

Fine-tuning rollback

Fine-tuning rollback

Meaning

Returning production traffic to a previously approved model or adapter after a problem is detected.

When to use it

Prepare it before release with artifact retention, compatibility checks, routing controls, and decision authority.

Practical example

Keep the last approved base-plus-adapter combination deployable and rehearse the rollback path.

Choosing prompting, RAG, or fine-tuning

Start with the least complex approach that reliably meets the requirement, then evaluate combinations when necessary.

What you needApproach to consider first
Improve response format or tonePrompt design or SFT
Answer from current or private documentsRAG with source-grounded retrieval
Learn repeatable task behaviorFine-tuning with representative examples
Adapt broad industry language and patternsContinued pre-training or domain fine-tuning
Learn from preferred and rejected responsesDPO or another validated preference-optimization method

SFT, DPO, and GRPO comparison

The methods require different data and optimize different signals; they are not interchangeable labels for fine-tuning.

MethodTypical data and objective
SFTInstruction-response or labeled examples; learn to reproduce reviewed target behavior.
DPOChosen/rejected response pairs; directly increase relative preference against reference behavior.
GRPOMultiple sampled outputs and verified rewards; optimize from group-relative advantages.

Frequently asked questions

What is the difference between pre-training and fine-tuning?

Pre-training teaches broad patterns at large scale and produces a base model. Fine-tuning continues from that model with narrower data and objectives to adapt a task, format, domain, preference, or safety behavior.

Should current knowledge be added with RAG or fine-tuning?

Frequently changing or source-sensitive knowledge usually fits RAG because documents can be updated and cited at request time. Fine-tuning is generally better suited to stable behavior, format, or task patterns. Some systems combine both.

How do LoRA and QLoRA differ?

LoRA trains low-rank adapter updates while keeping base weights frozen. QLoRA additionally loads the base model in a supported quantized representation to reduce memory. Quality and compatibility must be evaluated for the exact stack.

Does fine-tuning automatically add current facts and citations?

No. A tuned model can still become outdated and does not inherently expose the source of a generated claim. Use retrieval or another verified data connection when freshness and citations matter.

When should SFT, DPO, or GRPO be used?

Use SFT for reviewed target responses, DPO for comparative preference pairs, and GRPO for tasks with reliable rewards across multiple sampled outputs. Choose only after confirming the data, objective, evaluation, safety, and compute requirements.

What must be checked before uploading fine-tuning data to a provider?

Verify data rights, consent, confidentiality, personal-data handling, provider terms, retention and deletion, geographic processing, model-access controls, secondary training use, encryption, incident response, and the current contract.

Official references