npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

algoman

v1.0.0

Published

High-performance enterprise algorithms, non-native data structures, and resilient execution framework for TypeScript & Node.js.

Readme

algoman

An enterprise-grade, resilient, zero-dependency algorithmic execution and data structure framework for TypeScript/JavaScript.

algoman provides every computer science data structure across all domains:

  • Core Fundamentals: Linked Lists, Stacks, Queues, Graphs, Chained Hash Tables.
  • Persistent Data Structures: Version-controlled trees with time-travel historical range queries.
  • Interval & Scheduling: Augmented 1D interval trees for collision detection and calendar bookings.
  • Balanced Search Trees: AVL Trees, Red-Black Trees, Splay Trees, Treaps, Ropes, Radix Trees.
  • Priority Queues & Heaps: Fibonacci Heaps, Pairing Heaps, Min-Max Heaps, Binary Heaps.
  • Spatial Multi-Dimensional Hierarchies: R-Trees, 2D QuadTrees, 2D K-D Trees.
  • Probabilistic & Streaming Big-Data: Cuckoo Filters, Bloom Filters, HyperLogLog, Count-Min Sketch.
  • High-Performance Automata: Aho-Corasick multi-pattern matching, Suffix Automaton DAWG.
  • Distributed Backend Infrastructure: Consistent Hashing Rings, Token Buckets, Sliding Window Rate Limiters, Circuit Breakers.

🏛️ Master Data Structure Catalog

1. Fundamental Core Structures

| Structure | Class Name | Complexity & Key Features | |---|---|---| | Linked List | LinkedList<T> | Singly linked list with $O(1)$ append/prepend, in-place reversal (reverse()), and iteration. | | Stack (LIFO) | Stack<T> | $O(1)$ amortized push, pop, peek, and reverse traversal. | | Queue (FIFO) | Queue<T> | Circular ring buffer queue with true $O(1)$ enqueue/dequeue without JavaScript array shift penalties. | | Double-Ended Queue | Deque<T> | True $O(1)$ push/pop at both front and back (std::deque / collections.deque). | | Graph | Graph<T> | Generic graph (directed/undirected, weighted/unweighted) with vertex & neighbor APIs. | | Hash Table | HashTable<K, V> | Low-level chained hash table with FNV-1a hashing and dynamic prime rehashing. | | BiMap | BiMap<K, V> | Strict 1-to-1 bidirectional bijection map with $O(1)$ forward (get) and inverse (getKey) lookups. | | MultiMap | MultiMap<K, V> | 1-to-many key-value multi-dictionary (std::multimap). | | Disjoint Set | DisjointSet<T> | Union-Find with path compression + rank ($\approx O(1)$). |


2. Persistent, Interval & Advanced Trees

| Structure | Class Name | Complexity & Key Features | |---|---|---| | Persistent Segment Tree | PersistentSegmentTree | Immutable version-controlled tree. Allows $O(\log N)$ historical range queries at ANY past version in history via path copying. | | Interval Tree | IntervalTree<T> | Stores 1D intervals $[low, high]$. Finds all overlapping intervals in $O(\log N + K)$ time for calendar booking and genomic sequences. | | AVL Tree | AVLTree<K, V> | Strictly height-balanced BST (balance factor $\le 1$). Faster lookups than Red-Black trees. | | Red-Black Tree (Map) | SortedMap<K, V> | Self-balancing BST (std::map / TreeMap) with $O(\log N)$ lowerKey, higherKey, minKey, maxKey. | | Red-Black Tree (Set) | SortedSet<T> | Unique sorted set with floor/ceiling checks (std::set). | | Splay Tree | SplayTree<K, V> | Self-adjusting BST moving hot elements to root via splay rotations (cache-oblivious 80/20 access). | | Rope | Rope | Binary tree of string leaves used in high-performance text editors (VS Code, Sublime). $O(\log N)$ insert, split, and $O(1)$ concat. | | Radix Tree | RadixTree<T> | Compact prefix trie for HTTP routing engines (Gin/Echo/Fastify). | | Standard Trie | Trie | Fast prefix search and autocomplete. |


3. Range & Spatial Indices

| Structure | Class Name | Complexity & Key Features | |---|---|---| | Segment Tree | SegmentTree<T> | $O(\log N)$ associative range queries (sum, min, max, gcd). | | Treap | Treap<T> | Randomized Cartesian BST with $O(\log N)$ split, merge, and kthSmallest. | | Fenwick Tree | FenwickTree | $O(\log N)$ point updates and prefix range sum queries. | | Sparse Table | SparseTable<T> | Range Minimum Queries (RMQ) in strictly guaranteed $O(1)$ constant time. | | R-Tree | RTree<T> | Multidimensional bounding-box index for spatial geographic databases (PostGIS, SQLite R*Tree). | | 2D QuadTree | QuadTree<T> | 2D quadrant spatial subdivision for collision detection and viewport culling. | | 2D K-D Tree | KDTree2D | $k$-d tree nearest neighbor search in $O(\log N)$. |


4. Priority Queues & Heaps

| Structure | Class Name | Complexity & Key Features | |---|---|---| | Fibonacci Heap | FibonacciHeap<T> | Gold standard for graph algorithms: $O(1)$ insert, $O(1)$ merge, $O(1)$ decreaseKey, $O(\log N)$ extractMin. | | Pairing Heap | PairingHeap<T> | Fast self-adjusting heap widely used in C++ STL and functional compilers for optimal real-world speed. | | Min-Max Heap | MinMaxHeap<T> | Double-ended heap supporting simultaneous $O(1)$ min AND $O(1)$ max access. | | Binary Min/Max Heap | PriorityQueue<T> | Binary heap with custom comparator support. |


5. Probabilistic & Big-Data Structures

  • CuckooFilter: Modern improvement over Bloom filters supporting safe deletion.
  • BloomFilter: Space-efficient probabilistic set membership with zero false negatives.
  • HyperLogLog: Cardinality estimator counting millions of distinct items in kilobytes (PFADD/PFCOUNT).
  • CountMinSketch: Sub-linear frequency estimator for massive streaming data.
  • BitSet: 32-bit word bitfield array (8x less memory than boolean arrays).
  • CircularBuffer<T>: Fixed circular buffer with auto oldest-element eviction.

6. High-Performance Automata

  • AhoCorasick: Multi-pattern dictionary search in single text pass via failure-link trie.
  • SuffixAutomaton: Directed Acyclic Word Graph (DAWG) encoding all substrings in linear $O(N)$ states.

7. Caching Systems


8. Distributed Backend & Cloud Systems


⚡ Complete Algorithm Catalog

  • Pathfinding & Flows: aStar2D (A* Search), tarjanSCC (Strongly Connected Components), edmondsKarp (Max flow), hopcroftKarp (Bipartite matching).
  • Sorting: bubbleSort, insertionSort, selectionSort, mergeSort (stable), quickSort (randomized pivot).
  • Searching: linearSearch, binarySearch, lowerBound, upperBound, quickSelect ($O(N)$ $k$-th element).
  • Dynamic Programming: knapsack01, longestIncreasingSubsequence ($O(N \log N)$), maxSubarraySum (Kadane), coinChange.
  • String Processing: kmpSearch ($O(N+M)$), longestCommonSubsequence (LCS), levenshteinDistance.
  • Graph & Networks: bfs, dfs, dijkstra, topologicalSort, kruskalMST, bellmanFord, floydWarshall.
  • Number Theory & Math: gcd, lcm, sieveOfEratosthenes, modularExponentiation, fft (Radix-2 FFT/IFFT).
  • Geometry: convexHull (Andrew's Monotone Chain), isPointInPolygon (Ray Casting), euclideanDistance.
  • Backtracking: permutations (Heap's algorithm), combinations, solveNQueens, solveSudoku.

Installation & Commands

npm install algoman
npm run test       # Run 85 Vitest unit test suites
npm run typecheck  # Strict TypeScript verification
npm run build      # Dual ESM/CJS build with typings

License

MIT