What is modUpload?
modUpload is the most complex Shiny UI module in the Artalytics platform, providing comprehensive artwork upload, validation, and async processing capabilities. It handles the complete ingestion workflow from file upload through advanced image/video analysis pipelines.
Key Features
- Multi-Step Wizard - Guided artwork submission with validation at each step
- Multiple File Types - Supports images (PNG, JPEG), videos (MP4), and raw canvas files (.procreate)
- Async Processing - Background pipeline execution with real-time progress monitoring using {future} and {promises}
- Validation Framework - Comprehensive input validation using {shinyvalidate}
- Deduplication - Image hash checking to prevent duplicate uploads
- Project Management - Artwork organization and purchase link management
System Requirements
modUpload depends on 11 system libraries for full functionality. These are automatically installed by {pak} when installing the package:
- ImageMagick++ - Image processing and analysis
- FFmpeg - Video frame extraction
- Tesseract OCR - Text recognition from images
- ExifTool - Metadata extraction
- Poppler - PDF processing
- Plus numerical libraries (Armadillo, BLAS/LAPACK, ARPACK, FFTW3)
See the package DESCRIPTION SystemRequirements field for the complete list.
Platform Position
modUpload sits in the application layer of the Artalytics ecosystem:
appPlatform (main Shiny app)
|
modUpload (upload/ingestion) - modGallery, modBrowse, modFrames (display)
|
artutils, artpixeltrace, artpipelines (processing)
|
artcore (infrastructure: DB, CDN, workflows)
modUpload is a MODULE package - it requires platform infrastructure and is designed to be embedded in appPlatform, not deployed standalone.
Basic Integration
UI Integration
library(shiny)
library(bslib)
library(modUpload)
ui <- bslib::page_fluid(
modUploadUI("upload")
)Server Integration
The server function requires a reactive list (r) containing:
-
r$artist- Artist UUID -
r$appdata- Complete artist context fromartutils::get_appdata()
server <- function(input, output, session) {
r <- reactiveValues(
artist = "746b8207-72f5-4ab6-8d19-a91d03daec3d"
)
observe({
r$appdata <- artutils::get_appdata(r$artist, r$artwork)
})
modUploadServer("upload", r)
}Environment Variables
modUpload inherits environment variables from its dependencies:
| Variable | Source | Purpose |
|---|---|---|
ART_PGHOST |
artcore | PostgreSQL host |
ART_PGPORT |
artcore | PostgreSQL port |
ART_PGUSER |
artcore | Database user |
ART_PGPASS |
artcore | Database password |
ART_BUCKETS_KEY_ID |
artcore | DigitalOcean Spaces key ID |
ART_BUCKETS_KEY_SECRET |
artcore | Spaces secret key |
ART_RUNAS_DEMO |
artcore | Enable demo mode (disables writes) |
See dependency package READMEs for full documentation.
Next Steps
- Processing Pipeline - Learn about async processing patterns
- Validation Framework - Understand input validation rules
- Wizard Workflow - Developer guide for the multi-step UI
- Function Reference - Complete API documentation
