├── rdf_graph_gen
├── __init__.py
├── datasets
│ ├── book_awards.csv
│ ├── movie_awards.csv
│ ├── movie_genre.csv
│ ├── job_title.csv
│ ├── book_genre.csv
│ ├── surnames.csv
│ └── male_first_name.csv
├── script.py
├── multiprocess_generate.py
├── rdf_graph_generator.py
├── shacl_mapping_generator.py
└── value_generators.py
├── .gitignore
├── requirements.txt
├── experiment_suite
├── results-single-simple.csv
├── results-three-simple.csv
├── results-single-complex.csv
├── results-three-complex.csv
├── shape-single-simple.ttl
├── shape-single-complex.ttl
├── measure.sh
├── shape-three-simple.ttl
└── shape-three-complex.ttl
├── setup.py
├── .github
└── workflows
│ └── build-and-release.yml
├── generated_examples
├── shape_examples
│ ├── random_shape.ttl
│ ├── example_product_shape.ttl
│ ├── movie_shape.ttl
│ ├── person_shape.ttl
│ ├── book_shape.ttl
│ ├── tv_series_shape.ttl
│ └── test_value_generation.ttl
└── generated_rdf
│ ├── generated_example_products.ttl
│ ├── generated_test_value_generation.ttl
│ ├── generated_random.ttl
│ ├── generated_movies.ttl
│ ├── generated_tvseries.ttl
│ └── generated_people.ttl
├── LICENSE
└── README.md
/rdf_graph_gen/__init__.py:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | old/
2 | documentation/
--------------------------------------------------------------------------------
/requirements.txt:
--------------------------------------------------------------------------------
1 | rdflib>=7.0.0
2 | python-dateutil>=2.8.2
3 | exrex>=0.11.0
4 | setuptools>=69.1.1
--------------------------------------------------------------------------------
/experiment_suite/results-single-simple.csv:
--------------------------------------------------------------------------------
1 | Size,Time
2 | 1,4
3 | 10,4
4 | 100,4
5 | 1000,5
6 | 10000,8
7 | 100000,10
8 | 1000000,35
9 | 10000000,287
10 | 100000000,2871
11 |
--------------------------------------------------------------------------------
/experiment_suite/results-three-simple.csv:
--------------------------------------------------------------------------------
1 | Size,Time
2 | 1,4
3 | 10,4
4 | 100,5
5 | 1000,5
6 | 10000,8
7 | 100000,16
8 | 1000000,102
9 | 10000000,1352
10 | 100000000,9888
11 |
--------------------------------------------------------------------------------
/experiment_suite/results-single-complex.csv:
--------------------------------------------------------------------------------
1 | Size,Time
2 | 1,4
3 | 10,4
4 | 100,4
5 | 1000,5
6 | 10000,8
7 | 100000,24
8 | 1000000,164
9 | 10000000,1608
10 | 100000000,17312
11 |
--------------------------------------------------------------------------------
/experiment_suite/results-three-complex.csv:
--------------------------------------------------------------------------------
1 | Size,Time
2 | 1,4
3 | 10,4
4 | 100,5
5 | 1000,5
6 | 10000,9
7 | 100000,30
8 | 1000000,244
9 | 10000000,2335
10 | 100000000,22734
11 |
--------------------------------------------------------------------------------
/experiment_suite/shape-single-simple.ttl:
--------------------------------------------------------------------------------
1 | @prefix schema: .
2 | @prefix sh: .
3 | @prefix xsd: .
4 | @prefix ex: .
5 |
6 | schema:ExampleShape
7 | a sh:NodeShape ;
8 | sh:property [
9 | sh:path ex:randomProperty ;
10 | sh:datatype xsd:string;
11 | sh:minLength 6;
12 | sh:maxLength 10;
13 | ] .
14 |
--------------------------------------------------------------------------------
/rdf_graph_gen/datasets/book_awards.csv:
--------------------------------------------------------------------------------
1 | Nobel Prize in Literature
2 | Pulitzer Prize
3 | Man Booker Prize
4 | National Book Award
5 | Caldecott Medal
6 | Newbery Medal
7 | Hugo Award
8 | Nebula Award
9 | National Book Critics Circle Award
10 | Costa Book Awards
11 | The Giller Prize
12 | The Women's Prize for Fiction
13 | The Edgar Allan Poe Awards
14 | The Agatha Awards
15 | The James Tait Black Memorial Prize
16 | The National Poetry Series
17 | The Bram Stoker Awards
18 | The Cervantes Prize
19 | The O. Henry Awards
--------------------------------------------------------------------------------
/setup.py:
--------------------------------------------------------------------------------
1 | from setuptools import setup, find_packages
2 |
3 | with open('requirements.txt') as f:
4 | requirements = f.read().splitlines()
5 |
6 | with open('README.md') as f:
7 | description = f.read()
8 |
9 | setup(
10 | name='rdf_graph_gen',
11 | version='1.2.0',
12 | description = 'Synthetic RDF graph generator based on SHACL shapes.',
13 | long_description = description,
14 | long_description_content_type = 'text/markdown',
15 | packages=find_packages(),
16 | package_data={'rdf_graph_gen': ['datasets/*.csv']},
17 | install_requires=requirements,
18 | entry_points={
19 | 'console_scripts': [
20 | 'rdfgen = rdf_graph_gen.script:main',
21 | ],
22 | },
23 | )
24 |
--------------------------------------------------------------------------------
/.github/workflows/build-and-release.yml:
--------------------------------------------------------------------------------
1 | name: Build and Release
2 |
3 | on:
4 | push:
5 | branches:
6 | - main
7 |
8 | jobs:
9 | build:
10 | runs-on: ubuntu-latest
11 |
12 | steps:
13 | - name: Checkout repository
14 | uses: actions/checkout@v2
15 |
16 | - name: Set up Python
17 | uses: actions/setup-python@v2
18 | with:
19 | python-version: 3.8
20 |
21 | - name: Install dependencies
22 | run: |
23 | python -m pip install --upgrade pip
24 | pip install setuptools wheel twine
25 |
26 | - name: Build and Publish
27 | run: |
28 | python setup.py sdist bdist_wheel
29 | twine upload dist/*
30 | env:
31 | TWINE_USERNAME: __token__
32 | TWINE_PASSWORD: ${{ secrets.PYPI_TOKEN }}
33 |
--------------------------------------------------------------------------------
/experiment_suite/shape-single-complex.ttl:
--------------------------------------------------------------------------------
1 | @prefix schema: .
2 | @prefix sh: .
3 | @prefix xsd: .
4 | @prefix ex: .
5 |
6 | schema:ExampleShape
7 | a sh:NodeShape ;
8 | sh:property [
9 | sh:path ex:randomProperty ;
10 | sh:datatype xsd:string;
11 | sh:minLength 10;
12 | sh:maxLength 10;
13 | ] ;
14 | sh:property [
15 | sh:path ex:anotherRandomProperty ;
16 | sh:minCount 3;
17 | sh:maxCount 6;
18 | ];
19 | sh:property [
20 | sh:path ex:date1 ;
21 | sh:lessThan ex:date2 ;
22 | ] ;
23 | sh:property [
24 | sh:path ex:date2 ;
25 | sh:minInclusive "2007-02-10"^^xsd:date ;
26 | sh:maxInclusive "2007-05-10"^^xsd:date ;
27 | ] .
28 |
--------------------------------------------------------------------------------
/generated_examples/shape_examples/random_shape.ttl:
--------------------------------------------------------------------------------
1 | @prefix schema: .
2 | @prefix sh: .
3 | @prefix xsd: .
4 | @prefix ex: .
5 |
6 | schema:ExampleShape
7 | a sh:NodeShape ;
8 | sh:property [
9 | sh:path ex:randomProperty ;
10 | sh:datatype xsd:string;
11 | sh:minLength 10;
12 | sh:maxLength 10;
13 | ] ;
14 | sh:property [
15 | sh:path ex:anotherRandomProperty ;
16 | sh:minCount 3;
17 | sh:maxCount 6;
18 | ];
19 | sh:property [
20 | sh:path ex:date1 ;
21 | sh:lessThan ex:date2 ;
22 | ] ;
23 | sh:property [
24 | sh:path ex:date2 ;
25 | sh:minInclusive "2007-02-10"^^xsd:date ;
26 | sh:maxInclusive "2007-05-10"^^xsd:date ;
27 | ] .
--------------------------------------------------------------------------------
/generated_examples/generated_rdf/generated_example_products.ttl:
--------------------------------------------------------------------------------
1 | @prefix ex: .
2 | @prefix schema: .
3 | @prefix sh: .
4 | @prefix xsd: .
5 |
6 | a ex:Product ;
7 | ex:identifier "I6sTsyxw",
8 | "nlctTaNsK5g",
9 | "pbuXXfsY",
10 | "rO3mdpRk" ;
11 | ex:dateOfProduction "1957-04-10"^^xsd:date ;
12 | ex:dateOfExpiration "2007-04-10"^^xsd:date ;
13 | ex:name "1bCJ3ZXgGK" ;
14 | sh:description schema:ExampleShape .
15 |
16 | a ex:Product ;
17 | ex:identifier "AArBAfHB",
18 | "Q1J4qXYuag",
19 | "YQJGquoIHx4" ;
20 | ex:dateOfProduction "1984-03-10"^^xsd:date ;
21 | ex:dateOfExpiration "2007-03-10"^^xsd:date ;
22 | ex:name "H2mklOGQDl" ;
23 | sh:description schema:ExampleShape .
24 |
--------------------------------------------------------------------------------
/generated_examples/shape_examples/example_product_shape.ttl:
--------------------------------------------------------------------------------
1 | @prefix schema: .
2 | @prefix sh: .
3 | @prefix xsd: .
4 | @prefix ex: .
5 |
6 | schema:ExampleShape
7 | a sh:NodeShape ;
8 | sh:targetClass ex:Product;
9 | sh:property [
10 | sh:path ex:name ;
11 | sh:datatype xsd:string;
12 | sh:minLength 10;
13 | sh:maxLength 10;
14 | ] ;
15 | sh:property [
16 | sh:path ex:identifier ;
17 | sh:minCount 3;
18 | sh:maxCount 6;
19 | ];
20 | sh:property [
21 | sh:path ex:dateOfProduction ;
22 | sh:lessThan ex:dateOfExpiration ;
23 | ] ;
24 | sh:property [
25 | sh:path ex:dateOfExpiration ;
26 | sh:minInclusive "2007-02-10"^^xsd:date ;
27 | sh:maxInclusive "2007-05-10"^^xsd:date ;
28 | ] .
29 |
--------------------------------------------------------------------------------
/experiment_suite/measure.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 | # This script is used to measure the performance of the RDFGraphGen application
3 | # It measures the time it takes for the RDFGraphGen to execute, under different configurations
4 | # and with different scale factors. The results are saved in a CSV file for later analysis.
5 | # Usage: ./measure.sh input-shacl-file.ttl scale-factor
6 |
7 | # create a CSV file to store the results
8 | echo "Size,Time" >> results.csv
9 |
10 | # start the timer in milliseconds
11 | start=$(date +%s)
12 | # run RDFGraphGen
13 | # usage: rdfgen [-h] [-b BATCH_SIZE] input_file output_file scale_factor
14 | rdfgen $1 generated-graph.ttl $2
15 | # end the timer
16 | end=$(date +%s)
17 | # calculate the elapsed time in milliseconds
18 | elapsed=$(( end - start ))
19 | # save the results in the CSV file
20 | echo "$2,$elapsed" >> results.csv
21 |
22 | echo "Done measuring performance. Results saved in results.csv"
23 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) 2024 Marija Vecovska, Milos Jovanovik
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 |
--------------------------------------------------------------------------------
/experiment_suite/shape-three-simple.ttl:
--------------------------------------------------------------------------------
1 | @prefix schema: .
2 | @prefix sh: .
3 | @prefix xsd: .
4 | @prefix ex: .
5 |
6 | ex:ExampleShape
7 | a sh:NodeShape ;
8 | sh:property [
9 | sh:path ex:randomProperty ;
10 | sh:datatype xsd:string;
11 | sh:minLength 2;
12 | sh:maxLength 8;
13 | ] ;
14 | sh:property [
15 | sh:path ex:firstConnectingProperty ;
16 | sh:node ex:AddressShape ;
17 | sh:minCount 1 ;
18 | sh:maxCount 1 ;
19 | ] ;
20 | sh:property [
21 | sh:path ex:secondConnectingProperty ;
22 | sh:node ex:PhoneShape ;
23 | sh:minCount 1 ;
24 | sh:maxCount 1 ;
25 | ] .
26 |
27 | ex:AddressShape
28 | a sh:NodeShape ;
29 | sh:property [
30 | sh:path ex:addressValue ;
31 | sh:datatype xsd:string ;
32 | sh:minLength 6 ;
33 | sh:maxLength 16 ;
34 | ] .
35 |
36 | ex:PhoneShape
37 | a sh:NodeShape ;
38 | sh:property [
39 | sh:path ex:phoneValue ;
40 | sh:datatype xsd:integer ;
41 | sh:minLength 6 ;
42 | sh:maxLength 12 ;
43 | ] .
44 |
45 |
--------------------------------------------------------------------------------
/rdf_graph_gen/script.py:
--------------------------------------------------------------------------------
1 | import argparse
2 | from rdf_graph_gen.multiprocess_generate import MultiprocessGenerator
3 |
4 |
5 | def main():
6 | parser = argparse.ArgumentParser(prog='RDFGraphGen',
7 | description="A tool for generating synthetic RDF graphs based on input SHACL shapes.",
8 | epilog='For more information, visit the GitHub repository: https://github.com/etnc/RDFGraphGen.')
9 | parser.add_argument("input_file", help="Path to the input file with SHACL shapes")
10 | parser.add_argument("output_file", help="Path to the output file where the generated RDF graph will be saved",
11 | default="output-graph.ttl")
12 | parser.add_argument("scale_factor", help="Controls the size of the generated RDF graph",
13 | default=1)
14 | parser.add_argument("-b", "--batch_size",
15 | help="After this number of entities if generated, they are appended to the file with the main generated RDF graph",
16 | default=1000)
17 |
18 | args = parser.parse_args()
19 |
20 | generator = MultiprocessGenerator(args.input_file, args.output_file, int(args.scale_factor), int(args.batch_size))
21 | generator.generate()
22 |
23 |
24 | if __name__ == "__main__":
25 | main()
--------------------------------------------------------------------------------
/generated_examples/generated_rdf/generated_test_value_generation.ttl:
--------------------------------------------------------------------------------
1 | @prefix ns1: .
2 | @prefix schemaorg: .
3 | @prefix sh: .
4 | @prefix xsd: .
5 |
6 | ns1:date1 "1994-02-10"^^xsd:date ;
7 | ns1:date2 "2007-02-10"^^xsd:date ;
8 | ns1:date3 "1976-02-10"^^xsd:date ;
9 | ns1:date4 "2007-02-01"^^xsd:date ;
10 | ns1:date5 "2007-01-20"^^xsd:date ;
11 | ns1:decimal1 -1.173161e+01 ;
12 | ns1:decimal2 2e+00 ;
13 | ns1:decimal3 3.308754e+00 ;
14 | ns1:integer1 -32 ;
15 | ns1:integer2 2 ;
16 | ns1:integer3 1 ;
17 | ns1:string1 "tnLJZmNqPT" ;
18 | ns1:string2 "tyjje" ;
19 | ns1:string3 "ucamdveorfa" ;
20 | sh:description schemaorg:PersonShape .
21 |
22 | ns1:date1 "2001-02-10"^^xsd:date ;
23 | ns1:date2 "2007-02-10"^^xsd:date ;
24 | ns1:date3 "1989-02-10"^^xsd:date ;
25 | ns1:date4 "2007-02-01"^^xsd:date ;
26 | ns1:date5 "2007-01-28"^^xsd:date ;
27 | ns1:decimal1 -1.99948e+01 ;
28 | ns1:decimal2 2e+00 ;
29 | ns1:decimal3 2.139781e+00 ;
30 | ns1:integer1 -46 ;
31 | ns1:integer2 2 ;
32 | ns1:integer3 1 ;
33 | ns1:string1 "A5Qq45DwxN" ;
34 | ns1:string2 "mtrzk" ;
35 | ns1:string3 "dgsnddmsmblnls" ;
36 | sh:description schemaorg:PersonShape .
37 |
38 |
--------------------------------------------------------------------------------
/experiment_suite/shape-three-complex.ttl:
--------------------------------------------------------------------------------
1 | @prefix schema: .
2 | @prefix sh: .
3 | @prefix xsd: .
4 | @prefix ex: .
5 |
6 | ex:ExampleShape
7 | a sh:NodeShape ;
8 | sh:property [
9 | sh:path ex:randomProperty ;
10 | sh:datatype xsd:string;
11 | sh:minLength 2;
12 | sh:maxLength 8;
13 | ] ;
14 | sh:property [
15 | sh:path ex:anotherRandomProperty ;
16 | sh:minCount 3 ;
17 | sh:maxCount 6 ;
18 | ] ;
19 | sh:property [
20 | sh:path ex:firstConnectingProperty ;
21 | sh:node ex:AddressShape ;
22 | sh:minCount 1 ;
23 | sh:maxCount 1 ;
24 | ] ;
25 | sh:property [
26 | sh:path ex:secondConnectingProperty ;
27 | sh:node ex:DateShape ;
28 | sh:minCount 1 ;
29 | sh:maxCount 1 ;
30 | ] .
31 |
32 | ex:AddressShape
33 | a sh:NodeShape ;
34 | sh:property [
35 | sh:path ex:addressValue ;
36 | sh:datatype xsd:string ;
37 | sh:minLength 6 ;
38 | sh:maxLength 16 ;
39 | sh:minCount 1 ;
40 | sh:maxCount 2 ;
41 | ] .
42 |
43 | ex:DateShape
44 | a sh:NodeShape ;
45 | sh:property [
46 | sh:path ex:date1 ;
47 | sh:lessThan ex:date2 ;
48 | ] ;
49 | sh:property [
50 | sh:path ex:date2 ;
51 | sh:minInclusive "2025-02-03"^^xsd:date ;
52 | sh:maxInclusive "2025-05-13"^^xsd:date ;
53 | ] .
54 |
--------------------------------------------------------------------------------
/generated_examples/shape_examples/movie_shape.ttl:
--------------------------------------------------------------------------------
1 | @prefix rdf: .
2 | @prefix rdfs: .
3 | @prefix schema: .
4 | @prefix sh: .
5 | @prefix xsd: .
6 |
7 | schema:MovieShape
8 | a sh:NodeShape ;
9 | sh:targetClass schema:Movie;
10 | sh:property [
11 | sh:path schema:director;
12 | sh:node schema:DirectorShape ;
13 | ] ;
14 | sh:property [
15 | sh:path schema:award ;
16 | ] ;
17 | sh:property [
18 | sh:path schema:name ;
19 | sh:datatype xsd:string ;
20 | sh:minCount 1 ;
21 | ] ;
22 | sh:property [
23 | sh:path schema:dateCreated ;
24 | sh:datatype xsd:date;
25 |
26 | ] ;
27 | sh:property [
28 | sh:path schema:datePublished ;
29 | ] ;
30 | sh:property [
31 | sh:path schema:genre ;
32 | sh:minCount 1 ;
33 | ] ;
34 | sh:property [
35 | sh:path schema:inLanguage ;
36 | sh:minCount 1 ;
37 | ] .
38 |
39 | schema:DirectorShape
40 | sh:targetClass schema:Person ;
41 | a sh:NodeShape ;
42 | sh:property [
43 | sh:path schema:givenName ;
44 | sh:datatype xsd:string ;
45 | sh:name "given name" ;
46 | ] ;
47 | sh:property [
48 | sh:path schema:gender ;
49 | sh:in ( "female" "male" ) ;
50 | ] ;
51 | sh:property [
52 | sh:path schema:email ;
53 | ] ;
54 | sh:property [
55 | sh:path schema:telephone ;
56 | ] .
--------------------------------------------------------------------------------
/rdf_graph_gen/datasets/movie_awards.csv:
--------------------------------------------------------------------------------
1 | Academy Awards
2 | Golden Globe Awards
3 | BAFTA Awards
4 | Screen Actors Guild Awards
5 | Cannes Film Festival
6 | Venice Film Festival
7 | Berlin International Film Festival
8 | Critics' Choice Movie Awards
9 | Independent Spirit Awards
10 | Directors Guild of America Awards
11 | Producers Guild of America Awards
12 | Writers Guild of America Awards
13 | Palm d'Or
14 | Palme d'Or
15 | Academy of Motion Picture Arts and Sciences
16 | MTV Movie & TV Awards
17 | Emmy Awards
18 | Tony Awards
19 | Grammy Awards
20 | African Movie Academy Awards
21 | Asia Pacific Screen Awards
22 | Saturn Awards
23 | National Film Awards (India)
24 | Festival de Cannes
25 | Sundance Film Festival
26 | Toronto International Film Festival
27 | American Film Institute Awards
28 | New York Film Critics Circle Awards
29 | Los Angeles Film Critics Association Awards
30 | Golden Raspberry Awards (Razzies)
31 | European Film Awards
32 | Gotham Awards
33 | Hugo Awards
34 | Annie Awards
35 | Cesar Awards
36 | Venice Film Festival
37 | Austin Film Festival
38 | American Cinema Editors (ACE) Eddie Awards
39 | Annapolis Film Festival
40 | BFI London Film Festival
41 | Tribeca Film Festival
42 | Sundance Film Festival
43 | Telluride Film Festival
44 | San Diego Film Critics Society Awards
45 | New York Film Critics Online Awards
46 | National Society of Film Critics Awards
47 | Chicago Film Critics Association Awards
48 | Los Angeles Online Film Critics Society Awards
49 | Hollywood Film Awards
50 | British Independent Film Awards
51 | Critics' Choice Documentary Awards
52 | Clio Awards
53 | Daytime Emmy Awards
54 | Primetime Emmy Awards
55 | Sports Emmy Awards
56 | Daytime Creative Arts Emmy Awards
57 | Primetime Creative Arts Emmy Awards
58 | News & Documentary Emmy Awards
59 | Primetime Engineering Emmy Awards
60 | International Emmy Awards
61 | National Academy of Television Arts and Sciences
62 | Television Academy
63 | The Grammy Museum
64 |
--------------------------------------------------------------------------------
/generated_examples/generated_rdf/generated_random.ttl:
--------------------------------------------------------------------------------
1 | @prefix ex: .
2 | @prefix schemaorg: .
3 | @prefix sh: .
4 | @prefix xsd: .
5 |
6 | ex:anotherRandomProperty "I6sTsyxw",
7 | "nlctTaNsK5g",
8 | "pbuXXfsY",
9 | "rO3mdpRk" ;
10 | ex:date1 "1957-04-10"^^xsd:date ;
11 | ex:date2 "2007-04-10"^^xsd:date ;
12 | ex:randomProperty "1bCJ3ZXgGK" ;
13 | sh:description schemaorg:ExampleShape .
14 |
15 | ex:anotherRandomProperty "AArBAfHB",
16 | "Q1J4qXYuag",
17 | "YQJGquoIHx4" ;
18 | ex:date1 "1984-03-10"^^xsd:date ;
19 | ex:date2 "2007-03-10"^^xsd:date ;
20 | ex:randomProperty "H2mklOGQDl" ;
21 | sh:description schemaorg:ExampleShape .
22 |
23 | ex:anotherRandomProperty "2se0cBKI83q0Nx",
24 | "6N5ODTa4E",
25 | "UZwbuosPQc",
26 | "XkU1QznGCLF" ;
27 | ex:date1 "1982-04-10"^^xsd:date ;
28 | ex:date2 "2007-04-10"^^xsd:date ;
29 | ex:randomProperty "oWjnuPuY6R" ;
30 | sh:description schemaorg:ExampleShape .
31 |
32 | ex:anotherRandomProperty "3Fc1bHlapqGAXr",
33 | "VuiIQW97xR6sP",
34 | "YRDymBxADq",
35 | "sNLoS6akBbiIGcg",
36 | "sjs10KnWINp",
37 | "t5PrApQU" ;
38 | ex:date1 "1999-03-10"^^xsd:date ;
39 | ex:date2 "2007-03-10"^^xsd:date ;
40 | ex:randomProperty "xPLmZ4JzDV" ;
41 | sh:description schemaorg:ExampleShape .
42 |
43 | ex:anotherRandomProperty "RFyEwkU5dH1",
44 | "Tkyga7Knfu",
45 | "aRxgO83fdic3z",
46 | "e0USaFcwY",
47 | "y14EWVdf" ;
48 | ex:date1 "1974-04-10"^^xsd:date ;
49 | ex:date2 "2007-04-10"^^xsd:date ;
50 | ex:randomProperty "6qxgPDqn42" ;
51 | sh:description schemaorg:ExampleShape .
52 |
53 |
--------------------------------------------------------------------------------
/generated_examples/shape_examples/person_shape.ttl:
--------------------------------------------------------------------------------
1 | @prefix rdf: .
2 | @prefix rdfs: .
3 | @prefix schema: .
4 | @prefix sh: .
5 | @prefix xsd: .
6 |
7 | schema:PersonShape
8 | a sh:NodeShape ;
9 | sh:targetClass schema:Person ;
10 | sh:xone (
11 | [
12 | sh:property [
13 | sh:path schema:givenName ;
14 | sh:datatype xsd:string ;
15 | sh:name "given name" ;
16 | ] ;
17 | sh:property [
18 | sh:path schema:familyName ;
19 | sh:datatype xsd:string ;
20 | sh:name "last name" ;
21 | ] ;
22 | ]
23 | [
24 | sh:path schema:name ;
25 | sh:datatype xsd:string ;
26 | sh:name "full name" ;
27 | ]
28 | );
29 | sh:property [
30 | sh:path schema:birthDate ;
31 | sh:lessThan schema:deathDate ;
32 | sh:minCount 1 ;
33 | sh:maxCount 1 ;
34 | ] ;
35 | sh:property [
36 | sh:path schema:gender ;
37 | sh:in ( "female" "male" ) ;
38 | ] ;
39 | sh:property [
40 | sh:path schema:email ;
41 | ] ;
42 | sh:property [
43 | sh:path schema:jobTitle ;
44 | ] ;
45 | sh:property [
46 | sh:path schema:telephone ;
47 | ] ;
48 | sh:property [
49 | sh:path schema:address ;
50 | sh:node schema:AddressShape ;
51 | ] .
52 |
53 | schema:AddressShape
54 | a sh:NodeShape ;
55 | sh:closed true ;
56 | sh:property [
57 | sh:path schema:streetAddress ;
58 | sh:datatype xsd:string ;
59 | ] ;
60 | sh:property [
61 | sh:path schema:postalCode ;
62 | sh:or ( [ sh:datatype xsd:string ] [ sh:datatype xsd:integer ] ) ;
63 | sh:minInclusive 10000 ;
64 | sh:maxInclusive 99999 ;
65 | ] .
--------------------------------------------------------------------------------
/rdf_graph_gen/multiprocess_generate.py:
--------------------------------------------------------------------------------
1 | import multiprocessing as mp
2 | from rdf_graph_gen.rdf_graph_generator import *
3 | from datetime import datetime
4 |
5 | class MultiprocessGenerator:
6 | def __init__(self, shape_file, output_file, graph_number, batch_size):
7 | self.shape_file = shape_file
8 | self.output_file = output_file
9 | self.graph_number = graph_number
10 | self.batch_size = batch_size
11 |
12 | self.shape = Graph()
13 | self.shape.parse(self.shape_file)
14 | self.dictionary = generate_dictionary_from_shapes_graph(self.shape)
15 |
16 | def worker(self, gueue, batchID, batch_size):
17 |
18 | graph = generate_rdf_graphs_from_dictionary(self.shape, self.dictionary, batch_size, batchID)
19 | graph = graph.serialize(format = 'ttl')
20 | gueue.put(graph)
21 | return graph
22 |
23 | def listener(self, gueue):
24 |
25 | with open(self.output_file, 'w') as file:
26 | while True:
27 | res = gueue.get()
28 | if res == 'finished generating':
29 | break
30 | file.write(res)
31 | file.flush()
32 |
33 | def generate(self):
34 |
35 | manager = mp.Manager()
36 | queue = manager.Queue()
37 | pool = mp.Pool(mp.cpu_count() + 2)
38 |
39 | watcher = pool.apply_async(self.listener, (queue,))
40 |
41 | start = datetime.now()
42 |
43 | jobs = []
44 | batch = 1
45 | while self.graph_number > 0:
46 |
47 | batch_size = min(self.graph_number, self.batch_size)
48 |
49 | job = pool.apply_async(self.worker, (queue, f'B{batch}', batch_size))
50 | jobs.append(job)
51 |
52 | self.graph_number -= self.batch_size
53 | batch += 1
54 |
55 | for job in jobs:
56 | job.get()
57 |
58 | queue.put('finished generating')
59 | pool.close()
60 | pool.join()
61 |
62 | time_delta = datetime.now() - start
63 |
64 | print(f'Generator ran on {mp.cpu_count()} CPUs, finished in {time_delta}.')
65 |
--------------------------------------------------------------------------------
/generated_examples/shape_examples/book_shape.ttl:
--------------------------------------------------------------------------------
1 | @prefix rdf: .
2 | @prefix rdfs: .
3 | @prefix schema: .
4 | @prefix sh: .
5 | @prefix xsd: .
6 |
7 | schema:BookShape
8 | a sh:NodeShape ;
9 | sh:targetClass schema:Book ;
10 | sh:property [
11 | sh:path schema:identifier ;
12 | sh:maxCount 1 ;
13 | sh:pattern '^[a-z]{4}[0-9]{4}$'
14 | ] ;
15 | sh:property [
16 | sh:path schema:name ;
17 | sh:datatype xsd:string ;
18 | ] ;
19 | sh:property [
20 | sh:path schema:bookEdition ;
21 | sh:maxCount 1 ;
22 | ] ;
23 | sh:property [
24 | sh:path schema:isbn ;
25 | sh:minCount 1 ;
26 | sh:maxCount 1 ;
27 | ] ;
28 | sh:property [
29 | sh:path schema:numberOfPages ;
30 | sh:minInclusive 100;
31 | ] ;
32 | sh:property [
33 | sh:path schema:author;
34 | sh:node schema:AuthorShape ;
35 | sh:minCount 1 ;
36 | sh:maxCount 3 ;
37 | ] ;
38 | sh:property [
39 | sh:path schema:dateCreated ;
40 | sh:datatype xsd:date;
41 | sh:lessThan schema:datePublished ;
42 | ] ;
43 | sh:property [
44 | sh:path schema:datePublished ;
45 | ] ;
46 | sh:property [
47 | sh:path schema:genre ;
48 | sh:minCount 2 ;
49 | sh:maxCount 4 ;
50 | sh:description "Each book has to have at least 3 genres, and a maximum of 8 genres(Test purpoes)" ;
51 | ] ;
52 | sh:property [
53 | sh:path schema:award ;
54 | ];
55 | sh:property [
56 | sh:path schema:inLanguage ;
57 | sh:in ("en-USA" "en-UK" )
58 | ] .
59 |
60 | schema:AuthorShape
61 | sh:targetClass schema:Person ;
62 | a sh:NodeShape ;
63 | sh:property [
64 | sh:path schema:givenName ;
65 | sh:datatype xsd:string ;
66 | sh:name "given name" ;
67 | ] ;
68 | sh:property [
69 | sh:path schema:birthDate ;
70 | sh:lessThan schema:deathDate ;
71 | sh:maxCount 1 ;
72 | ] ;
73 | sh:property [
74 | sh:path schema:gender ;
75 | sh:in ( "female" "male" ) ;
76 | ] ;
77 | sh:property [
78 | sh:path schema:email ;
79 | ] ;
80 | sh:property [
81 | sh:path schema:telephone ;
82 | ] .
--------------------------------------------------------------------------------
/generated_examples/shape_examples/tv_series_shape.ttl:
--------------------------------------------------------------------------------
1 | @prefix rdf: .
2 | @prefix rdfs: .
3 | @prefix schema: .
4 | @prefix sh: .
5 | @prefix xsd: .
6 |
7 | schema:TVSeriesShape
8 | a sh:NodeShape ;
9 | sh:targetClass schema:TVSeries;
10 | sh:property [
11 | sh:path schema:director;
12 | sh:node schema:DirectorShape ;
13 | ] ;
14 | sh:property [
15 | sh:path schema:actor;
16 | sh:node schema:ActorShape ;
17 | sh:minCount 3 ;
18 | ] ;
19 | sh:property [
20 | sh:path schema:season ;
21 | sh:datatype xsd:integer ;
22 | sh:equals schema:numberOfSeasons ;
23 | sh:minInclusive 0 ;
24 | ] ;
25 | sh:property [
26 | sh:path schema:numberOfEpisodes ;
27 | sh:minInclusive 0 ;
28 | ] ;
29 | sh:property [
30 | sh:path schema:numberOfSeasons ;
31 | sh:lessThan schema:numberOfEpisodes ;
32 | sh:minInclusive 0 ;
33 | ] ;
34 | sh:property [
35 | sh:path schema:titleEIDR ;
36 | sh:datatype xsd:string ;
37 | sh:pattern '[A-Z1-9.-/]{10,20}';
38 | ] ;
39 | sh:property [
40 | sh:path schema:name ;
41 | sh:datatype xsd:string ;
42 | ] ;
43 | sh:property [
44 | sh:path schema:startDate ;
45 | sh:datatype xsd:date;
46 | sh:lessThan schema:datePublished ;
47 | ] ;
48 | sh:property [
49 | sh:path schema:endDate ;
50 | sh:datatype xsd:date;
51 | ] ;
52 | sh:property [
53 | sh:path schema:datePublished ;
54 | sh:lessThanOrEquals schema:endDate ;
55 | ] ;
56 | sh:property [
57 | sh:path schema:genre ;
58 | ] .
59 |
60 | schema:DirectorShape
61 | sh:targetClass schema:Person ;
62 | a sh:NodeShape ;
63 | sh:property [
64 | sh:path schema:givenName ;
65 | sh:datatype xsd:string ;
66 | ] ;
67 | sh:property [
68 | sh:path schema:familyName ;
69 | sh:datatype xsd:string ;
70 | ] ;
71 | sh:property [
72 | sh:path schema:gender ;
73 | sh:in ( "female" "male" ) ;
74 | ] ;
75 | sh:property [
76 | sh:path schema:email ;
77 | ] ;
78 | sh:property [
79 | sh:path schema:telephone ;
80 | ] .
81 |
82 | schema:ActorShape
83 | sh:targetClass schema:Person ;
84 | a sh:NodeShape ;
85 | sh:property [
86 | sh:path schema:name ;
87 | sh:datatype xsd:string ;
88 | sh:name "given name" ;
89 | ] ;
90 | sh:property [
91 | sh:path schema:gender ;
92 | sh:in ( "female" "male" ) ;
93 | ] .
94 |
--------------------------------------------------------------------------------
/generated_examples/shape_examples/test_value_generation.ttl:
--------------------------------------------------------------------------------
1 | @prefix dash: .
2 | @prefix rdf: .
3 | @prefix rdfs: .
4 | @prefix schema: .
5 | @prefix sh: .
6 | @prefix xsd: .
7 | @prefix ex: .
8 |
9 | schema:PersonShape
10 | a sh:NodeShape ;
11 | sh:property [
12 | sh:path ex:date1 ;
13 | sh:lessThan ex:date2 ;
14 | ] ;
15 | sh:property [
16 | sh:path ex:date3 ;
17 | sh:lessThanOrEquals ex:date2 ;
18 | ] ;
19 | sh:property [
20 | sh:path ex:date2 ;
21 | sh:minInclusive "2007-02-10"^^xsd:date ;
22 | sh:maxInclusive "2007-02-10"^^xsd:date ;
23 | ] ;
24 | sh:property [
25 | sh:path ex:date4 ;
26 | sh:maxExclusive "2007-02-02"^^xsd:date ;
27 | sh:minInclusive "2007-02-01"^^xsd:date ;
28 | ] ;
29 | sh:property [
30 | sh:path ex:date5 ;
31 | sh:maxExclusive "2007-02-02"^^xsd:date ;
32 | sh:minExclusive "2007-01-01"^^xsd:date ;
33 | ] ;
34 | #test integer functionality
35 | sh:property [
36 | sh:path ex:integer1;
37 | sh:datatype xsd:integer;
38 | sh:lessThan ex:integer2 ;
39 | ] ;
40 | sh:property [
41 | sh:path ex:integer2 ;
42 | sh:datatype xsd:integer;
43 | sh:minInclusive 2 ;
44 | sh:maxInclusive 2 ;
45 | ] ;
46 | sh:property [
47 | sh:path ex:integer3 ;
48 | sh:datatype xsd:integer;
49 | sh:minExclusive 0 ;
50 | sh:maxInclusive 2 ;
51 | ] ;
52 | #test float functionality
53 | sh:property [
54 | sh:path ex:decimal1;
55 | sh:datatype xsd:decimal;
56 | sh:lessThan ex:decimal2 ;
57 | ] ;
58 | sh:property [
59 | sh:path ex:decimal2 ;
60 | sh:datatype xsd:decimal;
61 | sh:minInclusive 2 ;
62 | sh:maxInclusive 2 ;
63 | ] ;
64 | sh:property [
65 | sh:path ex:decimal3 ;
66 | sh:datatype xsd:decimal;
67 | sh:minExclusive 2 ;
68 | sh:maxInclusive 4 ;
69 | ] ;
70 | #test string functionality
71 | sh:property [
72 | sh:path ex:string1 ;
73 | sh:datatype xsd:string;
74 | sh:minLength 10;
75 | sh:maxLength 10;
76 | ] ;
77 | sh:property [
78 | sh:path ex:string2 ;
79 | sh:datatype xsd:string;
80 | sh:pattern '^([a-z])*' ;
81 | sh:minLength 4;
82 | sh:maxLength 5;
83 | ] ;
84 | sh:property [
85 | sh:path ex:string3 ;
86 | sh:datatype xsd:string;
87 | sh:pattern '^([a-z])*' ;
88 | ] .
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # RDFGraphGen: A Synthetic RDF Graph Generator based on SHACL Shapes
2 |
3 | This is a Python package which can be used to generate synthetic RDF knowledge graphs, based on SHACL shapes.
4 |
5 | The Shapes Constraint Language (SHACL) is a W3C standard which specifies ways to validate data in RDF graphs, by defining constraining shapes. However, even though the main purpose of SHACL is validation of existing RDF data, in order to solve the problem with the lack of available RDF datasets in multiple RDF-based application development processes, we envisioned and implemented a reverse role for SHACL: we use SHACL shape definitions as a starting point to generate synthetic data for an RDF graph.
6 |
7 | The generation process involves extracting the constraints from the SHACL shapes, converting the specified constraints into rules, and then generating artificial data for a predefined number of RDF entities, based on these rules. The purpose of RDFGraphGen is the generation of small, medium or large RDF knowledge graphs for the purpose of benchmarking, testing, quality control, training and other similar purposes for applications from the RDF, Linked Data and Semantic Web domain.
8 |
9 | ## Usage
10 |
11 | The following function can be used to generate RDF data:
12 |
13 | __generate_rdf(input-shape.ttl, output-graph.ttl, scale-factor)__
14 | - input-shape.ttl is a Turtle file that contains SHACL shapes
15 | - output-graph.ttl is a Turtle file that will store the generated RDF entities
16 | - scale-factor determines the size of the generated RDF graph
17 |
18 | ## Installation
19 |
20 | RDFGraphGen is available on PyPi: https://pypi.org/project/rdf-graph-gen/
21 |
22 | To install it, use:
23 |
24 | ```pip install rdf-graph-gen```
25 |
26 | After installation, this package can be used as a command line tool:
27 |
28 | ```rdfgen input-shape.ttl output-graph.ttl scale-factor```
29 |
30 | There are also some optional parameters. You can find out more by using the:
31 |
32 | ```rdfgen --help```
33 |
34 | ## Examples
35 |
36 | Examples of SHACL shapes based on Schema.org and other types, along with generated synthetic RDF graphs based on these shapes, can be found in the [generated examples](generated_examples/) directory in this repo.
37 |
38 | ## Publications
39 |
40 | * (preprint) Milos Jovanovik, Marija Vecovska, Maxime Jakubowski, Katja Hose. "[RDFGraphGen: An RDF Graph Generator based on SHACL Shapes](https://arxiv.org/abs/2407.17941)". arXiv:2407.17941.
41 |
42 | ## Remarks
43 |
44 | - A SHACL shape has to have a 'a sh:NodeShape' property and object in order to be recognized as a Node Shape.
45 | - ``sh:severity`` is ignored because it has no useful info.
46 | - Only predicate paths are supported at this time.
47 | - Most common ``sh:datatype`` scenarios are supported.
48 | - Currently ``sh:nodeKind`` is ignored.
49 |
--------------------------------------------------------------------------------
/rdf_graph_gen/datasets/movie_genre.csv:
--------------------------------------------------------------------------------
1 | Action
2 | Adventure
3 | Animation
4 | Biography
5 | Comedy
6 | Crime
7 | Documentary
8 | Drama
9 | Family
10 | Fantasy
11 | Film Noir
12 | History
13 | Horror
14 | Music
15 | Musical
16 | Mystery
17 | Romance
18 | Sci-Fi
19 | Sport
20 | Superhero
21 | Thriller
22 | War
23 | Western
24 | Fantasy Adventure
25 | Historical Drama
26 | Romantic Comedy
27 | Science Fiction
28 | Supernatural Horror
29 | Teen Drama
30 | Post-Apocalyptic
31 | Action Comedy
32 | Crime Thriller
33 | Biographical Documentary
34 | Animation Comedy
35 | Musical Drama
36 | Family Fantasy
37 | Sci-Fi Horror
38 | Mystery Crime
39 | War Drama
40 | Historical Biography
41 | Fantasy Romance
42 | Adventure Comedy
43 | Superhero Action
44 | Film Noir Thriller
45 | Musical Fantasy
46 | Sci-Fi Adventure
47 | Sports Biography
48 | Comedy Drama
49 | Horror Mystery
50 | Teen Romance
51 | Action Adventure Comedy
52 | Historical War Drama
53 | Romantic Fantasy Adventure
54 | Sci-Fi Thriller
55 | Crime Mystery Thriller
56 | Family Animation
57 | Western Adventure
58 | Musical Comedy
59 | Biographical Sports Drama
60 | Historical Romance
61 | Superhero Sci-Fi
62 | Fantasy Mystery
63 | Animated Musical
64 | Action Thriller
65 | War Romance Drama
66 | Sci-Fi Fantasy
67 | Crime Drama
68 | Biographical Crime
69 | Adventure Fantasy
70 | Mystery Horror Thriller
71 | Historical Musical
72 | Teen Comedy
73 | Action Sci-Fi
74 | Romantic Drama
75 | Sports Comedy
76 | War Action
77 | Comedy Mystery
78 | Documentary Biography
79 | Fantasy Adventure Drama
80 | Musical Romance
81 | Science Fiction Comedy
82 | Supernatural Thriller
83 | Film Noir Crime Drama
84 | Family Adventure
85 | Animation Fantasy
86 | Biographical Drama
87 | Teen Fantasy
88 | Romantic Comedy Drama
89 | Horror Sci-Fi
90 | Action Mystery
91 | War Biography
92 | Sports Romance
93 | Western Crime
94 | Historical Adventure
95 | Musical Biography
96 | Science Fiction Adventure
97 | Fantasy Action
98 | Superhero Fantasy Adventure
99 | Crime Comedy
100 | Animated Adventure
101 | War Drama Thriller
102 | Teen Romance Drama
103 | Action Horror
104 | Sci-Fi Mystery
105 | Romantic Mystery
106 | Biographical Musical
107 | Horror Fantasy
108 | Historical Fantasy Adventure
109 | Comedy Fantasy
110 | Sports Drama Romance
111 | War Fantasy
112 | Adventure Mystery
113 | Film Noir Thriller Drama
114 | Family Comedy
115 | Mystery Romance
116 | Western Adventure Action
117 | Teen Sci-Fi
118 | Sci-Fi Action Comedy
119 | Musical Fantasy Romance
120 | Supernatural Horror Mystery
121 | Action Crime Thriller
122 | Biographical Comedy Drama
123 | Fantasy Mystery Adventure
124 | Historical Comedy
125 | Romantic Musical
126 | Adventure Romance
127 | Superhero Action Adventure
128 | Animation Comedy Drama
129 | Sci-Fi Drama
130 | Documentary Biography Drama
131 |
--------------------------------------------------------------------------------
/rdf_graph_gen/datasets/job_title.csv:
--------------------------------------------------------------------------------
1 | accountant
2 | aerospace engineer
3 | aide
4 | air conditioning installer
5 | architect
6 | artist
7 | author
8 | baker
9 | bartender
10 | bus driver
11 | butcher
12 | career counselor
13 | carpenter
14 | carpet installer
15 | cashier
16 | ceo
17 | childcare worker
18 | civil engineer
19 | claims appraiser
20 | cleaner
21 | clergy
22 | clerk
23 | coach
24 | community manager
25 | compliance officer
26 | computer programmer
27 | computer support specialist
28 | computer systems analyst
29 | construction worker
30 | cook
31 | correctional officer
32 | courier
33 | credit counselor
34 | customer service representative
35 | data entry keyer
36 | dental assistant
37 | dental hygienist
38 | dentist
39 | designer
40 | detective
41 | director
42 | dishwasher
43 | dispatcher
44 | doctor
45 | drywall installer
46 | electrical engineer
47 | electrician
48 | engineer
49 | event planner
50 | executive assistant
51 | facilities manager
52 | farmer
53 | fast food worker
54 | file clerk
55 | financial advisor
56 | financial analyst
57 | financial manager
58 | firefighter
59 | fitness instructor
60 | graphic designer
61 | groundskeeper
62 | hairdresser
63 | head cook
64 | health technician
65 | host
66 | hostess
67 | industrial engineer
68 | insurance agent
69 | interior designer
70 | interviewer
71 | inventory clerk
72 | it specialist
73 | jailer
74 | janitor
75 | laboratory technician
76 | language pathologist
77 | lawyer
78 | librarian
79 | logistician
80 | machinery mechanic
81 | machinist
82 | maid
83 | manager
84 | manicurist
85 | market research analyst
86 | marketing manager
87 | massage therapist
88 | mechanic
89 | mechanical engineer
90 | medical records specialist
91 | mental health counselor
92 | metal worker
93 | mover
94 | musician
95 | network administrator
96 | nurse
97 | nursing assistant
98 | nutritionist
99 | occupational therapist
100 | office clerk
101 | office worker
102 | painter
103 | paralegal
104 | payroll clerk
105 | pharmacist
106 | pharmacy technician
107 | photographer
108 | physical therapist
109 | pilot
110 | plane mechanic
111 | plumber
112 | police officer
113 | postal worker
114 | printing press operator
115 | producer
116 | psychologist
117 | public relations specialist
118 | purchasing agent
119 | radiologic technician
120 | real estate broker
121 | receptionist
122 | repair worker
123 | roofer
124 | sales manager
125 | salesperson
126 | school bus driver
127 | scientist
128 | security guard
129 | sheet metal worker
130 | singer
131 | social assistant
132 | social worker
133 | software developer
134 | stocker
135 | stubborn
136 | supervisor
137 | taxi driver
138 | teacher
139 | teaching assistant
140 | teller
141 | therapist
142 | tractor operator
143 | truck driver
144 | tutor
145 | underwriter
146 | veterinarian
147 | waiter
148 | waitress
149 | welder
150 | wholesale buyer
151 | writer
152 |
--------------------------------------------------------------------------------
/rdf_graph_gen/datasets/book_genre.csv:
--------------------------------------------------------------------------------
1 | Science Fiction
2 | Fantasy
3 | Mystery
4 | Romance
5 | Historical Fiction
6 | Thriller
7 | Horror
8 | Non-Fiction
9 | Biography
10 | Self-Help
11 | Science
12 | Dystopian
13 | Young Adult
14 | Crime
15 | Adventure
16 | Poetry
17 | Graphic Novel
18 | Cookbook
19 | Travel
20 | Memoir
21 | Children's
22 | Satire
23 | Business
24 | Historical Non-Fiction
25 | Western
26 | Classic Literature
27 | Fairy Tale
28 | Magical Realism
29 | Paranormal
30 | Epic Fantasy
31 | Steampunk
32 | Cyberpunk
33 | Post-Apocalyptic
34 | Political Thriller
35 | Chick Lit
36 | Urban Fantasy
37 | Legal Thriller
38 | Psychological Thriller
39 | Military History
40 | True Crime
41 | Religious Texts
42 | Sociology
43 | Anthropology
44 | Psychology
45 | Art and Photography
46 | Crafts and Hobbies
47 | Science Fiction Fantasy
48 | Biographical Fiction
49 | Hard Science Fiction
50 | Soft Science Fiction
51 | Mythology
52 | Adventure Fiction
53 | Sports and Recreation
54 | Environment and Nature
55 | Parenting
56 | Health and Wellness
57 | Social Sciences
58 | True Adventure
59 | Short Stories
60 | Humor
61 | Detective Fiction
62 | Cyberpunk
63 | Space Opera
64 | Alternative History
65 | Time Travel
66 | Utopian and Dystopian Fiction
67 | Occult and Supernatural
68 | Medical Thriller
69 | Techno-Thriller
70 | Contemporary Fiction
71 | African American Literature
72 | Asian Literature
73 | Latin American Literature
74 | European Literature
75 | Middle Eastern Literature
76 | African Literature
77 | Psychological Fiction
78 | Legal Fiction
79 | Medical Fiction
80 | Domestic Fiction
81 | Family Saga
82 | Literary Fiction
83 | Experimental Fiction
84 | Fan Fiction
85 | Academic and Educational
86 | Economics
87 | Drama
88 | Magazine and Journal
89 | Cookbook
90 | Travel Guide
91 | Reference
92 | Religion and Spirituality
93 | Myth and Folklore
94 | Fable and Allegory
95 | Instructional and How-To
96 | Bildungsroman
97 | Inspirational Fiction
98 | Philosophical Fiction
99 | Travel Fiction
100 | Travelogue
101 | Historical Fantasy
102 | Alternate History Fantasy
103 | Weird Fiction
104 | Space Western
105 | Cosy Mystery
106 | Legal Drama
107 | Medical Drama
108 | Music Biography
109 | Film Biography
110 | Pop Culture
111 | Celebrity Biography
112 | Nature Writing
113 | Political Memoir
114 | Science Biography
115 | True Crime Memoir
116 | Historical Memoir
117 | Travel Memoir
118 | Cooking Memoir
119 | Religious Memoir
120 | Military Memoir
121 | Adventure Memoir
122 | Comedic Memoir
123 | Science Journalism
124 | Art History
125 | Culinary Arts
126 | DIY and Crafts
127 | Self-Improvement
128 | Motivational and Inspirational
129 | Spiritual and New Age
130 | Religious Texts
131 | Philosophy
132 | Psychology
133 | Sociology
134 | Political Science
135 | Economics
136 | History
137 | Biography and Autobiography
138 | True Crime
139 | Current Affairs
140 | Science and Nature
141 | Travel and Adventure
142 | Cooking and Food
143 | Health and Wellness
144 | Parenting and Family
145 | Education
146 | Business and Economics
147 | Self-Help and Personal Development
148 | Memoirs and Biographies
149 | Travel Writing
150 | Art and Photography
151 |
--------------------------------------------------------------------------------
/generated_examples/generated_rdf/generated_movies.ttl:
--------------------------------------------------------------------------------
1 | @prefix schema: .
2 | @prefix sh: .
3 | @prefix xsd: .
4 |
5 | a schema:Movie ;
6 | schema:award "Emmy Awards" ;
7 | schema:dateCreated "1977-07-07"^^xsd:date ;
8 | schema:datePublished "1972-07-07"^^xsd:date ;
9 | schema:director ;
10 | schema:genre "Crime Mystery Thriller" ;
11 | schema:inLanguage "KmkbQDYBOi" ;
12 | schema:name "The Ten Commandments" ;
13 | sh:description schema:MovieShape .
14 |
15 | a schema:Movie ;
16 | schema:award "Academy Awards" ;
17 | schema:dateCreated "1994-07-07"^^xsd:date ;
18 | schema:datePublished "1974-07-07"^^xsd:date ;
19 | schema:director ;
20 | schema:genre "Sci-Fi Action Comedy" ;
21 | schema:inLanguage "om1acng9GpL" ;
22 | schema:name "One True Thing" ;
23 | sh:description schema:MovieShape .
24 |
25 | a schema:Movie ;
26 | schema:award "Saturn Awards" ;
27 | schema:dateCreated "1971-07-07"^^xsd:date ;
28 | schema:datePublished "2014-07-07"^^xsd:date ;
29 | schema:director ;
30 | schema:genre "Musical Biography" ;
31 | schema:inLanguage "Bt5pDhTM9tLagO" ;
32 | schema:name "Mulberry Street" ;
33 | sh:description schema:MovieShape .
34 |
35 | a schema:Movie ;
36 | schema:award "Critics' Choice Movie Awards" ;
37 | schema:dateCreated "2001-07-07"^^xsd:date ;
38 | schema:datePublished "1978-07-07"^^xsd:date ;
39 | schema:director ;
40 | schema:genre "Documentary Biography Drama" ;
41 | schema:inLanguage "JSypjCS3yUikGQ" ;
42 | schema:name "Police Academy 3: Back in Training" ;
43 | sh:description schema:MovieShape .
44 |
45 | a schema:Movie ;
46 | schema:award "Chicago Film Critics Association Awards" ;
47 | schema:dateCreated "1995-07-07"^^xsd:date ;
48 | schema:datePublished "1980-07-07"^^xsd:date ;
49 | schema:director ;
50 | schema:genre "Horror Mystery" ;
51 | schema:inLanguage "1KY9olE00" ;
52 | schema:name "Ovosodo" ;
53 | sh:description schema:MovieShape .
54 |
55 | a schema:Movie ;
56 | schema:award "African Movie Academy Awards" ;
57 | schema:dateCreated "2000-07-07"^^xsd:date ;
58 | schema:datePublished "2003-07-07"^^xsd:date ;
59 | schema:director ;
60 | schema:genre "Fantasy Action" ;
61 | schema:inLanguage "xSNp4rJveCyp5" ;
62 | schema:name "Signed, Sealed, Delivered" ;
63 | sh:description schema:MovieShape .
64 |
65 | a schema:Movie ;
66 | schema:award "Academy of Motion Picture Arts and Sciences" ;
67 | schema:dateCreated "1971-07-07"^^xsd:date ;
68 | schema:datePublished "1983-07-07"^^xsd:date ;
69 | schema:director ;
70 | schema:genre "Sports Drama Romance" ;
71 | schema:inLanguage "yuqVKiNF" ;
72 | schema:name "Whistling in the Dark" ;
73 | sh:description schema:MovieShape .
74 |
75 | a schema:Movie ;
76 | schema:award "New York Film Critics Circle Awards" ;
77 | schema:dateCreated "1994-07-07"^^xsd:date ;
78 | schema:datePublished "2007-07-07"^^xsd:date ;
79 | schema:director ;
80 | schema:genre "Historical Biography" ;
81 | schema:inLanguage "tSUYRok2lO" ;
82 | schema:name "An Oversimplification of Her Beauty" ;
83 | sh:description schema:MovieShape .
84 |
85 | a schema:Movie ;
86 | schema:award "MTV Movie & TV Awards" ;
87 | schema:dateCreated "1975-07-07"^^xsd:date ;
88 | schema:datePublished "1991-07-07"^^xsd:date ;
89 | schema:director ;
90 | schema:genre "Romantic Comedy" ;
91 | schema:inLanguage "8jFcS25i124" ;
92 | schema:name "Donkey Punch" ;
93 | sh:description schema:MovieShape .
94 |
95 | a schema:Movie ;
96 | schema:award "Annie Awards" ;
97 | schema:dateCreated "2018-07-07"^^xsd:date ;
98 | schema:datePublished "1978-07-07"^^xsd:date ;
99 | schema:director ;
100 | schema:genre "Supernatural Horror Mystery" ;
101 | schema:inLanguage "l69SwUY3I5Vzybt" ;
102 | schema:name "Dragonball Evolution" ;
103 | sh:description schema:MovieShape .
104 |
105 | a schema:Person ;
106 | schema:email "sabine_537@gmail.com" ;
107 | schema:gender "female" ;
108 | schema:givenName "Sabine" ;
109 | schema:telephone "918379-503" ;
110 | sh:description schema:DirectorShape .
111 |
112 | a schema:Person ;
113 | schema:email "adeline_358@gmail.com" ;
114 | schema:gender "female" ;
115 | schema:givenName "Adeline" ;
116 | schema:telephone "527-096-369317" ;
117 | sh:description schema:DirectorShape .
118 |
119 | a schema:Person ;
120 | schema:email "douglis_825@gmail.com" ;
121 | schema:gender "male" ;
122 | schema:givenName "Douglis" ;
123 | schema:telephone "202-164-" ;
124 | sh:description schema:DirectorShape .
125 |
126 | a schema:Person ;
127 | schema:email "cleva_724@gmail.com" ;
128 | schema:gender "female" ;
129 | schema:givenName "Cleva" ;
130 | schema:telephone "990-892-01" ;
131 | sh:description schema:DirectorShape .
132 |
133 | a schema:Person ;
134 | schema:email "janette_680@gmail.com" ;
135 | schema:gender "female" ;
136 | schema:givenName "Janette" ;
137 | schema:telephone "617626-2" ;
138 | sh:description schema:DirectorShape .
139 |
140 | a schema:Person ;
141 | schema:email "mendel_486@gmail.com" ;
142 | schema:gender "male" ;
143 | schema:givenName "Mendel" ;
144 | schema:telephone "780-455-886456" ;
145 | sh:description schema:DirectorShape .
146 |
147 | a schema:Person ;
148 | schema:email "marion_507@gmail.com" ;
149 | schema:gender "female" ;
150 | schema:givenName "Marion" ;
151 | schema:telephone "238125-00351" ;
152 | sh:description schema:DirectorShape .
153 |
154 | a schema:Person ;
155 | schema:email "malina_813@gmail.com" ;
156 | schema:gender "female" ;
157 | schema:givenName "Malina" ;
158 | schema:telephone "004-531-95" ;
159 | sh:description schema:DirectorShape .
160 |
161 | a schema:Person ;
162 | schema:email "dominic_448@gmail.com" ;
163 | schema:gender "male" ;
164 | schema:givenName "Dominic" ;
165 | schema:telephone "101-111-0383097" ;
166 | sh:description schema:DirectorShape .
167 |
168 | a schema:Person ;
169 | schema:email "giles_884@gmail.com" ;
170 | schema:gender "male" ;
171 | schema:givenName "Giles" ;
172 | schema:telephone "108-906-3" ;
173 | sh:description schema:DirectorShape .
174 |
175 |
--------------------------------------------------------------------------------
/generated_examples/generated_rdf/generated_tvseries.ttl:
--------------------------------------------------------------------------------
1 | @prefix schema: .
2 | @prefix sh: .
3 | @prefix xsd: .
4 |
5 | a schema:TVSeries ;
6 | schema:actor ,
7 | ,
8 | ;
9 | schema:datePublished "1952-07-07"^^xsd:date ;
10 | schema:director ;
11 | schema:endDate "1971-07-07"^^xsd:date ;
12 | schema:genre "Sports Romance" ;
13 | schema:name "Top Boy" ;
14 | schema:numberOfEpisodes 37 ;
15 | schema:numberOfSeasons 21 ;
16 | schema:season 21 ;
17 | schema:startDate "1925-07-07"^^xsd:date ;
18 | schema:titleEIDR "ZQ28HQ5S1LYFKT" ;
19 | sh:description schema:TVSeriesShape .
20 |
21 | a schema:TVSeries ;
22 | schema:actor ,
23 | ,
24 | ;
25 | schema:datePublished "1958-07-07"^^xsd:date ;
26 | schema:director ;
27 | schema:endDate "1981-07-07"^^xsd:date ;
28 | schema:genre "Mystery Crime" ;
29 | schema:name "History's Greatest Hoaxes" ;
30 | schema:numberOfEpisodes 3 ;
31 | schema:numberOfSeasons 8 ;
32 | schema:season 8 ;
33 | schema:startDate "1919-07-07"^^xsd:date ;
34 | schema:titleEIDR "SM51UMWCB" ;
35 | sh:description schema:TVSeriesShape .
36 |
37 | a schema:TVSeries ;
38 | schema:actor ,
39 | ,
40 | ;
41 | schema:datePublished "1965-07-07"^^xsd:date ;
42 | schema:director ;
43 | schema:endDate "1986-07-07"^^xsd:date ;
44 | schema:genre "Adventure Romance" ;
45 | schema:name "Oct-01" ;
46 | schema:numberOfEpisodes 20 ;
47 | schema:numberOfSeasons 33 ;
48 | schema:season 33 ;
49 | schema:startDate "1953-07-07"^^xsd:date ;
50 | schema:titleEIDR "3GH5UNM8N/" ;
51 | sh:description schema:TVSeriesShape .
52 |
53 | a schema:TVSeries ;
54 | schema:actor ,
55 | ,
56 | ;
57 | schema:datePublished "1954-07-07"^^xsd:date ;
58 | schema:director ;
59 | schema:endDate "1974-07-07"^^xsd:date ;
60 | schema:genre "War Action" ;
61 | schema:name "New York Minute" ;
62 | schema:numberOfEpisodes 31 ;
63 | schema:numberOfSeasons 26 ;
64 | schema:season 26 ;
65 | schema:startDate "1941-07-07"^^xsd:date ;
66 | schema:titleEIDR "U3POWIHD553B" ;
67 | sh:description schema:TVSeriesShape .
68 |
69 | a schema:TVSeries ;
70 | schema:actor ,
71 | ,
72 | ;
73 | schema:datePublished "1958-07-07"^^xsd:date ;
74 | schema:director ;
75 | schema:endDate "1990-07-07"^^xsd:date ;
76 | schema:genre "Western Adventure Action" ;
77 | schema:name "Williams" ;
78 | schema:numberOfEpisodes 47 ;
79 | schema:numberOfSeasons 36 ;
80 | schema:season 36 ;
81 | schema:startDate "1909-07-07"^^xsd:date ;
82 | schema:titleEIDR "K/3KQSRT74V" ;
83 | sh:description schema:TVSeriesShape .
84 |
85 | a schema:TVSeries ;
86 | schema:actor ,
87 | ,
88 | ;
89 | schema:datePublished "1976-07-07"^^xsd:date ;
90 | schema:director ;
91 | schema:endDate "1981-07-07"^^xsd:date ;
92 | schema:genre "Sports Comedy" ;
93 | schema:name "Mirai" ;
94 | schema:numberOfEpisodes 5 ;
95 | schema:numberOfSeasons 50 ;
96 | schema:season 50 ;
97 | schema:startDate "1930-07-07"^^xsd:date ;
98 | schema:titleEIDR "8KSPIM8G9EM11" ;
99 | sh:description schema:TVSeriesShape .
100 |
101 | a schema:TVSeries ;
102 | schema:actor ,
103 | ,
104 | ;
105 | schema:datePublished "2002-07-07"^^xsd:date ;
106 | schema:director ;
107 | schema:endDate "2014-07-07"^^xsd:date ;
108 | schema:genre "Teen Fantasy" ;
109 | schema:name "Sinister 2" ;
110 | schema:numberOfEpisodes 35 ;
111 | schema:numberOfSeasons 36 ;
112 | schema:season 36 ;
113 | schema:startDate "1960-07-07"^^xsd:date ;
114 | schema:titleEIDR "1ID/1AML6W98" ;
115 | sh:description schema:TVSeriesShape .
116 |
117 | a schema:Person ;
118 | schema:email "leonhard_joseph@gmail.com" ;
119 | schema:familyName "Joseph" ;
120 | schema:gender "male" ;
121 | schema:givenName "Leonhard" ;
122 | schema:telephone "333-512-23" ;
123 | sh:description schema:DirectorShape .
124 |
125 | a schema:Person ;
126 | schema:gender "male" ;
127 | schema:name "Silvan Carpenter" ;
128 | sh:description schema:ActorShape .
129 |
130 | a schema:Person ;
131 | schema:gender "female" ;
132 | schema:name "Angela Swartz" ;
133 | sh:description schema:ActorShape .
134 |
135 | a schema:Person ;
136 | schema:gender "female" ;
137 | schema:name "Anitra Cordero" ;
138 | sh:description schema:ActorShape .
139 |
140 | a schema:Person ;
141 | schema:email "leontine_gilliam@gmail.com" ;
142 | schema:familyName "Gilliam" ;
143 | schema:gender "female" ;
144 | schema:givenName "Leontine" ;
145 | schema:telephone "678924-32" ;
146 | sh:description schema:DirectorShape .
147 |
148 | a schema:Person ;
149 | schema:gender "male" ;
150 | schema:name "Russell Combs" ;
151 | sh:description schema:ActorShape .
152 |
153 | a schema:Person ;
154 | schema:gender "male" ;
155 | schema:name "Jude Wallace" ;
156 | sh:description schema:ActorShape .
157 |
158 | a schema:Person ;
159 | schema:gender "female" ;
160 | schema:name "Dew Dolan" ;
161 | sh:description schema:ActorShape .
162 |
163 | a schema:Person ;
164 | schema:email "bellamy_ramirez@gmail.com" ;
165 | schema:familyName "Ramirez" ;
166 | schema:gender "female" ;
167 | schema:givenName "Bellamy" ;
168 | schema:telephone "511-047-" ;
169 | sh:description schema:DirectorShape .
170 |
171 | a schema:Person ;
172 | schema:gender "female" ;
173 | schema:name "Marjie Shaw" ;
174 | sh:description schema:ActorShape .
175 |
176 | a schema:Person ;
177 | schema:gender "female" ;
178 | schema:name "Eudora Nava" ;
179 | sh:description schema:ActorShape .
180 |
181 | a schema:Person ;
182 | schema:gender "female" ;
183 | schema:name "Korney Rouse" ;
184 | sh:description schema:ActorShape .
185 |
186 | a schema:Person ;
187 | schema:email "boris_ritter@gmail.com" ;
188 | schema:familyName "Ritter" ;
189 | schema:gender "male" ;
190 | schema:givenName "Boris" ;
191 | schema:telephone "378-791-560" ;
192 | sh:description schema:DirectorShape .
193 |
194 | a schema:Person ;
195 | schema:gender "male" ;
196 | schema:name "Forster Macdonald" ;
197 | sh:description schema:ActorShape .
198 |
199 | a schema:Person ;
200 | schema:gender "female" ;
201 | schema:name "Amalle Holden" ;
202 | sh:description schema:ActorShape .
203 |
204 | a schema:Person ;
205 | schema:gender "male" ;
206 | schema:name "Murray Cherry" ;
207 | sh:description schema:ActorShape .
208 |
209 | a schema:Person ;
210 | schema:email "crawford_thompson@gmail.com" ;
211 | schema:familyName "Thompson" ;
212 | schema:gender "male" ;
213 | schema:givenName "Crawford" ;
214 | schema:telephone "985929-872792" ;
215 | sh:description schema:DirectorShape .
216 |
217 | a schema:Person ;
218 | schema:gender "female" ;
219 | schema:name "Sybila Keller" ;
220 | sh:description schema:ActorShape .
221 |
222 | a schema:Person ;
223 | schema:gender "male" ;
224 | schema:name "Davide Hill" ;
225 | sh:description schema:ActorShape .
226 |
227 | a schema:Person ;
228 | schema:gender "female" ;
229 | schema:name "Aina Singleton" ;
230 | sh:description schema:ActorShape .
231 |
232 | a schema:Person ;
233 | schema:email "rudd_boone@gmail.com" ;
234 | schema:familyName "Boone" ;
235 | schema:gender "male" ;
236 | schema:givenName "Rudd" ;
237 | schema:telephone "787985-0679644-" ;
238 | sh:description schema:DirectorShape .
239 |
240 | a schema:Person ;
241 | schema:gender "female" ;
242 | schema:name "Agneta Stephenson" ;
243 | sh:description schema:ActorShape .
244 |
245 | a schema:Person ;
246 | schema:gender "male" ;
247 | schema:name "Oral Thurman" ;
248 | sh:description schema:ActorShape .
249 |
250 | a schema:Person ;
251 | schema:gender "male" ;
252 | schema:name "Zackariah Esposito" ;
253 | sh:description schema:ActorShape .
254 |
255 | a schema:Person ;
256 | schema:email "ardyce_oneil@gmail.com" ;
257 | schema:familyName "Oneil" ;
258 | schema:gender "female" ;
259 | schema:givenName "Ardyce" ;
260 | schema:telephone "811-693-4867729" ;
261 | sh:description schema:DirectorShape .
262 |
263 | a schema:Person ;
264 | schema:gender "male" ;
265 | schema:name "Merril Corbin" ;
266 | sh:description schema:ActorShape .
267 |
268 | a schema:Person ;
269 | schema:gender "male" ;
270 | schema:name "Talbot Battle" ;
271 | sh:description schema:ActorShape .
272 |
273 | a schema:Person ;
274 | schema:gender "male" ;
275 | schema:name "Rabbi Ortega" ;
276 | sh:description schema:ActorShape .
277 |
278 |
--------------------------------------------------------------------------------
/generated_examples/generated_rdf/generated_people.ttl:
--------------------------------------------------------------------------------
1 | @prefix schema: .
2 | @prefix sh: .
3 | @prefix xsd: .
4 |
5 | a schema:Person ;
6 | schema:address ;
7 | schema:birthDate "1985-07-07"^^xsd:date ;
8 | schema:deathDate "1999-07-07"^^xsd:date ;
9 | schema:email "verney_moore@gmail.com" ;
10 | schema:familyName "Moore" ;
11 | schema:gender "male" ;
12 | schema:givenName "Verney" ;
13 | schema:jobTitle "electrician" ;
14 | schema:telephone "348474-0459" ;
15 | sh:description schema:PersonShape .
16 |
17 | a schema:Person ;
18 | schema:address ;
19 | schema:birthDate "1973-07-07"^^xsd:date ;
20 | schema:deathDate "2002-07-07"^^xsd:date ;
21 | schema:email "tysononeal@gmail.com" ;
22 | schema:gender "male" ;
23 | schema:jobTitle "occupational therapist" ;
24 | schema:name "Tyson Oneal" ;
25 | schema:telephone "005781-6" ;
26 | sh:description schema:PersonShape .
27 |
28 | a schema:Person ;
29 | schema:address ;
30 | schema:birthDate "1983-07-07"^^xsd:date ;
31 | schema:deathDate "1990-07-07"^^xsd:date ;
32 | schema:email "hillortiz@gmail.com" ;
33 | schema:gender "male" ;
34 | schema:jobTitle "construction worker" ;
35 | schema:name "Hill Ortiz" ;
36 | schema:telephone "667-260-75" ;
37 | sh:description schema:PersonShape .
38 |
39 | a schema:Person ;
40 | schema:address ;
41 | schema:birthDate "1988-07-07"^^xsd:date ;
42 | schema:deathDate "2008-07-07"^^xsd:date ;
43 | schema:email "hildegarde_lange@gmail.com" ;
44 | schema:familyName "Lange" ;
45 | schema:gender "female" ;
46 | schema:givenName "Hildegarde" ;
47 | schema:jobTitle "welder" ;
48 | schema:telephone "030405-6924089" ;
49 | sh:description schema:PersonShape .
50 |
51 | a schema:Person ;
52 | schema:address ;
53 | schema:birthDate "1934-07-07"^^xsd:date ;
54 | schema:deathDate "1973-07-07"^^xsd:date ;
55 | schema:email "deeann_webb@gmail.com" ;
56 | schema:familyName "Webb" ;
57 | schema:gender "female" ;
58 | schema:givenName "Deeann" ;
59 | schema:jobTitle "financial manager" ;
60 | schema:telephone "613124-49539" ;
61 | sh:description schema:PersonShape .
62 |
63 | a schema:Person ;
64 | schema:address ;
65 | schema:birthDate "1957-07-07"^^xsd:date ;
66 | schema:deathDate "2001-07-07"^^xsd:date ;
67 | schema:email "cam_snow@gmail.com" ;
68 | schema:familyName "Snow" ;
69 | schema:gender "female" ;
70 | schema:givenName "Cam" ;
71 | schema:jobTitle "manicurist" ;
72 | schema:telephone "491-822-83" ;
73 | sh:description schema:PersonShape .
74 |
75 | a schema:Person ;
76 | schema:address ;
77 | schema:birthDate "1958-07-07"^^xsd:date ;
78 | schema:deathDate "1984-07-07"^^xsd:date ;
79 | schema:email "kriscurran@gmail.com" ;
80 | schema:gender "female" ;
81 | schema:jobTitle "director" ;
82 | schema:name "Kris Curran" ;
83 | schema:telephone "671-621-7766" ;
84 | sh:description schema:PersonShape .
85 |
86 | a schema:Person ;
87 | schema:address ;
88 | schema:birthDate "1996-07-07"^^xsd:date ;
89 | schema:deathDate "2010-07-07"^^xsd:date ;
90 | schema:email "estrella_quinones@gmail.com" ;
91 | schema:familyName "Quinones" ;
92 | schema:gender "female" ;
93 | schema:givenName "Estrella" ;
94 | schema:jobTitle "electrical engineer" ;
95 | schema:telephone "040368-14282057" ;
96 | sh:description schema:PersonShape .
97 |
98 | a schema:Person ;
99 | schema:address ;
100 | schema:birthDate "1930-07-07"^^xsd:date ;
101 | schema:deathDate "1976-07-07"^^xsd:date ;
102 | schema:email "mohammed_kendall@gmail.com" ;
103 | schema:familyName "Kendall" ;
104 | schema:gender "male" ;
105 | schema:givenName "Mohammed" ;
106 | schema:jobTitle "air conditioning installer" ;
107 | schema:telephone "996-023-015558" ;
108 | sh:description schema:PersonShape .
109 |
110 | a schema:Person ;
111 | schema:address ;
112 | schema:birthDate "1963-07-07"^^xsd:date ;
113 | schema:deathDate "2012-07-07"^^xsd:date ;
114 | schema:email "fonsie_mayo@gmail.com" ;
115 | schema:familyName "Mayo" ;
116 | schema:gender "male" ;
117 | schema:givenName "Fonsie" ;
118 | schema:jobTitle "jailer" ;
119 | schema:telephone "175097-2" ;
120 | sh:description schema:PersonShape .
121 |
122 | a schema:Person ;
123 | schema:address ;
124 | schema:birthDate "1969-07-07"^^xsd:date ;
125 | schema:deathDate "2016-07-07"^^xsd:date ;
126 | schema:email "valeria_whitley@gmail.com" ;
127 | schema:familyName "Whitley" ;
128 | schema:gender "female" ;
129 | schema:givenName "Valeria" ;
130 | schema:jobTitle "bartender" ;
131 | schema:telephone "136-083-844" ;
132 | sh:description schema:PersonShape .
133 |
134 | a schema:Person ;
135 | schema:address ;
136 | schema:birthDate "1991-07-07"^^xsd:date ;
137 | schema:deathDate "2006-07-07"^^xsd:date ;
138 | schema:email "diane-mariesantiago@gmail.com" ;
139 | schema:gender "female" ;
140 | schema:jobTitle "manicurist" ;
141 | schema:name "Diane-Marie Santiago" ;
142 | schema:telephone "298620-6075831-" ;
143 | sh:description schema:PersonShape .
144 |
145 | a schema:Person ;
146 | schema:address ;
147 | schema:birthDate "1970-07-07"^^xsd:date ;
148 | schema:deathDate "1994-07-07"^^xsd:date ;
149 | schema:email "john-patrick_brandon@gmail.com" ;
150 | schema:familyName "Brandon" ;
151 | schema:gender "male" ;
152 | schema:givenName "John-Patrick" ;
153 | schema:jobTitle "market research analyst" ;
154 | schema:telephone "930737-42119" ;
155 | sh:description schema:PersonShape .
156 |
157 | a schema:Person ;
158 | schema:address ;
159 | schema:birthDate "1959-07-07"^^xsd:date ;
160 | schema:deathDate "1982-07-07"^^xsd:date ;
161 | schema:email "nelsenbaez@gmail.com" ;
162 | schema:gender "male" ;
163 | schema:jobTitle "marketing manager" ;
164 | schema:name "Nelsen Baez" ;
165 | schema:telephone "957470-661" ;
166 | sh:description schema:PersonShape .
167 |
168 | a schema:Person ;
169 | schema:address ;
170 | schema:birthDate "1981-07-07"^^xsd:date ;
171 | schema:deathDate "1986-07-07"^^xsd:date ;
172 | schema:email "dale_garrison@gmail.com" ;
173 | schema:familyName "Garrison" ;
174 | schema:gender "male" ;
175 | schema:givenName "Dale" ;
176 | schema:jobTitle "hostess" ;
177 | schema:telephone "455-774-2" ;
178 | sh:description schema:PersonShape .
179 |
180 | a schema:Person ;
181 | schema:address ;
182 | schema:birthDate "1989-07-07"^^xsd:date ;
183 | schema:deathDate "2000-07-07"^^xsd:date ;
184 | schema:email "ambrosiacherry@gmail.com" ;
185 | schema:gender "female" ;
186 | schema:jobTitle "baker" ;
187 | schema:name "Ambrosia Cherry" ;
188 | schema:telephone "654-943-6689875" ;
189 | sh:description schema:PersonShape .
190 |
191 | a schema:Person ;
192 | schema:address ;
193 | schema:birthDate "1964-07-07"^^xsd:date ;
194 | schema:deathDate "1970-07-07"^^xsd:date ;
195 | schema:email "ditaburks@gmail.com" ;
196 | schema:gender "female" ;
197 | schema:jobTitle "jailer" ;
198 | schema:name "Dita Burks" ;
199 | schema:telephone "837-990-" ;
200 | sh:description schema:PersonShape .
201 |
202 | a schema:Person ;
203 | schema:address ;
204 | schema:birthDate "1958-07-07"^^xsd:date ;
205 | schema:deathDate "1991-07-07"^^xsd:date ;
206 | schema:email "hadleighhernandez@gmail.com" ;
207 | schema:gender "male" ;
208 | schema:jobTitle "machinist" ;
209 | schema:name "Hadleigh Hernandez" ;
210 | schema:telephone "488952-391" ;
211 | sh:description schema:PersonShape .
212 |
213 | a schema:Person ;
214 | schema:address ;
215 | schema:birthDate "1953-07-07"^^xsd:date ;
216 | schema:deathDate "1995-07-07"^^xsd:date ;
217 | schema:email "careymathis@gmail.com" ;
218 | schema:gender "female" ;
219 | schema:jobTitle "machinist" ;
220 | schema:name "Carey Mathis" ;
221 | schema:telephone "365-445-" ;
222 | sh:description schema:PersonShape .
223 |
224 | a schema:Person ;
225 | schema:address ;
226 | schema:birthDate "1974-07-07"^^xsd:date ;
227 | schema:deathDate "1978-07-07"^^xsd:date ;
228 | schema:email "giorgia_pierson@gmail.com" ;
229 | schema:familyName "Pierson" ;
230 | schema:gender "female" ;
231 | schema:givenName "Giorgia" ;
232 | schema:jobTitle "computer support specialist" ;
233 | schema:telephone "951824-9331" ;
234 | sh:description schema:PersonShape .
235 |
236 | schema:postalCode "sdNTo47HT5" ;
237 | schema:streetAddress "no. 95 Alton ave" ;
238 | sh:description schema:AddressShape .
239 |
240 | schema:postalCode "fVw0lBG5gk" ;
241 | schema:streetAddress "no. 80 Douglass st" ;
242 | sh:description schema:AddressShape .
243 |
244 | schema:postalCode 64484 ;
245 | schema:streetAddress "no. 90 Lester ct" ;
246 | sh:description schema:AddressShape .
247 |
248 | schema:postalCode 35355 ;
249 | schema:streetAddress "no. 12 Lucky st" ;
250 | sh:description schema:AddressShape .
251 |
252 | schema:postalCode 53830 ;
253 | schema:streetAddress "no. 15 Miles ct" ;
254 | sh:description schema:AddressShape .
255 |
256 | schema:postalCode 16186 ;
257 | schema:streetAddress "no. 12 Battery wagner rd" ;
258 | sh:description schema:AddressShape .
259 |
260 | schema:postalCode "dqG2MLEE732j" ;
261 | schema:streetAddress "no. 10 Ruger st" ;
262 | sh:description schema:AddressShape .
263 |
264 | schema:postalCode 34740 ;
265 | schema:streetAddress "no. 94 Commer ct" ;
266 | sh:description schema:AddressShape .
267 |
268 | schema:postalCode "OHW3t2h9z" ;
269 | schema:streetAddress "no. 74 Jeff adachi way" ;
270 | sh:description schema:AddressShape .
271 |
272 | schema:postalCode 35788 ;
273 | schema:streetAddress "no. 93 Russian hill pl" ;
274 | sh:description schema:AddressShape .
275 |
276 | schema:postalCode 50769 ;
277 | schema:streetAddress "no. 1 Merriam ln" ;
278 | sh:description schema:AddressShape .
279 |
280 | schema:postalCode "n5juRlNF" ;
281 | schema:streetAddress "no. 32 Unnamed 037" ;
282 | sh:description schema:AddressShape .
283 |
284 | schema:postalCode 64234 ;
285 | schema:streetAddress "no. 90 Mabrey ct" ;
286 | sh:description schema:AddressShape .
287 |
288 | schema:postalCode "j6CnCLABj8u" ;
289 | schema:streetAddress "no. 23 Bercut access rd" ;
290 | sh:description schema:AddressShape .
291 |
292 | schema:postalCode "gtZ2DsiFoINdC" ;
293 | schema:streetAddress "no. 69 Long bridge vara" ;
294 | sh:description schema:AddressShape .
295 |
296 | schema:postalCode "20SNIQn4b" ;
297 | schema:streetAddress "no. 76 Merchant st" ;
298 | sh:description schema:AddressShape .
299 |
300 | schema:postalCode 46186 ;
301 | schema:streetAddress "no. 1 Paraiso pl" ;
302 | sh:description schema:AddressShape .
303 |
304 | schema:postalCode "EsyTbzFrmTfBg" ;
305 | schema:streetAddress "no. 56 Serrano dr" ;
306 | sh:description schema:AddressShape .
307 |
308 | schema:postalCode "ebJDeaZWuJJ" ;
309 | schema:streetAddress "no. 100 Bonifacio st" ;
310 | sh:description schema:AddressShape .
311 |
312 | schema:postalCode "2YyfFn925Dz" ;
313 | schema:streetAddress "no. 35 Peacemakers st" ;
314 | sh:description schema:AddressShape .
315 |
316 |
--------------------------------------------------------------------------------
/rdf_graph_gen/rdf_graph_generator.py:
--------------------------------------------------------------------------------
1 | from copy import deepcopy
2 | from rdflib import Graph, BNode
3 |
4 | from rdf_graph_gen.shacl_mapping_generator import *
5 | from rdf_graph_gen.value_generators import *
6 |
7 | COUNTER = 100
8 |
9 | """
10 | Function Explanation:
11 | ---------------------
12 | The 'dictionary_to_rdf_graph' function generates RDF triples based on the specified constraints of a SHACL shape
13 | represented as a dictionary.
14 |
15 | Parameters:
16 | -----------
17 | shape_dictionary (dict): A dictionary representing a SHACL shape with constraints and properties.
18 | shape_name (str): Name of the SHACL shape.
19 | result (rdflib.Graph): RDF graph to which the generated triples will be added.
20 | parent (rdflib.BNode or None): Parent node in the RDF graph to which the generated triples will be attached.
21 | dictionary (dict): Dictionary containing other SHACL shapes for reference.
22 | property_pair_constraint_components_parent (list): List of property pair constraint components.
23 | parent_class (rdflib.URIRef): URIRef representing the parent class of the SHACL shape.
24 |
25 | Returns:
26 | --------
27 | rdflib.BNode or rdflib.URIRef: The RDF node representing the SHACL shape in the generated graph.
28 | """
29 |
30 |
31 | def dictionary_to_rdf_graph(shape_dictionary, shape_name, result, parent, dictionary,
32 | property_pair_constraint_components_parent, parent_class, batchID):
33 | # initialization
34 | property_pair_constraint_components = []
35 | node = BNode()
36 |
37 | if shape_name:
38 | global COUNTER
39 | node = URIRef(f'http://example.org/ns#Node{batchID}_{COUNTER}')
40 | COUNTER += 1
41 | # as SH.description add the name of the shape that this node was generated from
42 | result.add((node, SH.description, shape_name))
43 |
44 | sh_class = shape_dictionary.get(SH.targetClass, shape_dictionary.get(URIRef(SH['class'])))
45 | if sh_class:
46 | result.add((node, RDF.type, sh_class))
47 | else:
48 | sh_class = parent_class
49 |
50 | # if there is a sh:xone for this dict, choose one of the choices and merge it with the existing properties
51 | sh_xone = shape_dictionary.get(URIRef(SH['xone']))
52 | if sh_xone:
53 | shape_dictionary = deepcopy(shape_dictionary)
54 | choice = random.choice(sh_xone)
55 | sh_path = choice.get(SH.path)
56 | if sh_path:
57 | choice = {"properties": {sh_path: choice}}
58 | update_dictionary(shape_dictionary, choice)
59 |
60 | # if there is a sh:and for this dict, merge all the choices with the existing properties
61 | sh_and = shape_dictionary.get(URIRef(SH['and']))
62 | if sh_and:
63 | shape_dictionary = deepcopy(shape_dictionary)
64 | for choice in sh_and:
65 | sh_path = choice.get(SH.path)
66 | if sh_path:
67 | choice = {"properties": {sh_path: choice}}
68 | update_dictionary(shape_dictionary, choice)
69 |
70 | # if there is a sh:or for this dict, choose some of the choices and merge it with the existing properties
71 | sh_or = shape_dictionary.get(URIRef(SH['or']))
72 | if sh_or:
73 | shape_dictionary = deepcopy(shape_dictionary)
74 | len_choices = len(sh_or)
75 | for choice in random.sample(sh_or, random.randint(1, len_choices)):
76 | sh_path = choice.get(SH.path)
77 | if sh_path:
78 | choice = {"properties": {sh_path: choice}}
79 | update_dictionary(shape_dictionary, choice)
80 |
81 | # get the dependent property for sh:equals
82 | sh_equals = shape_dictionary.get(SH.equals)
83 | if sh_equals:
84 | sh_equals = next(result.objects(parent, sh_equals), None)
85 | if sh_equals is None:
86 | property_pair_constraint_components_parent.append(shape_dictionary)
87 | return None
88 |
89 | # get the dependent property for sh:disjoint
90 | sh_disjoint = shape_dictionary.get(SH.disjoint)
91 | if sh_disjoint:
92 | sh_disjoint = next(result.objects(parent, sh_disjoint), None)
93 | if not sh_disjoint is None:
94 | property_pair_constraint_components_parent.append(shape_dictionary)
95 | return None
96 |
97 | # get the dependent property for sh:lessThan
98 | sh_less_than = shape_dictionary.get(SH.lessThan)
99 | if sh_less_than:
100 | # sh_less_than = next(result.objects(parent, sh_less_than), None)
101 | sh_less_than = [o for o in result.objects(parent, sh_less_than)]
102 | if len(sh_less_than) == 0:
103 | property_pair_constraint_components_parent.append(shape_dictionary)
104 | return None
105 |
106 | # get the dependent property for sh:lessThanOrEquals
107 | sh_less_than_or_equals = shape_dictionary.get(SH.lessThanOrEquals)
108 | if sh_less_than_or_equals:
109 | sh_less_than_or_equals = [o for o in result.objects(parent, sh_less_than_or_equals)]
110 | if len(sh_less_than_or_equals) == 0:
111 | property_pair_constraint_components_parent.append(shape_dictionary)
112 | return None
113 |
114 | # Define dependencies for the dictionary, so the generated result makes sense
115 | define_dependencies(shape_dictionary)
116 |
117 | dependencies = {}
118 | depends_on = shape_dictionary.get("depends_on", []) # [] is to mot check if there are dependencies
119 | for dep in depends_on:
120 | val = [o for o in result.objects(parent, dep)]
121 | if len(val) == 0:
122 | property_pair_constraint_components_parent.append(shape_dictionary)
123 | return None
124 | dependencies[dep] = val
125 |
126 | # Get the rest of the constraints
127 | sh_in = shape_dictionary.get(URIRef(SH + "in"))
128 | sh_datatype = shape_dictionary.get(SH.datatype)
129 | sh_min_exclusive = shape_dictionary.get(SH.minExclusive)
130 | sh_min_inclusive = shape_dictionary.get(SH.minInclusive)
131 | sh_max_exclusive = shape_dictionary.get(SH.maxExclusive)
132 | sh_max_inclusive = shape_dictionary.get(SH.maxInclusive)
133 | sh_min_length = shape_dictionary.get(SH.minLength)
134 | sh_max_length = shape_dictionary.get(SH.maxLength)
135 | sh_pattern = shape_dictionary.get(SH.pattern)
136 | sh_node = shape_dictionary.get(SH.node)
137 | sh_path = shape_dictionary.get(SH.path)
138 |
139 | # get the nested properties
140 | properties = shape_dictionary.get("properties")
141 | # for each nested property generate a rdf graph recursively
142 | if properties:
143 | for key, value in properties.items():
144 |
145 | # the min count of the property that is generated (generate at least 1)
146 | sh_min_count = int(value.get(SH.minCount, "1"))
147 | sh_max_count = int(value.get(SH.maxCount, sh_min_count))
148 |
149 | # check if property has hasValue, and if it has add one tuple and go on with that property
150 | sh_has_value = value.get(SH.hasValue)
151 | if sh_has_value is not None:
152 | result.add((node, key, sh_has_value))
153 | sh_max_count -= 1
154 |
155 | # decrease sh_max_count because one value is generated. If the new value is lesser than sh_min_count, decrease sh_min_count to sh_max_count
156 | if sh_max_count < sh_min_count:
157 | sh_min_count = sh_max_count
158 |
159 | for i in range(0, random.randint(sh_min_count, sh_max_count)):
160 | generated_prop = dictionary_to_rdf_graph(value, None, result, node, dictionary,
161 | property_pair_constraint_components, sh_class, batchID)
162 | if generated_prop is not None:
163 | result.add((node, key, generated_prop))
164 |
165 | # generate the properties that weren't generated due to a missing dependency
166 | while property_pair_constraint_components:
167 | value = property_pair_constraint_components.pop(0)
168 | sh_min_count = int(value.get(SH.minCount, "1"))
169 | sh_max_count = int(value.get(SH.maxCount, sh_min_count))
170 | for i in range(0, random.randint(sh_min_count, sh_max_count)):
171 | generated_prop = dictionary_to_rdf_graph(value, None, result, node, dictionary,
172 | property_pair_constraint_components, sh_class, batchID)
173 | if generated_prop is not None:
174 | result.add((node, value.get(SH.path), generated_prop))
175 | else:
176 | break
177 | return node
178 |
179 | # if sh:in exists, return a value from it's predefined set.
180 | # Check the parent shape so you dont add the same tuple multiple times.
181 | elif sh_in:
182 | existing = {o for o in result.objects(parent, sh_path)}
183 | potential = set(sh_in) - existing
184 | if len(potential) > 0:
185 | return random.choice(list(potential))
186 | return random.choice(sh_in)
187 |
188 | # if the property is described by a sh:node, generate a node and add it
189 | elif sh_node:
190 | n = dictionary.get(sh_node)
191 | if not n:
192 | raise Exception("The SHACL shape " + sh_node + " cannot be found!")
193 | return dictionary_to_rdf_graph(n, sh_node, result, None, dictionary, [], sh_class, batchID)
194 |
195 | # check if a predefined value exists for this iteration
196 | predefined_value = generate_intuitive_value(sh_path, sh_class, dependencies)
197 | if predefined_value:
198 | return predefined_value
199 |
200 | # return a generated value based on multiple constarints
201 | existing_values = {o.toPython() for o in result.objects(parent, sh_path)}
202 | return generate_default_value(existing_values, sh_datatype, sh_min_exclusive, sh_min_inclusive, sh_max_exclusive, sh_max_inclusive,
203 | sh_min_length, sh_max_length, sh_pattern, sh_equals, sh_disjoint, sh_less_than,
204 | sh_less_than_or_equals, sh_path, sh_class)
205 |
206 |
207 | """
208 | Function Explanation:
209 | ---------------------
210 | The 'generate_rdf_graph' function generates RDF graphs by processing SHACL shapes from the provided shapes_graph.
211 | For each independent node shape, it generates the specified number of RDF samples using the 'dictionary_to_rdf_graph'
212 | function.
213 |
214 | Parameters:
215 | -----------
216 | shapes_graph (rdflib.Graph): The RDF Shapes graph containing SHACL shapes and related information.
217 | dictionary (dict): Dictionary of SHACL shapes.
218 | number_of_samples (int): The number of RDF samples to generate for each independent node shape.
219 |
220 | Returns:
221 | --------
222 | rdflib.Graph: The resulting RDF graph containing generated samples based on SHACL shapes.
223 |
224 | Explanation:
225 | ------------
226 | - The function initializes an empty RDF graph ('result_graph') to store the generated triples.
227 | - It identifies independent node shapes using the 'find_independent_node_shapes' function.
228 | - For each independent node shape, it iteratively calls the 'dictionary_to_rdf_graph' function to generate
229 | RDF samples and adds them to 'result_graph'.
230 | - Finally, it returns the resulting RDF graph containing the generated samples.
231 |
232 | Note: The 'dictionary_to_rdf_graph' function is responsible for generating RDF triples based on SHACL constraints.
233 | """
234 |
235 |
236 | def generate_rdf_graphs_from_dictionary(shapes_graph, dictionary, number_of_samples, batchID):
237 | result_graph = Graph()
238 | result_graph.bind("schemaorg", SCH)
239 |
240 | # Find independent node shapes in the provided shapes_graph
241 | independent_node_shapes = find_independent_node_shapes(shapes_graph)
242 |
243 | # Generate RDF samples for each independent node shape
244 | for key in independent_node_shapes:
245 | for i in range(0, number_of_samples):
246 | # Call 'dictionary_to_rdf_graph' to generate RDF triples for the current shape
247 | dictionary_to_rdf_graph(dictionary[key], key, result_graph, None, dictionary, [], None, batchID)
248 |
249 | return result_graph
250 |
251 |
252 | """
253 | Function Explanation:
254 | ---------------------
255 | The 'generate_rdf_graphs_from_shacl_constraints' function streamlines the process of generating RDF graphs based on
256 | SHACL (Shapes Constraint Language) constraints specified in a given file. It parses the SHACL shapes from the input
257 | file, converts them into a dictionary representation, and utilizes this dictionary to create RDF graphs conforming to
258 | the specified constraints.
259 |
260 | Parameters:
261 | -----------
262 | shape_file (str): The path to the file containing SHACL shapes.
263 | number (int): The number of RDF graphs to generate.
264 |
265 | Returns:
266 | --------
267 | rdflib.Graph: The resulting RDF graph conforming to the SHACL constraints.
268 |
269 | Explanation:
270 | ------------
271 | - The function begins by creating an empty RDF graph ('shape') using the 'rdflib' library and parses the SHACL
272 | shapes from the given file into this graph.
273 | - It then calls the helper function 'generate_dictionary_from_shapes_graph' to convert the parsed SHACL shapes
274 | graph into a dictionary representation. This dictionary encompasses the properties and constraints specified
275 | in SHACL shapes.
276 | - The function proceeds to invoke 'generate_rdf_graph', passing the parsed SHACL shapes graph, the generated
277 | dictionary, and the specified number of samples. This function creates RDF graphs conforming to the SHACL
278 | constraints.
279 | - Finally, the function returns the resulting RDF graph, providing easy access to a representation of RDF data
280 | structures compliant with the specified SHACL constraints.
281 | """
282 |
283 |
284 | def generate_rdf_graphs_from_shacl_constraints(shape_file, number):
285 | # Create an empty RDF graph
286 | shape = Graph()
287 | # Parse SHACL shapes from the input file into the graph
288 | shape.parse(shape_file)
289 | # Convert parsed SHACL shapes graph into a dictionary representation
290 | dictionary = generate_dictionary_from_shapes_graph(shape)
291 | # Generate RDF graphs conforming to SHACL constraints
292 | graph = generate_rdf_graphs_from_dictionary(shape, dictionary, number, 'B1')
293 | # Return the resulting RDF graph
294 | return graph
295 |
296 |
297 | def generate_rdf(shape_file, output_file, number, batch_size):
298 | shape = Graph()
299 | shape.parse(shape_file)
300 | dictionary = generate_dictionary_from_shapes_graph(shape)
301 |
302 | # implement generating and writing down of the graphs in batches
303 | with open(output_file, "a") as ttl_file:
304 | while number > 0:
305 |
306 | batch_number = min(number, batch_size)
307 | graph = generate_rdf_graphs_from_dictionary(shape, dictionary, batch_number, 'B1')
308 | text_graph = graph.serialize(format = 'ttl')
309 | ttl_file.write(text_graph)
310 |
311 | number -= batch_size
312 |
313 | ttl_file.flush()
314 | ttl_file.close()
315 |
--------------------------------------------------------------------------------
/rdf_graph_gen/shacl_mapping_generator.py:
--------------------------------------------------------------------------------
1 | from rdflib import SH, RDF, URIRef, Namespace
2 |
3 | SCH = Namespace("http://schema.org/")
4 | """
5 | Function Explanation:
6 | ---------------------
7 | The `update_dictionary` function facilitates the merging of two dictionaries, `dict1` and `dict2`. It iterates through
8 | the key-value pairs of `dict2` and updates the values in `dict1`. In cases where a key already exists in `dict1` and
9 | corresponds to a dictionary, the function recursively extends the update to nested dictionaries.
10 |
11 | Parameters:
12 | -----------
13 | dict1 (dict): The primary dictionary to be updated.
14 | dict2 (dict): The secondary dictionary containing values for the update.
15 |
16 | Returns:
17 | --------
18 | None
19 |
20 | Example:
21 | --------
22 | update_dictionary({'a': 1, 'b': {'c': 2}}, {'b': {'d': 3}})
23 | # Result: {'a': 1, 'b': {'c': 2, 'd': 3}}
24 | """
25 |
26 |
27 | def update_dictionary(dict1, dict2):
28 | # Iterate through keys and values in dict2
29 | for key2, value2 in dict2.items():
30 | # Get the corresponding value from dict1 for the current key
31 | value1 = dict1.get(key2)
32 |
33 | # Check if value1 is a dictionary
34 | if type(value1) == dict:
35 | # If it's a dictionary, recursively call update_dictionary
36 | update_dictionary(value1, value2)
37 | else:
38 | # If it's not a dictionary, update the value in dict1 with the value from dict2
39 | dict1[key2] = value2
40 |
41 |
42 | """
43 | Function Explanation:
44 | ---------------------
45 | The `find_node_shapes` function identifies and returns the unique SHACL Node Shapes present in a given RDF Shapes graph.
46 |
47 | Parameters:
48 | -----------
49 | shapes_graph (rdflib.Graph): The RDF Shapes graph to analyze.
50 |
51 | Returns:
52 | --------
53 | set: A set containing the unique SHACL Node Shapes identified in the given RDF Shapes graph.
54 |
55 | Example:
56 | --------
57 | # Assuming SHACL Node Shapes are represented in the graph
58 | shapes_graph = ... # Some RDF Shapes graph
59 | node_shapes = find_node_shapes(shapes_graph)
60 | # Result: A set of unique SHACL Node Shapes in the RDF Shapes graph.
61 | """
62 |
63 |
64 | def find_node_shapes(shapes_graph):
65 | # Use RDFlib to identify unique SHACL Node Shapes
66 | node_shapes = {s for s in shapes_graph.subjects(RDF.type, SH.NodeShape)}
67 | return node_shapes
68 |
69 |
70 | """
71 | Function Explanation:
72 | ---------------------
73 | The `find_independent_node_shapes` function identifies and returns unique SHACL Node Shapes that are independent (not pointed to by other shapes) within an RDF Shapes graph.
74 |
75 | Parameters:
76 | -----------
77 | shapes_graph (rdflib.Graph): The RDF Shapes graph to analyze.
78 |
79 | Returns:
80 | --------
81 | set: A set containing the unique independent SHACL Node Shapes in the given RDF Shapes graph.
82 | """
83 |
84 |
85 | def find_independent_node_shapes(shapes_graph):
86 | # Step 1: Retrieve all SHACL Node Shapes in the graph
87 | node_shapes = find_node_shapes(shapes_graph)
88 |
89 | # Step 2: Retrieve SHACL Node Shapes that are pointed to by other shapes
90 | node_shapes_pointed = {s for s in shapes_graph.objects(None, SH.node)}
91 |
92 | # Step 3: Return the set difference to find independent SHACL Node Shapes
93 | return node_shapes - node_shapes_pointed
94 |
95 |
96 | # given a rdf list, it returns a python list containing the items in the RDF list.
97 | """
98 | Function Explanation:
99 | ---------------------
100 | The function 'get_list_from_shacl_list' extracts a list from a SHACL list in an RDF Shapes graph, starting from a given node.
101 |
102 | Parameters:
103 | -----------
104 | start (rdflib.term.Identifier): The starting node of the SHACL list.
105 | shapes_graph (rdflib.Graph): The RDF Shapes graph containing the SHACL list.
106 |
107 | Returns:
108 | --------
109 | list: A Python list containing the elements of the SHACL list.
110 | """
111 |
112 |
113 | def get_list_from_shacl_list(start, shapes_graph):
114 | # Initialize an empty list to store SHACL list elements
115 | _list = []
116 |
117 | # Get the value of the first element in the SHACL list
118 | first = next(shapes_graph.objects(start, RDF.first))
119 | _list.append(first)
120 |
121 | # Get the value of the rest of the list
122 | rest = next(shapes_graph.objects(start, RDF.rest))
123 |
124 | # Check if the rest is RDF.nil, indicating the end of the list
125 | if rest == RDF.nil:
126 | return _list
127 | else:
128 | # If the rest is not RDF.nil, recursively call the function with the rest as the new starting node
129 | # Append the result to the current list
130 | return _list + get_list_from_shacl_list(rest, shapes_graph)
131 |
132 |
133 | """
134 | Function Explanation:
135 | ---------------------
136 | The function 'get_dict_list_from_shacl_list' extracts a list of dictionaries from a SHACL list in an RDF Shapes graph, starting from a given node.
137 |
138 | Parameters:
139 | -----------
140 | start (rdflib.term.Identifier): The starting node of the SHACL list.
141 | shapes_graph (rdflib.Graph): The RDF Shapes graph containing the SHACL list.
142 | property_pair_constraint_components (list): List of property pair constraint components.
143 |
144 | Returns:
145 | --------
146 | list: A Python list containing dictionaries converted from SHACL shapes in the list.
147 | """
148 |
149 |
150 | def get_dict_list_from_shacl_list(start, shapes_graph, property_pair_constraint_components):
151 | # Initialize an empty list to store dictionaries converted from SHACL shapes
152 | items = []
153 |
154 | # Get the value of the first element in the SHACL list
155 | first = next(shapes_graph.objects(start, RDF.first))
156 |
157 | # Convert the SHACL shape to a dictionary and append it to the list
158 | items.append(shape_to_dictionary(first, shapes_graph, property_pair_constraint_components))
159 |
160 | # Get the value of the rest of the list
161 | rest = next(shapes_graph.objects(start, RDF.rest))
162 |
163 | # Check if the rest is RDF.nil, indicating the end of the list
164 | if rest == RDF.nil:
165 | return items
166 | else:
167 | # If the rest is not RDF.nil, recursively call the function with the rest as the new starting node
168 | # Append the result to the current list
169 | return items + get_dict_list_from_shacl_list(rest, shapes_graph, property_pair_constraint_components)
170 |
171 |
172 | """
173 | Function Explanation:
174 | ---------------------
175 | The 'shape_to_dictionary' function converts a SHACL shape into a dictionary representation, capturing its properties and
176 | constraints. It recursively processes nested shapes, property paths, and other SHACL constructs.
177 |
178 | Parameters:
179 | -----------
180 | shape (rdflib.term.Identifier): The SHACL shape to be converted into a dictionary.
181 | shapes_graph (rdflib.Graph): The RDF Shapes graph containing the SHACL shape and related information.
182 | property_pair_constraint_components_parent (list): List of property pair constraint components from the parent shape.
183 |
184 | Returns:
185 | --------
186 | dict: A Python dictionary representing the converted SHACL shape.
187 |
188 | Explanation:
189 | ------------
190 | - The function begins by retrieving all triples associated with the given SHACL shape from the RDF Shapes graph.
191 | - It initializes several old_shapes structures to store property information, dictionaries, and the final shape dictionary.
192 |
193 | # Handling SHACL Properties and Nested Constructs
194 | - The function iterates through the triples, handling different cases for SHACL properties, paths, and nested constructs.
195 | - For properties represented by SH:path, SH:in, SH:or, SH:and, SH:xone, and SH:not, the function recursively calls itself or other specific functions.
196 | - The resulting dictionaries and values are added to the shape dictionary.
197 |
198 | # Special Handling for Property Pair Constraint Components
199 | - Special handling is performed for Property Pair Constraint Components, ensuring proper dependencies and constraints are captured.
200 | - This includes checking for SH:equals, SH:disjoint, SH:lessThan, SH:lessThanOrEquals constraints and updating the shape dictionary accordingly.
201 |
202 | # Finalization and Return
203 | - The function returns the final shape dictionary, representing the SHACL shape in a structured Python format.
204 |
205 | Note: The function utilizes other helper functions such as 'get_list_from_shacl_list' and 'get_dict_list_from_shacl_list'.
206 | """
207 |
208 |
209 | def shape_to_dictionary(shape, shapes_graph, property_pair_constraint_components_parent):
210 | # Get all triples related to the SHACL shape
211 | triples = shapes_graph.triples((shape, None, None))
212 |
213 | # Initialize old_shapes structures
214 | property_pair_constraint_components = []
215 | sh_properties = {}
216 | shape_dictionary = {}
217 |
218 | # Iterate through triples and process SHACL properties and constructs
219 | for s, p, o in triples:
220 | if p == SH.property:
221 | # Handle SH:path property and nested shapes
222 | property_path = next(shapes_graph.objects(o, SH.path))
223 |
224 | # Retrieve or initialize property dictionary for the current property path
225 | property_dict = sh_properties.get(property_path, {})
226 |
227 | # Recursively call the function to process nested shapes within the property
228 | new_prop_dict = shape_to_dictionary(o, shapes_graph, property_pair_constraint_components)
229 |
230 | # Update the existing property dictionary with the new old_shapes
231 | update_dictionary(property_dict, new_prop_dict)
232 |
233 | # Update the sh_properties dictionary with the updated property dictionary
234 | sh_properties[property_path] = property_dict
235 |
236 | elif p == URIRef(SH['in']):
237 | # Handle SH:in property
238 | shape_dictionary[p] = get_list_from_shacl_list(o, shapes_graph)
239 |
240 | elif p in {URIRef(SH['or']), URIRef(SH['and']), URIRef(SH['xone']), URIRef(SH['not'])}:
241 | # Handle SH:or, SH:and, SH:xone, SH:not properties
242 | shape_dictionary[p] = get_dict_list_from_shacl_list(o, shapes_graph,
243 | property_pair_constraint_components_parent)
244 |
245 | else:
246 | # Handle other SHACL properties
247 | if p == SH.lessThan or p == SH.lessThanOrEquals or p == SH.equals or p == SH.disjoint:
248 | # Add the current shape_dictionary to the list of property pair constraint components
249 | property_pair_constraint_components_parent.append(shape_dictionary)
250 |
251 | shape_dictionary[p] = o
252 |
253 | # Add properties dictionary only if the node has properties
254 | if bool(sh_properties):
255 | shape_dictionary["properties"] = sh_properties
256 |
257 | # Fix dependencies caused by Property Pair Constraint Components
258 | for d in property_pair_constraint_components:
259 | # Handle SH:equals, SH:disjoint, SH:lessThan, SH:lessThanOrEquals constraints
260 | equals = d.get(SH.equals)
261 | disjoint = d.get(SH.disjoint)
262 | less_than = d.get(SH.lessThan)
263 | less_than_or_equals = d.get(SH.lessThanOrEquals)
264 |
265 | # Additional handling for constraints
266 | if equals and not sh_properties.get(SH.equals):
267 | sh_properties[equals] = {SH.path: equals}
268 | if disjoint and not sh_properties.get(SH.disjoint):
269 | sh_properties[disjoint] = {SH.path: disjoint}
270 | if less_than and not sh_properties.get(less_than):
271 | less_than_dict = sh_properties.get(less_than, {})
272 | less_than_dict[SH.path] = less_than
273 | if not less_than_dict.get(SH.datatype) and d.get(SH.datatype):
274 | less_than_dict[SH.datatype] = d.get(SH.datatype)
275 | sh_properties[less_than] = less_than_dict
276 | min_constraint = d.get(SH.minInclusive, d.get(SH.minExclusive))
277 | if min_constraint:
278 | less_than_dict[SH.minInclusive] = min_constraint
279 | if less_than_or_equals and not sh_properties.get(less_than_or_equals):
280 | less_than_or_equals_dict = sh_properties.get(less_than_or_equals, {})
281 | less_than_or_equals_dict[SH.path] = less_than_or_equals
282 | if not less_than_or_equals_dict.get(SH.datatype) and d.get(SH.datatype):
283 | less_than_or_equals_dict[SH.datatype] = d.get(SH.datatype)
284 | sh_properties[less_than_or_equals] = less_than_or_equals_dict
285 | min_constraint = d.get(SH.minInclusive, d.get(SH.minExclusive))
286 | if min_constraint:
287 | less_than_or_equals_dict[SH.minInclusive] = min_constraint
288 |
289 | return shape_dictionary
290 |
291 |
292 | """
293 | Function Explanation:
294 | ---------------------
295 | The 'define_dependencies' function establishes dependencies between properties within a SHACL shape based on the
296 | specified target class. It specifically addresses the 'Person' class, examining properties such as 'gender',
297 | 'givenName', 'familyName', 'name', and 'email', and updates the 'depends_on' list accordingly.
298 |
299 | Parameters:
300 | -----------
301 | dictionary (dict): A dictionary representing a SHACL shape.
302 | - SH.targetClass (rdflib.term.Identifier): The target class of the SHACL shape.
303 | - "properties" (dict): Dictionary containing properties of the SHACL shape.
304 |
305 | Returns:
306 | --------
307 | None: The function modifies the input dictionary in place.
308 |
309 | Explanation:
310 | ------------
311 | - The function begins by retrieving the target class and properties dictionary from the input SHACL shape dictionary.
312 | - It then extracts the last segment of the target class URI as a string for further processing.
313 |
314 | # Handling Dependencies for 'Person' Class Properties
315 | - The function checks if the target class is 'Person' and proceeds to handle dependencies for specific properties.
316 | - Dependencies are established between 'givenName' and 'gender' and between 'name' and 'gender'.
317 | - Additionally, dependencies are considered for 'email' based on other properties such as 'givenName' and 'familyName'.
318 |
319 | # Modifying 'depends_on' Lists
320 | - The function updates the 'depends_on' lists for relevant properties to reflect the established dependencies.
321 |
322 | Note: This function assumes the presence of certain SHACL properties ('gender', 'givenName', 'familyName', 'name',
323 | 'email') and may need adaptation for other contexts.
324 | """
325 |
326 |
327 | def define_dependencies(dictionary):
328 | # Retrieve the target class and properties from the SHACL shape dictionary
329 | t_class = dictionary.get(SH.targetClass)
330 | properties = dictionary.get("properties")
331 |
332 | if t_class:
333 |
334 | # Check if the target class is 'Person'
335 | if t_class == SCH.Person:
336 | # Define URIs for specific properties
337 | gender = URIRef(SCH.gender)
338 | given_name = URIRef(SCH.givenName)
339 | family_name = URIRef(SCH.familyName)
340 | name = URIRef(SCH.name)
341 | email = URIRef(SCH.email)
342 |
343 | # Retrieve dictionaries for each property
344 | gender_dict = properties.get(gender)
345 | given_name_dict = properties.get(given_name)
346 | family_name_dict = properties.get(family_name)
347 | name_dict = properties.get(name)
348 | email_dict = properties.get(email)
349 |
350 | # Check and establish dependencies for 'givenName' and 'gender'
351 | if gender_dict and given_name_dict:
352 | dependency_list = given_name_dict.get('depends_on', [])
353 | dependency_list.append(gender)
354 | given_name_dict['depends_on'] = dependency_list
355 |
356 | # Check and establish dependencies for 'name' and 'gender'
357 | if gender_dict and name_dict:
358 | dependency_list = name_dict.get('depends_on', [])
359 | dependency_list.append(gender)
360 | name_dict['depends_on'] = dependency_list
361 |
362 | # Check and establish dependencies for 'email' based on other properties
363 | if email_dict:
364 | dependency_list = email_dict.get('depends_on', [])
365 |
366 | # Check for 'givenName' and 'familyName' dependencies
367 | if given_name_dict and family_name_dict:
368 | dependency_list.append(given_name)
369 | dependency_list.append(family_name)
370 | # Check for 'name' dependency
371 | elif name_dict:
372 | dependency_list.append(name)
373 | # Check for 'givenName' dependency
374 | elif given_name_dict:
375 | dependency_list.append(given_name)
376 |
377 | email_dict['depends_on'] = dependency_list
378 |
379 |
380 | """
381 | Function Explanation:
382 | ---------------------
383 | The 'generate_dictionary_from_shapes_graph' function creates a dictionary representation of SHACL shapes within an RDF Shapes graph. It utilizes the 'find_node_shapes' function to identify node shapes, and the 'shape_to_dictionary' function to convert each shape into a dictionary format.
384 |
385 | Parameters:
386 | -----------
387 | shapes_graph (rdflib.Graph): The RDF Shapes graph containing SHACL shapes.
388 |
389 | Returns:
390 | --------
391 | dict: A Python dictionary representing SHACL shapes and their properties.
392 |
393 | Explanation:
394 | ------------
395 | - The function begins by identifying all node shapes in the RDF Shapes graph using the 'find_node_shapes' function.
396 | - It initializes an empty dictionary to store the converted shapes.
397 | - For each node shape found, the 'shape_to_dictionary' function is called to convert the shape into a dictionary.
398 | - The resulting dictionary is added to the main dictionary with the node shape URI as the key.
399 |
400 | # Note:
401 | - The function currently calls the 'define_dependencies' function to establish dependencies for each shape. However, this line is commented out, as it may require adaptation based on specific use cases or constraints.
402 |
403 | Note: This function assumes the presence of the 'find_node_shapes' and 'shape_to_dictionary' functions.
404 | """
405 |
406 |
407 | def generate_dictionary_from_shapes_graph(shapes_graph):
408 | # Identify all node shapes in the RDF Shapes graph
409 | node_shapes = find_node_shapes(shapes_graph)
410 |
411 | # Initialize an empty dictionary to store converted shapes
412 | dictionary = {}
413 |
414 | # Process each node shape and convert it into a dictionary
415 | for n in node_shapes:
416 | # Convert the shape into a dictionary
417 | d = shape_to_dictionary(n, shapes_graph, [])
418 |
419 | # Add the dictionary to the main dictionary with the node shape URI as the key
420 | dictionary[n] = d
421 |
422 | return dictionary
423 |
--------------------------------------------------------------------------------
/rdf_graph_gen/datasets/surnames.csv:
--------------------------------------------------------------------------------
1 | Smith
2 | Johnson
3 | Williams
4 | Brown
5 | Jones
6 | Miller
7 | Davis
8 | Garcia
9 | Rodriguez
10 | Wilson
11 | Martinez
12 | Anderson
13 | Taylor
14 | Thomas
15 | Hernandez
16 | Moore
17 | Martin
18 | Jackson
19 | Thompson
20 | White
21 | Lopez
22 | Lee
23 | Gonzalez
24 | Harris
25 | Clark
26 | Lewis
27 | Robinson
28 | Walker
29 | Perez
30 | Hall
31 | Young
32 | Allen
33 | Sanchez
34 | Wright
35 | King
36 | Scott
37 | Green
38 | Baker
39 | Adams
40 | Nelson
41 | Hill
42 | Ramirez
43 | Campbell
44 | Mitchell
45 | Roberts
46 | Carter
47 | Phillips
48 | Evans
49 | Turner
50 | Torres
51 | Parker
52 | Collins
53 | Edwards
54 | Stewart
55 | Flores
56 | Morris
57 | Nguyen
58 | Murphy
59 | Rivera
60 | Cook
61 | Rogers
62 | Morgan
63 | Peterson
64 | Cooper
65 | Reed
66 | Bailey
67 | Bell
68 | Gomez
69 | Kelly
70 | Howard
71 | Ward
72 | Cox
73 | Diaz
74 | Richardson
75 | Wood
76 | Watson
77 | Brooks
78 | Bennett
79 | Gray
80 | James
81 | Reyes
82 | Cruz
83 | Hughes
84 | Price
85 | Myers
86 | Long
87 | Foster
88 | Sanders
89 | Ross
90 | Morales
91 | Powell
92 | Sullivan
93 | Russell
94 | Ortiz
95 | Jenkins
96 | Gutierrez
97 | Perry
98 | Butler
99 | Barnes
100 | Fisher
101 | Henderson
102 | Coleman
103 | Simmons
104 | Patterson
105 | Jordan
106 | Reynolds
107 | Hamilton
108 | Graham
109 | Kim
110 | Gonzales
111 | Alexander
112 | Ramos
113 | Wallace
114 | Griffin
115 | West
116 | Cole
117 | Hayes
118 | Chavez
119 | Gibson
120 | Bryant
121 | Ellis
122 | Stevens
123 | Murray
124 | Ford
125 | Marshall
126 | Owens
127 | Mcdonald
128 | Harrison
129 | Ruiz
130 | Kennedy
131 | Wells
132 | Alvarez
133 | Woods
134 | Mendoza
135 | Castillo
136 | Olson
137 | Webb
138 | Washington
139 | Tucker
140 | Freeman
141 | Burns
142 | Henry
143 | Vasquez
144 | Snyder
145 | Simpson
146 | Crawford
147 | Jimenez
148 | Porter
149 | Mason
150 | Shaw
151 | Gordon
152 | Wagner
153 | Hunter
154 | Romero
155 | Hicks
156 | Dixon
157 | Hunt
158 | Palmer
159 | Robertson
160 | Black
161 | Holmes
162 | Stone
163 | Meyer
164 | Boyd
165 | Mills
166 | Warren
167 | Fox
168 | Rose
169 | Rice
170 | Moreno
171 | Schmidt
172 | Patel
173 | Ferguson
174 | Nichols
175 | Herrera
176 | Medina
177 | Ryan
178 | Fernandez
179 | Weaver
180 | Daniels
181 | Stephens
182 | Gardner
183 | Payne
184 | Kelley
185 | Dunn
186 | Pierce
187 | Arnold
188 | Tran
189 | Spencer
190 | Peters
191 | Hawkins
192 | Grant
193 | Hansen
194 | Castro
195 | Hoffman
196 | Hart
197 | Elliott
198 | Cunningham
199 | Knight
200 | Bradley
201 | Carroll
202 | Hudson
203 | Duncan
204 | Armstrong
205 | Berry
206 | Andrews
207 | Johnston
208 | Ray
209 | Lane
210 | Riley
211 | Carpenter
212 | Perkins
213 | Aguilar
214 | Silva
215 | Richards
216 | Willis
217 | Matthews
218 | Chapman
219 | Lawrence
220 | Garza
221 | Vargas
222 | Watkins
223 | Wheeler
224 | Larson
225 | Carlson
226 | Harper
227 | George
228 | Greene
229 | Burke
230 | Guzman
231 | Morrison
232 | Munoz
233 | Jacobs
234 | Obrien
235 | Lawson
236 | Franklin
237 | Lynch
238 | Bishop
239 | Carr
240 | Salazar
241 | Austin
242 | Mendez
243 | Gilbert
244 | Jensen
245 | Williamson
246 | Montgomery
247 | Harvey
248 | Oliver
249 | Howell
250 | Dean
251 | Hanson
252 | Weber
253 | Garrett
254 | Sims
255 | Burton
256 | Fuller
257 | Soto
258 | Mccoy
259 | Welch
260 | Chen
261 | Schultz
262 | Walters
263 | Reid
264 | Fields
265 | Walsh
266 | Little
267 | Fowler
268 | Bowman
269 | Davidson
270 | May
271 | Day
272 | Schneider
273 | Newman
274 | Brewer
275 | Lucas
276 | Holland
277 | Wong
278 | Banks
279 | Santos
280 | Curtis
281 | Pearson
282 | Delgado
283 | Valdez
284 | Pena
285 | Rios
286 | Douglas
287 | Sandoval
288 | Barrett
289 | Hopkins
290 | Keller
291 | Guerrero
292 | Stanley
293 | Bates
294 | Alvarado
295 | Beck
296 | Ortega
297 | Wade
298 | Estrada
299 | Contreras
300 | Barnett
301 | Caldwell
302 | Santiago
303 | Lambert
304 | Powers
305 | Chambers
306 | Nunez
307 | Craig
308 | Leonard
309 | Lowe
310 | Rhodes
311 | Byrd
312 | Gregory
313 | Shelton
314 | Frazier
315 | Becker
316 | Maldonado
317 | Fleming
318 | Vega
319 | Sutton
320 | Cohen
321 | Jennings
322 | Parks
323 | Mcdaniel
324 | Watts
325 | Barker
326 | Norris
327 | Vaughn
328 | Vazquez
329 | Holt
330 | Schwartz
331 | Steele
332 | Benson
333 | Neal
334 | Dominguez
335 | Horton
336 | Terry
337 | Wolfe
338 | Hale
339 | Lyons
340 | Graves
341 | Haynes
342 | Miles
343 | Park
344 | Warner
345 | Padilla
346 | Bush
347 | Thornton
348 | Mccarthy
349 | Mann
350 | Zimmerman
351 | Erickson
352 | Fletcher
353 | Mckinney
354 | Page
355 | Dawson
356 | Joseph
357 | Marquez
358 | Reeves
359 | Klein
360 | Espinoza
361 | Baldwin
362 | Moran
363 | Love
364 | Robbins
365 | Higgins
366 | Ball
367 | Cortez
368 | Le
369 | Griffith
370 | Bowen
371 | Sharp
372 | Cummings
373 | Ramsey
374 | Hardy
375 | Swanson
376 | Barber
377 | Acosta
378 | Luna
379 | Chandler
380 | Blair
381 | Daniel
382 | Cross
383 | Simon
384 | Dennis
385 | Oconnor
386 | Quinn
387 | Gross
388 | Navarro
389 | Moss
390 | Fitzgerald
391 | Doyle
392 | Mclaughlin
393 | Rojas
394 | Rodgers
395 | Stevenson
396 | Singh
397 | Yang
398 | Figueroa
399 | Harmon
400 | Newton
401 | Paul
402 | Manning
403 | Garner
404 | Mcgee
405 | Reese
406 | Francis
407 | Burgess
408 | Adkins
409 | Goodman
410 | Curry
411 | Brady
412 | Christensen
413 | Potter
414 | Walton
415 | Goodwin
416 | Mullins
417 | Molina
418 | Webster
419 | Fischer
420 | Campos
421 | Avila
422 | Sherman
423 | Todd
424 | Chang
425 | Blake
426 | Malone
427 | Wolf
428 | Hodges
429 | Juarez
430 | Gill
431 | Farmer
432 | Hines
433 | Gallagher
434 | Duran
435 | Hubbard
436 | Cannon
437 | Miranda
438 | Wang
439 | Saunders
440 | Tate
441 | Mack
442 | Hammond
443 | Carrillo
444 | Townsend
445 | Wise
446 | Ingram
447 | Barton
448 | Mejia
449 | Ayala
450 | Schroeder
451 | Hampton
452 | Rowe
453 | Parsons
454 | Frank
455 | Waters
456 | Strickland
457 | Osborne
458 | Maxwell
459 | Chan
460 | Deleon
461 | Norman
462 | Harrington
463 | Casey
464 | Patton
465 | Logan
466 | Bowers
467 | Mueller
468 | Glover
469 | Floyd
470 | Hartman
471 | Buchanan
472 | Cobb
473 | French
474 | Kramer
475 | Mccormick
476 | Clarke
477 | Tyler
478 | Gibbs
479 | Moody
480 | Conner
481 | Sparks
482 | Mcguire
483 | Leon
484 | Bauer
485 | Norton
486 | Pope
487 | Flynn
488 | Hogan
489 | Robles
490 | Salinas
491 | Yates
492 | Lindsey
493 | Lloyd
494 | Marsh
495 | Mcbride
496 | Owen
497 | Solis
498 | Pham
499 | Lang
500 | Pratt
501 | Lara
502 | Brock
503 | Ballard
504 | Trujillo
505 | Shaffer
506 | Drake
507 | Roman
508 | Aguirre
509 | Morton
510 | Stokes
511 | Lamb
512 | Pacheco
513 | Patrick
514 | Cochran
515 | Shepherd
516 | Cain
517 | Burnett
518 | Hess
519 | Li
520 | Cervantes
521 | Olsen
522 | Briggs
523 | Ochoa
524 | Cabrera
525 | Velasquez
526 | Montoya
527 | Roth
528 | Meyers
529 | Cardenas
530 | Fuentes
531 | Weiss
532 | Hoover
533 | Wilkins
534 | Nicholson
535 | Underwood
536 | Short
537 | Carson
538 | Morrow
539 | Colon
540 | Holloway
541 | Summers
542 | Bryan
543 | Petersen
544 | Mckenzie
545 | Serrano
546 | Wilcox
547 | Carey
548 | Clayton
549 | Poole
550 | Calderon
551 | Gallegos
552 | Greer
553 | Rivas
554 | Guerra
555 | Decker
556 | Collier
557 | Wall
558 | Whitaker
559 | Bass
560 | Flowers
561 | Davenport
562 | Conley
563 | Houston
564 | Huff
565 | Copeland
566 | Hood
567 | Monroe
568 | Massey
569 | Roberson
570 | Combs
571 | Franco
572 | Larsen
573 | Pittman
574 | Randall
575 | Skinner
576 | Wilkinson
577 | Kirby
578 | Cameron
579 | Bridges
580 | Anthony
581 | Richard
582 | Kirk
583 | Bruce
584 | Singleton
585 | Mathis
586 | Bradford
587 | Boone
588 | Abbott
589 | Charles
590 | Allison
591 | Sweeney
592 | Atkinson
593 | Horn
594 | Jefferson
595 | Rosales
596 | York
597 | Christian
598 | Phelps
599 | Farrell
600 | Castaneda
601 | Nash
602 | Dickerson
603 | Bond
604 | Wyatt
605 | Foley
606 | Chase
607 | Gates
608 | Vincent
609 | Mathews
610 | Hodge
611 | Garrison
612 | Trevino
613 | Villarreal
614 | Heath
615 | Dalton
616 | Valencia
617 | Callahan
618 | Hensley
619 | Atkins
620 | Huffman
621 | Roy
622 | Boyer
623 | Shields
624 | Lin
625 | Hancock
626 | Grimes
627 | Glenn
628 | Cline
629 | Delacruz
630 | Camacho
631 | Dillon
632 | Parrish
633 | Oneill
634 | Melton
635 | Booth
636 | Kane
637 | Berg
638 | Harrell
639 | Pitts
640 | Savage
641 | Wiggins
642 | Brennan
643 | Salas
644 | Marks
645 | Russo
646 | Sawyer
647 | Baxter
648 | Golden
649 | Hutchinson
650 | Liu
651 | Walter
652 | Mcdowell
653 | Wiley
654 | Rich
655 | Humphrey
656 | Johns
657 | Koch
658 | Suarez
659 | Hobbs
660 | Beard
661 | Gilmore
662 | Ibarra
663 | Keith
664 | Macias
665 | Khan
666 | Andrade
667 | Ware
668 | Stephenson
669 | Henson
670 | Wilkerson
671 | Dyer
672 | Mcclure
673 | Blackwell
674 | Mercado
675 | Tanner
676 | Eaton
677 | Clay
678 | Barron
679 | Beasley
680 | Oneal
681 | Preston
682 | Small
683 | Wu
684 | Zamora
685 | Macdonald
686 | Vance
687 | Snow
688 | Mcclain
689 | Stafford
690 | Orozco
691 | Barry
692 | English
693 | Shannon
694 | Kline
695 | Jacobson
696 | Woodard
697 | Huang
698 | Kemp
699 | Mosley
700 | Prince
701 | Merritt
702 | Hurst
703 | Villanueva
704 | Roach
705 | Nolan
706 | Lam
707 | Yoder
708 | Mccullough
709 | Lester
710 | Santana
711 | Valenzuela
712 | Winters
713 | Barrera
714 | Leach
715 | Orr
716 | Berger
717 | Mckee
718 | Strong
719 | Conway
720 | Stein
721 | Whitehead
722 | Bullock
723 | Escobar
724 | Knox
725 | Meadows
726 | Solomon
727 | Velez
728 | Odonnell
729 | Kerr
730 | Stout
731 | Blankenship
732 | Browning
733 | Kent
734 | Lozano
735 | Bartlett
736 | Pruitt
737 | Buck
738 | Barr
739 | Gaines
740 | Durham
741 | Gentry
742 | Mcintyre
743 | Sloan
744 | Rocha
745 | Melendez
746 | Herman
747 | Sexton
748 | Moon
749 | Hendricks
750 | Rangel
751 | Stark
752 | Lowery
753 | Hardin
754 | Hull
755 | Sellers
756 | Ellison
757 | Calhoun
758 | Gillespie
759 | Mora
760 | Knapp
761 | Mccall
762 | Morse
763 | Dorsey
764 | Weeks
765 | Nielsen
766 | Livingston
767 | Leblanc
768 | Mclean
769 | Bradshaw
770 | Glass
771 | Middleton
772 | Buckley
773 | Schaefer
774 | Frost
775 | Howe
776 | House
777 | Mcintosh
778 | Ho
779 | Pennington
780 | Reilly
781 | Hebert
782 | Mcfarland
783 | Hickman
784 | Noble
785 | Spears
786 | Conrad
787 | Arias
788 | Galvan
789 | Velazquez
790 | Huynh
791 | Frederick
792 | Randolph
793 | Cantu
794 | Fitzpatrick
795 | Mahoney
796 | Peck
797 | Villa
798 | Michael
799 | Donovan
800 | Mcconnell
801 | Walls
802 | Boyle
803 | Mayer
804 | Zuniga
805 | Giles
806 | Pineda
807 | Pace
808 | Hurley
809 | Mays
810 | Mcmillan
811 | Crosby
812 | Ayers
813 | Case
814 | Bentley
815 | Shepard
816 | Everett
817 | Pugh
818 | David
819 | Mcmahon
820 | Dunlap
821 | Bender
822 | Hahn
823 | Harding
824 | Acevedo
825 | Raymond
826 | Blackburn
827 | Duffy
828 | Landry
829 | Dougherty
830 | Bautista
831 | Shah
832 | Potts
833 | Arroyo
834 | Valentine
835 | Meza
836 | Gould
837 | Vaughan
838 | Fry
839 | Rush
840 | Avery
841 | Herring
842 | Dodson
843 | Clements
844 | Sampson
845 | Tapia
846 | Bean
847 | Lynn
848 | Crane
849 | Farley
850 | Cisneros
851 | Benton
852 | Ashley
853 | Mckay
854 | Finley
855 | Best
856 | Blevins
857 | Friedman
858 | Moses
859 | Sosa
860 | Blanchard
861 | Huber
862 | Frye
863 | Krueger
864 | Bernard
865 | Rosario
866 | Rubio
867 | Mullen
868 | Benjamin
869 | Haley
870 | Chung
871 | Moyer
872 | Choi
873 | Horne
874 | Yu
875 | Woodward
876 | Ali
877 | Nixon
878 | Hayden
879 | Rivers
880 | Estes
881 | Mccarty
882 | Richmond
883 | Stuart
884 | Maynard
885 | Brandt
886 | Oconnell
887 | Hanna
888 | Sanford
889 | Sheppard
890 | Church
891 | Burch
892 | Levy
893 | Rasmussen
894 | Coffey
895 | Ponce
896 | Faulkner
897 | Donaldson
898 | Schmitt
899 | Novak
900 | Costa
901 | Montes
902 | Booker
903 | Cordova
904 | Waller
905 | Arellano
906 | Maddox
907 | Mata
908 | Bonilla
909 | Stanton
910 | Compton
911 | Kaufman
912 | Dudley
913 | Mcpherson
914 | Beltran
915 | Dickson
916 | Mccann
917 | Villegas
918 | Proctor
919 | Hester
920 | Cantrell
921 | Daugherty
922 | Cherry
923 | Bray
924 | Davila
925 | Rowland
926 | Levine
927 | Madden
928 | Spence
929 | Good
930 | Irwin
931 | Werner
932 | Krause
933 | Petty
934 | Whitney
935 | Baird
936 | Hooper
937 | Pollard
938 | Zavala
939 | Jarvis
940 | Holden
941 | Haas
942 | Hendrix
943 | Mcgrath
944 | Bird
945 | Lucero
946 | Terrell
947 | Riggs
948 | Joyce
949 | Mercer
950 | Rollins
951 | Galloway
952 | Duke
953 | Odom
954 | Andersen
955 | Downs
956 | Hatfield
957 | Benitez
958 | Archer
959 | Huerta
960 | Travis
961 | Mcneil
962 | Hinton
963 | Zhang
964 | Hays
965 | Mayo
966 | Fritz
967 | Branch
968 | Mooney
969 | Ewing
970 | Ritter
971 | Esparza
972 | Frey
973 | Braun
974 | Gay
975 | Riddle
976 | Haney
977 | Kaiser
978 | Holder
979 | Chaney
980 | Mcknight
981 | Gamble
982 | Vang
983 | Cooley
984 | Carney
985 | Cowan
986 | Forbes
987 | Ferrell
988 | Davies
989 | Barajas
990 | Shea
991 | Osborn
992 | Bright
993 | Cuevas
994 | Bolton
995 | Murillo
996 | Lutz
997 | Duarte
998 | Kidd
999 | Key
1000 | Cooke
1001 | Goff
1002 | Dejesus
1003 | Marin
1004 | Dotson
1005 | Bonner
1006 | Cotton
1007 | Merrill
1008 | Lindsay
1009 | Lancaster
1010 | Mcgowan
1011 | Felix
1012 | Salgado
1013 | Slater
1014 | Carver
1015 | Guthrie
1016 | Holman
1017 | Fulton
1018 | Snider
1019 | Sears
1020 | Witt
1021 | Newell
1022 | Byers
1023 | Lehman
1024 | Gorman
1025 | Costello
1026 | Donahue
1027 | Delaney
1028 | Albert
1029 | Workman
1030 | Rosas
1031 | Springer
1032 | Kinney
1033 | Justice
1034 | Odell
1035 | Lake
1036 | Donnelly
1037 | Law
1038 | Dailey
1039 | Guevara
1040 | Shoemaker
1041 | Barlow
1042 | Marino
1043 | Winter
1044 | Craft
1045 | Katz
1046 | Pickett
1047 | Espinosa
1048 | Maloney
1049 | Daly
1050 | Goldstein
1051 | Crowley
1052 | Vogel
1053 | Kuhn
1054 | Pearce
1055 | Hartley
1056 | Cleveland
1057 | Palacios
1058 | Mcfadden
1059 | Britt
1060 | Wooten
1061 | Cortes
1062 | Dillard
1063 | Childers
1064 | Alford
1065 | Dodd
1066 | Emerson
1067 | Wilder
1068 | Lange
1069 | Goldberg
1070 | Quintero
1071 | Beach
1072 | Enriquez
1073 | Quintana
1074 | Helms
1075 | Mackey
1076 | Finch
1077 | Cramer
1078 | Minor
1079 | Flanagan
1080 | Franks
1081 | Corona
1082 | Kendall
1083 | Mccabe
1084 | Hendrickson
1085 | Moser
1086 | Mcdermott
1087 | Camp
1088 | Mcleod
1089 | Bernal
1090 | Kaplan
1091 | Medrano
1092 | Lugo
1093 | Tracy
1094 | Bacon
1095 | Crowe
1096 | Richter
1097 | Welsh
1098 | Holley
1099 | Ratliff
1100 | Mayfield
1101 | Talley
1102 | Haines
1103 | Dale
1104 | Gibbons
1105 | Hickey
1106 | Byrne
1107 | Kirkland
1108 | Farris
1109 | Correa
1110 | Tillman
1111 | Sweet
1112 | Kessler
1113 | England
1114 | Hewitt
1115 | Blanco
1116 | Connolly
1117 | Pate
1118 | Elder
1119 | Bruno
1120 | Holcomb
1121 | Hyde
1122 | Mcallister
1123 | Cash
1124 | Christopher
1125 | Whitfield
1126 | Meeks
1127 | Hatcher
1128 | Fink
1129 | Sutherland
1130 | Noel
1131 | Ritchie
1132 | Rosa
1133 | Leal
1134 | Joyner
1135 | Starr
1136 | Morin
1137 | Delarosa
1138 | Connor
1139 | Hilton
1140 | Alston
1141 | Gilliam
1142 | Wynn
1143 | Wills
1144 | Jaramillo
1145 | Oneil
1146 | Nieves
1147 | Britton
1148 | Rankin
1149 | Belcher
1150 | Guy
1151 | Chamberlain
1152 | Tyson
1153 | Puckett
1154 | Downing
1155 | Sharpe
1156 | Boggs
1157 | Truong
1158 | Pierson
1159 | Godfrey
1160 | Mobley
1161 | John
1162 | Kern
1163 | Dye
1164 | Hollis
1165 | Bravo
1166 | Magana
1167 | Rutherford
1168 | Ng
1169 | Tuttle
1170 | Lim
1171 | Romano
1172 | Trejo
1173 | Arthur
1174 | Knowles
1175 | Lyon
1176 | Shirley
1177 | Quinones
1178 | Childs
1179 | Dolan
1180 | Head
1181 | Reyna
1182 | Saenz
1183 | Hastings
1184 | Kenney
1185 | Cano
1186 | Foreman
1187 | Denton
1188 | Villalobos
1189 | Pryor
1190 | Sargent
1191 | Doherty
1192 | Hopper
1193 | Phan
1194 | Womack
1195 | Lockhart
1196 | Ventura
1197 | Dwyer
1198 | Muller
1199 | Galindo
1200 | Grace
1201 | Sorensen
1202 | Courtney
1203 | Parra
1204 | Rodrigues
1205 | Nicholas
1206 | Ahmed
1207 | Mcginnis
1208 | Langley
1209 | Madison
1210 | Locke
1211 | Jamison
1212 | Nava
1213 | Gustafson
1214 | Sykes
1215 | Dempsey
1216 | Hamm
1217 | Rodriquez
1218 | Mcgill
1219 | Xiong
1220 | Esquivel
1221 | Simms
1222 | Kendrick
1223 | Boyce
1224 | Vigil
1225 | Downey
1226 | Mckenna
1227 | Sierra
1228 | Webber
1229 | Kirkpatrick
1230 | Dickinson
1231 | Couch
1232 | Burks
1233 | Sheehan
1234 | Slaughter
1235 | Pike
1236 | Whitley
1237 | Magee
1238 | Cheng
1239 | Sinclair
1240 | Cassidy
1241 | Rutledge
1242 | Burris
1243 | Bowling
1244 | Crabtree
1245 | Mcnamara
1246 | Avalos
1247 | Vu
1248 | Herron
1249 | Broussard
1250 | Abraham
1251 | Garland
1252 | Corbett
1253 | Corbin
1254 | Stinson
1255 | Chin
1256 | Burt
1257 | Hutchins
1258 | Woodruff
1259 | Lau
1260 | Brandon
1261 | Singer
1262 | Hatch
1263 | Rossi
1264 | Shafer
1265 | Ott
1266 | Goss
1267 | Gregg
1268 | Dewitt
1269 | Tang
1270 | Polk
1271 | Worley
1272 | Covington
1273 | Saldana
1274 | Heller
1275 | Emery
1276 | Swartz
1277 | Cho
1278 | Mccray
1279 | Elmore
1280 | Rosenberg
1281 | Simons
1282 | Clemons
1283 | Beatty
1284 | Harden
1285 | Herbert
1286 | Bland
1287 | Rucker
1288 | Manley
1289 | Ziegler
1290 | Grady
1291 | Lott
1292 | Rouse
1293 | Gleason
1294 | Mcclellan
1295 | Abrams
1296 | Vo
1297 | Albright
1298 | Meier
1299 | Dunbar
1300 | Ackerman
1301 | Padgett
1302 | Mayes
1303 | Tipton
1304 | Coffman
1305 | Peralta
1306 | Shapiro
1307 | Roe
1308 | Weston
1309 | Plummer
1310 | Helton
1311 | Stern
1312 | Fraser
1313 | Stover
1314 | Fish
1315 | Schumacher
1316 | Baca
1317 | Curran
1318 | Vinson
1319 | Vera
1320 | Clifton
1321 | Ervin
1322 | Eldridge
1323 | Lowry
1324 | Childress
1325 | Becerra
1326 | Gore
1327 | Seymour
1328 | Chu
1329 | Field
1330 | Akers
1331 | Carrasco
1332 | Bingham
1333 | Sterling
1334 | Greenwood
1335 | Leslie
1336 | Groves
1337 | Manuel
1338 | Swain
1339 | Edmonds
1340 | Muniz
1341 | Thomson
1342 | Crouch
1343 | Walden
1344 | Smart
1345 | Tomlinson
1346 | Alfaro
1347 | Quick
1348 | Goldman
1349 | Mcelroy
1350 | Yarbrough
1351 | Funk
1352 | Hong
1353 | Portillo
1354 | Lund
1355 | Ngo
1356 | Elkins
1357 | Stroud
1358 | Meredith
1359 | Battle
1360 | Mccauley
1361 | Zapata
1362 | Bloom
1363 | Gee
1364 | Givens
1365 | Cardona
1366 | Schafer
1367 | Robison
1368 | Gunter
1369 | Griggs
1370 | Tovar
1371 | Teague
1372 | Swift
1373 | Bowden
1374 | Schulz
1375 | Blanton
1376 | Buckner
1377 | Whalen
1378 | Pritchard
1379 | Pierre
1380 | Kang
1381 | Metcalf
1382 | Butts
1383 | Kurtz
1384 | Sanderson
1385 | Tompkins
1386 | Inman
1387 | Crowder
1388 | Dickey
1389 | Hutchison
1390 | Conklin
1391 | Hoskins
1392 | Holbrook
1393 | Horner
1394 | Neely
1395 | Tatum
1396 | Hollingsworth
1397 | Draper
1398 | Clement
1399 | Lord
1400 | Reece
1401 | Feldman
1402 | Kay
1403 | Hagen
1404 | Crews
1405 | Bowles
1406 | Post
1407 | Jewell
1408 | Daley
1409 | Cordero
1410 | Mckinley
1411 | Velasco
1412 | Masters
1413 | Driscoll
1414 | Burrell
1415 | Valle
1416 | Crow
1417 | Devine
1418 | Larkin
1419 | Chappell
1420 | Pollock
1421 | Ly
1422 | Kimball
1423 | Schmitz
1424 | Lu
1425 | Rubin
1426 | Self
1427 | Barrios
1428 | Pereira
1429 | Phipps
1430 | Mcmanus
1431 | Nance
1432 | Steiner
1433 | Poe
1434 | Crockett
1435 | Jeffries
1436 | Amos
1437 | Nix
1438 | Newsome
1439 | Dooley
1440 | Payton
1441 | Rosen
1442 | Swenson
1443 | Connelly
1444 | Tolbert
1445 | Segura
1446 | Esposito
1447 | Coker
1448 | Biggs
1449 | Hinkle
1450 | Thurman
1451 | Drew
1452 | Ivey
1453 | Bullard
1454 | Baez
1455 | Neff
1456 | Maher
1457 | Stratton
1458 | Egan
1459 | Dubois
1460 | Gallardo
1461 | Blue
1462 | Rainey
1463 | Yeager
1464 | Saucedo
1465 | Ferreira
1466 | Sprague
1467 | Lacy
1468 | Hurtado
1469 | Heard
1470 | Connell
1471 | Stahl
1472 | Aldridge
1473 | Amaya
1474 | Forrest
1475 | Erwin
1476 | Gunn
1477 | Swan
1478 | Butcher
1479 | Rosado
1480 | Godwin
1481 | Hand
1482 | Gabriel
1483 | Otto
1484 | Whaley
1485 | Ludwig
1486 | Clifford
1487 | Grove
1488 | Beaver
1489 | Silver
1490 | Dang
1491 | Hammer
1492 | Dick
1493 | Boswell
1494 | Mead
1495 | Colvin
1496 | Oleary
1497 | Milligan
1498 | Goins
1499 | Ames
1500 | Dodge
1501 |
--------------------------------------------------------------------------------
/rdf_graph_gen/value_generators.py:
--------------------------------------------------------------------------------
1 | import csv
2 | import math
3 | import random
4 | from exrex import *
5 | from exrex import _randone
6 | from rdflib import XSD, Literal, URIRef, Namespace
7 | from datetime import date
8 | from dateutil.relativedelta import relativedelta
9 | from rdf_graph_gen.shacl_mapping_generator import SCH
10 | import pkg_resources
11 | import warnings
12 |
13 | """
14 | Reads data from a CSV file and returns the content as a list of values.
15 |
16 | Parameters:
17 | -----------
18 | file_name (str): The name of the CSV file from which data will be read.
19 |
20 | Returns:
21 | --------
22 | list: A list containing the values read from the CSV file.
23 | """
24 |
25 |
26 | def get_path(file_name):
27 | file_path = pkg_resources.resource_filename('rdf_graph_gen', f'datasets/{file_name}')
28 | return file_path
29 |
30 |
31 | def get_array_from_csv(file_name):
32 | results = [] # Initialize an empty list to store the values
33 | with open(file_name, encoding='utf-8') as csvfile:
34 | reader = csv.reader(csvfile)
35 | for row in reader: # Iterate through each row in the CSV file
36 | results = results + row # Append values from each row to the results list
37 | return results # Return the list containing values from the CSV file
38 |
39 | dataset_dictionary = {'streetAddress': get_array_from_csv(get_path("street_name.csv")),
40 | 'givenNameMale': get_array_from_csv(get_path("male_first_name.csv")),
41 | 'givenNameFemale': get_array_from_csv(get_path("female_first_name.csv")),
42 | 'familyName': get_array_from_csv(get_path("surnames.csv")),
43 | 'gender': ['male', 'female', 'non-binary'],
44 | 'jobTitle': get_array_from_csv(get_path("job_title.csv")),
45 | 'bookAward': get_array_from_csv(get_path("book_awards.csv")),
46 | 'bookGenre': get_array_from_csv(get_path("book_genre.csv")),
47 | 'bookTitle': get_array_from_csv(get_path("book_titles.csv")),
48 | 'movieGenre': get_array_from_csv(get_path("movie_genre.csv")),
49 | 'movieAward': get_array_from_csv(get_path("movie_awards.csv")),
50 | 'movieTitle': get_array_from_csv(get_path("movie_titles.csv")),
51 | 'tvSeriesTitle': get_array_from_csv(get_path("tvseries_titles.csv"))
52 | }
53 |
54 |
55 | def getBookFormat():
56 | return URIRef(SCH[random.choice(["AudiobookFormat", "EBook", "GraphicNovel", "Hardcover", "Paperback"])])
57 |
58 |
59 | def get_date_between_two_dates(date1, date2):
60 | days_between = relativedelta(date2, date1).days
61 | months_between = relativedelta(date2, date1).months
62 | years_between = relativedelta(date2, date1).years
63 |
64 | increase = random.random()
65 | new_days = relativedelta(days=int(days_between * increase))
66 | new_months = relativedelta(months=int(months_between * increase))
67 | new_years = relativedelta(years=int(years_between * increase))
68 |
69 | between_date = date1 + new_years + new_months + new_days
70 | return between_date
71 |
72 |
73 | def add_to_date(date1, years, months, days):
74 | time_addition = relativedelta(days=days, months=months, years=years)
75 | return time_addition + date1
76 |
77 |
78 | # The min_length, max_length, pattern, disjoint, has_value properties are not taken into account at this point for date
79 | # generation
80 | def generate_date(existing_values, min_exclusive, min_inclusive, max_exclusive, max_inclusive, less_than, less_than_or_equals):
81 | min_date, max_date = None, None
82 | if min_inclusive or min_exclusive:
83 | min_date = date.fromisoformat(min_inclusive) if min_inclusive else add_to_date(
84 | date.fromisoformat(min_exclusive), 0, 0, +1)
85 | if max_inclusive or max_exclusive:
86 | max_date = date.fromisoformat(max_inclusive) if max_inclusive else add_to_date(
87 | date.fromisoformat(max_exclusive), 0, 0, -1)
88 | if less_than_or_equals and len(less_than_or_equals) > 0:
89 | max_date = date.fromisoformat(min(less_than_or_equals))
90 | if less_than and len(less_than) > 0:
91 | max_date = date.fromisoformat(min(less_than))
92 | if max_date:
93 | if min_date:
94 | if max_date < min_date:
95 | # raise Exception("A conflicting date definition")
96 | min_date_replacement = add_to_date(max_date, -50, 0, 0)
97 | warnings.warn(f"Invalid date range: ({min_date}, {max_date}). The range will be changed to: ({min_date_replacement}, {max_date}).", stacklevel=2)
98 | min_date = min_date_replacement
99 | else:
100 | min_date = add_to_date(max_date, -50, 0, 0)
101 | else:
102 | if not min_date:
103 | min_date = date.fromisoformat('1970-07-07')
104 | max_date = add_to_date(min_date, 50, 0, 0)
105 |
106 | # Find a value in interval that is not allready generated
107 | date_value_down = date_value_up = get_date_between_two_dates(min_date, max_date)
108 |
109 | while date_value_up <= max_date:
110 | if date_value_up not in existing_values:
111 | return date_value_up
112 | date_value_up = add_to_date(date_value_up, 0, 0, 1)
113 |
114 | while date_value_down >= min_date:
115 | if date_value_down not in existing_values:
116 | return date_value_down
117 | date_value_down = add_to_date(date_value_down, 0, 0, -1)
118 |
119 | return None
120 |
121 |
122 |
123 | # The min_length, max_length, pattern, disjoint, has_value properties are not taken into account at this point for
124 | # integer generation
125 | def generate_integer(existing_values, min_exclusive, min_inclusive, max_exclusive, max_inclusive, less_than, less_than_or_equals):
126 | min_int, max_int = None, None
127 | if min_inclusive is not None or min_exclusive is not None:
128 | min_int = int(min_inclusive) if min_inclusive is not None else int(min_exclusive) + 1
129 | if max_inclusive is not None or max_exclusive is not None:
130 | max_int = int(max_inclusive) if max_inclusive is not None else int(max_exclusive) - 1
131 | if less_than_or_equals and len(less_than_or_equals) > 0:
132 | max_int = int(min(less_than_or_equals))
133 | if less_than and len(less_than) > 0:
134 | max_int = int(min(less_than) - 1)
135 | if max_int is not None:
136 | if min_int is not None:
137 | if max_int < min_int:
138 | min_int_replacement = max_int - 50
139 | warnings.warn(f"Invalid int range: ({min_int}, {max_int}). The range will be changed to: ({min_int_replacement}, {max_int}).", stacklevel=2)
140 | min_int = min_int_replacement
141 | else:
142 | min_int = max_int - 50
143 | else:
144 | if min_int is None:
145 | min_int = 1
146 | max_int = min_int + 50
147 |
148 | # Find a value in interval that is not allready generated
149 | int_value_down = int_value_up = random.randint(min_int, max_int)
150 |
151 | while int_value_up <= max_int:
152 | if int_value_up not in existing_values:
153 | return Literal(int_value_up)
154 | int_value_up += 1
155 |
156 | while int_value_down >= min_int:
157 | if int_value_down not in existing_values:
158 | return Literal(int_value_down)
159 | int_value_down -= 1
160 |
161 | return None
162 |
163 |
164 | # The min_length, max_length, pattern, disjoint, has_value properties are not taken into account at this point for
165 | # decimal generation
166 | def generate_decimal(existing_values, min_exclusive, min_inclusive, max_exclusive, max_inclusive, less_than, less_than_or_equals):
167 | min_float, max_float = None, None
168 | if min_inclusive is not None or min_exclusive is not None:
169 | min_float = float(min_inclusive) if min_inclusive is not None else math.nextafter(float(min_exclusive), +math.inf)
170 | if max_inclusive or max_exclusive:
171 | max_float = float(max_inclusive) if max_inclusive is not None else math.nextafter(float(max_exclusive), -math.inf)
172 | if less_than_or_equals and len(less_than_or_equals) > 0:
173 | max_float = float(min(less_than_or_equals))
174 | if less_than and len(less_than) > 0:
175 | max_float = math.nextafter(float(min(less_than)), -math.inf)
176 | if max_float is not None:
177 | if min_float is not None:
178 | if max_float < min_float:
179 | min_float_replacement = max_float - 50
180 | warnings.warn(f"Invalid float range: ({min_float}, {max_float}). The range will be changed to: ({min_float_replacement}, {max_float}).", stacklevel=2)
181 | min_float = min_float_replacement
182 | else:
183 | min_float = max_float - 50
184 | else:
185 | if min_float is None:
186 | min_float = 1
187 | max_float = min_float + 50
188 |
189 | # Prevention from regenerating the same float value again.
190 | # Should not be stuck in an infinite loop, its a 4-decimal float
191 | float_value = random.uniform(min_float, max_float)
192 | while float_value in existing_values:
193 | float_value = random.uniform(min_float, max_float, 4)
194 | return Literal(float_value)
195 |
196 |
197 | # The min_exclusive, min_inclusive, max_exclusive, max_inclusive, disjoint, less_than, less_than_or_equals, has_value
198 | # properties are not taken into account at this point for string generation
199 | def generate_string(existing_values, min_length, max_length, pattern):
200 |
201 | # If pattern is present, generate a literal using it.
202 | # Try to find a value that is not allready generated 10 times, if u cant, give up.
203 | if pattern:
204 | for i in range(10):
205 | literal = _randone(parse(pattern))
206 | if literal not in existing_values:
207 | return Literal(literal)
208 | return None
209 |
210 | if min_length:
211 | min_length = int(min_length)
212 | if max_length:
213 | max_length = int(max_length)
214 | if min_length > max_length:
215 | max_length_replacement = min_length + 10
216 | warnings.warn(f"Invalid string length range: ({min_length}, {max_length}). The range will be changed to: ({min_length}, {max_length_replacement}).", stacklevel=2)
217 | max_length = max_length_replacement
218 | else:
219 | max_length = min_length + 10
220 | else:
221 | if max_length:
222 | max_length = int(max_length)
223 | min_length = max_length - 5 if max_length > 5 else 0
224 | else:
225 | min_length, max_length = 8, 15
226 |
227 | # If a pattern is not present, use this one
228 | pattern = '^([a-zA-Z0-9])*'
229 | # Try to find a value that is not allready generated 10 times, if u cant, give up.
230 | for i in range(10):
231 | length = random.randint(min_length, max_length)
232 | strp = ''
233 | while len(strp) < length:
234 | strp = strp + _randone(parse(pattern))
235 | if len(strp) > length:
236 | strp = strp[:length]
237 | if strp not in existing_values:
238 | return Literal(strp)
239 |
240 | return None
241 |
242 |
243 | """
244 | Generate a random value based on the specified constraints for a given SHACL property.
245 |
246 | Parameters:
247 | - datatype (URIRef): The datatype of the SHACL property.
248 | - min_exclusive, min_inclusive, max_exclusive, max_inclusive: Numeric constraints for the property.
249 | - min_length, max_length: String length constraints.
250 | - pattern (str): Regular expression pattern for string values.
251 | - equals, disjoint, less_than, less_than_or_equals, has_value: Specific constraints for certain values.
252 | - path (URIRef): SHACL path for the property.
253 | - sh_class (URIRef): SHACL class to which the property belongs.
254 |
255 | Returns:
256 | - Literal or None: The generated RDF literal value for the SHACL property, or None if it cannot be generated.
257 |
258 | Explanation:
259 | - The function starts by extracting the specific class (cl) and property path (path) from the given SHACL class.
260 | - It handles special cases and applies standard constraints based on the SHACL class and property path.
261 | - For specific properties like 'isbn', 'numberOfPages', 'abridged', 'bookEdition', 'date', 'number', 'email',
262 | and 'telephone', it sets standard data types and patterns if not explicitly specified.
263 | - If constraints like 'equals' are specified, the function returns the specified value.
264 | - For different data types (integer, decimal, boolean, date, string), it invokes specific helper functions
265 | to generate values based on constraints.
266 | - The function returns the generated value or None if a value cannot be generated based on constraints.
267 | """
268 |
269 |
270 | def generate_default_value(existing_values, datatype, min_exclusive, min_inclusive, max_exclusive, max_inclusive, min_length, max_length,
271 | pattern, equals, disjoint, less_than, less_than_or_equals, path, sh_class):
272 |
273 | # Return specified value if 'equals' constraint is present
274 | if equals:
275 | return equals
276 |
277 | # Extract the class and property path from URIs
278 | cl = str(sh_class).split('/')[-1]
279 | path = str(path).split('/')[-1]
280 |
281 | # Apply default datatype and pattern for certain property paths
282 | if ('date' in path or 'Date' in path) and not datatype:
283 | datatype = XSD.date
284 | elif ('number' in path or 'Number' in path) and not datatype:
285 | datatype = XSD.integer
286 |
287 | # Apply default patterns for certain property paths
288 | elif 'email' in path and not pattern:
289 | pattern = '([a-z0-9]+[_])*[A-Za-z0-9]@gmail.com'
290 | elif 'telephone' in path and not pattern:
291 | pattern = '^(([0-9]{3})|[0-9]{3}-)[0-9]{3}-[0-9]{4}$'
292 |
293 | # Special handling for certain properties and their constraints
294 | if cl == 'Person':
295 | if 'taxID' == path and not pattern:
296 | pattern = '[0-9]{9}'
297 | if cl == 'Book':
298 | if 'isbn' in path and not pattern:
299 | pattern = '[0-9]{3}-[0-9]-[0-9]{2}-[0-9]{6}-[0-9]'
300 | elif 'numberOfPages' in path and not datatype:
301 | datatype = XSD.integer
302 | if not min_inclusive:
303 | min_inclusive = 100
304 | elif 'abridged' in path and not datatype:
305 | datatype = XSD.boolean
306 | elif 'bookEdition' in path and not datatype:
307 | datatype = XSD.integer
308 |
309 | # Generate values based on datatype and constraints
310 | if datatype == XSD.integer:
311 | return generate_integer(existing_values, min_exclusive, min_inclusive, max_exclusive, max_inclusive, less_than,
312 | less_than_or_equals)
313 | elif datatype == XSD.decimal:
314 | return generate_decimal(existing_values, min_exclusive, min_inclusive, max_exclusive, max_inclusive, less_than,
315 | less_than_or_equals)
316 | elif datatype == XSD.boolean:
317 | return Literal(bool(random.getrandbits(1)))
318 | elif datatype == XSD.date:
319 | date = generate_date(existing_values, min_exclusive, min_inclusive, max_exclusive, max_inclusive, less_than,
320 | less_than_or_equals)
321 | if date:
322 | return Literal(date)
323 | return None
324 |
325 | # Default case: Generate a string value
326 | return generate_string(existing_values, min_length, max_length, pattern)
327 |
328 |
329 | """
330 | Function Explanation:
331 | ---------------------
332 | The 'get_predefined_value' function generates predefined values for specific SHACL properties based on the provided
333 | constraints. It handles different cases for SHACL classes such as 'Person', 'Book', 'Movie', and 'TVSeries' and
334 | generates values accordingly.
335 |
336 | Parameters:
337 | -----------
338 | sh_path (rdflib.term.Identifier): SHACL property for which to generate a predefined value.
339 | sh_class (rdflib.term.Identifier): SHACL class to which the property belongs.
340 | dependencies (dict): Dictionary containing required dependencies for generating predefined values.
341 |
342 | Returns:
343 | --------
344 | rdflib.term.Literal or None: The generated predefined value or None if a predefined value cannot be generated.
345 |
346 | Explanation:
347 | ------------
348 | - The function starts by extracting the specific property ('prop') and class ('cl') from the given SHACL path and class.
349 | - For each case (class-property combination), it generates a predefined value using the 'values_dict' dictionary.
350 | - The function supports various properties such as 'givenName', 'familyName', 'name', 'streetAddress', 'gender',
351 | 'jobTitle', 'bookTitle', 'bookAward', 'bookGenre', 'movieTitle', 'movieAward', 'movieGenre', 'tvSeriesTitle', etc.
352 | - 'random.choice' is used to select values from predefined data, ensuring diversity in the generated values.
353 | - The function returns the generated predefined value or None if a predefined value cannot be generated for the given constraints.
354 | """
355 |
356 |
357 | def generate_intuitive_value(sh_path, sh_class, dependencies):
358 |
359 | # Handle cases for Person class
360 | if sh_class == SCH.Person:
361 | gender = URIRef(SCH.gender)
362 | given_name = URIRef(SCH.givenName)
363 | family_name = URIRef(SCH.familyName)
364 | name = URIRef(SCH.name)
365 |
366 | if sh_path == SCH.additionalName or sh_path == SCH.givenName:
367 | # Generate predefined value based on gender dependency
368 | gender = str(dependencies.get(gender, ["none"])[0])
369 | if gender in (SCH.Female, 'female', 'f', 'fem'):
370 | return Literal(random.choice(dataset_dictionary.get('givenNameFemale')))
371 | elif gender in (SCH.Male, 'male', 'm'):
372 | return Literal(random.choice(dataset_dictionary.get('givenNameMale')))
373 | else:
374 | return Literal(
375 | random.choice(dataset_dictionary.get('givenNameMale') + dataset_dictionary.get('givenNameFemale')))
376 |
377 | if sh_path == SCH.email:
378 | given_name = dependencies.get(given_name)
379 | family_name = dependencies.get(family_name)
380 | name = dependencies.get(name)
381 |
382 | # Generate email based on given_name, family_name, or name dependencies
383 | if given_name and family_name:
384 | return Literal(given_name[0].lower() + "_" + family_name[0].lower() + "@gmail.com")
385 | elif name:
386 | email = ""
387 | for p in name[0].split(' '):
388 | email = email + p.lower()
389 | return Literal(email + "@gmail.com")
390 | elif given_name:
391 | return Literal(given_name[0].lower() + "_" + str(random.randrange(100, 1000)) + "@gmail.com")
392 |
393 | # Handle other properties for Person class
394 | if sh_path == SCH.familyName:
395 | return Literal(random.choice(dataset_dictionary.get('familyName')))
396 | if sh_path == SCH.name:
397 | gender = str(dependencies.get(gender, ["none"])[0])
398 | if gender in (SCH.Female, 'female', 'f', 'fem'):
399 | return Literal(random.choice(dataset_dictionary.get('givenNameFemale')) + " " + random.choice(
400 | dataset_dictionary.get('familyName')))
401 | elif gender in (SCH.Male, 'male', 'm'):
402 | return Literal(random.choice(dataset_dictionary.get('givenNameMale')) + " " + random.choice(
403 | dataset_dictionary.get('familyName')))
404 | else:
405 | return Literal(
406 | random.choice(dataset_dictionary.get('givenNameMale') + dataset_dictionary.get('givenNameFemale')) +
407 | " " + random.choice(dataset_dictionary.get('familyName')))
408 | if sh_path == SCH.streetAddress:
409 | return Literal(
410 | "no. " + str(random.randint(1, 100)) + " " + random.choice(dataset_dictionary.get('streetAddress')))
411 | if sh_path == SCH.gender:
412 | return Literal(random.choice(dataset_dictionary.get('gender')))
413 | if sh_path == SCH.jobTitle:
414 | return Literal(random.choice(dataset_dictionary.get('jobTitle')))
415 |
416 | # Handle cases for Book class
417 | elif sh_class == SCH.Book:
418 | # Handle properties for Book class
419 | if sh_path == SCH.name:
420 | return Literal(random.choice(dataset_dictionary.get("bookTitle")))
421 | if sh_path == SCH.award:
422 | return Literal(random.choice(dataset_dictionary.get('bookAward')))
423 | if sh_path == SCH.genre:
424 | return Literal(random.choice(dataset_dictionary.get('bookGenre')))
425 | if sh_path == SCH.bookEdition:
426 | return getBookFormat()
427 |
428 | # Handle cases for Movie class
429 | elif sh_class == SCH.Movie:
430 | # Handle properties for Movie class
431 | if sh_path == SCH.name:
432 | return Literal(random.choice(dataset_dictionary.get("movieTitle")))
433 | if sh_path == SCH.award:
434 | return Literal(random.choice(dataset_dictionary.get('movieAward')))
435 | if sh_path == SCH.genre:
436 | return Literal(random.choice(dataset_dictionary.get('movieGenre')))
437 |
438 | # Handle cases for TVSeries class
439 | elif sh_class == SCH.TVSeries:
440 | # Handle properties for TVSeries class
441 | if sh_path == SCH.name:
442 | return Literal(random.choice(dataset_dictionary.get("tvSeriesTitle")))
443 | if sh_path == SCH.genre:
444 | return Literal(random.choice(dataset_dictionary.get('movieGenre')))
445 |
446 | return None
447 |
--------------------------------------------------------------------------------
/rdf_graph_gen/datasets/male_first_name.csv:
--------------------------------------------------------------------------------
1 | Aamir
2 | Aaron
3 | Abbey
4 | Abbie
5 | Abbot
6 | Abbott
7 | Abby
8 | Abdel
9 | Abdul
10 | Abdulkarim
11 | Abdullah
12 | Abe
13 | Abel
14 | Abelard
15 | Abner
16 | Abraham
17 | Abram
18 | Ace
19 | Adair
20 | Adam
21 | Adams
22 | Addie
23 | Adger
24 | Aditya
25 | Adlai
26 | Adnan
27 | Adolf
28 | Adolfo
29 | Adolph
30 | Adolphe
31 | Adolpho
32 | Adolphus
33 | Adrian
34 | Adrick
35 | Adrien
36 | Agamemnon
37 | Aguinaldo
38 | Aguste
39 | Agustin
40 | Aharon
41 | Ahmad
42 | Ahmed
43 | Ahmet
44 | Ajai
45 | Ajay
46 | Al
47 | Alaa
48 | Alain
49 | Alan
50 | Alasdair
51 | Alastair
52 | Albatros
53 | Albert
54 | Alberto
55 | Albrecht
56 | Alden
57 | Aldis
58 | Aldo
59 | Aldric
60 | Aldrich
61 | Aldus
62 | Aldwin
63 | Alec
64 | Aleck
65 | Alejandro
66 | Aleks
67 | Aleksandrs
68 | Alessandro
69 | Alex
70 | Alexander
71 | Alexei
72 | Alexis
73 | Alf
74 | Alfie
75 | Alfonse
76 | Alfonso
77 | Alfonzo
78 | Alford
79 | Alfred
80 | Alfredo
81 | Algernon
82 | Ali
83 | Alic
84 | Alister
85 | Alix
86 | Allah
87 | Allan
88 | Allen
89 | Alley
90 | Allie
91 | Allin
92 | Allyn
93 | Alonso
94 | Alonzo
95 | Aloysius
96 | Alphonse
97 | Alphonso
98 | Alston
99 | Alton
100 | Alvin
101 | Alwin
102 | Amadeus
103 | Ambros
104 | Ambrose
105 | Ambrosi
106 | Ambrosio
107 | Ambrosius
108 | Amery
109 | Amory
110 | Amos
111 | Anatol
112 | Anatole
113 | Anatollo
114 | Anatoly
115 | Anders
116 | Andie
117 | Andonis
118 | Andre
119 | Andrea
120 | Andreas
121 | Andrej
122 | Andres
123 | Andrew
124 | Andrey
125 | Andri
126 | Andros
127 | Andrus
128 | Andrzej
129 | Andy
130 | Angel
131 | Angelico
132 | Angelo
133 | Angie
134 | Angus
135 | Ansel
136 | Ansell
137 | Anselm
138 | Anson
139 | Anthony
140 | Antin
141 | Antoine
142 | Anton
143 | Antone
144 | Antoni
145 | Antonin
146 | Antonino
147 | Antonio
148 | Antonius
149 | Antony
150 | Anurag
151 | Apollo
152 | Apostolos
153 | Aram
154 | Archibald
155 | Archibold
156 | Archie
157 | Archon
158 | Archy
159 | Arel
160 | Ari
161 | Arie
162 | Ariel
163 | Aristotle
164 | Arlo
165 | Armand
166 | Armando
167 | Armond
168 | Armstrong
169 | Arne
170 | Arnie
171 | Arnold
172 | Arnoldo
173 | Aron
174 | Arron
175 | Art
176 | Arther
177 | Arthur
178 | Artie
179 | Artur
180 | Arturo
181 | Arvie
182 | Arvin
183 | Arvind
184 | Arvy
185 | Ash
186 | Ashby
187 | Ashish
188 | Ashley
189 | Ashton
190 | Aub
191 | Aube
192 | Aubert
193 | Aubrey
194 | Augie
195 | August
196 | Augustin
197 | Augustine
198 | Augusto
199 | Augustus
200 | Austen
201 | Austin
202 | Ave
203 | Averell
204 | Averil
205 | Averill
206 | Avery
207 | Avi
208 | Avraham
209 | Avram
210 | Avrom
211 | Axel
212 | Aylmer
213 | Aziz
214 | Bailey
215 | Bailie
216 | Baillie
217 | Baily
218 | Baird
219 | Baldwin
220 | Bancroft
221 | Barbabas
222 | Barclay
223 | Bard
224 | Barde
225 | Barn
226 | Barnabas
227 | Barnabe
228 | Barnaby
229 | Barnard
230 | Barnebas
231 | Barnett
232 | Barney
233 | Barnie
234 | Barny
235 | Baron
236 | Barr
237 | Barret
238 | Barrett
239 | Barri
240 | Barrie
241 | Barris
242 | Barron
243 | Barry
244 | Bart
245 | Bartel
246 | Barth
247 | Barthel
248 | Bartholemy
249 | Bartholomeo
250 | Bartholomeus
251 | Bartholomew
252 | Bartie
253 | Bartlet
254 | Bartlett
255 | Bartolemo
256 | Bartolomei
257 | Bartolomeo
258 | Barton
259 | Barty
260 | Bary
261 | Basil
262 | Batholomew
263 | Baxter
264 | Bay
265 | Bayard
266 | Beale
267 | Bealle
268 | Bear
269 | Bearnard
270 | Beau
271 | Beaufort
272 | Beauregard
273 | Beck
274 | Bela
275 | Ben
276 | Benedict
277 | Bengt
278 | Benito
279 | Benjamen
280 | Benjamin
281 | Benji
282 | Benjie
283 | Benjy
284 | Benn
285 | Bennet
286 | Bennett
287 | Bennie
288 | Benny
289 | Benson
290 | Bentley
291 | Benton
292 | Beowulf
293 | Berchtold
294 | Berk
295 | Berke
296 | Berkeley
297 | Berkie
298 | Berkley
299 | Bernard
300 | Bernardo
301 | Bernd
302 | Bernhard
303 | Bernie
304 | Bert
305 | Bertie
306 | Bertram
307 | Bertrand
308 | Bharat
309 | Biff
310 | Bill
311 | Billie
312 | Billy
313 | Bing
314 | Binky
315 | Bishop
316 | Bjorn
317 | Bjorne
318 | Blaine
319 | Blair
320 | Blake
321 | Blare
322 | Blayne
323 | Bo
324 | Bob
325 | Bobbie
326 | Bobby
327 | Bogart
328 | Bogdan
329 | Boniface
330 | Boris
331 | Boyce
332 | Boyd
333 | Brad
334 | Braden
335 | Bradford
336 | Bradley
337 | Bradly
338 | Brady
339 | Brandon
340 | Brandy
341 | Brant
342 | Brendan
343 | Brent
344 | Bret
345 | Brett
346 | Brewer
347 | Brewster
348 | Brian
349 | Brice
350 | Briggs
351 | Brinkley
352 | Britt
353 | Brock
354 | Broddie
355 | Broddy
356 | Broderic
357 | Broderick
358 | Brodie
359 | Brody
360 | Bronson
361 | Brook
362 | Brooke
363 | Brooks
364 | Bruce
365 | Bruno
366 | Bryan
367 | Bryant
368 | Bryce
369 | Bryn
370 | Bryon
371 | Bubba
372 | Buck
373 | Bucky
374 | Bud
375 | Buddy
376 | Burgess
377 | Burke
378 | Burl
379 | Burnaby
380 | Burt
381 | Burton
382 | Buster
383 | Butch
384 | Butler
385 | Byram
386 | Byron
387 | Caesar
388 | Cain
389 | Cal
390 | Caldwell
391 | Caleb
392 | Calhoun
393 | Calvin
394 | Cam
395 | Cameron
396 | Cammy
397 | Carey
398 | Carl
399 | Carleigh
400 | Carlie
401 | Carlin
402 | Carlo
403 | Carlos
404 | Carlton
405 | Carlyle
406 | Carmine
407 | Carroll
408 | Carson
409 | Carsten
410 | Carter
411 | Cary
412 | Caryl
413 | Case
414 | Casey
415 | Caspar
416 | Casper
417 | Cass
418 | Cat
419 | Cecil
420 | Cesar
421 | Chad
422 | Chadd
423 | Chaddie
424 | Chaddy
425 | Chadwick
426 | Chaim
427 | Chalmers
428 | Chan
429 | Chance
430 | Chancey
431 | Chanderjit
432 | Chandler
433 | Chane
434 | Chariot
435 | Charles
436 | Charleton
437 | Charley
438 | Charlie
439 | Charlton
440 | Chas
441 | Chase
442 | Chaunce
443 | Chauncey
444 | Che
445 | Chelton
446 | Chen
447 | Chester
448 | Cheston
449 | Chet
450 | Chev
451 | Chevalier
452 | Chevy
453 | Chip
454 | Chris
455 | Chrissy
456 | Christ
457 | Christian
458 | Christiano
459 | Christie
460 | Christof
461 | Christofer
462 | Christoph
463 | Christophe
464 | Christopher
465 | Christorpher
466 | Christos
467 | Christy
468 | Chrisy
469 | Chuck
470 | Churchill
471 | Clair
472 | Claire
473 | Clancy
474 | Clarance
475 | Clare
476 | Clarence
477 | Clark
478 | Clarke
479 | Claude
480 | Claudio
481 | Claudius
482 | Claus
483 | Clay
484 | Clayborn
485 | Clayborne
486 | Claybourne
487 | Clayton
488 | Cleland
489 | Clem
490 | Clemens
491 | Clement
492 | Clemente
493 | Clemmie
494 | Cletus
495 | Cleveland
496 | Cliff
497 | Clifford
498 | Clifton
499 | Clint
500 | Clinten
501 | Clinton
502 | Clive
503 | Clyde
504 | Cob
505 | Cobb
506 | Cobbie
507 | Cobby
508 | Cody
509 | Colbert
510 | Cole
511 | Coleman
512 | Colin
513 | Collin
514 | Collins
515 | Conan
516 | Connie
517 | Connolly
518 | Connor
519 | Conrad
520 | Conroy
521 | Constantin
522 | Constantine
523 | Constantinos
524 | Conway
525 | Cooper
526 | Corbin
527 | Corby
528 | Corey
529 | Corky
530 | Cornelius
531 | Cornellis
532 | Corrie
533 | Cortese
534 | Corwin
535 | Cory
536 | Cosmo
537 | Costa
538 | Courtney
539 | Craig
540 | Crawford
541 | Creighton
542 | Cris
543 | Cristopher
544 | Curt
545 | Curtice
546 | Curtis
547 | Cy
548 | Cyril
549 | Cyrill
550 | Cyrille
551 | Cyrillus
552 | Cyrus
553 | Dabney
554 | Daffy
555 | Dale
556 | Dallas
557 | Dalton
558 | Damian
559 | Damien
560 | Damon
561 | Dan
562 | Dana
563 | Dane
564 | Dani
565 | Danie
566 | Daniel
567 | Dannie
568 | Danny
569 | Dante
570 | Darby
571 | Darcy
572 | Daren
573 | Darian
574 | Darien
575 | Darin
576 | Dario
577 | Darius
578 | Darrel
579 | Darrell
580 | Darren
581 | Darrick
582 | Darrin
583 | Darryl
584 | Darth
585 | Darwin
586 | Daryl
587 | Daryle
588 | Dave
589 | Davey
590 | David
591 | Davidde
592 | Davide
593 | Davidson
594 | Davie
595 | Davin
596 | Davis
597 | Davon
598 | Davoud
599 | Davy
600 | Dawson
601 | Dean
602 | Deane
603 | Del
604 | Delbert
605 | Dell
606 | Delmar
607 | Demetre
608 | Demetri
609 | Demetris
610 | Demetrius
611 | Demosthenis
612 | Denis
613 | Dennie
614 | Dennis
615 | Denny
616 | Derby
617 | Derek
618 | Derick
619 | Derk
620 | Derrek
621 | Derrick
622 | Derrin
623 | Derrol
624 | Derron
625 | Deryl
626 | Desmond
627 | Desmund
628 | Devin
629 | Devon
630 | Dewey
631 | Dewitt
632 | Dexter
633 | Dick
634 | Dickey
635 | Dickie
636 | Diego
637 | Dieter
638 | Dietrich
639 | Dillon
640 | Dimitri
641 | Dimitrios
642 | Dimitris
643 | Dimitrou
644 | Dimitry
645 | Dino
646 | Dion
647 | Dionis
648 | Dionysus
649 | Dirk
650 | Dmitri
651 | Dom
652 | Domenic
653 | Domenico
654 | Dominic
655 | Dominick
656 | Dominique
657 | Don
658 | Donal
659 | Donald
660 | Donn
661 | Donnie
662 | Donny
663 | Donovan
664 | Dorian
665 | Dory
666 | Doug
667 | Douggie
668 | Dougie
669 | Douglas
670 | Douglass
671 | Douglis
672 | Dov
673 | Doyle
674 | Drake
675 | Drew
676 | Dru
677 | Dryke
678 | Duane
679 | Dudley
680 | Duffie
681 | Duffy
682 | Dugan
683 | Duke
684 | Dunc
685 | Duncan
686 | Dunstan
687 | Durand
688 | Durant
689 | Durante
690 | Durward
691 | Dustin
692 | Dwain
693 | Dwaine
694 | Dwane
695 | Dwayne
696 | Dwight
697 | Dylan
698 | Dyson
699 | Earl
700 | Earle
701 | Easton
702 | Eben
703 | Ebeneser
704 | Ebenezer
705 | Eberhard
706 | Ed
707 | Eddie
708 | Eddy
709 | Edgar
710 | Edgardo
711 | Edie
712 | Edmond
713 | Edmund
714 | Edouard
715 | Edsel
716 | Eduard
717 | Eduardo
718 | Edward
719 | Edwin
720 | Efram
721 | Egbert
722 | Ehud
723 | Elbert
724 | Elden
725 | Eldon
726 | Eli
727 | Elias
728 | Elihu
729 | Elijah
730 | Eliot
731 | Eliott
732 | Elisha
733 | Elliot
734 | Elliott
735 | Ellis
736 | Ellsworth
737 | Ellwood
738 | Elmer
739 | Elmore
740 | Elnar
741 | Elric
742 | Elroy
743 | Elton
744 | Elvin
745 | Elvis
746 | Elwin
747 | Elwood
748 | Elwyn
749 | Ely
750 | Emanuel
751 | Emerson
752 | Emery
753 | Emil
754 | Emile
755 | Emilio
756 | Emmanuel
757 | Emmery
758 | Emmet
759 | Emmett
760 | Emmit
761 | Emmott
762 | Emmy
763 | Emory
764 | Ender
765 | Engelbart
766 | Engelbert
767 | Englebart
768 | Englebert
769 | Enoch
770 | Enrico
771 | Enrique
772 | Ephraim
773 | Ephram
774 | Ephrayim
775 | Ephrem
776 | Er
777 | Erasmus
778 | Erastus
779 | Erek
780 | Erhard
781 | Erhart
782 | Eric
783 | Erich
784 | Erick
785 | Erik
786 | Erin
787 | Erl
788 | Ernest
789 | Ernesto
790 | Ernie
791 | Ernst
792 | Erny
793 | Errol
794 | Ervin
795 | Erwin
796 | Esau
797 | Esme
798 | Esteban
799 | Ethan
800 | Ethelbert
801 | Ethelred
802 | Etienne
803 | Euclid
804 | Eugen
805 | Eugene
806 | Eustace
807 | Ev
808 | Evan
809 | Evelyn
810 | Everard
811 | Everett
812 | Ewan
813 | Ewart
814 | Ez
815 | Ezechiel
816 | Ezekiel
817 | Ezra
818 | Fabian
819 | Fabio
820 | Fairfax
821 | Farley
822 | Fazeel
823 | Federico
824 | Felice
825 | Felicio
826 | Felipe
827 | Felix
828 | Ferd
829 | Ferdie
830 | Ferdinand
831 | Ferdy
832 | Fergus
833 | Ferguson
834 | Ferinand
835 | Fernando
836 | Fidel
837 | Filbert
838 | Filip
839 | Filipe
840 | Filmore
841 | Finley
842 | Finn
843 | Fitz
844 | Fitzgerald
845 | Flem
846 | Fleming
847 | Flemming
848 | Fletch
849 | Fletcher
850 | Flin
851 | Flinn
852 | Flint
853 | Flipper
854 | Florian
855 | Floyd
856 | Flynn
857 | Fons
858 | Fonsie
859 | Fonz
860 | Fonzie
861 | Forbes
862 | Ford
863 | Forest
864 | Forester
865 | Forrest
866 | Forrester
867 | Forster
868 | Foster
869 | Fowler
870 | Fox
871 | Fran
872 | Francesco
873 | Francis
874 | Francisco
875 | Francois
876 | Frank
877 | Frankie
878 | Franklin
879 | Franklyn
880 | Franky
881 | Frans
882 | Franz
883 | Fraser
884 | Frazier
885 | Fred
886 | Freddie
887 | Freddy
888 | Frederic
889 | Frederich
890 | Frederick
891 | Frederico
892 | Frederik
893 | Fredric
894 | Fredrick
895 | Freeman
896 | Freemon
897 | Fremont
898 | French
899 | Friedric
900 | Friedrich
901 | Friedrick
902 | Fritz
903 | Fulton
904 | Fyodor
905 | Gabe
906 | Gabriel
907 | Gabriele
908 | Gabriell
909 | Gabriello
910 | Gail
911 | Gale
912 | Galen
913 | Gallagher
914 | Gamaliel
915 | Garcia
916 | Garcon
917 | Gardener
918 | Gardiner
919 | Gardner
920 | Garey
921 | Garfield
922 | Garfinkel
923 | Garold
924 | Garp
925 | Garret
926 | Garrett
927 | Garrot
928 | Garrott
929 | Garry
930 | Garth
931 | Garv
932 | Garvey
933 | Garvin
934 | Garvy
935 | Garwin
936 | Garwood
937 | Gary
938 | Gaspar
939 | Gasper
940 | Gaston
941 | Gav
942 | Gaven
943 | Gavin
944 | Gavriel
945 | Gay
946 | Gayle
947 | Gearard
948 | Gene
949 | Geo
950 | Geof
951 | Geoff
952 | Geoffrey
953 | Geoffry
954 | Georg
955 | George
956 | Georges
957 | Georgia
958 | Georgie
959 | Georgy
960 | Gerald
961 | Geraldo
962 | Gerard
963 | Gere
964 | Gerhard
965 | Gerhardt
966 | Geri
967 | Germaine
968 | Gerold
969 | Gerome
970 | Gerrard
971 | Gerri
972 | Gerrit
973 | Gerry
974 | Gershom
975 | Gershon
976 | Giacomo
977 | Gian
978 | Giancarlo
979 | Giavani
980 | Gibb
981 | Gideon
982 | Giff
983 | Giffard
984 | Giffer
985 | Giffie
986 | Gifford
987 | Giffy
988 | Gil
989 | Gilbert
990 | Gilberto
991 | Gilburt
992 | Giles
993 | Gill
994 | Gilles
995 | Ginger
996 | Gino
997 | Giordano
998 | Giorgi
999 | Giorgio
1000 | Giovanne
1001 | Giovanni
1002 | Giraldo
1003 | Giraud
1004 | Giuseppe
1005 | Glen
1006 | Glenn
1007 | Glynn
1008 | Godard
1009 | Godart
1010 | Goddard
1011 | Goddart
1012 | Godfree
1013 | Godfrey
1014 | Godfry
1015 | Godwin
1016 | Gomer
1017 | Gonzales
1018 | Gonzalo
1019 | Goober
1020 | Goose
1021 | Gordan
1022 | Gordie
1023 | Gordon
1024 | Grace
1025 | Grady
1026 | Graehme
1027 | Graeme
1028 | Graham
1029 | Graig
1030 | Grant
1031 | Granville
1032 | Greg
1033 | Gregg
1034 | Greggory
1035 | Gregor
1036 | Gregorio
1037 | Gregory
1038 | Gretchen
1039 | Griff
1040 | Griffin
1041 | Griffith
1042 | Griswold
1043 | Grove
1044 | Grover
1045 | Guido
1046 | Guillaume
1047 | Guillermo
1048 | Gunner
1049 | Gunter
1050 | Gunther
1051 | Gus
1052 | Gustaf
1053 | Gustav
1054 | Gustave
1055 | Gustavo
1056 | Gustavus
1057 | Guthrey
1058 | Guthrie
1059 | Guthry
1060 | Guy
1061 | Hadleigh
1062 | Hadley
1063 | Hadrian
1064 | Hagan
1065 | Hagen
1066 | Hailey
1067 | Hakeem
1068 | Hakim
1069 | Hal
1070 | Hale
1071 | Haleigh
1072 | Haley
1073 | Hall
1074 | Hallam
1075 | Halvard
1076 | Ham
1077 | Hamel
1078 | Hamid
1079 | Hamil
1080 | Hamilton
1081 | Hamish
1082 | Hamlen
1083 | Hamlet
1084 | Hamlin
1085 | Hammad
1086 | Hamnet
1087 | Han
1088 | Hanan
1089 | Hanford
1090 | Hank
1091 | Hannibal
1092 | Hans
1093 | Hans-Peter
1094 | Hansel
1095 | Hanson
1096 | Harald
1097 | Harcourt
1098 | Hari
1099 | Harlan
1100 | Harland
1101 | Harley
1102 | Harlin
1103 | Harman
1104 | Harmon
1105 | Harold
1106 | Harris
1107 | Harrison
1108 | Harrold
1109 | Harry
1110 | Hart
1111 | Hartley
1112 | Hartwell
1113 | Harv
1114 | Harvard
1115 | Harvey
1116 | Harvie
1117 | Harwell
1118 | Hasheem
1119 | Hashim
1120 | Haskel
1121 | Haskell
1122 | Hassan
1123 | Hastings
1124 | Hasty
1125 | Haven
1126 | Hayden
1127 | Haydon
1128 | Hayes
1129 | Hayward
1130 | Haywood
1131 | Hazel
1132 | Heath
1133 | Heathcliff
1134 | Hebert
1135 | Hector
1136 | Heinrich
1137 | Heinz
1138 | Helmuth
1139 | Henderson
1140 | Hendrick
1141 | Hendrik
1142 | Henri
1143 | Henrie
1144 | Henrik
1145 | Henrique
1146 | Henry
1147 | Herb
1148 | Herbert
1149 | Herbie
1150 | Herby
1151 | Hercule
1152 | Hercules
1153 | Herculie
1154 | Herman
1155 | Hermann
1156 | Hermon
1157 | Hermy
1158 | Hernando
1159 | Herold
1160 | Herrick
1161 | Herrmann
1162 | Hersch
1163 | Herschel
1164 | Hersh
1165 | Hershel
1166 | Herve
1167 | Hervey
1168 | Hew
1169 | Hewe
1170 | Hewet
1171 | Hewett
1172 | Hewie
1173 | Hewitt
1174 | Heywood
1175 | Hezekiah
1176 | Higgins
1177 | Hilary
1178 | Hilbert
1179 | Hill
1180 | Hillard
1181 | Hillary
1182 | Hillel
1183 | Hillery
1184 | Hilliard
1185 | Hilton
1186 | Hiralal
1187 | Hiram
1188 | Hiro
1189 | Hirsch
1190 | Hobart
1191 | Hodge
1192 | Hogan
1193 | Hollis
1194 | Holly
1195 | Homer
1196 | Horace
1197 | Horacio
1198 | Horatio
1199 | Horatius
1200 | Horst
1201 | Howard
1202 | Howie
1203 | Hoyt
1204 | Hubert
1205 | Hudson
1206 | Huey
1207 | Hugh
1208 | Hugo
1209 | Humbert
1210 | Humphrey
1211 | Hunt
1212 | Hunter
1213 | Huntington
1214 | Huntlee
1215 | Huntley
1216 | Hurley
1217 | Husain
1218 | Husein
1219 | Hussein
1220 | Hy
1221 | Hyatt
1222 | Hyman
1223 | Hymie
1224 | Iago
1225 | Iain
1226 | Ian
1227 | Ibrahim
1228 | Ichabod
1229 | Iggie
1230 | Iggy
1231 | Ignace
1232 | Ignacio
1233 | Ignacius
1234 | Ignatius
1235 | Ignaz
1236 | Ignazio
1237 | Igor
1238 | Ike
1239 | Ikey
1240 | Immanuel
1241 | Ingamar
1242 | Ingelbert
1243 | Ingemar
1244 | Inglebert
1245 | Ingmar
1246 | Ingram
1247 | Inigo
1248 | Ira
1249 | Irvin
1250 | Irvine
1251 | Irving
1252 | Irwin
1253 | Isa
1254 | Isaac
1255 | Isaak
1256 | Isador
1257 | Isadore
1258 | Isaiah
1259 | Ishmael
1260 | Isidore
1261 | Ismail
1262 | Israel
1263 | Istvan
1264 | Ivan
1265 | Ivor
1266 | Izaak
1267 | Izak
1268 | Izzy
1269 | Jabez
1270 | Jack
1271 | Jackie
1272 | Jackson
1273 | Jacob
1274 | Jacques
1275 | Jae
1276 | Jaime
1277 | Jake
1278 | Jakob
1279 | James
1280 | Jameson
1281 | Jamey
1282 | Jamie
1283 | Jan
1284 | Janos
1285 | Janus
1286 | Jared
1287 | Jarrett
1288 | Jarvis
1289 | Jason
1290 | Jasper
1291 | Javier
1292 | Jay
1293 | Jean
1294 | Jean-Christophe
1295 | Jean-Francois
1296 | Jean-Lou
1297 | Jean-Luc
1298 | Jean-Marc
1299 | Jean-Paul
1300 | Jean-Pierre
1301 | Jeb
1302 | Jed
1303 | Jedediah
1304 | Jef
1305 | Jeff
1306 | Jefferey
1307 | Jefferson
1308 | Jeffery
1309 | Jeffie
1310 | Jeffrey
1311 | Jeffry
1312 | Jefry
1313 | Jehu
1314 | Jennings
1315 | Jens
1316 | Jephthah
1317 | Jerald
1318 | Jeramie
1319 | Jere
1320 | Jereme
1321 | Jeremiah
1322 | Jeremias
1323 | Jeremie
1324 | Jeremy
1325 | Jermain
1326 | Jermaine
1327 | Jermayne
1328 | Jerold
1329 | Jerome
1330 | Jeromy
1331 | Jerri
1332 | Jerrie
1333 | Jerrold
1334 | Jerrome
1335 | Jerry
1336 | Jervis
1337 | Jerzy
1338 | Jess
1339 | Jesse
1340 | Jessee
1341 | Jessey
1342 | Jessie
1343 | Jesus
1344 | Jeth
1345 | Jethro
1346 | Jim
1347 | Jimbo
1348 | Jimmie
1349 | Jimmy
1350 | Jo
1351 | Joab
1352 | Joachim
1353 | Joao
1354 | Joaquin
1355 | Job
1356 | Jock
1357 | Jodi
1358 | Jodie
1359 | Jody
1360 | Joe
1361 | Joel
1362 | Joey
1363 | Johan
1364 | Johann
1365 | Johannes
1366 | John
1367 | John-David
1368 | John-Patrick
1369 | Johnathan
1370 | Johnathon
1371 | Johnnie
1372 | Johnny
1373 | Johny
1374 | Jon
1375 | Jonah
1376 | Jonas
1377 | Jonathan
1378 | Jonathon
1379 | Jonny
1380 | Jordan
1381 | Jordon
1382 | Jordy
1383 | Jorge
1384 | Jory
1385 | Jose
1386 | Josef
1387 | Joseph
1388 | Josephus
1389 | Josh
1390 | Joshua
1391 | Joshuah
1392 | Josiah
1393 | Jotham
1394 | Juan
1395 | Juanita
1396 | Jud
1397 | Judah
1398 | Judas
1399 | Judd
1400 | Jude
1401 | Judith
1402 | Judson
1403 | Judy
1404 | Juergen
1405 | Jule
1406 | Jules
1407 | Julian
1408 | Julie
1409 | Julio
1410 | Julius
1411 | Justin
1412 | Justis
1413 | Kaiser
1414 | Kaleb
1415 | Kalil
1416 | Kalle
1417 | Kalman
1418 | Kalvin
1419 | Kam
1420 | Kane
1421 | Kareem
1422 | Karel
1423 | Karim
1424 | Karl
1425 | Karsten
1426 | Kaspar
1427 | Keefe
1428 | Keenan
1429 | Keene
1430 | Keil
1431 | Keith
1432 | Kellen
1433 | Kelley
1434 | Kelly
1435 | Kelsey
1436 | Kelvin
1437 | Kelwin
1438 | Ken
1439 | Kendal
1440 | Kendall
1441 | Kendrick
1442 | Kenn
1443 | Kennedy
1444 | Kenneth
1445 | Kenny
1446 | Kent
1447 | Kenton
1448 | Kenyon
1449 | Kermie
1450 | Kermit
1451 | Kerry
1452 | Kevan
1453 | Kevin
1454 | Kim
1455 | Kimball
1456 | Kimmo
1457 | Kin
1458 | Kincaid
1459 | King
1460 | Kingsley
1461 | Kingsly
1462 | Kingston
1463 | Kip
1464 | Kirby
1465 | Kirk
1466 | Kit
1467 | Klaus
1468 | Klee
1469 | Knox
1470 | Konrad
1471 | Konstantin
1472 | Kory
1473 | Kostas
1474 | Kraig
1475 | Kris
1476 | Krishna
1477 | Kristian
1478 | Kristopher
1479 | Kristos
1480 | Kurt
1481 | Kurtis
1482 | Kyle
1483 | Laird
1484 | Lamar
1485 | Lambert
1486 | Lamont
1487 | Lance
1488 | Lancelot
1489 | Lane
1490 | Langston
1491 | Lanny
1492 | Larry
1493 | Lars
1494 | Laurance
1495 | Lauren
1496 | Laurence
1497 | Laurens
1498 | Laurent
1499 | Laurie
1500 | Lawerence
1501 | Lawrence
1502 | Lawson
1503 | Lawton
1504 | Lay
1505 | Layton
1506 | Lazar
1507 | Lazare
1508 | Lazaro
1509 | Lazarus
1510 | Lazlo
1511 | Lee
1512 | Lefty
1513 | Leif
1514 | Leigh
1515 | Leighton
1516 | Leland
1517 | Lem
1518 | Lemar
1519 | Lemmie
1520 | Lemmy
1521 | Lemuel
1522 | Len
1523 | Lenard
1524 | Lennie
1525 | Lenny
1526 | Leo
1527 | Leon
1528 | Leonard
1529 | Leonardo
1530 | Leonerd
1531 | Leonhard
1532 | Leonid
1533 | Leonidas
1534 | Leopold
1535 | Leroy
1536 | Les
1537 | Lesley
1538 | Leslie
1539 | Lester
1540 | Lev
1541 | Levi
1542 | Levin
1543 | Levon
1544 | Levy
1545 | Lew
1546 | Lewis
1547 | Lex
1548 | Liam
1549 | Lin
1550 | Lincoln
1551 | Lind
1552 | Lindsay
1553 | Lindsey
1554 | Lindy
1555 | Linoel
1556 | Linus
1557 | Lion
1558 | Lionel
1559 | Lionello
1560 | Llewellyn
1561 | Lloyd
1562 | Locke
1563 | Lockwood
1564 | Logan
1565 | Lon
1566 | Lonnie
1567 | Lonny
1568 | Loren
1569 | Lorenzo
1570 | Lorne
1571 | Lorrie
1572 | Lothar
1573 | Lou
1574 | Louie
1575 | Louis
1576 | Lovell
1577 | Lowell
1578 | Lucas
1579 | Luce
1580 | Lucian
1581 | Luciano
1582 | Lucien
1583 | Lucio
1584 | Lucius
1585 | Ludvig
1586 | Ludwig
1587 | Luigi
1588 | Luis
1589 | Lukas
1590 | Luke
1591 | Luther
1592 | Lyle
1593 | Lyn
1594 | Lyndon
1595 | Lynn
1596 | Mac
1597 | Mace
1598 | Mack
1599 | Mackenzie
1600 | Maddie
1601 | Maddy
1602 | Madison
1603 | Magnum
1604 | Magnus
1605 | Mahesh
1606 | Mahmoud
1607 | Mahmud
1608 | Maison
1609 | Major
1610 | Malcolm
1611 | Manfred
1612 | Manish
1613 | Manny
1614 | Manuel
1615 | Marc
1616 | Marcel
1617 | Marcello
1618 | Marcellus
1619 | Marcelo
1620 | Marchall
1621 | Marcio
1622 | Marco
1623 | Marcos
1624 | Marcus
1625 | Marietta
1626 | Marilu
1627 | Mario
1628 | Marion
1629 | Marius
1630 | Mark
1631 | Marko
1632 | Markos
1633 | Markus
1634 | Marlin
1635 | Marlo
1636 | Marlon
1637 | Marlow
1638 | Marlowe
1639 | Marmaduke
1640 | Marsh
1641 | Marshal
1642 | Marshall
1643 | Mart
1644 | Martainn
1645 | Marten
1646 | Martie
1647 | Martin
1648 | Martino
1649 | Marty
1650 | Martyn
1651 | Marv
1652 | Marve
1653 | Marven
1654 | Marvin
1655 | Marwin
1656 | Mason
1657 | Mateo
1658 | Mathew
1659 | Mathias
1660 | Matias
1661 | Matt
1662 | Matteo
1663 | Matthaeus
1664 | Mattheus
1665 | Matthew
1666 | Matthias
1667 | Matthieu
1668 | Matthiew
1669 | Matthus
1670 | Mattias
1671 | Mattie
1672 | Matty
1673 | Maurice
1674 | Mauricio
1675 | Maurie
1676 | Maurise
1677 | Maurits
1678 | Mauritz
1679 | Maury
1680 | Max
1681 | Maxfield
1682 | Maxie
1683 | Maxim
1684 | Maximilian
1685 | Maximilien
1686 | Maxwell
1687 | Mayer
1688 | Maynard
1689 | Maynord
1690 | Mayor
1691 | Mead
1692 | Meade
1693 | Meier
1694 | Meir
1695 | Mel
1696 | Melvin
1697 | Melvyn
1698 | Menard
1699 | Mendel
1700 | Mendie
1701 | Meredeth
1702 | Meredith
1703 | Merell
1704 | Merill
1705 | Merle
1706 | Merlin
1707 | Merrel
1708 | Merrick
1709 | Merril
1710 | Merrill
1711 | Merry
1712 | Merv
1713 | Mervin
1714 | Merwin
1715 | Meryl
1716 | Meyer
1717 | Mic
1718 | Micah
1719 | Michael
1720 | Michail
1721 | Michal
1722 | Michale
1723 | Micheal
1724 | Micheil
1725 | Michel
1726 | Michele
1727 | Mick
1728 | Mickey
1729 | Mickie
1730 | Micky
1731 | Miguel
1732 | Mika
1733 | Mikael
1734 | Mike
1735 | Mikel
1736 | Mikey
1737 | Mikhail
1738 | Miles
1739 | Millicent
1740 | Milo
1741 | Milt
1742 | Milton
1743 | Mischa
1744 | Mitch
1745 | Mitchael
1746 | Mitchel
1747 | Mitchell
1748 | Moe
1749 | Mohamad
1750 | Mohamed
1751 | Mohammad
1752 | Mohammed
1753 | Mohan
1754 | Moise
1755 | Moises
1756 | Moishe
1757 | Monroe
1758 | Montague
1759 | Monte
1760 | Montgomery
1761 | Monty
1762 | Moore
1763 | Mordecai
1764 | Morgan
1765 | Morlee
1766 | Morley
1767 | Morly
1768 | Morrie
1769 | Morris
1770 | Morry
1771 | Morse
1772 | Mort
1773 | Morten
1774 | Mortie
1775 | Mortimer
1776 | Morton
1777 | Morty
1778 | Mose
1779 | Moses
1780 | Moshe
1781 | Moss
1782 | Muffin
1783 | Mugsy
1784 | Muhammad
1785 | Munmro
1786 | Munroe
1787 | Murdoch
1788 | Murdock
1789 | Murphy
1790 | Murray
1791 | Mustafa
1792 | Myke
1793 | Myles
1794 | Mylo
1795 | Myron
1796 | Nahum
1797 | Napoleon
1798 | Nat
1799 | Natale
1800 | Nate
1801 | Nathan
1802 | Nathanael
1803 | Nathanial
1804 | Nathaniel
1805 | Nathanil
1806 | Neal
1807 | Neale
1808 | Neall
1809 | Nealon
1810 | Nealson
1811 | Nealy
1812 | Ned
1813 | Neddie
1814 | Neddy
1815 | Neel
1816 | Neil
1817 | Nels
1818 | Nelsen
1819 | Nelson
1820 | Nero
1821 | Neron
1822 | Nester
1823 | Nestor
1824 | Nev
1825 | Nevil
1826 | Nevile
1827 | Neville
1828 | Nevin
1829 | Nevins
1830 | Newton
1831 | Niall
1832 | Niccolo
1833 | Nicholas
1834 | Nichole
1835 | Nichols
1836 | Nick
1837 | Nickey
1838 | Nickie
1839 | Nickolas
1840 | Nicky
1841 | Nico
1842 | Nicolas
1843 | Niels
1844 | Nigel
1845 | Niki
1846 | Nikita
1847 | Nikki
1848 | Nikolai
1849 | Nikos
1850 | Niles
1851 | Nils
1852 | Nilson
1853 | Niven
1854 | Noach
1855 | Noah
1856 | Noam
1857 | Noble
1858 | Noe
1859 | Noel
1860 | Nolan
1861 | Noland
1862 | Norbert
1863 | Norm
1864 | Norman
1865 | Normand
1866 | Normie
1867 | Norris
1868 | Northrop
1869 | Northrup
1870 | Norton
1871 | Norwood
1872 | Nunzio
1873 | Obadiah
1874 | Obadias
1875 | Oberon
1876 | Obie
1877 | Octavius
1878 | Odell
1879 | Odie
1880 | Odin
1881 | Odysseus
1882 | Olaf
1883 | Olag
1884 | Ole
1885 | Oleg
1886 | Olin
1887 | Oliver
1888 | Olivier
1889 | Olle
1890 | Ollie
1891 | Omar
1892 | Oral
1893 | Oran
1894 | Orazio
1895 | Orbadiah
1896 | Oren
1897 | Orin
1898 | Orion
1899 | Orlando
1900 | Orren
1901 | Orrin
1902 | Orson
1903 | Orton
1904 | Orville
1905 | Osbert
1906 | Osborn
1907 | Osborne
1908 | Osbourn
1909 | Osbourne
1910 | Oscar
1911 | Osgood
1912 | Osmond
1913 | Osmund
1914 | Ossie
1915 | Oswald
1916 | Oswell
1917 | Otes
1918 | Othello
1919 | Otho
1920 | Otis
1921 | Otto
1922 | Owen
1923 | Ozzie
1924 | Ozzy
1925 | Pablo
1926 | Pace
1927 | Paco
1928 | Paddie
1929 | Paddy
1930 | Padraig
1931 | Page
1932 | Paige
1933 | Pail
1934 | Palmer
1935 | Paolo
1936 | Park
1937 | Parke
1938 | Parker
1939 | Parnell
1940 | Parrnell
1941 | Parry
1942 | Parsifal
1943 | Partha
1944 | Pascal
1945 | Pascale
1946 | Pasquale
1947 | Pat
1948 | Pate
1949 | Patel
1950 | Paten
1951 | Patin
1952 | Paton
1953 | Patric
1954 | Patrice
1955 | Patricio
1956 | Patrick
1957 | Patrik
1958 | Patsy
1959 | Pattie
1960 | Patty
1961 | Paul
1962 | Paulo
1963 | Pavel
1964 | Pearce
1965 | Pedro
1966 | Peirce
1967 | Pembroke
1968 | Pen
1969 | Penn
1970 | Pennie
1971 | Penny
1972 | Penrod
1973 | Pepe
1974 | Pepillo
1975 | Pepito
1976 | Perceval
1977 | Percival
1978 | Percy
1979 | Perry
1980 | Pete
1981 | Peter
1982 | Petey
1983 | Petr
1984 | Peyter
1985 | Peyton
1986 | Phil
1987 | Philbert
1988 | Philip
1989 | Phillip
1990 | Phillipe
1991 | Phillipp
1992 | Phineas
1993 | Phip
1994 | Pierce
1995 | Pierre
1996 | Pierson
1997 | Piet
1998 | Pieter
1999 | Pietro
2000 | Piggy
2001 | Pincas
2002 | Pinchas
2003 | Pincus
2004 | Piotr
2005 | Pip
2006 | Plato
2007 | Pooh
2008 | Porter
2009 | Poul
2010 | Powell
2011 | Praneetf
2012 | Prasad
2013 | Prasun
2014 | Prent
2015 | Prentice
2016 | Prentiss
2017 | Prescott
2018 | Preston
2019 | Price
2020 | Prince
2021 | Pryce
2022 | Puff
2023 | Purcell
2024 | Putnam
2025 | Pyotr
2026 | Quent
2027 | Quentin
2028 | Quiggly
2029 | Quigly
2030 | Quigman
2031 | Quill
2032 | Quillan
2033 | Quincey
2034 | Quincy
2035 | Quinlan
2036 | Quinn
2037 | Quint
2038 | Quintin
2039 | Quinton
2040 | Quintus
2041 | Rab
2042 | Rabbi
2043 | Rabi
2044 | Rad
2045 | Radcliffe
2046 | Rafael
2047 | Rafe
2048 | Ragnar
2049 | Rahul
2050 | Raimund
2051 | Rainer
2052 | Raj
2053 | Rajeev
2054 | Raleigh
2055 | Ralf
2056 | Ralph
2057 | Ram
2058 | Ramesh
2059 | Ramon
2060 | Ramsay
2061 | Ramsey
2062 | Rand
2063 | Randal
2064 | Randall
2065 | Randell
2066 | Randi
2067 | Randie
2068 | Randolf
2069 | Randolph
2070 | Randy
2071 | Ransell
2072 | Ransom
2073 | Raoul
2074 | Raphael
2075 | Raul
2076 | Ravi
2077 | Ravil
2078 | Rawley
2079 | Ray
2080 | Raymond
2081 | Raymund
2082 | Raymundo
2083 | Raynard
2084 | Rayner
2085 | Raynor
2086 | Reagan
2087 | Red
2088 | Redford
2089 | Redmond
2090 | Reece
2091 | Reed
2092 | Rees
2093 | Reese
2094 | Reg
2095 | Regan
2096 | Regen
2097 | Reggie
2098 | Reggis
2099 | Reggy
2100 | Reginald
2101 | Reginauld
2102 | Reid
2103 | Reilly
2104 | Reinhard
2105 | Reinhold
2106 | Rem
2107 | Remington
2108 | Remus
2109 | Renado
2110 | Renaldo
2111 | Renard
2112 | Renato
2113 | Renaud
2114 | Renault
2115 | Rene
2116 | Reube
2117 | Reuben
2118 | Reuven
2119 | Rex
2120 | Rey
2121 | Reynard
2122 | Reynold
2123 | Reynolds
2124 | Reza
2125 | Rhett
2126 | Ric
2127 | Ricard
2128 | Ricardo
2129 | Riccardo
2130 | Rice
2131 | Rich
2132 | Richard
2133 | Richardo
2134 | Richie
2135 | Richmond
2136 | Richy
2137 | Rick
2138 | Rickard
2139 | Rickey
2140 | Ricki
2141 | Rickie
2142 | Ricky
2143 | Rik
2144 | Rikki
2145 | Riley
2146 | Rinaldo
2147 | Ripley
2148 | Ritch
2149 | Ritchie
2150 | Roarke
2151 | Rob
2152 | Robb
2153 | Robbert
2154 | Robbie
2155 | Robert
2156 | Roberto
2157 | Robin
2158 | Robinson
2159 | Rochester
2160 | Rock
2161 | Rockwell
2162 | Rocky
2163 | Rod
2164 | Rodd
2165 | Roddie
2166 | Roddy
2167 | Roderic
2168 | Roderich
2169 | Roderick
2170 | Roderigo
2171 | Rodge
2172 | Rodger
2173 | Rodney
2174 | Rodolfo
2175 | Rodolph
2176 | Rodolphe
2177 | Rodrick
2178 | Rodrigo
2179 | Rodrique
2180 | Rog
2181 | Roger
2182 | Rogers
2183 | Roice
2184 | Roland
2185 | Rolando
2186 | Rolf
2187 | Rolfe
2188 | Rolland
2189 | Rollin
2190 | Rollins
2191 | Rollo
2192 | Rolph
2193 | Romain
2194 | Roman
2195 | Romeo
2196 | Ron
2197 | Ronald
2198 | Ronen
2199 | Roni
2200 | Ronnie
2201 | Ronny
2202 | Roosevelt
2203 | Rory
2204 | Roscoe
2205 | Ross
2206 | Roth
2207 | Rourke
2208 | Rowland
2209 | Roy
2210 | Royal
2211 | Royce
2212 | Rube
2213 | Ruben
2214 | Rubin
2215 | Ruby
2216 | Rudd
2217 | Ruddie
2218 | Ruddy
2219 | Rudie
2220 | Rudiger
2221 | Rudolf
2222 | Rudolfo
2223 | Rudolph
2224 | Rudy
2225 | Rudyard
2226 | Rufe
2227 | Rufus
2228 | Rupert
2229 | Ruperto
2230 | Russ
2231 | Russel
2232 | Russell
2233 | Rustie
2234 | Rustin
2235 | Rusty
2236 | Rutger
2237 | Rutherford
2238 | Rutledge
2239 | Rutter
2240 | Ryan
2241 | Sal
2242 | Salem
2243 | Salim
2244 | Salman
2245 | Salmon
2246 | Salomo
2247 | Salomon
2248 | Salomone
2249 | Salvador
2250 | Salvatore
2251 | Salvidor
2252 | Sam
2253 | Sammie
2254 | Sammy
2255 | Sampson
2256 | Samson
2257 | Samuel
2258 | Samuele
2259 | Sancho
2260 | Sander
2261 | Sanders
2262 | Sanderson
2263 | Sandor
2264 | Sandro
2265 | Sandy
2266 | Sanford
2267 | Sanson
2268 | Sansone
2269 | Sarge
2270 | Sargent
2271 | Sascha
2272 | Sasha
2273 | Saul
2274 | Sauncho
2275 | Saunder
2276 | Saunders
2277 | Saunderson
2278 | Saundra
2279 | Saw
2280 | Sawyer
2281 | Sawyere
2282 | Sax
2283 | Saxe
2284 | Saxon
2285 | Say
2286 | Sayer
2287 | Sayers
2288 | Sayre
2289 | Sayres
2290 | Scarface
2291 | Schroeder
2292 | Schuyler
2293 | Scot
2294 | Scott
2295 | Scotti
2296 | Scottie
2297 | Scotty
2298 | Seamus
2299 | Sean
2300 | Sebastian
2301 | Sebastiano
2302 | Sebastien
2303 | See
2304 | Selby
2305 | Selig
2306 | Serge
2307 | Sergeant
2308 | Sergei
2309 | Sergent
2310 | Sergio
2311 | Seth
2312 | Seymour
2313 | Shadow
2314 | Shaine
2315 | Shalom
2316 | Shamus
2317 | Shanan
2318 | Shane
2319 | Shannan
2320 | Shannon
2321 | Shaughn
2322 | Shaun
2323 | Shaw
2324 | Shawn
2325 | Shay
2326 | Shayne
2327 | Shea
2328 | Sheff
2329 | Sheffie
2330 | Sheffield
2331 | Sheffy
2332 | Shelby
2333 | Shelden
2334 | Sheldon
2335 | Shell
2336 | Shelley
2337 | Shelton
2338 | Shem
2339 | Shep
2340 | Shepard
2341 | Shepherd
2342 | Sheppard
2343 | Shepperd
2344 | Sheridan
2345 | Sherlock
2346 | Sherlocke
2347 | Sherman
2348 | Sherwin
2349 | Sherwood
2350 | Sherwynd
2351 | Shimon
2352 | Shlomo
2353 | Sholom
2354 | Shorty
2355 | Shumeet
2356 | Shurlock
2357 | Shurlocke
2358 | Shurwood
2359 | Si
2360 | Sibyl
2361 | Sid
2362 | Siddhartha
2363 | Sidnee
2364 | Sidney
2365 | Siegfried
2366 | Siffre
2367 | Sig
2368 | Sigfrid
2369 | Sigfried
2370 | Sigmund
2371 | Silas
2372 | Silvain
2373 | Silvan
2374 | Silvano
2375 | Silvanus
2376 | Silvester
2377 | Silvio
2378 | Sim
2379 | Simeon
2380 | Simmonds
2381 | Simon
2382 | Simone
2383 | Sinclair
2384 | Sinclare
2385 | Sivert
2386 | Siward
2387 | Skell
2388 | Skelly
2389 | Skip
2390 | Skipp
2391 | Skipper
2392 | Skippie
2393 | Skippy
2394 | Skipton
2395 | Sky
2396 | Skye
2397 | Skylar
2398 | Skyler
2399 | Slade
2400 | Slim
2401 | Sloan
2402 | Sloane
2403 | Sly
2404 | Smith
2405 | Smitty
2406 | Socrates
2407 | Sol
2408 | Sollie
2409 | Solly
2410 | Solomon
2411 | Somerset
2412 | Son
2413 | Sonnie
2414 | Sonny
2415 | Sparky
2416 | Spence
2417 | Spencer
2418 | Spense
2419 | Spenser
2420 | Spike
2421 | Spiro
2422 | Spiros
2423 | Spud
2424 | Srinivas
2425 | Stacy
2426 | Staffard
2427 | Stafford
2428 | Staford
2429 | Stan
2430 | Standford
2431 | Stanfield
2432 | Stanford
2433 | Stanislaw
2434 | Stanleigh
2435 | Stanley
2436 | Stanly
2437 | Stanton
2438 | Stanwood
2439 | Stavros
2440 | Stearn
2441 | Stearne
2442 | Stefan
2443 | Stefano
2444 | Steffen
2445 | Stephan
2446 | Stephanus
2447 | Stephen
2448 | Sterling
2449 | Stern
2450 | Sterne
2451 | Steve
2452 | Steven
2453 | Stevie
2454 | Stevy
2455 | Stew
2456 | Steward
2457 | Stewart
2458 | Stig
2459 | Stillman
2460 | Stillmann
2461 | Sting
2462 | Stinky
2463 | Stirling
2464 | Stu
2465 | Stuart
2466 | Sturgis
2467 | Sullivan
2468 | Sully
2469 | Sumner
2470 | Sunny
2471 | Sutherland
2472 | Sutton
2473 | Sven
2474 | Swen
2475 | Syd
2476 | Sydney
2477 | Sylvan
2478 | Sylvester
2479 | Tab
2480 | Tabb
2481 | Tabbie
2482 | Tabby
2483 | Taber
2484 | Tabor
2485 | Tad
2486 | Tadd
2487 | Taddeo
2488 | Taddeus
2489 | Tadeas
2490 | Tailor
2491 | Tait
2492 | Taite
2493 | Talbert
2494 | Talbot
2495 | Tallie
2496 | Tally
2497 | Tam
2498 | Tamas
2499 | Tammie
2500 | Tammy
2501 | Tan
2502 | Tann
2503 | Tanner
2504 | Tanney
2505 | Tannie
2506 | Tanny
2507 | Tarrance
2508 | Tarrant
2509 | Tarzan
2510 | Tate
2511 | Taylor
2512 | Teador
2513 | Ted
2514 | Tedd
2515 | Teddie
2516 | Teddy
2517 | Tedie
2518 | Tedman
2519 | Tedmund
2520 | Tedrick
2521 | Temp
2522 | Temple
2523 | Templeton
2524 | Teodoor
2525 | Teodor
2526 | Teodorico
2527 | Teodoro
2528 | Terence
2529 | Terencio
2530 | Terrance
2531 | Terrel
2532 | Terrell
2533 | Terrence
2534 | Terri
2535 | Terrill
2536 | Terry
2537 | Thacher
2538 | Thad
2539 | Thaddeus
2540 | Thaddius
2541 | Thaddus
2542 | Thadeus
2543 | Thain
2544 | Thaine
2545 | Thane
2546 | Tharen
2547 | Thatch
2548 | Thatcher
2549 | Thaxter
2550 | Thayne
2551 | Thebault
2552 | Thedric
2553 | Thedrick
2554 | Theo
2555 | Theobald
2556 | Theodor
2557 | Theodore
2558 | Theodoric
2559 | Theophyllus
2560 | Thibaud
2561 | Thibaut
2562 | Thom
2563 | Thomas
2564 | Thor
2565 | Thorn
2566 | Thorndike
2567 | Thornie
2568 | Thornton
2569 | Thorny
2570 | Thorpe
2571 | Thorstein
2572 | Thorsten
2573 | Thorvald
2574 | Thurstan
2575 | Thurston
2576 | Tibold
2577 | Tiebold
2578 | Tiebout
2579 | Tiler
2580 | Tim
2581 | Timmie
2582 | Timmy
2583 | Timothee
2584 | Timotheus
2585 | Timothy
2586 | Tirrell
2587 | Tito
2588 | Titos
2589 | Titus
2590 | Tobe
2591 | Tobiah
2592 | Tobias
2593 | Tobie
2594 | Tobin
2595 | Tobit
2596 | Toby
2597 | Tod
2598 | Todd
2599 | Toddie
2600 | Toddy
2601 | Tom
2602 | Tomas
2603 | Tome
2604 | Tomkin
2605 | Tomlin
2606 | Tommie
2607 | Tommy
2608 | Tonnie
2609 | Tony
2610 | Tore
2611 | Torey
2612 | Torin
2613 | Torr
2614 | Torrance
2615 | Torre
2616 | Torrence
2617 | Torrey
2618 | Torrin
2619 | Torry
2620 | Town
2621 | Towney
2622 | Townie
2623 | Townsend
2624 | Towny
2625 | Trace
2626 | Tracey
2627 | Tracie
2628 | Tracy
2629 | Traver
2630 | Travers
2631 | Travis
2632 | Tray
2633 | Tre
2634 | Tremain
2635 | Tremaine
2636 | Tremayne
2637 | Trent
2638 | Trenton
2639 | Trev
2640 | Trevar
2641 | Trever
2642 | Trevor
2643 | Trey
2644 | Trip
2645 | Tristan
2646 | Troy
2647 | Truman
2648 | Tuck
2649 | Tucker
2650 | Tuckie
2651 | Tucky
2652 | Tudor
2653 | Tull
2654 | Tulley
2655 | Tully
2656 | Turner
2657 | Ty
2658 | Tybalt
2659 | Tye
2660 | Tyler
2661 | Tymon
2662 | Tymothy
2663 | Tynan
2664 | Tyrone
2665 | Tyrus
2666 | Tyson
2667 | Udale
2668 | Udall
2669 | Udell
2670 | Ugo
2671 | Ulberto
2672 | Uli
2673 | Ulick
2674 | Ulises
2675 | Ulric
2676 | Ulrich
2677 | Ulrick
2678 | Ulysses
2679 | Umberto
2680 | Upton
2681 | Urbain
2682 | Urban
2683 | Urbano
2684 | Urbanus
2685 | Uri
2686 | Uriah
2687 | Uriel
2688 | Urson
2689 | Vachel
2690 | Vaclav
2691 | Vail
2692 | Val
2693 | Valdemar
2694 | Vale
2695 | Valentin
2696 | Valentine
2697 | Van
2698 | Vance
2699 | Vasili
2700 | Vasilis
2701 | Vasily
2702 | Vassili
2703 | Vassily
2704 | Vaughan
2705 | Vaughn
2706 | Venkat
2707 | Verge
2708 | Vergil
2709 | Vern
2710 | Verne
2711 | Vernen
2712 | Verney
2713 | Vernon
2714 | Vernor
2715 | Vibhu
2716 | Vic
2717 | Vick
2718 | Victor
2719 | Vijay
2720 | Vilhelm
2721 | Vin
2722 | Vince
2723 | Vincent
2724 | Vincents
2725 | Vinnie
2726 | Vinny
2727 | Vinod
2728 | Virge
2729 | Virgie
2730 | Virgil
2731 | Virgilio
2732 | Vite
2733 | Vito
2734 | Vlad
2735 | Vladamir
2736 | Vladimir
2737 | Voltaire
2738 | Von
2739 | Wade
2740 | Wadsworth
2741 | Wain
2742 | Waine
2743 | Wainwright
2744 | Wait
2745 | Waite
2746 | Waiter
2747 | Wake
2748 | Wakefield
2749 | Wald
2750 | Waldemar
2751 | Walden
2752 | Waldo
2753 | Waldon
2754 | Waleed
2755 | Walker
2756 | Wallace
2757 | Wallache
2758 | Wallas
2759 | Wallie
2760 | Wallis
2761 | Wally
2762 | Walsh
2763 | Walt
2764 | Walter
2765 | Walther
2766 | Walton
2767 | Wang
2768 | Ward
2769 | Warde
2770 | Warden
2771 | Ware
2772 | Waring
2773 | Warner
2774 | Warren
2775 | Wash
2776 | Washington
2777 | Wat
2778 | Waverley
2779 | Waverly
2780 | Way
2781 | Waylan
2782 | Wayland
2783 | Waylen
2784 | Waylin
2785 | Waylon
2786 | Wayne
2787 | Web
2788 | Webb
2789 | Weber
2790 | Webster
2791 | Weidar
2792 | Weider
2793 | Welbie
2794 | Welby
2795 | Welch
2796 | Wells
2797 | Welsh
2798 | Wendall
2799 | Wendel
2800 | Wendell
2801 | Werner
2802 | Wes
2803 | Wesley
2804 | Weslie
2805 | West
2806 | Westbrook
2807 | Westbrooke
2808 | Westleigh
2809 | Westley
2810 | Weston
2811 | Weylin
2812 | Wheeler
2813 | Whit
2814 | Whitaker
2815 | Whitby
2816 | Whitman
2817 | Whitney
2818 | Whittaker
2819 | Wiatt
2820 | Wilber
2821 | Wilbert
2822 | Wilbur
2823 | Wilburn
2824 | Wilburt
2825 | Wilden
2826 | Wildon
2827 | Wilek
2828 | Wiley
2829 | Wilfred
2830 | Wilfrid
2831 | Wilhelm
2832 | Will
2833 | Willard
2834 | Willdon
2835 | Willem
2836 | Willey
2837 | Willi
2838 | William
2839 | Willie
2840 | Willis
2841 | Willmott
2842 | Willy
2843 | Wilmar
2844 | Wilmer
2845 | Wilson
2846 | Wilt
2847 | Wilton
2848 | Win
2849 | Windham
2850 | Winfield
2851 | Winford
2852 | Winfred
2853 | Winifield
2854 | Winn
2855 | Winnie
2856 | Winny
2857 | Winslow
2858 | Winston
2859 | Winthrop
2860 | Winton
2861 | Wit
2862 | Witold
2863 | Wittie
2864 | Witty
2865 | Wojciech
2866 | Wolf
2867 | Wolfgang
2868 | Wolfie
2869 | Wolfram
2870 | Wolfy
2871 | Woochang
2872 | Wood
2873 | Woodie
2874 | Woodman
2875 | Woodrow
2876 | Woody
2877 | Worden
2878 | Worth
2879 | Worthington
2880 | Worthy
2881 | Wright
2882 | Wyatan
2883 | Wyatt
2884 | Wye
2885 | Wylie
2886 | Wyn
2887 | Wyndham
2888 | Wynn
2889 | Wynton
2890 | Xavier
2891 | Xenos
2892 | Xerxes
2893 | Xever
2894 | Ximenes
2895 | Ximenez
2896 | Xymenes
2897 | Yaakov
2898 | Yacov
2899 | Yale
2900 | Yanaton
2901 | Yance
2902 | Yancey
2903 | Yancy
2904 | Yank
2905 | Yankee
2906 | Yard
2907 | Yardley
2908 | Yehudi
2909 | Yigal
2910 | Yule
2911 | Yuri
2912 | Yves
2913 | Zach
2914 | Zacharia
2915 | Zachariah
2916 | Zacharias
2917 | Zacharie
2918 | Zachary
2919 | Zacherie
2920 | Zachery
2921 | Zack
2922 | Zackariah
2923 | Zak
2924 | Zalman
2925 | Zane
2926 | Zared
2927 | Zary
2928 | Zeb
2929 | Zebadiah
2930 | Zebedee
2931 | Zebulen
2932 | Zebulon
2933 | Zechariah
2934 | Zed
2935 | Zedekiah
2936 | Zeke
2937 | Zelig
2938 | Zerk
2939 | Zeus
2940 | Zippy
2941 | Zollie
2942 | Zolly
2943 | Zorro
2944 |
--------------------------------------------------------------------------------