Skip to main content
Glama
Audiobook Library MCP Server

Audiobook Library MCP Server

by joelmale

🎧 Audiobook Library MCP Server

Advanced MCP server for intelligent audiobook library management with AI-powered pattern recognition, web lookup capabilities, and audio processing features.

TypeScript Node.js Claude MCP

✨ Features

🧠 AI-Powered Intelligence

  • Web Lookup Integration - Identifies books using Google Books, Open Library, and more

  • Advanced Pattern Recognition - Learns your organizational preferences

  • Smart Entity Recognition - Extracts authors, titles, series from any filename format

  • Intelligent Suggestions - Context-aware recommendations with confidence scoring

🎡 Audio Processing

  • MP3 Combination - Merge multiple files with lossless concatenation

  • M4B Audiobook Creation - Professional audiobooks with metadata and chapters

  • Format Conversion - Support for MP3, M4A, FLAC, OGG β†’ M4B

  • Automatic Chapter Markers - Generated from individual files

πŸ“š Library Management

  • Audiobookshelf Compatibility - Perfect integration with Audiobookshelf

  • Intelligent Organization - Author-first, series-first, or hybrid structures

  • Bulk Operations - Process hundreds of files efficiently

  • Archive Handling - Extract ZIP, RAR, 7Z files automatically

πŸ” Advanced Analysis

  • Filename Intelligence - Handles any naming convention

  • Metadata Enhancement - Combines file metadata with web sources

  • Confidence Scoring - Reliability ratings for all suggestions

  • Learning System - Gets smarter with every interaction

Related MCP server: calibre-mcp

πŸš€ Quick Start

Prerequisites

# Install FFmpeg (required for audio processing)
brew install ffmpeg  # macOS
# or visit https://ffmpeg.org/download.html

# Verify installation
ffmpeg -version

Installation

# Clone the repository
git clone https://github.com/yourusername/audiobook-mcp-server.git
cd audiobook-mcp-server

# Install dependencies
npm install

# Build the project
npm run build

Configuration

  1. Set up Claude Desktop configuration at ~/Library/Application Support/Claude/claude_desktop_config.json:

{
  "mcpServers": {
    "audiobook-library": {
      "command": "node",
      "args": ["/path/to/audiobook-mcp-server/dist/index.js"],
      "env": {
        "AUDIOBOOK_ROOT": "/path/to/your/audiobook/library"
      }
    }
  }
}
  1. Restart Claude Desktop

  2. Test the connection:

    "Scan my audiobooks library"

πŸ’‘ Usage Examples

Basic Operations

"Scan my audiobooks library"
"Analyze my Temp folder and suggest integration"
"Extract archive files in [folder]"

AI-Powered Analysis

"Analyze this filename using web lookup: 'HP1_sorcerers_stone_jim_dale.mp3'"
"Bulk analyze my messy files and suggest proper names"
"Get smart suggestions for organizing my library"

Audio Processing

"Combine the MP3 files in this folder into one audiobook"
"Create an M4B audiobook with metadata and chapters"
"Convert this series to M4B format with proper naming"

Learning & Preferences

"Learn from this action: I renamed the file to include the author"
"Update my preferences: I prefer author-first organization"
"Show me insights about my organizing patterns"

πŸ› οΈ Available Tools

Tool

Description

scan_library

Recursively scan audiobook directories

intelligent_filename_analysis

Analyze filenames using web lookups

smart_entity_recognition

Identify authors, titles, series from names

web_lookup_book

Query web sources for book information

bulk_filename_enrichment

Mass analyze and suggest improvements

combine_mp3_files

Merge multiple MP3s into single file

create_m4b_audiobook

Convert to M4B with metadata and chapters

analyze_patterns

Deep analysis of library patterns

smart_suggestions

AI-powered organization recommendations

learn_from_action

Record user actions for learning

🌍 Web Sources

  • Google Books API - Comprehensive book database

  • Open Library - Open-source book information

  • LibriVox - Public domain audiobooks

  • Audible - Audiobook-specific data (limited)

πŸ—οΈ Architecture

src/
β”œβ”€β”€ index.ts                 # Main MCP server implementation
β”œβ”€β”€ WebLookupEngine         # Web API integration and caching
β”œβ”€β”€ PatternRecognizer       # AI pattern detection and learning
β”œβ”€β”€ SmartSuggestionEngine   # Intelligent recommendation system
└── AudiobookMCPServer      # Core server with all tool implementations

πŸ“Š Data Storage

The server creates these files in your audiobook root directory:

  • .mcp_learning_data.json - Pattern recognition and user actions

  • .mcp_user_preferences.json - Explicit user preferences

  • .mcp_lookup_cache.json - Cached web lookup results (7-day expiry)

All data stays local on your system - no external data transmission except for web API queries.

πŸ”§ Development

# Development mode with auto-reload
npm run dev

# Build for production
npm run build

# Test the built server
node dist/index.js

πŸ“‹ Requirements

  • Node.js 18.0.0 or higher

  • FFmpeg (for audio processing)

  • TypeScript 5.0.0 or higher

  • Claude Desktop (for MCP integration)

🀝 Contributing

  1. Fork the repository

  2. Create a feature branch (git checkout -b feature/amazing-feature)

  3. Commit your changes (git commit -m 'Add amazing feature')

  4. Push to the branch (git push origin feature/amazing-feature)

  5. Open a Pull Request

πŸ“ License

This project is licensed under the MIT License - see the LICENSE file for details.

πŸ™ Acknowledgments

πŸ“§ Support

If you encounter issues or have questions:

  1. Check the Issues page

  2. Create a new issue with detailed information

  3. Include your system information and error logs


Transform your chaotic audiobook collection into a perfectly organized, AI-enhanced library! 🎧✨

Available Tools

24 tools
analyze_patternsB

Analyze library patterns and user behavior to provide intelligent suggestions

Inputs: analysisType, learningDepth, includePredictions.

bulk_filename_enrichmentC

Bulk analyze and suggest improvements for multiple files using web lookups

Inputs: batchSize, fileTypes, targetDirectory, generateSuggestions, +1 more.

combine_mp3_filesC

Combine multiple MP3 files into a single MP3 file

Inputs: inputFiles (required), outputPath (required), dryRun, deleteOriginals.

create_directoryC

Create a new directory structure

Inputs: relativePath (required).

create_m4b_audiobookC

Convert and combine audio files into M4B audiobook format with metadata

Inputs: inputFiles (required), outputPath (required), dryRun, bitrate, +3 more.

enhance_metadata_with_lookupC

Enhance existing metadata using web lookup results

Inputs: filePath (required), forceRefresh, mergingStrategy.

extract_archiveC

Extract compressed audio book archives

Inputs: archivePath (required), dryRun, extractTo, deleteAfter.

generate_audiobookshelf_structureC

Generate optimal Audiobookshelf directory structure from metadata

Inputs: basedOn, convention, includeSeriesNumbers.

get_file_infoC

Get detailed information about a specific file or directory

Inputs: relativePath (required), includeMetadata.

integrate_temp_folderB

Analyze Temp folder and suggest integration into main audiobooks library

Inputs: dryRun.

intelligent_filename_analysisB

Analyze filenames using web lookups to identify authors, titles, and series

Inputs: maxResults, targetPath, lookupSources, minConfidence.

learn_from_actionC

Record and learn from user actions to improve future suggestions

Inputs: context (required), outcome (required), actionType (required), feedback.

move_fileC

Move a file or directory to a new location

Inputs: sourcePath (required), destinationPath (required), dryRun.

pattern_insightsC

Get insights about detected patterns and learning progress

Inputs: timeframe, insightType.

rename_fileB

Rename a file or directory

Inputs: newPath (required), oldPath (required), dryRun.

scan_libraryC

Recursively scan the audiobook library and return structure

Inputs: maxDepth, subfolder, includeMetadata.

smart_entity_recognitionB

Identify authors, titles, series from filenames using pattern matching and web lookups

Inputs: filenames (required), contextPath, enableWebLookup, aggressiveMatching.

smart_suggestionsC

Generate intelligent suggestions based on learned patterns and user preferences

Inputs: targetPath, minConfidence, maxSuggestions, suggestionTypes.

standardize_audiobookshelf_structureC

Convert current structure to Audiobookshelf naming standards

Inputs: dryRun, convention, targetPath, includeMetadata.

suggest_reorganizationC

Analyze current structure and suggest improvements

Inputs: targetStructure.

update_preferencesC

Update user preferences based on explicit input or learned behavior

Inputs: preferences (required), learningMode.

validate_audiobookshelf_complianceC

Check if library structure follows Audiobookshelf best practices

Inputs: strictMode, targetPath.

validate_naming_rulesC

Check if files follow Audiobookshelf naming conventions

Inputs: relativePath (required).

web_lookup_bookC

Perform web lookups for specific book information

Inputs: query (required), sources, useCache, queryType.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    C2.8/5.0

    Scored across 24 tools

    Disambiguation2/5

    Several clusters of near-duplicate tools exist: intelligent_filename_analysis, smart_entity_recognition, and bulk_filename_enrichment all parse filenames with web lookups; analyze_patterns, smart_suggestions, pattern_insights, and learn_from_action all operate on the same learning/pattern domain; and validate_naming_rules, validate_audiobookshelf_compliance, standardize_audiobookshelf_structure, and suggest_reorganization overlap heavily. An agent would struggle to pick the right tool for 'identify book from filename' or 'check naming'.

    Naming Consistency3/5

    All names use snake_case, but verb style is inconsistent: verb-first action names (rename_file, validate_naming_rules) mix with noun-first and adjective-prefixed names (pattern_insights, intelligent_filename_analysis, smart_suggestions, web_lookup_book). The smart_/intelligent_/analyze_ prefixes don't map to a predictable pattern.

    Tool Count3/5

    24 tools is at the heavy end for what is essentially a file-management/metadata domain, and the count is inflated by redundant learning and validation tools. The core capabilities could be delivered in roughly half the tools without loss of function.

    Completeness4/5

    Coverage spans scanning, metadata enrichment, file operations, structure standardization, and MP3/M4B conversion, which is broadly complete for an audiobook library workflow. Gaps remain: no delete/remove file tool, no search/query tool over the library, and no direct read of embedded audio tags.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      B
      maintenance
      MCP server for Audiobookshelf that lets AI assistants browse libraries and manage listening progress, bookmarks, collections, and playlists.
      44
      84 npm
      2
      MIT
    • A
      license
      A
      quality
      D
      maintenance
      Enables AI assistants to search, browse, import, and manage a local Calibre ebook library, including duplicate detection and an inbox-based drop folder workflow.
      11
      MIT
    • F
      license
      A
      quality
      C
      maintenance
      Converts a single-file MP3/M4A audiobook plus its EPUB into a chaptered M4B, using silence-gap detection to find real chapter boundaries, with checkpointed job-based progress, EPUB preview, boundary inspection/waveform review, metadata lookup, and cover fetching/embedding tools for resumable, verifiable audiobook production.
      15
      -
    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables AI assistants to fetch and write ebook metadata, download covers, convert books between formats, and manage an ebook library through command-line tools. Batch operations default to dry-run, so changes can be previewed before being applied.
      MIT