X (Twitter) algorithm rules & viral strategies for AI agents. Boost engagement, avoid reach death. Works with Cursor, Claude, ChatGPT, Copilot. Vibe-coding ready.
JWA implementation (supports all JWS algorithms)
Implementation of JSON Web Signatures
Fastest random ID and random string generation for Node.js
A point in polygon based on the paper Optimal Reliable Point-in-Polygon Test and Differential Coding Boolean Operations on Polygons
Implements the WebIDL algorithms for converting to and from JavaScript values
Find the longest common subsequence.
node's assert.deepEqual algorithm except for NaN being equal to NaN
A JS library for finding optimal label position inside a polygon
Martinez polygon clipping algorithm, does boolean operation on polygons (multipolygons, polygons with holes etc): intersection, union, difference, xor
Find the first config file matching a given name in the current directory or the nearest ancestor directory.
Fast 2D concave hull algorithm in JavaScript (generates an outline of a point set)
Missing ECMAScript module utils for Node.js
High-performance Base64 encoder and decoder
Javascript FNV-1a Hashing Algorithm up to 1024 bits, with highly optimized 32bit and 52bit implementations.
Encryption, decryption, and key related utility functions
A packing algorithm for 2D bin packing. Largely based on code and a blog post by Jake Gordon.
Implementation of the Graham Scan algorithm to calculate a convex hull from a given array of x, y coordinates.
Call require pretending your are at another directory
Write viral X posts using deep knowledge of the actual recommendation algorithm
ECMAScript (ESTree) AST walker
Fastify compression utils
Detect the indentation of code
Simple “Least Recently Used” (LRU) cache
An unofficial Rust port of Sensirion's gas-index-algorithm
Clustering algorithms (ABS, DBSCAN, Graph, Grid) with spatial indexing
They are some performance critical pieces of code that will be executed on huge data sets, which we want to make sure will run fast enough. Unfortunately, enforcing this is not easy, often requiring large scale and slow benchmarks. This rspec library (the result of an experiment to learn machine learning) uses linear regression to determine the time complexity (Big O notation, O(x)) of a piece of code and to check that it is at least as good as what we expect. This does not require huge data sets (only a few large ones) and can be written as any unit test (not as fast though).
This is a Ruby implementation of the k-means++ algorithm for data clustering. In other words: Grouping a bunch of X, Y points into K groups.
Deterministic pseudorandom integer generator, uses the basic 4*x*(1-x) chaos algorithm
== DESCRIPTION: Charlie is a library for genetic algorithms (GA) and genetic programming (GP). == FEATURES: - Quickly develop GAs by combining several parts (genotype, selection, crossover, mutation) provided by the library. - Sensible defaults are provided with any genotype, so often you only need to define a fitness function. - Easily replace any of the parts by your own code. - Test different strategies in GA, and generate reports comparing them. Example report: http://charlie.rubyforge.org/example_report.html == INSTALL: * sudo gem install charlie == EXAMPLES: This example solves a TSP problem (also quiz #142): N=5 CITIES = (0...N).map{|i| (0...N).map{|j| [i,j] } }.inject{|a,b|a+b} class TSP < PermutationGenotype(CITIES.size) def fitness d=0 (genes + [genes[0]]).each_cons(2){|a,b| a,b=CITIES[a],CITIES[b] d += Math.sqrt( (a[0]-b[0])**2 + (a[1]-b[1])**2 ) } -d # lower distance -> higher fitness. end use EdgeRecombinationCrossover, InversionMutator end Population.new(TSP,20).evolve_on_console(50) This example finds a polynomial which approximates cos(x) class Cos < TreeGenotype([proc{3*rand-1.5},:x], [:-@], [:+,:*,:-]) def fitness -[0,0.33,0.66,1].map{|x| (eval_genes(:x=>x) - Math.cos(x)).abs }.max end use TournamentSelection(4) end Population.new(Cos).evolve_on_console(500)
Post-quantum cryptography SaaS API supporting ML-KEM (Kyber) and ML-DSA (Dilithium) algorithms. Provides keypair management and cryptographic operations (encrypt, decrypt, sign, verify). ## Authentication - **JWT Bearer Token** — user-based auth, obtained from `/auth/login` or `/auth/register` - **API Key (header)** — programmatic access via `X-API-Key` header - **API Key (query)** — programmatic access via `?api_key=` query parameter ## Quick Start 1. Register → `POST /auth/register` 2. Login → `POST /auth/login` → copy `data.token` 3. Generate keypair → `POST /generate-keypair` 4. Encrypt / Sign with the keypair ID
No description provided.
No description provided.
No description provided.
No description provided.
No description provided.
No description provided.
No description provided.
No description provided.
No description provided.
No description provided.
No description provided.
No description provided.