Skip to content
This repository has been archived by the owner on Jun 25, 2020. It is now read-only.
/ wikidata-to-gedcom Public archive

use wikidata lineage to generate a gedcom file

License

Notifications You must be signed in to change notification settings

lmallez/wikidata-to-gedcom

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

complete refactor of this project here : https://github.com/lmallez/wikidata-tree-generator

wikidata-to-gedcom

use wikidata lineage to generate a gedcom file

Usage

usage: WikidataToGedcom.py [-h] [--max-depth MAX_DEPTH]
                           [--allow-men ALLOW_MEN]
                           [--men-descendants MEN_DESCENDANTS]
                           [--men-ascendants MEN_ASCENDANTS]
                           [--allow-women ALLOW_WOMEN]
                           [--women-descendants WOMEN_DESCENDANTS]
                           [--women-ascendants WOMEN_ASCENDANTS]
                           [--load-parents LOAD_PARENTS]
                           [--load-children LOAD_CHILDREN]
                           [--enable-correction ENABLE_CORRECTION]
                           [--thread-max THREAD_MAX]
                           id {all,desc,asc,linear} output
name type default description
id str wikidata id of the entity choose
method str {all, asc, desc, linear} method of gedcom generation (see bellow)
output str output file name
max_depth int 10 maximum number of generation differences
allow-mens bool True add men in gedcom
men-descendants bool True add men descendants (can't be activate if allow-men is false)
men-ascendants bool True add men ascendants (can't be activate if allow-men is false)
allow-womens bool True add women in gedcom
women-descendants bool True add women descendants (can't be activate if allow-women is false)
women-ascendants bool True add women ascendants (can't be activate if allow-women is false)
load-parents bool False add the parents of each character
load-children bool False add the children of each character
enable-correction bool True add missing wikidata links
thread-max int 100 maximum number of threads
methods of gedcom generation description
all all the family members (can take a long time to complete)
desc all the descendants of the root character
asc all the ascendants of the root character
linear combine desc and asc

beware of the different options you choose, some characters have a very large number of ancestors on wikidata

Samples

the generated images bellow are not created in this project, they are generated via the gramps software from the output gedcom

  • WikidataToGedcom.py Q9696 linear ../samples/Q9696_1.ged img

  • WikidataToGedcom.py Q9696 linear ../samples/Q9696_2.ged --load-children 1 --load-parents 1 img

  • WikidataToGedcom.py Q82339 desc ../sample Q82339 --allow-women 0 img

  • Q2042 all ../samples/Q2042.ged img

TODO

  • parse the name and use GIVN and SURN tags
  • use more properties of wikidata to fill gedcom (date of birth/death, weddings...)
  • find an appropriate way to enter into transactions when a wikidata entity has more than one parent

About

use wikidata lineage to generate a gedcom file

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages