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 🙏

© 2024 – Pkg Stats / Ryan Hefner

uuid-readable

v0.0.2

Published

Easy to Remember, Readable UUIDs, that are Shakespearean gramatically correct sentences 🥳

Downloads

3,295

Readme

uuid-readable

Generic badge Generic badge

Generate Easy to Remember, Readable UUIDs, that are Shakespearean and Grammatically Correct Sentences 🥳

Logo

  • Built on UUID v4
  • Optionally pass your UUID to generate a unique sentence
  • 128 Bit Crypto Secure
  • Grammatically correct sentences
  • Easy to remember
  • Has a Shakespeare feeling
  • Universally Unique Identifier
  • Generate Low Entropy 32 Bit Tokens

Example

128 Bit UUID Readable

Loren Chariot Addy the Titbit of Cholame questioned Cele Garth Alda and 16 windy frogs

Drucill Hubert Lewse the Comer of Avera rejoices Fiann Craggy Florie and 5 hard trouts

Jacquette Brandt John the Pectus of Barnsdall doubted Glenn Gay Gregg and 12 noisy stoats

Low Entropy 32 Bit

11 pretty dragonflies regularly sang 2 fat toads happily buzzed

Note

Think of it this way, it's impossible to remember 32 random characters in UUID, but these sentences even though hard can be remembered, and are definitely fun!

Alternatively, generate 32 bit readable small sentences from 128 bit UUID and check later if they match.

API

Thanks to uuid.rocks, we have an API Endpoint

curl https://uuid.rocks/plain?readable
# Joyce Ange Barrett the Orient of Alco killed Marlyn Hewett Lady and 11 strong bulls

Installation

npm install uuid-readable --save

Usage

const id = require('uuid-readable')

console.log( id.generate() )
// Cathleen d Dieball the Monolith of Alderson reflects Arly Arnie Keenan and 18 large ants

Pass your own UUID

console.log( id.generate(uuid) )

Inverse, get UUID back from Readable UUID

const uuid = '1b9d6bcd-bbfd-4b2d-9b5d-ab8dfbbd4bed'
const readable = id.generate(uuid)
const inverse = id.inverse(readable)
 
inverse === uuid // true

Low Entropy 32bit Readable (Use as Readable Hash)

const short = id.short(uuid)
// 5 fat toads happily buzzed

// Check Later
id.check(short, uuid) //true

MongoDB

const id = require('uuid-readable')

readable_id: {
  'type': String,
  'default': id
}

// or use as real id

_id: {
  'type': String,
  'default': id
}

How does it work?

UUID is converted to 128 bits.

  • 12 bits for first name
  • 11 bits for middle name
  • 14 bits for last name
  • 13 bits for a personal pronoun
  • 13 bits for name of place
  • 10 bits for verb
  • 12 bits for first name
  • 11 bits for middle name
  • 14 bits for last name
  • 5 bits for number of animals
  • 6 bits for animal adjective
  • 7 bits for animal

For example, 7 bits for animal means we choose one animal from a list of atleast 2**7 = 128 animals

Alternatively, the inverse funcation proves that UUID and Readable UUID form a bijection, hence no loss of entropy.

Use Cases

  • Customer Support

You can remember parts of the id and that's enough to search it up and communicate throughout a large team. I will be using it as a secret generation for a service, and customer tickets.

Sponsors

Shakespeare Geek