00jlich/abs-kosync-bridge

By 00jlich

Updated about 18 hours ago

Sync your reading progress between Audiobookshelf (Audiobooks) and KOReader/KoSync (Ebooks).

Image
Integration & delivery
Internet of things
Machine learning & AI
1

10K+

00jlich/abs-kosync-bridge repository overview

ABS-KoSync Bridge

Buy Me A Coffee

GitHub tag License issues - abs-kosync-bridge Docker Pulls GitHub Downloads (all assets, all releases) Docker Stars

The missing link between your ears and your eyes.

Seamlessly sync your reading progress between Audiobookshelf (Audiobooks) and KOReader/KoSync (Ebooks). Start listening in the car, and pick up exactly where you left off on your Kindle or Kobo.

🚀 Deployment

services:
  # ---------------------------------------------------------------------------
  # 1. The Bridge Service
  # ---------------------------------------------------------------------------
  abs-kosync:
    image: 00jlich/abs-kosync-bridge:latest
    container_name: abs_kosync
    restart: unless-stopped
    # depends_on:
    #  - audiobookshelf
    #  - kosync
    
    # CRITICAL: Machine Learning libraries need shared memory
    shm_size: '2gb'

    environment:
      - TZ=America/New_York
      # --- Server Connections ---
      - ABS_SERVER=http://audiobookshelf:80
      - ABS_KEY=your_abs_api_key_here
      - KOSYNC_SERVER=http://kosync:3000
      - KOSYNC_USER=admin
      - KOSYNC_KEY=your_kosync_password
      
      # --- Sync Logic ---
      - SYNC_PERIOD_MINS=5
      # Loop Prevention: Ignore small changes caused by rounding errors
      - SYNC_DELTA_ABS_SECONDS=60
      - SYNC_DELTA_KOSYNC_PERCENT=1
      
      # --- Matching Logic ---
      - FUZZY_MATCH_THRESHOLD=80
      - KOSYNC_HASH_METHOD=content  # Use 'content' for KOReader native hashing
      
    volumes:
      # Map the EXACT same folder structure used by your KOReader device if possible,
      # or just the root folder containing your EPUBs.
      - ./library:/books
      - ./bridge_data:/data

Configuration Variables

VariableDefaultDescription
ABS_SERVERNoneURL of your Audiobookshelf server (e.g., http://abs:13378)
ABS_KEYNoneAPI Key generated in ABS Settings
KOSYNC_SERVERNoneURL of your KoSync server (No trailing slash!)
KOSYNC_USERNoneYour KoSync username
KOSYNC_KEYNoneYour KoSync password
SYNC_PERIOD_MINS5How often to check for progress updates
SYNC_DELTA_ABS_SECONDS60Ignore audiobook changes smaller than X seconds (Loop prevention)
SYNC_DELTA_KOSYNC_PERCENT1Ignore ebook changes smaller than X% (Loop prevention)
FUZZY_MATCH_THRESHOLD80Confidence score (0-100) required for fuzzy matching
KOSYNC_HASH_METHODcontentcontent (Recommended/KOReader default) or filename (Legacy)

📖 Usage Guide

  1. The Matching Wizard Before syncing, you must link an Audiobook to an Ebook.
docker-compose run --rm abs-kosync python src/main.py match

1.1. Select the Audiobook from the list. 1.2. Select the Ebook from the list. 1.3. Done. The job is queued. You can close the terminal. The container logs will show the transcription progress.

  1. Monitoring Check the logs to see the sync in action:
docker-compose logs -f abs-kosync

  • Processing: Shows download and transcription status.
  • Syncing: Shows exactly what text is being matched and the calculated XPath.

Tag summary

Content type

Image

Digest

sha256:c95bf4436

Size

390.8 MB

Last updated

about 18 hours ago

docker pull 00jlich/abs-kosync-bridge:sha-902a3e2