{"categories":[{"label":"Libraries","url":"https://skillfed.io/packages/category/software-development-libraries/2"},{"label":"Text Editors","url":"https://skillfed.io/packages/category/text-editors"}],"enrichment":{"capability":"Finds multiple keyword strings in text efficiently using an Aho-Corasick automaton, built and pickled for reuse.","skillfed_tags":["string-matching","trie","pattern-search"],"use_cases":["Scan DNA sequencing reads for known CRISPR guide sequences or genetic markers in bioinformatics pipelines","Detect multiple malware signatures or intrusion patterns in network traffic or log files","Find all occurrences of a dictionary of keywords in large text documents for content filtering or analysis","Build a reusable index of product codes or identifiers to match against incoming transaction or inventory data","Implement fast spell-checking or autocorrect by matching input against a pre-built dictionary of valid words"],"what_it_does":"pyahocorasick is a C-based Python library implementing the Aho-Corasick string matching algorithm, allowing you to search for multiple keyword strings in text in a single pass. It exposes both a Trie data structure for dict-like key-value storage by string and a finalized automaton for efficient multi-pattern search. You build the automaton ahead of time, optionally pickle it to disk, then reuse it to search text repeatedly\u2014making it suited for applications like intrusion detection, anti-virus scanning, or bioinformatics where you have a fixed set of patterns to match against variable input.\n\nThe library stores pattern prefixes efficiently in memory and guarantees similar worst-case and best-case runtime regardless of pattern count, depending mainly on input text size and match count. It supports both unicode and bytes, works on Python 3.10 and up, and is available as pre-built wheels for Linux, macOS, and Windows, though building from source requires a C compiler.","worth_installing":"Yes, if you need to match multiple fixed patterns in text efficiently. The C implementation, active maintenance, permissive license, and zero security vulnerabilities make it reliable. Medium install friction is offset by pre-built wheels and performance gains over pure-Python alternatives for large-scale matching. Not necessary for single-pattern or occasional searches."},"id":"pyahocorasick","links":{"html":"https://skillfed.io/packages/pyahocorasick","md":"https://skillfed.io/packages/pyahocorasick.md","pypi":"https://pypi.org/project/pyahocorasick/"},"maintenance":{"status":"active"},"meta":{"latest_release":"2026-04-27","license_spdx":null,"license_treatment":"permissive","name":"pyahocorasick","python_support":"supports_current","summary":"pyahocorasick is a fast and memory efficient library for exact or approximate multi-pattern string search.  With the ``ahocorasick.Automaton`` class, you can find multiple key string occurrences at once in some input text.  You can use it as a plain dict-like Trie or convert a Trie to an automaton for efficient Aho-Corasick search. And pickle to disk for easy reuse of large automatons. Implemented in C and tested on Python 3.6+. Works on Linux, macOS and Windows. BSD-3-Cause license."},"popularity":{"monthly_downloads":5979577,"position":1997,"tier":"top_5000"},"security":{"n_vulnerabilities":0},"version":"2.3.1"}
