File size: 1,338 Bytes
267c524
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
---
language: en
tags:
- zero-shot-classification
- wikidata
- knowledge-graph
license: mit
datasets:
- wikidata
- wikipedia
---

# Zero-Shot Wikidata Classifier

This model performs **zero-shot text classification** by dynamically integrating knowledge from Wikidata. It classifies text into custom categories without requiring training data.

## How It Works
1. **Input**: Receives any text input
2. **Knowledge Expansion**: Queries Wikidata for related concepts
3. **Classification**: Uses Wikipedia-trained BART model to match text to concepts
4. **Output**: Returns ranked categories with confidence scores

## Capabilities
- 🧠 **Dynamic Classification**: Adapts to new categories via Wikidata
-**Zero-Shot Learning**: No training required
- 🔍 **Knowledge Integration**: Leverages Wikipedia's semantic relationships
- 🌐 **Multilingual Support**: Works with 100+ languages (see multilingual section)

## Usage
```python
from transformers import pipeline
from wikidata import get_wikidata_labels

classifier = pipeline("zero-shot-classification", 
                      model="your-username/zero-shot-wikidata-classifier")

# Classify with Wikidata expansion
labels = get_wikidata_labels("renewable energy")
result = classifier("Perovskite solar cells achieve 30% efficiency", 
                   candidate_labels=labels)