8000 GitHub - calthejuggler/dewey: An AI powered digital librarian for renaming movie titles.
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

calthejuggler/dewey

Repository files navigation

The Dewey logo. An AI generated image of an owl sat atop a library book

Dewey

Hey there! Welcome to Dewey. My solution for renaming and organising movies in my own home server. Maybe it can be a solution for you too!

Note

This is a work in progress.

Caution

Dewey deletes files when moving them around! I am not responsible for any data loss! (but if it happens, please let me know and I can try to make sure it never happens again?)

Long story short - Use at your own risk!

Dewey is a file-organising tool that monitors an input directory for movie files, retrieves movie name suggestions from ChatGPT, and moves/renames the files to a structured output directory.

Table of Contents

  1. Features
  2. Installation
  3. Configuration
  4. License

Features

  • Watches an Input Directory – Continuously scans for new movie files.
  • OpenAI Integration – Uses a GPT-based service to generate or validate movie names.
  • Automatic Renaming – Moves and renames files to an organised output directory.
  • Configurable Logging – Supports different log levels (DEBUG, INFO, WARN, ERROR).
  • Docker Support – Easily run Dewey in a Docker container.
  • Docker Compose Support – Easily run Dewey in a Docker Compose
  • Other AI Integrations – Support for other AI services.
  • In Place Renaming – Rename files in place instead of moving them.
  • Copy Only – Copy files instead of moving them.

Installation

Option 1: Docker compose

services:
  dewey:
    image: calthejuggler/dewey:latest
    environment:
      - OPENAI_API_KEY=YOUR_API_KEY
      - LOG_LEVEL=DEBUG
    volumes:
      - /path/to/input/dir:/input
      - /path/to/output/dir:/output

Option 2: Docker

docker run -d \
  -v $(pwd)/input:/input \
  -v $(pwd)/output:/output \
  -e OPENAI_API_KEY=YOUR_API_KEY \
  -e LOG_LEVEL=INFO \
  calthejuggler/dewey:latest

Option 2: Using Bun locally

  1. Install Bun (follow the instructions at https://bun.sh/)

  2. Clone this repository:

    git clone https://github.com/calthejuggler/dewey.git
    cd dewey
  3. Install dependencies:

    bun install
  4. Run the application:

    bun run src/index.ts

Configuration

The application reads environment variables for certain configuration values:

  • INPUT_DIR: Directory to watch for new movie files (defaults to "/input").
  • OUTPUT_DIR: Directory to move and rename processed files (defaults to "/output").
  • STALE_TIME_MS: Time in milliseconds after which a directory is considered “stale” and ready for renaming (defaults to 30000, i.e., 30 seconds).
  • LOG_LEVEL: Controls the logging verbosity. Allowed values: "DEBUG", "INFO", "WARN", "ERROR" (defaults to "INFO").

License

This project is licensed under the MIT License.

Happy Movie Organising! For feedback, questions or feature requests, feel free to open an issue. Thank you for using Dewey!

About

An AI powered digital librarian for renaming movie titles.

Resources

License

Stars

Watchers

Forks

Packages

No packages published
0