-
-
Notifications
You must be signed in to change notification settings - Fork 8
package structure
This document explains the structure of the GGUF Loader 2.0.0 PyPI package and how the Smart Floating Assistant addon is included.
Package Name: ggufloader
Version: 2.0.0
Command: ggufloader
When users install with pip install ggufloader, they get:
- Complete GGUF Loader application
- Smart Floating Assistant addon (pre-installed)
- Comprehensive documentation
- All necessary dependencies
ggufloader/
├── pyproject.toml # Package configuration
├── README_PYPI.md # PyPI package description
├── build_pypi.py # Build script for PyPI
├── requirements.txt # Dependencies
├──
├── # Main Application Files
├── main.py # Basic GGUF Loader (no addons)
├── gguf_loader_main.py # GGUF Loader with addon support
├── addon_manager.py # Addon management system
├── config.py # Configuration
├── utils.py # Utilities
├── icon.ico # Application icon
├──
├── # UI Components
├── ui/
│ ├── ai_chat_window.py # Main chat interface
│ └── apply_style.py # UI styling
├──
├── # Core Models
├── models/
│ ├── model_loader.py # GGUF model loading
│ └── chat_generator.py # Text generation
├──
├── # UI Mixins
├── mixins/
│ ├── ui_setup_mixin.py # UI setup
│ ├── model_handler_mixin.py # Model handling
│ ├── chat_handler_mixin.py # Chat functionality
│ ├── event_handler_mixin.py # Event handling
│ └── utils_mixin.py # Utility functions
├──
├── # Widgets
├── widgets/
│ └── chat_bubble.py # Chat bubble component
├──
├── # Pre-installed Addons
├── addons/
│ └── smart_floater/ # Smart Floating Assistant
│ ├── __init__.py # Addon entry point
│ ├── simple_main.py # Main addon logic
│ ├── main.py # Full-featured version
│ ├── floater_ui.py # UI components
│ ├── comment_engine.py # Text processing
│ ├── injector.py # Text injection
│ ├── error_handler.py # Error handling
│ ├── privacy_security.py # Privacy features
│ └── performance_optimizer.py # Performance
├──
└── # Documentation
└── docs/
├── README.md # Documentation index
├── installation.md # Installation guide
├── quick-start.md # Quick start guide
├── user-guide.md # Complete user manual
├── addon-development.md # Addon development guide
├── addon-api.md # API reference
├── smart-floater-example.md # Example addon
├── configuration.md # Configuration guide
├── troubleshooting.md # Troubleshooting
├── contributing.md # Contributing guide
└── package-structure.md # This file
pip install ggufloaderggufloaderThis command launches gguf_loader_main.py which includes:
- Full GGUF Loader functionality
- Smart Floating Assistant addon (automatically loaded)
- Addon management system
- All UI components
When GGUF Loader starts, the AddonManager automatically:
-
Scans the
addons/directory -
Finds folders with
__init__.pyfiles -
Loads addons by calling their
register()function - Displays addon buttons in the sidebar
The Smart Floating Assistant is included as a pre-installed addon:
# addons/smart_floater/__init__.py
from .simple_main import register
__all__ = ["register"]
# When loaded, it provides:
# - Global text selection detection
# - Floating button interface
# - AI text processing (summarize/comment)
# - Seamless clipboard integration- Package Installation: Addon files are installed with the package
-
Application Start:
AddonManagerdiscovers and loads addons - User Interaction: Users can access addons via the sidebar
- Background Operation: Smart Floater runs continuously in background
[project]
name = "ggufloader"
version = "2.0.0"
dependencies = [
"llama-cpp-python>=0.2.72",
"PySide6>=6.6.1",
"pyautogui>=0.9.54",
"pyperclip>=1.8.2",
"pywin32>=306; sys_platform == 'win32'",
]
[project.scripts]
ggufloader = "gguf_loader.gguf_loader_main:main"
[tool.setuptools]
packages = [
"gguf_loader",
"gguf_loader.addons",
"gguf_loader.addons.smart_floater"
]
include-package-data = trueAll necessary files are included:
- Python source code
- Documentation (
.mdfiles) - Icons and images
- Configuration files
- Addon files
-
Install:
pip install ggufloader -
Launch:
ggufloader - Load Model: Click "Select GGUF Model"
- Use Smart Floater: Select text anywhere → click ✨ button
- Smart Floater appears in addon sidebar automatically
- Users can click to open control panel
- No additional installation required
- Works immediately after model loading
Users can access documentation:
- Online: GitHub repository
- Locally: Installed with package in
docs/folder - In-app: Help links and tooltips
When releasing new versions:
-
Update version in
pyproject.toml - Update changelog and documentation
- Test addon compatibility
- Build and upload to PyPI
Smart Floater updates are included in package updates:
- Bug fixes and improvements
- New features and capabilities
- Performance optimizations
- Security enhancements
- Develop new features and addons
- Test thoroughly with various models
- Update documentation
-
Build package with
python build_pypi.py - Upload to PyPI
- Study the Smart Floater example
- Follow the addon development guide
-
Create addons in
addons/directory - Test with GGUF Loader
- Share with community
- Package Size: ~50MB (includes all dependencies)
- Core Dependencies: 5 main packages
- Optional Dependencies: GPU acceleration packages
- Documentation: 10+ comprehensive guides
- Python: 3.8+ (tested on 3.8, 3.9, 3.10, 3.11, 3.12)
- Operating Systems: Windows, macOS, Linux
- Architectures: x86_64, ARM64 (Apple Silicon)
- Python Version: Ensure Python 3.8+
- Dependencies: Install build tools if needed
-
Permissions: Use
--userflag if needed - Virtual Environment: Recommended for isolation
- Check Logs: Look for addon loading errors
-
Verify Structure: Ensure
__init__.pyexists - Dependencies: Check addon-specific requirements
- Permissions: Verify file permissions
-
Documentation: Check
docs/folder - GitHub Issues: Report bugs and issues
- Community: Join discussions and forums
- Support: Contact [email protected]
The package structure is designed to provide:
-
Easy Installation: Single
pip installcommand - Immediate Functionality: Smart Floater works out of the box
- Extensibility: Clear addon development path
- Maintainability: Well-organized codebase
- User-Friendly: Comprehensive documentation
This package structure ensures that GGUF Loader 2.0.0 provides a complete, professional AI text processing solution with the Smart Floating Assistant included by default! 🚀