killykilly's picture
Upload folder using huggingface_hub
59b19e3 verified
|
Raw
History Blame Contribute Delete
784 Bytes
metadata
title: Nigerian Transaction Classifier API
emoji: 🏦
colorFrom: green
colorTo: gray
sdk: docker
app_port: 7860
pinned: false

Nigerian Transaction Classifier API

Serves killykilly/nigerian-transaction-classifier (DistilBERT) over a plain HTTP API for the finance-analyzer backend, since the model is not available through HF serverless Inference Providers.

The model is downloaded from the Hub at container startup, so pushing retrained weights to the model repo and restarting this Space is all that is needed to upgrade.

API

  • GET /health{"status": "ok", "model": "..."}
  • POST /classify with {"texts": ["debit | uber trip lagos", ...]}{"predictions": [{"label": "Transport", "score": 0.97}, ...]} (one prediction per input, same order)