π« The Pain Point
Every customer request needs a professional quotation PDF. You have product data in Excel but creating formatted quotes manually takes 30 minutes each.
π Agentic Solution
A Template-Based Quotation Generator that produces professional PDFs from data.
Key Features:
- Template System: Reusable quote layout.
- Auto-Calculation: Sum totals, apply discounts.
- Batch Generation: Create multiple quotes from Excel.
βοΈ Phase 1: Commander (Quick Fix)
For a single quote.
Prompt:
βI have product data for a quote. Write a Python script using reportlab to:
- Header: Company logo, name, address, quote number/date.
- Table: Product name, quantity, unit price, total.
- Footer: Subtotal, VAT (10%), Grand Total.
- Output: Save as
Quote_001.pdf.Accept data as JSON or from Excel. Print confirmation.β
Result: Professional quotation ready to send.
ποΈ Phase 2: Architect (Permanent Tool)
For Sales Teams.
Engineering Prompt:
**Role:** Python GUI Developer (PyQt6 Specialist)
**Task:** Create "Quotation PDF Generator" Desktop App
**Objective:** A wizard-style tool to generate professional PDF quotes from data inputs.
**Tech Stack:**
* Language: Python 3.10+
* GUI Library: PyQt6 (Cross-platform)
* PDF Engine: ReportLab
* Packaging: PyInstaller
**Functional Requirements:**
1. **UI Layout (PyQt6):**
* **Step 1: Customer:** Inputs for Name, Address, Date.
* **Step 2: Items:** Table widget to add Product, Qty, Price (Auto-calc Total).
* **Step 3: Styling:** Logo picker, Color theme selection.
* **Action:** "Export PDF".
2. **Core Logic:**
* **ReportLab Canvas:** Draw vector graphics and text.
* **Layout:** Table flowable for dynamic item lists.
* **Calculations:** Subtotal, VAT, Grand Total logic.
* **Threading:** Generation is fast, but threaded to keep UI fluid.
3. **Deliverables:**
* `main.py`: Complete source code.
* `requirements.txt`: Dependencies.
* **Build Instructions:**
* Windows: `pyinstaller --onefile --noconsole main.py`
* macOS: `pyinstaller --windowed --noconsole main.py`
π§ Prompt Decoding
- reportlab: Pythonβs de facto standard for programmatic PDF creation.
π οΈ Instructions
- Install:
pip install reportlab - Copy Prompt β Customize template β Run.