BaseMax / qt-markdown-knowledge-base
A powerful desktop GUI application for managing a local Markdown-based knowledge base. Built with Python and PyQt5. Local-first Markdown knowledge base with search, tags, and previews. Desktop app built with Python and PyQt5.
README
Qt Markdown Knowledge Base
A powerful desktop GUI application for managing a local Markdown-based knowledge base. Built with Python and PyQt5.
Features
- ๐ Folder Indexing - Automatically indexes all markdown files in your knowledge base
- ๐ Full-Text Search - Search across all documents by title, content, or tags
- ๐ท๏ธ Tag Support - Organize documents with hashtags (#tag)
- ๐ Backlinks - Track wiki-style links ([[Document Name]]) between documents
- ๐๏ธ Live Preview - Real-time HTML preview of your markdown
- ๐ Syntax Highlighting - Beautiful markdown syntax highlighting in the editor
- ๐ Dark Mode - Easy on the eyes with dark mode support
- ๐ค Export - Export documents to HTML or PDF
- ๐พ Auto-Save - Automatic saving every 30 seconds
- ๐จ Clean Interface - Modern Qt-based user interface
Installation
Prerequisites
- Python 3.7 or higher
- pip (Python package installer)
Setup
-
Clone the repository:
git clone https://github.com/BaseMax/qt-markdown-knowledge-base.git cd qt-markdown-knowledge-base -
Install dependencies:
pip install -r requirements.txt -
(Optional) For PDF export, install wkhtmltopdf:
- Windows: Download from https://wkhtmltopdf.org/downloads.html
- macOS:
brew install wkhtmltopdf - Linux:
sudo apt-get install wkhtmltopdf
Usage
Run the application:
python main.py
Getting Started
-
Select Your Knowledge Base Folder
- On first run, the app creates a default folder at
~/MarkdownKB - Use
File > Open Folderto select a different location
- On first run, the app creates a default folder at
-
Create a New Document
- Click
Newor useCtrl+N(Cmd+N on macOS) - Enter a filename (
.mdextension is added automatically)
- Click
-
Write in Markdown
- Use standard markdown syntax
- Add tags with
#tagsyntax - Link to other documents with
[[Document Name]]
-
Search
- Use the search bar to find documents by title, content, or tags
- Results update in real-time
-
View Backlinks
- Switch to the "Backlinks" tab to see which documents link to the current one
-
Export
- Use
File > Export as HTMLorFile > Export as PDF
- Use
Keyboard Shortcuts
Ctrl+N/Cmd+N- New DocumentCtrl+O/Cmd+O- Open FolderCtrl+S/Cmd+S- Save DocumentCtrl+Q/Cmd+Q- QuitF5- Refresh Index
Project Structure
qt-markdown-knowledge-base/
โโโ main.py # Main application entry point
โโโ models.py # Data models (Document, KnowledgeBase)
โโโ editor.py # Markdown editor with syntax highlighting
โโโ renderer.py # Markdown rendering and export
โโโ requirements.txt # Python dependencies
โโโ README.md # This file
โโโ LICENSE # MIT License
Markdown Syntax Support
- Headers:
# H1,## H2,### H3, etc. - Bold:
**bold** - Italic:
*italic* - Code:
`inline code` - Code blocks:
```language ... ``` - Links:
[text](url) - Wiki Links:
[[Document Name]] - Tags:
#tag - Lists:
- itemor1. item - Blockquotes:
> quote - Tables: Standard markdown tables
- And more!
Configuration
Settings are automatically saved and include:
- Knowledge base folder location
- Dark mode preference
- Window size and position
Settings are stored in:
- Windows:
%APPDATA%/MarkdownKB/KnowledgeBase.ini - macOS:
~/Library/Preferences/com.MarkdownKB.KnowledgeBase.plist - Linux:
~/.config/MarkdownKB/KnowledgeBase.conf
Development
Running Tests
Currently, this project focuses on functionality. Tests can be added using pytest:
pip install pytest
pytest
Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Author
Max Base - GitHub
Acknowledgments
- Built with PyQt5
- Markdown rendering by Python-Markdown
- Syntax highlighting with Pygments
KiloClaw - Managed ๐ฆ 