Explore how Constitutional AI aligns models with ethical principles. Learn how to implement safety checks in computer vision using YOLO26 for more reliable AI.
Constitutional AI is a method for training artificial intelligence systems to align with human values by providing them with a set of high-level principles—a "constitution"—rather than relying solely on extensive human feedback on individual outputs. This approach essentially teaches the AI model to critique and revise its own behavior based on a predefined set of rules, such as "be helpful," "be harmless," and "avoid discrimination." By embedding these ethical guidelines directly into the training process, developers can create systems that are safer, more transparent, and easier to scale than those dependent on manual Reinforcement Learning from Human Feedback (RLHF).
The core innovation of Constitutional AI lies in its two-phase training process, which automates the alignment of models. Unlike traditional supervised learning, where humans must label every correct response, Constitutional AI uses the model itself to generate training data.
Embora a IA constitucional tenha surgido no contexto dos Grandes Modelos de Linguagem (LLM) desenvolvidos por organizações como Anthropic, os seus princípios são cada vez mais relevantes para tarefas mais amplas de aprendizagem automática, incluindo Visão Computacional (CV).
Embora o treinamento completo da IA constitucional envolva ciclos de feedback complexos, os desenvolvedores podem aplicar o conceito de "verificações constitucionais" durante a inferência para filtrar os resultados com base em políticas de segurança . O exemplo a seguir demonstra o uso do YOLO26 para detect e aplicar uma regra de segurança para filtrar detecções de baixa confiança, imitando uma constituição de confiabilidade.
from ultralytics import YOLO
# Load the YOLO26 model (latest stable Ultralytics release)
model = YOLO("yolo26n.pt")
# Run inference on an image
results = model("https://ultralytics.com/images/bus.jpg")
# Apply a "constitutional" safety check: Only accept high-confidence detections
for result in results:
# Filter boxes with confidence > 0.5 to ensure reliability
safe_boxes = [box for box in result.boxes if box.conf > 0.5]
print(f"Safety Check Passed: {len(safe_boxes)} reliable objects detected.")
# Further processing would only use 'safe_boxes'
It is important to distinguish Constitutional AI from standard Reinforcement Learning from Human Feedback (RLHF).
medida que os modelos evoluem para a Inteligência Artificial Geral (AGI), cresce a importância de estratégias de alinhamento robustas como a IA Constitucional. Estes métodos são essenciais para para cumprir as normas emergentes de organismos como o Instituto de Segurança de IA do NIST.
The Ultralytics Platform offers tools to manage data governance and model monitoring, facilitating the creation of responsible AI systems. By integrating these ethical considerations into the lifecycle of AI development—from data collection to model deployment—organizations can mitigate risks and ensure their technologies contribute positively to society.