A tool to manage Hugging Face models.
Project description
HF-MODEL-TOOL
A CLI tool for managing your locally downloaded HuggingFace models and datasets
Features
Core Functionality
- Smart Asset Listing: View models & datasets with comprehensive size and metadata information
- Duplicate Detection: Automatically find and clean duplicate downloads to save space
- Asset Details: View model configurations and dataset documentation with rich formatting
Installation
From PyPI (Recommended)
pip install hf-model-tool
From Source
git clone https://github.com/Chen-zexi/hf-model-tool.git
cd hf-model-tool
pip install -e .
Usage
Quick Start
hf-model-tool
This launches the interactive CLI with a professional welcome screen showing:
- System status and cache information
- Feature overview and navigation help
- Intuitive menu-driven interface
Navigation
- ↑/↓ arrows: Navigate menu options
- Enter: Select current option
- Back: Return to previous menu
- Config: Access settings and sort options
- Main Menu: Quick return to main menu from anywhere
- Exit: Clean application shutdown
Key Workflows
- List Assets: View all models and datasets with size information
- Manage Assets: Access deletion and deduplication tools
- View Details: Inspect model configs and dataset documentation
- Configuration: Change sorting preferences and access help
Configuration
Access the configuration menu via "Config" from any screen:
- Sort Options: Size (default), Date, or Name
- Future Features: Cache directory, display preferences
- Help System: Navigation and usage guide
Project Structure
hf_model_tool/
├── __main__.py # Application entry point with welcome screen
├── cache.py # HuggingFace cache directory scanning
├── ui.py # Rich terminal interface components
├── utils.py # Asset grouping and duplicate detection
└── navigation.py # Unified menu navigation system
🛠️ Development
Requirements
- Python ≥ 3.7
- Dependencies:
rich,inquirer,html2text
Logging
Application logs are written to ~/.hf-model-tool.log for debugging and monitoring.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file hf_model_tool-0.2.0.tar.gz.
File metadata
- Download URL: hf_model_tool-0.2.0.tar.gz
- Upload date:
- Size: 19.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a33b00756da3be60592503b3e9ff12de190b2805a8ee0bbac3697f49ae2cb0aa
|
|
| MD5 |
7b0f852e3d23842d733e2fba4de3c2a7
|
|
| BLAKE2b-256 |
6b0da5ec6ed91774d998ae9656d11728d73baa07e6e1b92c9e7c12a9b5be5b8a
|
File details
Details for the file hf_model_tool-0.2.0-py3-none-any.whl.
File metadata
- Download URL: hf_model_tool-0.2.0-py3-none-any.whl
- Upload date:
- Size: 15.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b9d5a8a24e486aa508ad061b0d703d2010bec75b250fff06955cfce8678b8829
|
|
| MD5 |
5e548353debc660ac38da71f04e47d52
|
|
| BLAKE2b-256 |
0dd3fecd4e2b1ff6d981f2e28104c48fb2fa51ea3fda1c618440b0ea16aac65d
|