Chuyển đến nội dung
Skillpedia
Học máy48k · #5224

model-registry-governance

Skill này làm gì

Công cụ này giúp tổ chức và kiểm soát các mô hình AI của công ty. Nó đảm bảo mọi mô hình có thể truy xuất nguồn gốc, an toàn và tuân theo các quy tắc đã định, từ khi tạo ra đến khi ngừng sử dụng.

Khi nào nên dùng

  • ✓Khi bạn thiết lập một nơi tập trung để lưu trữ tất cả mô hình AI.
  • ✓Khi bạn xác định thông tin (metadata) mà mỗi mô hình cần có.
  • ✓Khi bạn thiết lập quy trình phê duyệt mô hình trước khi đưa vào sản xuất.

Liên kết skill

https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/model-registry-governance/SKILL.md

Sao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.

Cách dùng

Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.

Tin nhắn có sẵn để dán

Hãy dùng skill này để giúp tôi: https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/model-registry-governance/SKILL.md Đọc tệp SKILL.md tại liên kết đó và làm theo hướng dẫn cho việc của tôi.
Bạn muốn AI tự tìm những skill như thế này?Cài MCP Skillpedia miễn phí: chỉ một dòng, và AI sẽ tìm trong 15.000+ skill trước mỗi việc.Cài đặt trong 1 phút →

Ví dụ cách nhờ AI

“Làm sao để thiết lập một hệ thống quản lý các mô hình AI của công ty, đảm bảo chúng an toàn và có thể truy xuất nguồn gốc?”

5 skill mới mỗi tuần. Đọc chỉ 1 phút.

Cách hoạt động

Công cụ hoạt động bằng cách thiết lập các quy tắc rõ ràng và một hệ thống để đăng ký từng mô hình. Điều này bao gồm thông tin về nguồn gốc, cách mô hình được kiểm thử, ai chịu trách nhiệm và khi nào nên ngừng sử dụng.

Nội dung kỹ thuật (SKILL.md gốc)

Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.

Model Registry Governance

Create a trustworthy system of record for model artifacts, prompts, adapters, and evaluation evidence.

When to Use This Skill

  • Setting up a centralized model registry for your organization
  • Defining metadata standards for model artifacts
  • Building approval workflows for model promotion to production
  • Implementing lifecycle policies for model retirement
  • Preparing for compliance audits of AI systems

Prerequisites

  • MLflow Tracking Server or Weights & Biases instance deployed
  • Object storage for model artifacts (S3, GCS, or MinIO)
  • CI/CD pipeline with access to the registry API
  • OPA or similar policy engine for governance checks
  • Git repository for policy definitions and promotion scripts

Core Principles

  • Traceability: every production model maps to source code, data snapshot, and evaluation results.
  • Reproducibility: builds are deterministic with pinned dependencies.
  • Policy-driven promotion: no manual bypass for critical safety checks.
  • Lifecycle hygiene: stale, vulnerable, or unowned models are retired automatically.

MLflow Registry Setup

# Install MLflow with required backends
pip install mlflow[extras] psycopg2-binary boto3

# Start MLflow tracking server with PostgreSQL backend and S3 artifact store
mlflow server \
  --backend-store-uri postgresql://mlflow:password@db:5432/mlflow \
  --default-artifact-root s3://mlflow-artifacts/models \
  --host 0.0.0.0 \
  --port 5000 \
  --serve-artifacts
# docker-compose.yaml for MLflow
services:
  mlflow:
    image: ghcr.io/mlflow/mlflow:2.12.0
    command: >
      mlflow server
      --backend-store-uri postgresql://mlflow:${DB_PASSWORD}@db:5432/mlflow
      --default-artifact-root s3://mlflow-artifacts/models
      --host 0.0.0.0
      --port 5000
      --serve-artifacts
    ports:
      - "5000:5000"
    environment:
      AWS_ACCESS_KEY_ID: ${AWS_ACCESS_KEY_ID}
      AWS_SECRET_ACCESS_KEY: ${AWS_SECRET_ACCESS_KEY}
    depends_on:
      - db

  db:
    image: postgres:16-alpine
    environment:
      POSTGRES_DB: mlflow
      POSTGRES_USER: mlflow
      POSTGRES_PASSWORD: ${DB_PASSWORD}
    volumes:
      - pgdata:/var/lib/postgresql/data

volumes:
  pgdata:

Required Metadata Schema

# model_metadata_schema.py
from pydantic import BaseModel, Field
from typing import List, Optional
from datetime import datetime
from enum import Enum

class LifecycleState(str, Enum):
    DRAFT = "draft"
    CANDIDATE = "candidate"
    APPROVED = "approved"
    DEPRECATED = "deprecated"
    RETIRED = "retired"

class RiskRating(str, Enum):
    LOW = "low"
    MEDIUM = "medium"
    HIGH = "high"
    CRITICAL = "critical"

class ModelMetadata(BaseModel):
    """Required metadata for every registered model."""
    # Identity
    name: str = Field(description="Model name matching registry key")
    version: str = Field(description="Semantic version")
    checksum: str = Field(description="SHA-256 of model artifact")
    storage_uri: str = Field(description="Artifact store path")

    # Lineage
    base_model: str = Field(description="Parent model identifier")
    fine_tune_method: Optional[str] = Field(default=None)
    training_dataset: Optional[str] = Field(default=None)
    training_date: Optional[datetime] = Field(default=None)
    source_commit: str = Field(description="Git SHA of training code")

    # Evaluation
    eval_datasets: List[str] = Field(description="Evaluation dataset IDs")
    eval_report_uri: str = Field(description="Path to evaluation results")
    quality_score: float = Field(ge=0, le=1)
    safety_score: float = Field(ge=0, le=1)

    # Governance
    license: str = Field(description="SPDX license identifier")
    allowed_use_cases: List[str]
    prohibited_use_cases: List[str]
    risk_rating: RiskRating
    security_controls: List[str]

    # Ownership
    owner: str = Field(description="Primary owner email")
    backup_owner: str = Field(description="Backup owner email")
    escalation_contact: str
    team: str

    # Lifecycle
    state: LifecycleState = LifecycleState.DRAFT
    created_at: datetime = Field(default_factory=datetime.utcnow)
    approved_at: Optional[datetime] = None
    approved_by: Optional[str] = None
    expires_at: Optional[datetime] = None

Model Registration Script

# register_model.py
import mlflow
from mlflow.tracking import MlflowClient
import json
import hashlib

def register_model(
    model_path: str,

…
Câu hỏi thường gặp

“Metadata” là gì?

Metadata là thông tin về dữ liệu, trong trường hợp này là thông tin về mô hình AI. Hãy coi nó như nhãn sản phẩm, cho biết mô hình là gì, ai làm ra, làm khi nào và để làm gì.

Vì sao “khả năng truy xuất nguồn gốc” quan trọng?

Khả năng truy xuất nguồn gốc nghĩa là chúng ta có thể biết chính xác mô hình đến từ đâu, dùng mã nào để tạo, dùng dữ liệu nào để huấn luyện và đã được kiểm thử ra sao. Điều này rất quan trọng cho bảo mật và kiểm toán.

“Lifecycle policies” là gì?

Đây là các quy tắc định nghĩa điều gì xảy ra với mô hình theo thời gian. Ví dụ, khi mô hình lỗi thời hoặc không an toàn, các chính sách này quy định cách ngừng sử dụng hoặc thay thế nó.

Chi tiết

Mô tả gốc của tác giả

Establish model registry standards, governance controls, metadata schemas, approvals, and lifecycle policies for enterprise AI deployments.

repo: sickn33/agentic-awesome-skills

Độ phổ biến

Sao GitHub
48k
Vị trí xếp hạng
#5224
Giấy phép
MIT
Cập nhật
15/10/2026

Skill này có hữu ích không?

0

Đăng nhập để bình chọn.

Bình luận

  • …

Thêm skill từ kho mã này

Skill tương tự