TL;DR

Threlmark’s design treats the local disk as the primary source of truth, using plain JSON files for simple, portable, and offline-ready project management. This approach reduces complexity and boosts collaboration potential.

Imagine a project management tool that works perfectly offline, needs no server, and everyone can peek into its data directly on disk. That’s the bold promise of Threlmark’s approach. It’s a different kind of architecture—one that flips the usual cloud-first model on its head.

Instead of a database sitting in a server, Threlmark uses plain JSON files living on your disk. This simple, yet powerful idea—’disk is the contract’—shapes everything from concurrency to collaboration. Today, I’ll walk you through how this design works, why it’s so effective, and what it means for your own projects.

Disk is the contract: inside Threlmark’s architecture — ThorstenMeyerAI.com
ThorstenMeyerAI.com
Threlmark · Technical Deep-Dive
Threlmark · architecture

Disk is the contract: inside a local-first roadmap hub

A Next.js app on top of plain JSON files — no database, no cloud, no accounts. The key decision: the on-disk layout IS the API. Everything else cascades from taking that seriously.

Next.js · TypeScript · JSON-on-disk · MIT · part 2 of the Threlmark series
01The core decision

There is no server-of-record — the files are the record

The UI and any external tool reach the same files through the same discipline. The data root defaults to ~/.threlmark — home-based, because it’s a shared hub every one of your apps points at.

~/.threlmark/ ├─ threlmark.json # manifest ├─ links.json # dependency graph ├─ projects// │ ├─ project.json # meta + wipLimits │ ├─ board.json # lane ordering │ ├─ items/.json # ONE card per file ← source of truth │ ├─ suggestions/ # the Inbox (drop-zone) │ ├─ handoffs/ # recorded agent handoffs │ ├─ reports/ # agent report drop-zone │ └─ ROADMAP.md # human-readable mirror ├─ shared/items/ # cards many projects ref └─ archive/ # archived, still readable

Inspectable

Every artifact is a file you can cat, diff, grep, commit.

Portable · no lock-in

Back up with cp, sync with Dropbox / git, migrate trivially.

Interoperable

Any tool in any language joins by reading / writing files.

Restartable

No in-memory state to lose — stateless over the files.

02Making files safe
Hi-Spec 17 Piece Metal Hand & Needle File Tool Kit Set. Large & Small Mini T12 Carbon Steel Flat, Half-Round, Round & Triangle Files. Complete in a Zipper Case with a Brush

Hi-Spec 17 Piece Metal Hand & Needle File Tool Kit Set. Large & Small Mini T12 Carbon Steel Flat, Half-Round, Round & Triangle Files. Complete in a Zipper Case with a Brush

Versatile Filing for Every Task: Includes 4 full-length 12-inch machinist’s files and 12 metal needle files; perfect for…

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

Two disciplined patterns instead of a database

“Just use files” is easy to get wrong. These two patterns — ported from a battle-tested sibling app — are what make file-based state sound rather than reckless.

Pattern 1

Atomic writes

Write to a temp file in the same dir, then rename() over the target. Rename is atomic on one filesystem — a crash mid-write leaves the complete old file or the complete new one, never a half.

write .tmp-pid-rand fsync rename() over target
Pattern 2 · one file per item

The board heals itself

A single roadmap.json array races when two tools write at once. One file per card makes writes collision-free. Lane order lives in board.json and reconciles on read.

The payoff: an external tool never touches board.json. It writes an item file — the board fixes itself on Threlmark’s next read. Unknown keys are preserved, so the contract is forward-compatible.
03Derived, never stored
Information Technology Project Management (MindTap Course List)

Information Technology Project Management (MindTap Course List)

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

The numbers can’t drift from the files

Anything computable from item state is computed — so the displayed numbers can never disagree with the underlying JSON. Priority is the clearest example: it’s calculated on read, never persisted.

priority — computed on read

Impact weighted heaviest; effort the only axis that subtracts. Reused verbatim from the original tool, so imported cards rank identically.

priority = max(0, round(impact·3 + evidence·2 + fit·2effort·1.5))
a 5 / 5 / 5 / 4 card 29
work-item age
now − lane-entry time. Past threshold (dev 7d, ranked 21d, idea 60d) → stale.
cycle time
first DevelopmentDone. Derived from append-only transitions[].
throughput
items reaching Done per ISO week, 8-week window.
WIP
count per lane; over the cap shows 3 / 2 in red.
04The closed agent loop · press play
Forvencer 12 Pocket Project Organizer, 1/6-cut Tab Binder Organizer with Sticky Labels, Multi Pocket Folder with Zipper Pouch, Folder Binder Spiral Pocket Notebook, Office Supplies, Letter Size, Blue

Forvencer 12 Pocket Project Organizer, 1/6-cut Tab Binder Organizer with Sticky Labels, Multi Pocket Folder with Zipper Pouch, Folder Binder Spiral Pocket Notebook, Office Supplies, Letter Size, Blue

High-efficiency Paper Organizer: 12 pockets, 6 dividers with 1/6-cut assorted tabs in bright colors, and 36 blank viewable…

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

A handoff is a first-class flow event

The genuinely 2026-shaped part: most building is done by AI agents, so Threlmark closes the loop. Watch a card go from ranked to Done without anyone dragging it.

Handoff → report → self-move

The brief carries a reporting protocol. The agent reports through REST or the filesystem — and a done report moves the card itself.

Ranked
Add price-drop alertsscore 31 · ready
Development
Handed off 🤖
Done
▶ preferred — REST
POST /api/projects/:id/
items/:itemId/report

Direct call. Applied immediately.

▶ fallback — filesystem
drop reports/.json
→ ingested on read

Robust even if the server’s down at finish time.

🤖 claude done: price-drop alerts shipped · typecheck + lint + build passed — card moved to Done
05Portfolio score & deployment
Lovell DESTRUCT PRO - USB Hard Drive Eraser & Data Destruction Tool - 3 Phase Crytopgraphic Wipe - Super Fast SMART Technology - Multi-Drive Compatibility - Works With HDD, SSD, & External Hard Drives

Lovell DESTRUCT PRO – USB Hard Drive Eraser & Data Destruction Tool – 3 Phase Crytopgraphic Wipe – Super Fast SMART Technology – Multi-Drive Compatibility – Works With HDD, SSD, & External Hard Drives

PERMANENT DATA DESTRUCTION: Factory resetting is a flawed process that isn’t enough to keep deleted data from being…

As an affiliate, we earn on qualifying purchases.

As an affiliate, we earn on qualifying purchases.

A small formula, and an honest hosting caveat

Because items are globally addressable (/), the Portfolio ranks everything together by a status-weighted score — finishing beats starting, blockers get a boost.

Portfolio ranking — status-weighted

In-flight work floats to the top; bottlenecks cost the most, so blockers get nudged up.

score = priority · statusWeight (+ 0.1 · blockedCount · priority)
1.3
development
1.0
ranked
0.85
idea
0.15
done
Path 1

Static read-only demo

Seeded data, writes to localStorage. Try-before-you-clone.

Path 2

Personal Node instance

Password-gated, persistent backed-up THRELMARK_DATA_DIR.

Path 3

Multi-tenant SaaS

Add accounts + per-tenant isolation. A separate build.

The elegant part: the store interface src/lib/*/store.ts is the natural seam — the same boundary that keeps the local tool simple is the one you’d extend for multi-tenancy. The architecture doesn’t fight that future; it just doesn’t pay for it until you need it.
ThorstenMeyerAI.com
Threlmark · open source (MIT) · github.com/MeyerThorsten/threlmark · part 2 of a series · file layout, formula, weights & agent-loop channels are Threlmark’s actual mechanics.

Key Takeaways

  • Treat your disk as the ultimate source of truth by storing data in plain JSON files. This simplifies backup, migration, and interoperability.
  • Design your system so each item is a separate file, enabling atomic updates and reducing race conditions in collaborative workflows.
  • Leverage self-healing structures that automatically reconcile inconsistencies, maintaining data integrity without manual intervention.
  • Use file-based architecture for offline-first workflows, especially for small teams or solo projects that value transparency and portability.
  • Be mindful of scalability and conflict resolution limitations; this approach works best in controlled, small-to-medium environments.

What ‘Disk Is the Contract’ Really Means For Your Data

At its core, ‘disk is the contract’ means your data lives in plain files on your computer. No middleman, no cloud service. When you open Threlmark, you’re directly reading and writing these JSON files, which serve as the ultimate source of truth.

It’s like having your project roadmap written in a notebook—accessible, editable, and portable. If you copy that notebook or back it up, you’ve got your entire project history. No database, no server dependency. This approach makes your data transparent and easy to manage.

What 'Disk Is the Contract' Really Means For Your Data
What ‘Disk Is the Contract’ Really Means For Your Data

Why Plain Files and JSON Make Life Easier

Plain files, especially JSON, are incredibly attractive because they’re human-readable and easy to edit. You can open them in any text editor, see exactly what’s inside, and even tweak them manually if needed.

For example, Threlmark keeps each project card as a separate JSON file in the items/ folder. Want to add a priority? Change a status? Just edit that one file. No complicated migrations or schema updates—just straightforward files that grow with your needs.

Plus, JSON’s structure is flexible. You can add new fields without breaking old tools—think of it like adding new pages to a notebook without ruining the old notes.

How Local-First Design Changes Your Workflow

Using Threlmark feels different from traditional cloud apps. You can work offline, immediately see your changes, and trust that your local files are the real record. When you reconnect, syncing happens seamlessly.

Imagine working on a plane, with no internet, and still updating your roadmap. When you land, Threlmark syncs with your other devices, merging changes—conflicts are handled gracefully because each file is atomic.

This approach reduces the cognitive load: no loading screens, no waiting for server responses. Your data is always just a file away.

How Local-First Design Changes Your Workflow
How Local-First Design Changes Your Workflow

Sync, Conflicts, and How Files Keep It Simple

Syncing in a file-based system is surprisingly straightforward. Each item gets its own file, so updates are atomic. When two devices edit the same card, Threlmark uses simple rules—last write wins or manual conflict resolution—to keep things consistent.

For example, if two laptops update the same task, the last one to save overwrites the other. But because each change is just a file write, conflicts are easy to spot and fix.

This simplicity contrasts sharply with complex databases that need elaborate conflict resolution strategies. Here, transparency and atomic operations make everything safer and more predictable.

The Power of Self-Healing Boards and Data Integrity

Threlmark’s board structure self-heals—meaning it constantly checks itself against the actual files. If a card is missing from the lane order but exists in items/, it reappears. This keeps your project view consistent without manual cleanup.

For example, if you accidentally delete a lane or a card, the system automatically detects and restores it on the next read, preserving data integrity.

This design reduces errors and keeps your project data trustworthy, even if you edit files outside the app or encounter interruptions.

The Power of Self-Healing Boards and Data Integrity
The Power of Self-Healing Boards and Data Integrity

Interoperability and External Tools: Making Files Play Nice

Because the data lives as plain files, any tool can join the party. Want to automate task creation? Just write a script that adds a JSON file. Need to visualize dependencies? Read the JSON and generate a graph. Learn more about practical knowledge and systems thinking.

Threlmark’s design invites collaboration from outside developers. They can peek, modify, or extend the system without a custom API or SDK.

For instance, an external AI tool could suggest new cards by creating JSON files in the suggestions/ folder, and Threlmark picks them up automatically.

Operational Tradeoffs: When Files Get Tricky

While simple and transparent, file-based systems aren’t perfect. Handling conflicts across devices can get messy if many people edit the same file simultaneously. Discover more about local-first architectures.

Schema changes require careful migration—adding new fields or changing structure can break older tools if not handled gracefully.

And as projects grow, managing thousands of files might slow down your system. But for many small to medium teams, these tradeoffs are manageable and worth the benefits.

Operational Tradeoffs: When Files Get Tricky
Operational Tradeoffs: When Files Get Tricky

Use Cases Where Threlmark Shines Bright

Threlmark excels in scenarios where offline access, transparency, and portability matter. Solo developers, small teams, or projects that need easy backups find it ideal. Explore sustainable living practices.

Imagine a remote software team working in the woods, disconnected from the internet. They can still update their project roadmap, then sync once connected. Threlmark keeps things simple and reliable.

It’s perfect for personal projects, research workflows, or any environment where control over data beats reliance on cloud services.

Where This Approach Might Fail You

If your team needs real-time collaboration across many users, a file-based system can become a headache. Conflicts multiply, and managing schema evolution gets complicated. Learn about the limitations of local-first systems.

Large-scale projects with hundreds or thousands of files may slow down, and conflict resolution might require custom tools or manual intervention.

In those cases, a database-backed system with server-side logic might be a better fit. Threlmark’s strength lies in simplicity, not scale.

Where This Approach Might Fail You
Where This Approach Might Fail You

Comparison: Threlmark vs. Traditional Local-First Tools

FeatureThrelmarkDatabase-Backed Systems
Data StoragePlain JSON files on diskSQL/NoSQL databases
Offline SupportExcellent — data is local
Sync ConflictsSimple, file-based rules
Setup ComplexityMinimal — just files and folders
ScalabilityLimited — best for small/medium
InteroperabilityHigh — any tool can read/write files

Frequently Asked Questions

What does ‘Disk Is the Contract’ really mean in practice?

It means your app’s data lives directly on your disk as plain files, especially JSON. This makes your data transparent, portable, and easy to manage without relying on a server or database.

How does Threlmark handle conflicts when multiple devices edit the same file?

It uses simple rules like last-writer-wins and atomic file operations. Conflicts are visible and easy to resolve because each change is just a file update.

Can this system support team collaboration across many devices?

Yes, but with caveats. It works best for small teams or solo projects. Large, highly collaborative environments may face conflict management challenges and slower performance.

How do I migrate schema or add new features?

You need to update your files carefully, often adding new fields or formats. Many tools handle this gracefully by preserving unknown keys, making schema evolution manageable.

Is this approach suitable for large-scale projects?

For very big projects or many concurrent users, a database-backed system might be better. File-based systems excel in simplicity and offline work, not raw scale.

Conclusion

Threlmark’s ‘disk is the contract’ architecture proves that simplicity can power robust, offline-capable tools. By making files the central source of truth, you gain transparency, portability, and resilience.

For your next project, ask: can I treat my disk as the ultimate record? If so, you might just find that less truly is more.

You May Also Like

What Makes Water Such a Powerful Solvent?

Inequalities in water’s molecular structure enable it to dissolve countless substances, but the full explanation reveals even more fascinating details.

How Do Batteries Generate Electricity?

Chemistry fuels batteries’ electricity, but understanding how electrons flow reveals the fascinating processes that power your devices.

Why Do Some Metals Conduct Better Than Others?

Just how free electrons and crystal structures influence metal conductivity remains a fascinating topic worth exploring further.

What Causes Fireworks to Display Different Colors?

Unlock the colorful secrets behind fireworks and discover how specific metals create dazzling hues, but the full explanation might surprise you.