All Projects → voku → phonetic-algorithms

voku / phonetic-algorithms

Licence: MIT license
Phonetic-Algorithms for fuzzy searching | PHP

Programming Languages

PHP
23972 projects - #3 most used programming language

Projects that are alternatives of or similar to phonetic-algorithms

double-metaphone
Fast Double Metaphone algorithm
Stars: ✭ 70 (+400%)
Mutual labels:  phonetic, metaphone
Jellyfish
🎐 a python library for doing approximate and phonetic matching of strings.
Stars: ✭ 1,571 (+11121.43%)
Mutual labels:  fuzzy-search, metaphone
Fuzzyfilepath
Autocomplete relative or absolute file paths in Sublime Text project folder
Stars: ✭ 153 (+992.86%)
Mutual labels:  fuzzy-search
Yoyo-leaf
Yoyo-leaf is an awesome command-line fuzzy finder.
Stars: ✭ 49 (+250%)
Mutual labels:  fuzzy-search
Fuzzball.js
Easy to use and powerful fuzzy string matching, port of fuzzywuzzy.
Stars: ✭ 225 (+1507.14%)
Mutual labels:  fuzzy-search
Enhancd
🚀 A next-generation cd command with your interactive filter
Stars: ✭ 2,049 (+14535.71%)
Mutual labels:  fuzzy-search
git-smart-checkout
🧠 A command-line utility for switching git branches more easily. Switch branches interactively or use a fuzzy search to find that long-forgotten branch name.
Stars: ✭ 51 (+264.29%)
Mutual labels:  fuzzy-search
Nvim Lsputils
Better defaults for nvim-lsp actions
Stars: ✭ 142 (+914.29%)
Mutual labels:  fuzzy-search
ceja
PySpark phonetic and string matching algorithms
Stars: ✭ 24 (+71.43%)
Mutual labels:  metaphone
Scoper
Fuzzy and semantic search for captioned YouTube videos.
Stars: ✭ 225 (+1507.14%)
Mutual labels:  fuzzy-search
Alfred Workflow
Full-featured library for writing Alfred 3 & 4 workflows
Stars: ✭ 2,622 (+18628.57%)
Mutual labels:  fuzzy-search
Fzy
🔍 A simple, fast fuzzy finder for the terminal
Stars: ✭ 2,295 (+16292.86%)
Mutual labels:  fuzzy-search
sqlscan
Quick SQL Scanner, Dorker, Webshell injector PHP
Stars: ✭ 140 (+900%)
Mutual labels:  fuzzy-search
Fuzzysearch
Find parts of long text or data, allowing for some changes/typos.
Stars: ✭ 157 (+1021.43%)
Mutual labels:  fuzzy-search
hotfuzz
🚓 Fuzzy Emacs completion style
Stars: ✭ 56 (+300%)
Mutual labels:  fuzzy-search
Kube Fzf
Shell commands using kubectl and fzf for command-line fuzzy searching of Kubernetes Pods.
Stars: ✭ 153 (+992.86%)
Mutual labels:  fuzzy-search
Tntsearch
A fully featured full text search engine written in PHP
Stars: ✭ 2,693 (+19135.71%)
Mutual labels:  fuzzy-search
levenshtein.c
Levenshtein algorithm in C
Stars: ✭ 77 (+450%)
Mutual labels:  fuzzy-search
itunes-cli
Command line interface for control iTunes
Stars: ✭ 16 (+14.29%)
Mutual labels:  fuzzy-search
LinSpell
Fast approximate strings search & spelling correction
Stars: ✭ 52 (+271.43%)
Mutual labels:  fuzzy-search

Build Status Coverage Status Latest Stable Version Total Downloads Latest Unstable Version License

Phonetic-Algorithms

Description

  • "PhoneticGerman"-Class:

A phonetic algorithms for the german language via "Kölner Phonetik": en.wikipedia.org/wiki/Cologne_phonetics

  • "PhoneticEnglish"-Class:

A phonetic algorithms for the english language via "metaphone": en.wikipedia.org/wiki/Metaphone

  • "PhoneticFrench"-Class:

A phonetic algorithms for the french language via "SOUNDEX FR": www.roudoudou.com/phonetic.php

Installation

  1. Install and use composer in your project.
  2. Require this package via composer:
composer require voku/phonetic-algorithms

Usage

You the "phonetic_word"-method if you need a fuzzy-search for single words e.g. last-names or product-names.

use voku\helper\Phonetic;

$words = array(
  'Moelleken',
  'Mölleken',
  'Möleken',
  'Moeleken',
  'Moellecken',
  'Möllecken',
  'Mölecken',
);
$phonetic = new Phonetic('de');
foreach ($words as $word) {
  $phonetic->phonetic_word($string); // '6546'
}

You can use the "phonetic_sentence"-method to process sentences.

use voku\helper\Phonetic;

$string = 'Ein Satz mit vielen Wortern';
$phonetic = new Phonetic('de');
$phonetic->phonetic_sentence($string, (bool) false, (false|int) false); 

// [
//   'Ein' => '06', 
//   'Satz' => '8', 
//   'mit' => '62', 
//   'vielen' => '356', 
//   'Wortern' => '37276'
// ]

You can use the "phonetic_matches"-method to search for words in an array of words.

use voku\helper\Phonetic;

$phonetic = new Phonetic('de');

$tests = array(
    'Moelleken',  // '6546',
    'Mölleken',   // '6546',
    'Möleken',    // '6546',
    'Moeleken',   // '6546',
    'oder',       // '027',
    'was',        // '38',
    'Moellecken', // '6546',
    'Möllecken',  // '6546',
    'Mölecken',   // '6546',
);

$phonetic->phonetic_matches('Moelleken', $tests);
    
// [
//   'Moelleken'  => 'Moelleken',
//   'Mölleken'   => 'Moelleken',
//   'Möleken'    => 'Moelleken',
//   'Moeleken'   => 'Moelleken',
//   'Moellecken' => 'Moelleken',
//   'Möllecken'  => 'Moelleken',
//   'Mölecken'   => 'Moelleken',
// ]

History

See CHANGELOG for the full history of changes.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].