Use when researching algorithms, data structures, optimization, performance, or need modern alternatives to classic algorithms
Use OTP built-ins first. Escalate to specialized structures only when profiling shows a bottleneck. For most Elixir applications, Map, MapSet, List, and the OTP modules cover 95% of needs.
What are you solving?
Data storage/lookup → See ets-and-persistent-term.md, otp-builtins.md
Concurrent shared state → See concurrent-data-structures.md, ets-and-persistent-term.md
Graph/dependency problem → See graph-algorithms.md
Text search/matching → See string-and-text.md
Location/spatial → See spatial.md
Time ranges/scheduling → See interval-and-range.md
Streaming metrics → See streaming-algorithms.md
Large-scale counting/sets → See probabilistic.md
Hashing → See hash-functions.md
Compression → See compression.md
Sorting large datasets → See sorting-and-search.md
Optimization/constraints → See optimization.md
Statistics/analytics → See statistics.md
read_concurrency: true:persistent_term for config read on every requestqueue ++ [item] is O(n); use :queue for O(1):atomics or :counters insteadRead the file that matches your current problem:
ets-and-persistent-term.md — When: Need concurrent shared state or config cache. ETS table types, concurrency options, cache/rate-limiter patterns, :persistent_term for configotp-builtins.md — When: Looking for queue, tree, set, or counter primitives. :queue, :gb_trees, :gb_sets, :atomics, :counters, :array, Okasaki structuresgraph-algorithms.md — When: Working with dependencies, networks, or paths. :digraph/:digraph_utils patterns: topological sort, shortest path, cycle detection, dependency resolutionstring-and-text.md — When: Building search, fuzzy matching, or autocomplete. Fuzzy matching (Levenshtein, Jaro-Winkler), full-text search (tsvector, pg_trgm), autocompleteconcurrent-data-structures.md — When: Need lock-free or high-concurrency patterns. CAS with :atomics, lock-free patterns, ETS concurrency, :counters write_concurrencyspatial.md — When: Working with geographic data or proximity queries. PostGIS (ST_DWithin, ST_Contains), geohashing, Haversine distanceinterval-and-range.md — When: Handling time ranges, scheduling, or overlap detection. Postgres range types, overlap detection, exclusion constraints, schedulingstreaming-algorithms.md — When: Computing metrics over unbounded data streams. Sliding windows, EMA, reservoir sampling, streaming percentilesoptimization.md — When: Solving constraint, scheduling, or resource allocation problems. Dynamic programming, greedy, constraint satisfaction, gradient descent (Nx), simulated annealing, linear programming, when to push to Postgresstatistics.md — When: Need analytics, anomaly detection, or A/B testing. Descriptive stats (Postgres and Elixir), anomaly detection (Z-score, IQR), A/B testing, Explorer DataFrames, histograms, correlationcompression.md — When: Need to compress data for storage or transfer. :zlib, Zstd, LZ4, :erlang.term_to_binary compressed optionprobabilistic.md — When: Counting or membership testing at massive scale. HyperLogLog, Cuckoo filters, Count-Min Sketch, Bloom filtershash-functions.md — When: Choosing hash function for non-crypto use. xxHash3, BLAKE3, HighwayHash selection guidesorting-and-search.md — When: Sorting large datasets or building indexes. Cache-efficient sorting, BlockQuicksort, pdqsort, B+ trees/algorithm-research — Deep research with academic paper citations/benchmark — Create Benchee benchmarks to compare data structure alternativesUse the algorithms-researcher agent for deep research with paper citations.