Skip to main content

Easily turn HTML docs into solveit dialogs

Project description

dialogify

The Python Standard Library documentation is very helpful for learning Python. So is Solveit! Solveit is jupyter notebook + AI with superpowers. Learning programming is so much fun and productive with AI. Therefore, I wanted to convert these html python documentation pages into solveit dialogues, which comprise small pieces of notes and code messages with appropriate headings, which can be extracted from the pages’ table of contents.

How it works:

  • We first get the html from the python documentation web page.
  • We turn it into (msg_type, element) where msg_type is note or code and element is soup element.
  • Turn elements into appropriate solveit messages for the dialog.

The goal is to use # for the title, ## for subheading, and ### for each function definition from the docs.

Installation

Install latest from the GitHub repository:

$ pip install git+https://github.com/galopyz/dialogify.git

or from pypi

$ pip install dialogify

How to use

To create a solveit dialog from python documentation, we need to pass the url to mk_dialog. Below code creates solveit messages after that message.

from dialogify.core import *

mk_dialog('https://docs.python.org/3.12/library/random.html')

Here is an example dialog on solveit from random python libary. It also works on Built-in Functions.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dialogify-0.1.0.tar.gz (10.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dialogify-0.1.0-py3-none-any.whl (9.5 kB view details)

Uploaded Python 3

File details

Details for the file dialogify-0.1.0.tar.gz.

File metadata

  • Download URL: dialogify-0.1.0.tar.gz
  • Upload date:
  • Size: 10.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.12

File hashes

Hashes for dialogify-0.1.0.tar.gz
Algorithm Hash digest
SHA256 fb15d600dc44597bd4f66016bc1da674a799cba7b27e3a6eb04f7774aff40ba7
MD5 766e7863e7ca2809473bf21590da80ae
BLAKE2b-256 8c03e4c45ad602b8bba651e95260fd338a473be15eb68b3c5707b067cb9d3e3b

See more details on using hashes here.

File details

Details for the file dialogify-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: dialogify-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 9.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.12

File hashes

Hashes for dialogify-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 22d5a888241dbe615a2435f3dc935ab3bb6b7bded9673ab576dedd31f74e4217
MD5 1df4d39b435347b1c7d7de4c8a43a56a
BLAKE2b-256 3ae7caa7b078a6de18a5682015c521c95e4504ad23c7ec8c1b539b41f403b2b9

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page