A demo application showcasing the PHP library markdown-object.
Markdown Object is a PHP library that intelligently parses and chunks Markdown documents for use in Retrieval-Augmented Generation (RAG) systems and embedding models. It maintains semantic coherence while splitting documents into manageable pieces.
Clone the repository:
git clone https://github.com/benbjurstrom/markdown-object-demo.git
cd markdown-object-demoInstall PHP dependencies:
composer installInstall JavaScript dependencies:
npm installBuild frontend assets:
npm run buildStart the development server:
php artisan serveThen visit http://localhost:8000 in your browser.
- Parse markdown instantly as you type
- Visual feedback with processing indicators
- Configurable chunking parameters
- Hierarchical chunking that maintains document structure
- Configurable target token size (128-8192)
- Hard cap limits to prevent oversized chunks (256-16384)
- Accurate token counting for embedding models
Chunks View
- See your markdown split into semantic chunks
- View token counts per chunk
- Track source line positions
- Copy all chunks in a text-friendly format
- Breadcrumb navigation showing document hierarchy
JSON View
- Inspect the complete structured markdown object
- Collapsible tree view
- Copy individual values
- Size indicators for arrays and objects
