Skip to main content

Bechstein Tales (provider)

A provider skill for ovos-common-reading-pipeline-plugin, delivering Ludwig Bechstein's German fairy tales.

Bechstein was a contemporary of the Brothers Grimm and published his own hugely popular collection - a genuinely different source, not just "more Grimm" (though a few titles overlap, since both drew from the same regional oral tradition).

Tests PyPI version

This skill has no standalone voice interface. It registers no intents and never speaks. It only answers ovos.common_reading.* bus messages, so you also need ovos-common-reading-pipeline-plugin installed and added to your pipeline config for it to be useful at all.

German only, no translation. Same situation as ovos-skill-andrew-lang-tales, just for German instead of English - full fairy tale prose is a bigger translation cost/quality risk than a blog post or abstract. It answers searches made in German (de-*) and stays silent for every other language, and only loads where German is configured - the device language or secondary_langs (see "Languages" below).

Install

pip install ovos-skill-bechstein-tales ovos-common-reading-pipeline-plugin

Story index

The story index (title, anchor per story) is bundled with this package (locale/de-de/index.json), not scraped live - browsing/ matching needs no internet at all. Only fetching a specific story's actual text (once chosen) needs a live request to Project Gutenberg.

80 stories from Ludwig Bechstein's Märchenbuch (Project Gutenberg ebook #63465). The index was built once via scripts/build_index.py, which parses the book's own "Inhalt" (table of contents) table rather than assuming every <div class="chapter"> is a real story - one entry ("Alphabetisches Verzeichnis der Märchen", the book's own index) was correctly excluded this way since it has no story paragraphs.

Two real bugs were found and fixed while building this:

  • Encoding: the Gutenberg page doesn't declare a charset in its HTTP headers, so requests defaulted to ISO-8859-1 and mangled German text (Aschenbrödel → Aschenbrödel). Fixed by decoding the page as UTF-8 explicitly.
  • Drop caps: get_text(' ', strip=True) inserts a spurious space at drop-cap span boundaries (<span>E</span>s war einmal → E s war einmal, splitting the first word). Fixed by extracting text with no separator and instead collapsing the source HTML's line-wrapped whitespace with a regex - the same class of bug as ovos-skill-ovosblog's inline-<code> finding, different cause.

Fetching and what gets read

Reading a story fetches the book from Project Gutenberg once, extracts the text of all 80 stories, and keeps it on disk under the skill's cache directory (<XDG cache>/mycroft/skills/<skill_id>/, one small JSON file per story). Any other story, or the same story after a restart, needs no request. After 30 days a story is checked again with If-Modified-Since, which downloads nothing when the book has not changed; a change to the extractor (CACHE_FORMAT) fetches the book again. When a fetch fails, it is not tried again for five minutes, and an older copy is read meanwhile if there is one. When the cache directory cannot be written, the stories are kept in memory instead. Requests say who is asking: ovos-skill-bechstein-tales/<version> (+https://github.com/andlo/ovos-skill-bechstein-tales).

What is read is the tale, with its verse line by line (the bird's rhyme in Aschenbrödel is a <div class="verse"> and used to be skipped), without the page numbers printed in the middle of sentences or the two footnotes and their numbers.

Languages

The provider loads only where German is one of the languages the installation is configured for: the device's own lang, or one of secondary_langs in mycroft.conf. A single device in another language never loads it. A HiveMind hub whose users speak German lists it there, even when the hub's own language is something else:

{
  "lang": "en-US",
  "secondary_langs": ["de-DE"]
}

Once loaded, it decides per search whether to answer: a search made in German gets an answer, any other language gets none. The language of a search is the pipeline plugin's lang field, else the language of the session the search came from, else (an older plugin sends neither) the device's own language. That matters on a HiveMind hub, where one ovos-core serves many users at once, each session in its own language: a German session must get these stories on a hub whose own language is English, and a French session must not get German ones. A ping that names a language (the same way) only gets a pong when that is German. Fetching a story is never gated on language - it is addressed to this provider directly.

Title matching

Titles match regardless of case, umlauts, punctuation, a leading article and a leading "Märchen vom" / "Vom" / "Von", so "rotkäppchen" finds Das Rotkäppchen and "schlaraffenland" Das Märchen vom Schlaraffenland at full confidence. The part before a title's first comma, or either half of an "X, oder Y" title, counts too, slightly below the whole title: "tischlein deck dich" finds Tischlein deck dich, Esel streck dich, Knüppel aus dem Sack. A search that names no title at all ("erzähl mir ein Märchen") gets one random story at confidence 0.9, or 1.0 when it named this collection.

Collection hints

Responds to collection_hint values like "bechstein", "ludwig bechstein", matched fuzzily (see COLLECTION_ALIASES in __init__.py).

Content type

Identifies as content_type: "story" or "tale". A search with a content_type hint for anything else gets no response from this provider.

Credits

Content sourced from Project Gutenberg. Scraping/extraction/caching logic ported from ovos-skill-andrew-lang-tales.

Category

Entertainment

Tags

#stories #fairytales #bechstein #german #provider

Metadata

Release files for ovos-skill-bechstein-tales 0.1.7

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ovos-skill-bechstein-tales 0.1.7
File Size Uploaded
ovos_skill_bechstein_tales-0.1.7.tar.gz 41.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for ovos-skill-bechstein-tales 0.1.7
File Interpreter ABI Platform
ovos_skill_bechstein_tales-0.1.7-py3-none-any.whl Python 3 none any Details

Total release size: 72.9 kB

Release files / ovos_skill_bechstein_tales-0.1.7.tar.gz

Download URL ovos_skill_bechstein_tales-0.1.7.tar.gz
Size 41.7 kB
Tags Source
SHA-256 checksum
How to use checksums
9041065541b11a280db52ad3df3d2cd2d1877ca6698d79c4df0eea0ce68c8d7c
BLAKE2b-256 checksum
How to use checksums
2105a80de07694a87bbd7fc204046f5a3cfd079bac82430185f0f04f8750c46f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 1, 2026.

Transparency log

Release files / ovos_skill_bechstein_tales-0.1.7-py3-none-any.whl

Download URL ovos_skill_bechstein_tales-0.1.7-py3-none-any.whl
Size 31.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e6b480c083e967fcbc65daa8f27725b432ab3d45ddf7012e694487a03bd0acf3
BLAKE2b-256 checksum
How to use checksums
7f0ec3d326a92459badde83ff931d0e1f813da211797e57f1210c947e2522a39
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 1, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.7 This release

2 release files

0.1.6

2 release files

0.1.5

2 release files

0.1.4

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page