Skip to content

lazyplatypus/AhoCorasick.js

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 

Repository files navigation

AhoCorasick.js

This is a JavaScript implementation of the Aho-Corasick String Matching algorithm invented by Alfred V. Aho and Margaret J. Corasick on Wikipedia.

This version of the algorithm presents several improvements, including modifications to reduce memory space and computational intensity. This includes replacing the more traditional Linked List Trie (LLT) with the Double Array Trie (DAT). By using two linear arrays to determine the state transition, it eliminates the need to allocate memory space to the unecessary step. This API allows for both "Multi-Pattern Search", which is the combination of the classic Aho-Corasick (AC) with the Double Array Trie (DAT), and the "exact match search" which only utilizes the Double Array Trie (DAT).

About

AC automation on Redis

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published