# Shawn1993/cnn-text-classification-pytorch

CNNs for Sentence Classification in PyTorch

Repository: https://github.com/Shawn1993/cnn-text-classification-pytorch
Canonical: https://ross.abutalabs.com/products/cnn-text-classification-pytorch
Language: Python
License: Apache-2.0
License Family: permissive
Topics: cnn-model, pytorch
Last push: 2026-03-23T08:26:02+00:00

## Health v2 (maintenance only)
Score: 65/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 73, release rhythm 35, longevity 100
- inputs: {"age_days": 3491, "days_push": 163, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1043, forks 270 (observed 2026-08-28T04:03:21.108652+00:00)

## What it is
A PyTorch implementation of Kim's CNN architecture for sentence classification, reproducing results from the paper 'Convolutional Neural Networks for Sentence Classification'. It trains CNN text classifiers on datasets like MR and SST via a command-line interface.

## Use cases
- train a CNN text classifier in pytorch
- reproduce Kim's sentence classification paper results
- classify sentences into sentiment categories
- learn how CNN text classification works
- benchmark text classification on MR and SST datasets

## When to choose
- you want a faithful PyTorch reproduction of Kim's CNN sentence classification model
- you need a simple, dependency-light text classification baseline
- you want to experiment with CNN hyperparameters for text classification

## When to avoid
- you need transformer-based or state-of-the-art text classification
- you want a production-ready text classification service
- you need multi-label or long-document classification

## Facets
- artifact type: library
- maturity: active
- function: machine-learning, nlp, deep-learning
- domain: deep-learning, machine-learning
- platform: python, cli
- tags: pytorch, cnn, text-classification, sentence-classification, research-reproduction, natural-language-processing, gpu

## Member repositories
- Shawn1993/cnn-text-classification-pytorch (main) score 65

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:03:21.108652+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T07:02:17.499170+00:00, confidence not recorded.
  - readme: https://github.com/Shawn1993/cnn-text-classification-pytorch (fetched 2026-08-28T04:03:21.108652+00:00, sha c699044fd1f2)
- Data as of 2026-08-30T08:39:29.467469+00:00.
