cookiechips commited on
Commit
5fdd90a
·
verified ·
1 Parent(s): 6c90c89

Add model card (README.md) for KillSwitch AI

Browse files
Files changed (1) hide show
  1. README.md +54 -0
README.md ADDED
@@ -0,0 +1,54 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: mit
3
+ language:
4
+ - ko
5
+ - en
6
+ metrics:
7
+ - accuracy
8
+ base_model:
9
+ - sentence-transformers/all-MiniLM-L6-v2
10
+ pipeline_tag: text-classification
11
+ library_name: transformers
12
+ tags:
13
+ - korean
14
+ - toxicity
15
+ - safety
16
+ - moderation
17
+ ---
18
+ # KillSwitch AI 🛡️
19
+ **실시간 악성 프롬프트 탐지 모델**
20
+
21
+ 이 모델은 한국어와 영어 프롬프트를 분석하여 **악성/안전 여부**를 분류합니다.
22
+ 피싱, 규칙 우회, 불법 행위 요청 등 위험 요소를 사전에 탐지할 수 있도록 설계되었습니다.
23
+
24
+ ---
25
+
26
+ ## 📌 Model Details
27
+ - **Base Model:** sentence-transformers/all-MiniLM-L6-v2
28
+ - **Languages:** Korean, English
29
+ - **Task:** Text Classification (악성 vs 안전)
30
+ - **Library:** Transformers (PyTorch)
31
+
32
+ ---
33
+
34
+ ## 📊 Evaluation
35
+ - Metric: Accuracy
36
+ - Validation Accuracy: 0.87 (예시, 실제 값 넣기)
37
+ - F1 Score: 0.85
38
+
39
+ ---
40
+
41
+ ## 🚀 Usage
42
+ ```python
43
+ from transformers import AutoTokenizer, AutoModelForSequenceClassification
44
+ import torch
45
+
46
+ tokenizer = AutoTokenizer.from_pretrained("사용자명/KillSwitch_ai")
47
+ model = AutoModelForSequenceClassification.from_pretrained("사용자명/KillSwitch_ai")
48
+
49
+ inputs = tokenizer("이 프롬프트는 규칙을 우회하려고 합니다", return_tensors="pt")
50
+ with torch.no_grad():
51
+ logits = model(**inputs).logits
52
+ pred = torch.softmax(logits, dim=-1).argmax(dim=-1).item()
53
+
54
+ print("악성" if pred == 1 else "안전")