Repository navigation
Better/Alternate HTML to markdown conversion. #372
MrDowntempo
started this conversation in
Ideas
Replies: 5 comments 4 replies
|
I use with |
0 replies
|
I implemented a version of this in the repo. This implementation just uses variables to enable or disable commands which all run in a pipeline. The available variables are [edit:] specified below. I only did a quick check and markitdown and html-to-markdown seemed to work. I didn't actually test rdrview and pulled the command from the documentation. |
0 replies
|
Potential alternative variable structure that I’m considering: |
4 replies
|
This functionality is now available via the |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
In getting used to nb and setting up a notebook, I've needed to add a lot of bookmarks that I use as source or reference notes. Installing readability-cli has been a great addition. Prior to this I would use a Firefox extension https://github.com/notlmn/copy-as-markdown to just copy the relevant chunks of content into a fresh markdown note, but readability-cli does most of that for me now, and quicker. That said, the pandoc conversion isn't always as flawless. A number of issues I've run into:
Pandoc is great, but not specialized. But HTML to markdown is apparently a common enough conversion that some specialized tools have sprung up. I've recently been trying out https://github.com/JohannesKaufmann/html-to-markdown and getting a lot better results. It's fixed the 3 issues above.
There are some other tools like mrusme/reader which look promising, but I've yet to try that one out. It seems like it might work well with w3m too. There's also tools like microsoft's markitdown and IBM's docling that accomplish this via some LLM magic. Probably much too heavy, but they support pdf to markdown too which would be super handy as well.
readability-cli can also extract some data like the title and byline from certain pages. I had hoped it could extract the date of an article if it was available too, but it doesn't. Ideally I'd want an imported bookmark to grab the author and date the page was posted and make that available in the template and/or front-matter. Putting the source URL up there would likely be a bit cleaner too.
I'm curious if others have found better tools or solutions for converting pages to markdown and/or using webpages as references in other notes.
All reactions