<commit_before>[![Build Status](https://api.travis-ci.org/robx/puzzle-draw.png?branch=master)][travis]

puzzle-draw
===========

puzzle-draw is a library and command-line tool for drawing pencil
puzzles using [Diagrams][diagrams]. It aims to provide a utility layer
on top of Diagrams to help with drawing arbitrary puzzles, as well as
supporting several specific puzzle types directly. In addition, it
includes functionality for parsing puzzle data from a YAML file format.

Examples
--------

A [liar slitherlink][liarslither] with solution:

![Liar Slitherlink](test/examples/slitherlink-liar-example.png)

This was rendered from the following YAML document:

```
type: slitherlinkliar
puzzle: |
  1..0.3
  .03222
  0....1
  3....3
  32202.
  3.3..3
solution:
  loop: |
    . .-.-.-. .-.
      |     | | |
    . . .-.-. . .
      | |     | |
    . . .-.-.-. .
      |         |
    .-. . .-.-. .
    |     |   | |<commit_msg>link to image via githubusercontent.com<commit_after>[![Build Status](https://api.travis-ci.org/robx/puzzle-draw.png?branch=master)][travis]

puzzle-draw
===========

puzzle-draw is a library and command-line tool for drawing pencil
puzzles using [Diagrams][diagrams]. It aims to provide a utility layer
on top of Diagrams to help with drawing arbitrary puzzles, as well as
supporting several specific puzzle types directly. In addition, it
includes functionality for parsing puzzle data from a YAML file format.

Examples
--------

A [liar slitherlink][liarslither] with solution:

![Liar Slitherlink](https://raw.githubusercontent.com/robx/puzzle-draw/master/tests/examples/slitherlink-liar-example.png)

This was rendered from the following YAML document:

```
type: slitherlinkliar
puzzle: |
  1..0.3
  .03222
  0....1
  3....3
  32202.
  3.3..3
solution:
  loop: |
    . .-.-.-. .-.
      |     | | |
    . . .-.-. . .
      | |     | |
    . . .-.-.-. .
      |         |
    .-. . .-.-. .
    |     |   | |
{'fraction_non_alphanumeric': 0.1602266872746007, 'fraction_numerical': 0.020607934054611025, 'mean_word_length': 2.35405872193437, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 3, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 1, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '994450', 'n_tokens_mistral': 703, 'n_tokens_neox': 658, 'n_words': 170}