Krep icon

Krep

Createdbmorphism

Enables high-performance string searches with automatic CPU core scaling.

About

Krep is a high-performance string search utility integrated with the Model Context Protocol (MCP). It leverages the krep binary, an ultra-fast pattern matching tool, to provide efficient pattern searching in files and strings for AI assistants. The server automatically scales to use all available CPU cores, optimizing search performance with algorithms selected based on pattern length and hardware acceleration through SIMD instructions.

Key Features

  • Hardware Acceleration: Leverages SIMD instructions (SSE4.2/AVX2 on x86/x64, NEON on ARM) when available
  • Unified Interface: Single function with multiple modes (file search, string search, count-only)
  • High-Performance Search: Uses optimized algorithms (KMP, Boyer-Moore-Horspool, Rabin-Karp) selected based on pattern length
  • Optimized Multi-Threading: Automatically uses all available CPU cores for maximum parallel search performance
  • MCP Integration: Seamless integration with AI assistants through the Model Context Protocol

Use Cases

  • Efficient pattern searching in files for AI assistants
  • Counting occurrences of patterns within large datasets
  • Rapid string searching for various applications
Craft Better Prompts with AnyPrompt