stoichiograph

Spell words with elemental symbols from the periodic table.
git clone git://git.amin.space/stoichiograph.git
Log | Files | Refs | LICENSE

README.rst (2380B)


      1 Stoichiograph - The Elemental Speller
      2 =====================================
      3 
      4 Spell words with elemental symbols from the periodic table ("He", "Cu", etc). I
      5 made this when I was bored in Chemistry class. I wrote about the process of
      6 making it `here`_.
      7 
      8 .. figure:: https://cloud.githubusercontent.com/assets/5744114/21043177/7c3efe8c-bdaa-11e6-9c1a-22db4de6bb2f.png
      9     :alt: A list of four words and their elemental spellings
     10 
     11     Some words and their elemental spellings
     12 
     13 .. _here: https://www.amin.space/blog/2017/5/elemental_speller/
     14 
     15 
     16 Installation
     17 ------------
     18 
     19 .. code-block::
     20 
     21     $ pip install stoichiograph
     22 
     23 
     24 Usage
     25 -----
     26 
     27 .. code-block::
     28 
     29     usage: stoichiograph [-h] [-b BATCH_FILE] [-c] [--debug] [--list-elements]
     30                          [--export-graph] [-o OUTPUT_FILE] [-s] [-t] [-v] [-V]
     31                          [words [words ...]]
     32 
     33     Spell words with elemental symbols from the periodic table.
     34 
     35     positional arguments:
     36       words                 word(s) for which to find elemental spellings
     37 
     38     optional arguments:
     39       -h, --help            show this help message and exit
     40       -b BATCH_FILE, --batch-file BATCH_FILE
     41                             text file containing one word per line
     42       -c, --clobber         overwrite output file if it exists
     43       --debug               print debug log
     44       --list-elements       print list of elemental symbols and exit
     45       --export-graph        export graph of first word as dot code
     46       -o OUTPUT_FILE, --output-file OUTPUT_FILE
     47                             path of output json file
     48       -s, --sort            sort words by length
     49       -t, --tuples          display spellings as tuples
     50       -v, --verbose         print a detailed log
     51       -V, --version         print version info and exit
     52 
     53 
     54 Graph Export
     55 ------------
     56 
     57 Stoichiograph builds a graph to find a word's elemental spellings. Use the
     58 `--export-graph` option to output dot code that `graphviz`_ can use to generate
     59 an image of the graph.
     60 
     61 .. code-block:: bash
     62 
     63     $ stoichiograph --export-graph flashbacks | dot -Tpng -o word_graph.png
     64 
     65 .. figure:: https://cloud.githubusercontent.com/assets/5744114/26102406/abf1a33a-39e9-11e7-8bdb-fef168e8e0cf.png
     66     :alt: The file output by the above command
     67 
     68     A visualization of the directed acyclic graph of elemental spellings for
     69     'flashbacks'.
     70 
     71 
     72 .. _Graphviz: http://www.graphviz.org/Home.php