A user-friendly web interface for Fabric built with Svelte, Skeleton UI, and Mdsvex.
Alt: Screenshot of the Fabric web app dashboard showing pattern inputs and outputs.
Note
Requires Node.js ≥18 and Fabric installed globally (fabric --version to check).
From the Fabric root directory:
Using npm:
./web/scripts/npm-install.shOr using pnpm (recommended for speed):
./web/scripts/pnpm-install.shThese scripts install Svelte dependencies and patch PDF-to-Markdown libraries (e.g., pdfjs-dist, pdf-to-markdown). Link to scripts:npm-install.sh and pnpm-install.sh
Start Fabric's server in a separate terminal:
fabric --serve(This exposes Fabric's API at http://localhost:8080)
In the web/ directory:
Using npm:
npm run devOr using pnpm:
pnpm run devVisit http://localhost:5173 (default port).
Tip
Sync Svelte types if needed: npx svelte-kit sync
For Python enthusiasts, this alternative UI excels at data visualization and chaining complex patterns. It supports clipboard ops across platforms (install pyperclip on Windows, xclip on Linux).
- macOS: Uses
pbcopyandpbpaste(built-in) - Windows: Uses
pypercliplibrary (install withpip install pyperclip) - Linux: Uses
xclip(install withsudo apt-get install xclipor equivalent for your Linux distribution)
- Run and edit patterns with real-time previews.
- Analyze outputs with charts (via Matplotlib/Seaborn).
- Export results to Markdown or CSV.
From web/:
pip install -r requirements.txt #Or: pip install streamlit pandas matplotlib seaborn numpy python-dotenv pyperclip
streamlit run streamlit.pyAccess at http://localhost:8501 (default port).
Turn web/src/lib/content/ into an Obsidian vault for note-taking synced with Fabric patterns. It includes pre-configured .obsidian/ and templates/ folders.
- Open Obsidian: File > Open folder as vault > Select
web/src/lib/content/ - To publish posts, move them to the posts directory (
web/src/lib/content/posts). - Use Fabric patterns to generate content directly in Markdown files.
Tip
When creating new posts, make sure to include a date (YYYY-MM-DD), description, tags (e.g., #ai #patterns), and aliases for SEO. Only a date is needed to display a note. Embed images (), link patterns ([[pattern-name]]), or code blocks for reusable snippets—all in standard Markdown.
Refer to the Contributing Guide for details on how to improve this content.