Skip to main content

One-line AutoML: from idea to trained model using Hugging Face + AutoGluon

Project description

AutoHF

One-line AutoML: from idea to trained model using Hugging Face + AutoGluon.

AutoHF is an autonomous machine learning pipeline that takes a natural language description of a task (e.g., "sentiment analysis") and automatically finds the best datasets on Hugging Face, ranks them by quality, and trains a state-of-the-art model using AutoGluon.


Features

  • Intent-to-Task: Automatically detects ML task types (classification, regression, etc.) and keywords from natural language.
  • Autonomous Dataset Discovery: Searches the Hugging Face Hub for relevant datasets using multi-strategy search.
  • Intelligent Ranking: Ranks datasets based on quality signals like downloads, likes, and metadata completeness.
  • Automated Training: Leverages AutoGluon to train high-quality models with minimal configuration.
  • Agentic Architecture: Inspired by patterns from AutoGen, LangGraph, and OpenHands for robust state management and collaboration.
  • Interactive Gemma Chat: Run a single prompt or start an interactive chat session with local Gemma models.

Installation

# Basic installation
pip install autohf

# With training support (recommended)
pip install "autohf[train]"

CLI Quick Start (Step-by-Step)

AutoHF provides a simple command-line interface:

Step 1: Detect and Train a Model

To find the best datasets and train a model directly from a task description:

autohf train "sentiment analysis"

Or with custom presets and training limits:

autohf train "spam detection" --preset high_quality --time-limit 600

Step 2: Search and Rank Datasets

If you only want to discover and rank the top Hugging Face datasets for your task without training:

autohf search "question answering"

You can also list top models for the task:

autohf search "question answering" --models

Step 3: Interactive local Gemma Chat

To query or chat with a local Gemma model (such as google/gemma-4-E2B-it):

# Start an interactive multi-turn chat REPL session
autohf chat

# Or run a single prompt query directly
autohf chat "Explain AutoML in one sentence."

Note: Make sure your HF_TOKEN environment variable is set to download the model.

Step 4: Show package info and supported task types

autohf info

Python API Usage

from autohf import AutoHF

# Initialize and train
hf = AutoHF.from_preset("medium_quality")
result = hf.train("customer review classification")

# Access results
print(f"Best model: {result.best_model_name}")
print(f"Accuracy: {result.metrics['accuracy']}")
print(f"Model saved at: {result.model_path}")

License

MIT License. See LICENSE for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

autohf-1.0.0.tar.gz (37.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

autohf-1.0.0-py3-none-any.whl (39.3 kB view details)

Uploaded Python 3

File details

Details for the file autohf-1.0.0.tar.gz.

File metadata

  • Download URL: autohf-1.0.0.tar.gz
  • Upload date:
  • Size: 37.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for autohf-1.0.0.tar.gz
Algorithm Hash digest
SHA256 a4d473f10c4a616f259ce646ab76a4a61f7a8ea80206445b3835cdd768686125
MD5 86f9166c218c6a6598c20c21a5799f51
BLAKE2b-256 0406bd26cd96d63ac0655ff5888266ebce08b075dedee02fe80471bb18f9c54f

See more details on using hashes here.

Provenance

The following attestation bundles were made for autohf-1.0.0.tar.gz:

Publisher: publish.yml on teambugbusters00/automl-pipeine

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file autohf-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: autohf-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 39.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for autohf-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f306e0ee7a498e3b2146d8f55642eca16fae4b8fd255a504cb3795ebe76e471b
MD5 3cb720a090adf3bc516286dfdf525d75
BLAKE2b-256 6a12f96eb8e01b61baf304e4674f401e9a5bf908a298c64352d50a5d287a12b1

See more details on using hashes here.

Provenance

The following attestation bundles were made for autohf-1.0.0-py3-none-any.whl:

Publisher: publish.yml on teambugbusters00/automl-pipeine

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page