Skip to content

Repository files navigation

MUVID Video Analyzer

A multimodal, unsupervised video-analytics tool (MUVID) that quantifies the typicality of short-form social-media videos and predicts their engagement. It is the application accompanying the paper below — upload a short video (e.g. a TikTok dance) and get its category, quality, likeability, recommended hashtags, most-similar videos, and how typical/atypical it is relative to a trend.

Live app: https://videoanalyzer.app


Paper

How Closely Should You Follow a Trend? Atypicality and Engagement on Social Media

Marc Bravin¹, Melanie Clegg², Reto Hofstetter³, Marc Pouly¹, Jonah Berger

  1. Lucerne School of Computer Science, Lucerne University of Applied Sciences and Arts (HSLU)
  2. Department of Marketing, Faculty of Business and Economics, University of Lausanne
  3. University of St. Gallen
  4. The Wharton School, University of Pennsylvania

Data availability: Journal of Marketing Dataverse — https://doi.org/10.7910/DVN/XXXXXX (DOI pending)

The paper develops MUVID to quantify the typicality of 85,000+ TikTok dance videos and shows that more atypical videos (more differentiated from the trend) generate more engagement. This repo is the public tool that lets researchers and practitioners quantify typicality and analyze short videos themselves.


What it does

Upload one or more short videos (MP4/MOV/AVI, ≤ 60 s) — or pick from the bundled examples — and MUVID returns:

  • Category — probability distribution across video types (dance, cooking, car, flipbook, …).
  • Quality scores — a visual-quality score, plus a dance-quality score for dance videos.
  • Likeability — predicted engagement (likes per 1,000 views).
  • Recommended hashtags — top-50 relevant hashtags as a word cloud.
  • Similar videos — nearest videos from a reference database (FAISS), linking back to TikTok.
  • Typicality / atypicality — upload 2+ videos to get pairwise visual / audio / overall similarity scores and a t-SNE scatter plot showing how differentiated each video is.
  • Export — download per-video features and embeddings as CSV.

How to use it

  1. Open the app (https://videoanalyzer.app or your local instance).
  2. Upload a short video, or click example videos to pick a bundled clip. Processing takes ~1 min/video.
  3. Open a video's details to see its category, quality, likeability, hashtags, and similar videos.
  4. Add a second video to compare — the similarity table and t-SNE chart show how typical/atypical each is.
  5. Export the results as CSV for downstream analysis.

Run locally

Docker (recommended)

Requires Docker and GNU Make.

make dev         # dev: frontend on :5173, backend on :8080 (hot-reload)
make local_prod  # production build, served on :8080

Without Docker

See INSTALL.md for the conda + npm setup (Ubuntu / macOS), then:

./start-production.sh   # builds the frontend and serves everything on :8080

Access points

URL Description
http://localhost:8080 Application frontend
http://localhost:8080/api REST API
http://localhost:8080/docs Interactive API docs
http://localhost:8080/health Health check

Architecture

  • Frontend — Vue 3 + Vite + TypeScript (Bootstrap, D3/Plotly for charts).
  • Backend — FastAPI (Python) with TensorFlow 2.15, FAISS, and librosa. Uvicorn (2 workers). In production the backend serves both the API and the built frontend on port 8080.

Main API routes (prefixed with /api):

Route Method Purpose
/process_video POST Analyze an uploaded video
/process_example_video/{id} POST Analyze a bundled example video
/example_videos GET List bundled example videos
/similar_videos POST Nearest videos for a processed video
/compute_similarities POST Pairwise similarity across processed videos
/similarity_chart POST t-SNE + cosine-similarity data (visual/audio/overall)
/health GET Health check

Models

The models/ folder holds the pre-trained assets loaded at startup:

  • MUVID/ — the core multimodal embedder (TensorFlow SavedModel; load with tf.keras.models.load_model).
  • category_classifier.h5, likeability_regressor.h5, *_quality_regressor.joblib — downstream predictors.
  • videos_*_embedding.index (FAISS) + *.parquet — reference embeddings and metadata for similarity search.
  • example_videos/ — sample clips for trying the app.

Repository layout

app/         FastAPI backend + Vue 3 frontend
models/      Pre-trained MUVID model, classifiers, FAISS indices, example videos
data/        Datasets
notebooks/   Analysis / model-development notebooks
load_test/   Load-testing scripts

Citation

Bravin, M., Clegg, M., Hofstetter, R., Pouly, M., & Berger, J. How Closely Should You Follow a Trend? Atypicality and Engagement on Social Media. Journal of Marketing (forthcoming).

MUVID-Video-Analyzer

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages