Huggingface deployment for FastHTML
Project description
FastHTML on 🤗 Spaces
Deploy a FastHTML application to HuggingFace Spaces for free with one command!
Quickstart
- Create a free account on HuggingFace
- Go to your account settings and create an access token with write access. Keep this token safe and don't share it.
- Set the
HF_TOKEN
environment variable to that token - Install fasthtml-hf:
pip install fasthtml-hf
- Run
fh_hf_deploy <space_name>
, replacing<space_name>
with the name you want to give your space.
By default this will upload a public space. You can make it private with --private true
.
Configuration
The space will upload a backup of your database to a HuggingFace Dataset. By default it will be private and its name will be <your-huggingface-id>/space-backup
. You can change this behavior in the config.ini
file. In not provided, a default file will be created with the contents (note that the [DEFAULT]
line is required at the top):
[DEFAULT]
dataset_id = space-backup
db_dir = data
private_backup = True
If you so choose, you can disable the automatic backups and use persistent storage instead for $5/month (USD).
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
Built Distribution
Hashes for fasthtml_hf-0.1.4-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6fb0146acee6ff34a364213871d1ef0474f4b5fd72e194a9a7b16e4611b74bed |
|
MD5 | 7f233ed94a29dddd01440b25c28db435 |
|
BLAKE2b-256 | 3645433b65c77a66de0f13550f0791374bee0b8cb6218ab4d5d1ca1f2b3a6f2e |