Skip to content
/ hyper_log Public

Fetch bookmarks from Karakeep, download videos via yt-dlp, compile to single MP4, generate report. Filters videos >3min.

Notifications You must be signed in to change notification settings

alx/hyper_log

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Hyper Log

Hyper Log

Fetch bookmarks from Karakeep, download videos via yt-dlp, compile to single MP4, generate report. Filters videos >3min.

Prerequisites

  • Python 3.7+: pip install requests python-dotenv jinja2
  • yt-dlp: pip install yt-dlp
  • FFmpeg: sudo apt install ffmpeg
  • Karakeep instance with API access

Setup

cp .env.example .env

Edit .env:

KARAKEEP_BASE_URL=http://localhost:3080
KARAKEEP_LIST_ID=your_list_id
KARAKEEP_API_KEY=ak2_xxxxx

Usage

# Default: last 7 days, YouTube format (1920x1080)
python main.py

# Specific date range
python main.py --start-date 2025-09-23 --end-date 2025-09-30

# Skip download, merge only
python main.py --merge-only --end-date 2025-09-30

# TikTok format (1080x1920 portrait)
python main.py --tiktok

# Combined flags
python main.py --tiktok --merge-only --end-date 2025-09-30

Features

  • Format normalization: Re-encodes mixed video formats (MP4/WebM) to uniform H.264/AAC
  • Dimension consistency: Scales videos to fit standard dimensions with letterboxing (no distortion)
  • Platform presets: YouTube (1920x1080) or TikTok (1080x1920) via --tiktok flag
  • Merge-only mode: Skip downloads, compile existing videos via --merge-only
  • Timestamp correction: Fixes non-monotonic DTS warnings with -vsync cfr and -async 1
  • Smart caching: Skips re-encoding if normalized files already exist

YouTube Publishing

Minimal YouTube uploader in youtube.py (104 lines):

# Setup environment variables
export YOUTUBE_CLIENT_ID="your_client_id"
export YOUTUBE_CLIENT_SECRET="your_secret"
export YOUTUBE_PROJECT_ID="your_project"

# Upload latest compilation
python youtube.py

Auto-uploads latest .mp4 from compilation/ with matching .md description as private video.

License

MIT

About

Fetch bookmarks from Karakeep, download videos via yt-dlp, compile to single MP4, generate report. Filters videos >3min.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •