├── .github └── workflows │ └── webpack.yml ├── .gitignore ├── CONTRIBUTING.md ├── LICENSE ├── README.md ├── package-lock.json ├── package.json ├── public ├── duckduckgo.svg ├── facebook.svg ├── favicon.ico └── google.svg ├── src ├── App.js ├── SiteFilters.js ├── TagsEditor.js ├── index.css ├── index.html └── index.js └── webpack.config.js /.github/workflows/webpack.yml: -------------------------------------------------------------------------------- 1 | name: NodeJS with Webpack 2 | 3 | on: 4 | push: 5 | branches: [ "main" ] 6 | pull_request: 7 | branches: [ "main" ] 8 | 9 | jobs: 10 | build: 11 | runs-on: ubuntu-latest 12 | 13 | strategy: 14 | matrix: 15 | node-version: [18.x] 16 | 17 | steps: 18 | - uses: actions/checkout@v3 19 | 20 | - name: Use Node.js ${{ matrix.node-version }} 21 | uses: actions/setup-node@v3 22 | with: 23 | node-version: ${{ matrix.node-version }} 24 | 25 | - name: Build 26 | run: | 27 | npm install 28 | npx webpack 29 | 30 | - name: Deploy 🚀 31 | uses: JamesIves/github-pages-deploy-action@v4 32 | with: 33 | folder: dist 34 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules/ 3 | dist/ 4 | -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | ## Want to report an issue or request a feature? 2 | 3 | This project consists of two separate codebases, one for the frontend search interface, and another for the generation of suggested name variants. 4 | 5 | Is there a problem with the user interface, such as button not working or a visual bug, 6 | please open an issue here: 7 | 8 | https://github.com/bellingcat/name-variant-search/issues 9 | 10 | Is there a name variant that you expect to see but is not included in the results? 11 | File your issue here: 12 | 13 | https://github.com/bellingcat/alias-generator/issues 14 | 15 | ### Tips for writing an effective issue: 16 | 17 | * Remember to search the list of open issues first, to avoid duplicates. If you see your issue has already been reported by someone else, feel free to add a comment or simply a "👍" reaction to the bottom of their report. 18 | 19 | * Keep the title short but descriptive like an email subject line, such as "Ukrainian spelling variations" 20 | 21 | * Write a detailed description, including specific examples and relevant screenshots. You can also reference other related issues by number to link to them, e.g., [#3](https://github.com/bellingcat/name-variant-search/issues/8). 22 | 23 | * Be excellent to each other. Software issues can be frustrating. Remember to comment with kindness. 24 | 25 | ## Are you a coder? 26 | 27 | Pull requests to address any open issues are welcome! Please leave a comment on any issue you'd like to work on. 28 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2021 Stichting Bellingcat 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Name Variant Search Tool 2 | 3 | https://bellingcat.github.io/name-variant-search/ 4 | 5 | ### Motivation 6 | 7 | When researching an individual online, it is useful to search not only for their full legal name but also for many variants. This can become tedious and time consuming for the researcher and could be streamlined. 8 | 9 | ### Goal 10 | 11 | Given a person's name, generate various plausible alternative forms of the name and streamline the work of researching each one. 12 | 13 | ## Generating variants 14 | 15 | Generating variants is handled by the node module [alias-generator](https://github.com/bellingcat/alias-generator) 16 | 17 | TextGain's language ID api may be useful when deciding which culturally-specific variants to include: https://apiv2.textgain.com/redoc#tag/Identification/operation/language_identification_language_post 18 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "name-variant-search", 3 | "version": "1.0.0", 4 | "description": "A tool for researching a person's name online in multiple formats", 5 | "scripts": { 6 | "dev": "webpack serve --no-client-overlay-warnings ", 7 | "build": "webpack" 8 | }, 9 | "repository": { 10 | "type": "git", 11 | "url": "https://github.com/bellingcat/name-variant-search.git" 12 | }, 13 | "author": "Stichting Bellingcat", 14 | "license": "MIT", 15 | "bugs": { 16 | "url": "https://github.com/bellingcat/name-variant-search/issues" 17 | }, 18 | "homepage": "https://github.com/bellingcat/name-variant-search#readme", 19 | "devDependencies": { 20 | "@babel/core": "^7.22.9", 21 | "@babel/plugin-syntax-import-assertions": "^7.22.5", 22 | "@babel/preset-env": "^7.22.9", 23 | "@babel/preset-react": "^7.22.5", 24 | "babel-loader": "^9.1.3", 25 | "css-loader": "^6.8.1", 26 | "html-loader": "^4.2.0", 27 | "html-webpack-plugin": "^5.5.3", 28 | "style-loader": "^3.3.3", 29 | "webpack": "^5.88.2", 30 | "webpack-cli": "^5.1.4", 31 | "webpack-dev-server": "^4.15.1" 32 | }, 33 | "dependencies": { 34 | "@bellingcat/alias-generator": "^4.0.0", 35 | "@fortawesome/free-solid-svg-icons": "^6.4.2", 36 | "@fortawesome/react-fontawesome": "^0.2.0", 37 | "react": "^18.2.0", 38 | "react-dom": "^18.2.0", 39 | "react-hot-toast": "^2.4.1", 40 | "react-tag-input-component": "^2.0.2" 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /public/duckduckgo.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /public/facebook.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 18 | -------------------------------------------------------------------------------- /public/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bellingcat/name-variant-search/c172abfe093e8ba4283bcc6b05a9ea03da4f1f12/public/favicon.ico -------------------------------------------------------------------------------- /public/google.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /src/App.js: -------------------------------------------------------------------------------- 1 | import React, { useState } from 'react'; 2 | import TagsEditor from './TagsEditor'; 3 | import SiteFilters from './SiteFilters'; 4 | 5 | function constructGoogleQuery(names, sites) { 6 | const nameQuery = names.map((name) => `\"${name}\"`).join(" OR "); 7 | 8 | if (sites.length) { 9 | const siteFilter = sites.map((site) => `site:${site}`).join(" OR "); 10 | return `${nameQuery} (${siteFilter})`; 11 | } else { 12 | return nameQuery; 13 | } 14 | } 15 | 16 | const App = () => { 17 | const [names, setNames] = useState([]); 18 | const [sites, setSites] = useState([]); 19 | 20 | const searchInput = document.querySelector('input.gsc-input'); 21 | if (searchInput) { 22 | searchInput.value = constructGoogleQuery(names, sites); 23 | const searchButton = document.querySelector('button.gsc-search-button'); 24 | searchButton.click(); 25 | } 26 | 27 | const searchResults = document.querySelector('#searchResults'); 28 | if (searchResults) { 29 | if (names.length > 0) { 30 | searchResults.className = ''; 31 | } else { 32 | searchResults.className = 'hide'; 33 | } 34 | } 35 | 36 | return ( 37 | <> 38 |
Filter by website:
38 |Search for exact matches on any of these names:
90 |