metadata
title: Biweekly Invoice Generator
emoji: π
colorFrom: red
colorTo: gray
sdk: gradio
sdk_version: 5.44.1
app_file: app.py
pinned: false
license: mit
short_description: A Gradio web application that processes employee CSV
π§Ύ Invoice Generator for Launch27 Data
A Gradio web application that processes employee CSV files and booking data to generate invoices with automatic tip calculations.
π Quick Start
For Hugging Face Spaces Deployment:
- Upload
app.py
andrequirements.txt
to your Space - Set SDK to "Gradio"
- The app will automatically launch
Local Installation:
pip install -r requirements.txt
python app.py
Requirements File (requirements.txt
):
gradio
pandas
π Features
- β Flexible CSV Upload: Works with 1-3 employee data files
- β Automatic Tip Processing: Extracts and includes tips from booking data
- β Date Range Filtering: Filter records by bi-weekly periods
- β Smart Date Parsing: Handles DD/MM/YY and DD/MM/YYYY formats
- β Pivot Table Generation: Creates summary report by employee
- β CSV Export: Download processed invoice as CSV file
π File Requirements
Required Files:
- Bookings CSV: Must contain booking data with tips
- At least 1 Employee CSV: Employee work data (1.csv, 2.csv, or 3.csv)
CSV Format Expected:
- Employee Files: Date, Team, Name, Hourly Rate, Hours Worked, Total
- Bookings File: Date, Teams Assigned (without IDs), Tip
π― Usage
- Upload Files: Add your employee CSV files and bookings CSV
- Set Date Range: Enter start and end dates (YYYY-MM-DD format)
- Generate: Click "Generate Invoice" button
- Download: Get your processed invoice CSV
π Output Format
The generated invoice includes:
- Employee summary with total hours and earnings
- Tips automatically added to respective employees
- Grand total calculations
- Matches Launch27 invoice format requirements
π Deployment
Local Development:
python app.py
Access at: http://localhost:7860
Cloud Deployment:
- Hugging Face Spaces: Upload
app.py
andrequirements.txt
- Railway/Render: Deploy with Python runtime
- Docker: Works with standard Python containers
π Notes
- Default date range: August 9-22, 2025
- Supports flexible employee file combinations
- Automatically handles name standardization
- Tips are processed from "Teams Assigned" field in bookings
- Output format matches expected Final-Invoice.csv structure
π§ Technical Details
- Framework: Gradio for web interface
- Data Processing: Pandas for CSV manipulation
- Date Handling: Flexible parsing with dayfirst=True
- File Management: Temporary files for secure downloads
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference