{"id":24998022,"url":"https://github.com/riennevaplus/human-id","last_synced_at":"2025-05-15T00:10:33.686Z","repository":{"id":32474195,"uuid":"134918163","full_name":"RienNeVaPlus/human-id","owner":"RienNeVaPlus","description":"💃🆔 Generates human readable identifier strings by chaning common (short) words of the english language.","archived":false,"fork":false,"pushed_at":"2025-02-03T14:39:19.000Z","size":42,"stargazers_count":202,"open_issues_count":1,"forks_count":20,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-02T09:44:37.135Z","etag":null,"topics":["human-id","human-readable-id","readable-identifier","word-generator"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/RienNeVaPlus.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-05-26T01:03:11.000Z","updated_at":"2025-03-17T07:54:25.000Z","dependencies_parsed_at":"2024-11-02T06:31:01.358Z","dependency_job_id":null,"html_url":"https://github.com/RienNeVaPlus/human-id","commit_stats":{"total_commits":29,"total_committers":6,"mean_commits":4.833333333333333,"dds":0.5862068965517242,"last_synced_commit":"8ca6397be3d3ec7eb136fb05114dd29bfbff2bbd"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RienNeVaPlus%2Fhuman-id","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RienNeVaPlus%2Fhuman-id/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RienNeVaPlus%2Fhuman-id/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RienNeVaPlus%2Fhuman-id/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/RienNeVaPlus","download_url":"https://codeload.github.com/RienNeVaPlus/human-id/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248027406,"owners_count":21035594,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["human-id","human-readable-id","readable-identifier","word-generator"],"created_at":"2025-02-04T17:38:21.008Z","updated_at":"2025-04-09T11:04:31.212Z","avatar_url":"https://github.com/RienNeVaPlus.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch3 align=\"center\"\u003e💃🆔\u003c/h3\u003e\n\n## Human-Readable Identifiers\n\n[![Downloads](https://img.shields.io/npm/dm/human-id)](https://www.npmjs.com/human-id)\n[![License](https://img.shields.io/npm/l/human-id)](https://github.com/RienNeVaPlus/human-id/blob/master/LICENSE)\n\n\u003e Using words to identify datasets (instead of numbers) provides various advantages when humans are involved, ie increased distinction and rememberability.\n\nHuman-ID generates readable strings by chaining common short words of the english language in a semi-meaningful way.\nThe result is concatenated of `adjective + noun + verb` resulting in a [minimum](#extended-pool-size) pool size of **15 000 000** possible combinations.\n\n- **SFW**: no bad words; family friendly results\n- No dependencies\n\n## Examples\n\n- FortyGhostsTalk\n- CalmSnailsDream\n- TastyRocksSparkle\n- HealthyCowsSmile\n- AfraidWallsExist\n- StrangeCarsRush\n- TwoLizardsSing\n- HappyLionsJump\n\n## Install\n\nYarn\n```\nyarn add human-id\n```\n\nNPM\n```\nnpm install human-id\n```\n\n## Usage\n\n### Command line\n\n```sh\nnpx human-id\n# RareGeckosJam\n\nnpx human-id lowercase + 2x\n# rare+geckos+jam\n# healthy+cows+smile\n```\n\n### Programmatic\n\n```js\nimport {humanId, poolSize, minLength, maxLength} from 'human-id'\n\n// RareGeckosJam\nhumanId()\n\n// Rare~Geckos~Jam\n// alias for { separator: '~' }\nhumanId('~')\n\n// rare-geckos-jam\nhumanId({\n  separator: '-',\n  capitalize: false,\n})\n\npoolSize()  // 15,000,000\nminLength() //          8\nmaxLength() //         19\n```\n\n## Extended Pool Size\n\nFor most cases, the default pool size should be large enough. However, the options `adjectiveCount` and `addAdverb` can be utilized to increase the pool size for the price of the string length.\n\n```js\nconst options = {\n  adjectiveCount: 2,\n  addAdverb: true,\n  separator: '.'\n}\n\nhumanId(options)   // Ten.Wet.Files.Cheer.Lazily\npoolSize(options)  // 630,000,000\nminLength(options) //          20\nmaxLength(options) //          41\n```\n\n## Executable arguments\n\nUse the following arguments to modify the default options or print multiple results.\n\n| Argument                   | Effect                                            |\n| -------------------------- | ------------------------------------------------- |\n| `a`, `adverb`, `addAdverb` | Sets `option.addAdverb` to `true`                 |\n| `l`, `lower`, `lowercase`  | Sets `option.capitalize` to `false`               |\n| `space`                    | Sets `option.separator` to an empty space ` `     |\n| any number                 | Sets `option.adjectiveCount` to the given integer |\n| any single character       | Sets `option.separator` to the character          |\n| any number followed by `x` | Repeats the output `number` times                 | \n\n### Example\n\n```bash\nnpx human-id adverb lower 2 _ 3x\n# clever_shaggy_memes_sit_quietly\n# cuddly_spicy_boxes_wave_politely\n# sweet_fair_wombats_fetch_bravely\n```\n\n## API\n\n#### `humanId(options?: string | Option): string`\nGenerates a human ID. **Options** can be a `string` (separator), a `boolean` (capitalize) or an `Options` object of:\n- **separator** `string = ''` - Separates the words from each other\n- **capitalize** `boolean = true` - Whether to transform the first character of each word to upper case\n- **adjectiveCount** `number = 1` - How many adjectives to return\n- **addAdverb** `boolean = false` - Adds a fourth part to the id\n\n*This function is also available as the default export*\n\n#### `poolSize(options?: string | Option): number`\nReturns the number of possible combinations for a given set of options.\n\n#### `minLength(options?: Option): number`\nThe length of the shortest possible id for a given set of options.\n\n#### `maxLength(options?: Option): number`\nThe length of the longest possible id for a given set of options.\n\n#### `adjectives: string[]`\nList of possible values for the first part of the human id.\n\n#### `nouns: string[]`\nList of possible values for the second part of the human id.\n\n#### `verbs: string[]`\nList of possible values for the third part of the human id.\n\n#### `adverbs: string[]`\nList of possible values for the optional fourth part of the human id.\n\n\n\u003ch6 align=\"center\"\u003e💃🆔\u003c/h6\u003e\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Friennevaplus%2Fhuman-id","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Friennevaplus%2Fhuman-id","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Friennevaplus%2Fhuman-id/lists"}