|
Download README.md from athenahq/ACE-classifier-doc2vec: direct link, hf CLI and curl.
- Browser
- Download file 2.39 kB
-
https://huggingface.co/athenahq/ACE-classifier-doc2vec/resolve/main/README.md
- Command line
-
hf download hf://athenahq/ACE-classifier-doc2vec/README.md
-
curl -L -o README.md https://huggingface.co/athenahq/ACE-classifier-doc2vec/resolve/main/README.md
2.39 kB
| title: ACE Classifier Doc2Vec | |
| emoji: 🤖 | |
| colorFrom: blue | |
| colorTo: green | |
| sdk: custom | |
| app_port: 8080 | |
| # ACE Content Attribution Classifier (Doc2Vec) | |
| This model classifies content as either "attributed" or "unattributed" using Doc2Vec embeddings and machine learning classifiers. | |
| ## Model Details | |
| - **Training Date**: 2025_09_17 | |
| - **Architecture**: Doc2Vec + Machine Learning Classifier | |
| - **Task**: Binary text classification | |
| - **Classes**: attributed, unattributed | |
| ## Usage | |
| ### API Format | |
| Send POST requests to the inference endpoint: | |
| ```json | |
| { | |
| "inputs": { | |
| "content": "Your content text here", | |
| "meta_description": "Optional meta description" | |
| } | |
| } | |
| ``` | |
| ### Response Format | |
| ```json | |
| [ | |
| { | |
| "label": "attributed", | |
| "score": 0.75 | |
| }, | |
| { | |
| "label": "unattributed", | |
| "score": 0.25 | |
| } | |
| ] | |
| ``` | |
| ### Python Example | |
| ```python | |
| import requests | |
| api_url = "https://api-inference.huggingface.co/models/athenahq/ACE-classifier-doc2vec" | |
| headers = {"Authorization": "Bearer YOUR_HF_TOKEN"} | |
| data = { | |
| "inputs": { | |
| "content": "Machine learning models for content attribution analysis", | |
| "meta_description": "A comprehensive guide to ML-based content classification" | |
| } | |
| } | |
| response = requests.post(api_url, headers=headers, json=data) | |
| result = response.json() | |
| print(result) | |
| ``` | |
| ### cURL Example | |
| ```bash | |
| curl -X POST \ | |
| https://api-inference.huggingface.co/models/athenahq/ACE-classifier-doc2vec \ | |
| -H "Authorization: Bearer YOUR_HF_TOKEN" \ | |
| -H "Content-Type: application/json" \ | |
| -d '{ | |
| "inputs": { | |
| "content": "Your content text here", | |
| "meta_description": "Optional meta description" | |
| } | |
| }' | |
| ``` | |
| ## Model Performance | |
| The model uses the best-performing combination from extensive hyperparameter tuning across multiple Doc2Vec configurations and classifiers. | |
| ## Files | |
| - `handler.py`: Custom inference handler | |
| - `model_summary.json`: Overview of all trained models | |
| - `rank_1_*_classifier.pkl`: Best performing classifier | |
| - `rank_1_*_doc2vec.model`: Best performing Doc2Vec model | |
| - `rank_1_*_metadata.json`: Model metadata and configuration | |
| ## Technical Details | |
| - **Doc2Vec**: Uses both PV-DM and PV-DBOW algorithms | |
| - **Preprocessing**: Text cleaning, tokenization, and filtering | |
| - **Classifiers**: Random Forest, SVM, Logistic Regression, Neural Networks | |
| - **Evaluation**: Comprehensive accuracy and confidence analysis | |