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

datanalysis-credit-risk

Skill này làm gì

Công cụ này sắp xếp và làm sạch dữ liệu rủi ro tín dụng. Nó loại bỏ thông tin không cần thiết hoặc có chất lượng thấp để chuẩn bị dữ liệu cho các phân tích sau này, như xây dựng mô hình cho vay.

Khi nào nên dùng

  • ✓Khi bạn có dữ liệu khách hàng thô cần được sắp xếp.
  • ✓Khi bạn cần xác định và loại bỏ dữ liệu có quá nhiều giá trị thiếu.
  • ✓Khi bạn muốn chọn thông tin quan trọng nhất trước khi xây dựng mô hình.

Liên kết skill

https://github.com/github/awesome-copilot/blob/main/skills/datanalysis-credit-risk/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/github/awesome-copilot/blob/main/skills/datanalysis-credit-risk/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

“Hãy làm sạch và chuẩn bị dữ liệu rủi ro tín dụng của tôi để phân tích.”

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

Cách hoạt động

Công cụ tải dữ liệu của bạn và kiểm tra chất lượng, loại bỏ dữ liệu có quá nhiều giá trị thiếu, thông tin không liên quan hoặc thông tin hầu như không thay đổi theo thời gian. Nó tạo một báo cáo chi tiết về mọi việc đã làm.

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.

Data Cleaning and Variable Screening

Quick Start

# Run the complete data cleaning pipeline
python ".github/skills/datanalysis-credit-risk/scripts/example.py"

Complete Process Description

The data cleaning pipeline consists of the following 11 steps, each executed independently without deleting the original data:

  1. Get Data - Load and format raw data
  2. Organization Sample Analysis - Statistics of sample count and bad sample rate for each organization
  3. Separate OOS Data - Separate out-of-sample (OOS) samples from modeling samples
  4. Filter Abnormal Months - Remove months with insufficient bad sample count or total sample count
  5. Calculate Missing Rate - Calculate overall and organization-level missing rates for each feature
  6. Drop High Missing Rate Features - Remove features with overall missing rate exceeding threshold
  7. Drop Low IV Features - Remove features with overall IV too low or IV too low in too many organizations
  8. Drop High PSI Features - Remove features with unstable PSI
  9. Null Importance Denoising - Remove noise features using label permutation method
  10. Drop High Correlation Features - Remove high correlation features based on original gain
  11. Export Report - Generate Excel report containing details and statistics of all steps

Core Functions

Function Purpose Module
get_dataset() Load and format data references.func
org_analysis() Organization sample analysis references.func
missing_check() Calculate missing rate references.func
drop_abnormal_ym() Filter abnormal months references.analysis
drop_highmiss_features() Drop high missing rate features references.analysis
drop_lowiv_features() Drop low IV features references.analysis
drop_highpsi_features() Drop high PSI features references.analysis
drop_highnoise_features() Null Importance denoising references.analysis
drop_highcorr_features() Drop high correlation features references.analysis
iv_distribution_by_org() IV distribution statistics references.analysis
psi_distribution_by_org() PSI distribution statistics references.analysis
value_ratio_distribution_by_org() Value ratio distribution statistics references.analysis
export_cleaning_report() Export cleaning report references.analysis

Parameter Description

Data Loading Parameters

  • DATA_PATH: Data file path (best are parquet format)
  • DATE_COL: Date column name
  • Y_COL: Label column name
  • ORG_COL: Organization column name
  • KEY_COLS: Primary key column name list

OOS Organization Configuration

  • OOS_ORGS: Out-of-sample organization list

Abnormal Month Filtering Parameters

  • min_ym_bad_sample: Minimum bad sample count per month (default 10)
  • min_ym_sample: Minimum total sample count per month (default 500)

Missing Rate Parameters

  • missing_ratio: Overall missing rate threshold (default 0.6)

IV Parameters

  • overall_iv_threshold: Overall IV threshold (default 0.1)
  • org_iv_threshold: Single organization IV threshold (default 0.1)
  • max_org_threshold: Maximum tolerated low IV organization count (default 2)

PSI Parameters

  • psi_threshold: PSI threshold (default 0.1)
  • max_months_ratio: Maximum unstable month ratio (default 1/3)
  • max_orgs: Maximum unstable organization count (default 6)

Null Importance Parameters

  • n_estimators: Number of trees (default 100)
  • max_depth: Maximum tree depth (default 5)
  • gain_threshold: Gain difference threshold (default 50)

High Correlation Parameters

  • max_corr: Correlation threshold (default 0.9)
  • top_n_keep: Keep top N features by original gain ranking (default 20)

Output Report

The generated Excel report contains the following sheets:

  1. 汇总 - Summary information of all steps, including operation results and conditions
  2. 机构样本统计 - Sample count and bad sample rate for each organization
  3. 分离OOS数据 - OOS sample and modeling sample counts
  4. Step4-异常月份处理 - Abnormal months that were removed
  5. 缺失率明细 - Overall and organization-level missing rates for each feature
  6. Step5-有值率分布统计 - Distribution of features in different value ratio ranges
  7. Step6-高缺失率处理 - High missing rate features that were removed
  8. Step7-IV明细 - IV values of each feature in each organization and overall

…

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

“Dữ liệu rủi ro tín dụng” là gì?

Đó là thông tin về khách hàng giúp dự đoán khả năng họ không trả được khoản vay.

“IV” và “PSI” là gì?

IV (Information Value) và PSI (Population Stability Index) là các chỉ số dùng để đánh giá chất lượng và độ ổn định của thông tin trong dữ liệu.

Công cụ có xóa dữ liệu gốc của tôi không?

Không. Công cụ làm việc với dữ liệu mà không xóa bản gốc, bảo đảm bạn luôn có file ban đầu.

Chi tiết

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

Credit risk data cleaning and variable screening pipeline for pre-loan modeling. Use when working with raw credit data that needs quality assessment, missing value analysis, or variable selection before modeling. it covers data loading and formatting, abnormal period filtering, missing rate calculation, high-missing variable removal,low-IV variable filtering, high-PSI variable removal, Null Impor

repo: github/awesome-copilot

Độ phổ biến

Sao GitHub
40k
Vị trí xếp hạng
#7162
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ự