TL;DR
Threlmark’s architecture treats the disk as the primary contract, making data portable, safe, and easily synchronized. This approach boosts offline resilience and simplifies multi-device workflows without relying on a central server.
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.
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.
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.

Samsung T7 Portable SSD, 1TB External Solid State Drive, Speeds Up to 1,050MB/s, USB 3.2 Gen 2, Reliable Storage for Gaming, Students, Professionals, MU-PC1T0T/AM, Gray
MADE FOR THE MAKERS: Create; Explore; Store; The T7 Portable SSD delivers fast speeds and durable features to…
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.
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.
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.
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.
256GB Flash Drive for iPhone Photo Stick,Thumb Drive USB Stick High Speed Transfer USB Drives External Picture Video Storage Memory Expansion for iPhone/iPad/PC (Blue)
Free Up Your iPhone Storage Space – With 256GB of additional storage capacity, you can easily transfer large…
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.
![Free Fling File Transfer Software for Windows [PC Download]](https://m.media-amazon.com/images/I/41Vq6ZqHfjL._SL500_.jpg)
Free Fling File Transfer Software for Windows [PC Download]
Intuitive interface of a conventional FTP client
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.
POST /api/projects/:id/
items/:itemId/reportDirect call. Applied immediately.
drop reports/.json
→ ingested on read Robust even if the server’s down at finish time.

Contemporary Project Management (MindTap Course List)
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.
Static read-only demo
Seeded data, writes to localStorage. Try-before-you-clone.
Personal Node instance
Password-gated, persistent backed-up THRELMARK_DATA_DIR.
Multi-tenant SaaS
Add accounts + per-tenant isolation. A separate build.
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.
Key Takeaways
- Treat the disk as the single source of truth—no database needed, just plain JSON files.
- Use one file per item to prevent race conditions and make updates atomic.
- Implement atomic writes by writing to a temp file then renaming, ensuring data safety.
- Design self-healing structures that reconcile and clean up automatically on each read.
- Sync changes by comparing file hashes and timestamps, resolving conflicts predictably.
What ‘disk is the contract’ really means in Threlmark
At its core, ‘disk is the contract’ means that the entire system’s state is stored in files on your disk. There’s no central server or database dictating the truth. Instead, your files are the source of truth, and every tool — whether it’s the app or an external script — reads or writes directly to these files.
Understanding this is crucial because it shifts the perspective from traditional centralized systems. Instead of relying on a server to maintain consistency, the system depends on the integrity of the files on your disk. This means that the reliability of your data hinges on proper file management—atomic writes, backups, and conflict resolution become vital. The advantage is that this approach makes the data inherently portable; you can move, copy, or back up your entire project simply by copying files. The tradeoff, however, is that managing consistency and synchronization requires careful design, since there’s no single source controlling the state. This decentralization empowers users with greater control and transparency but demands discipline in handling concurrent changes and conflicts.

How local-first architecture differs from traditional cloud apps
| Feature | Traditional Cloud Apps | Threlmark’s Local-First |
|---|---|---|
| Data storage | Server-side database | Local JSON files on disk |
| Offline work | Limited, syncs later | Full offline capability |
| Syncing | Background, often complex | Manual or automatic file-based sync |
| Resilience | Dependent on server availability | Works entirely offline |
| Portability | Limited, tied to platform |
The mechanics of syncing and conflict resolution
Syncing in Threlmark is built into the design—files are the protocol. When devices connect, they compare file modification timestamps and hashes. Changes are merged intelligently, preserving unknown fields to stay compatible. Conflicts are resolved based on timestamps or user intervention.
Understanding this process is important because it highlights the balance between simplicity and robustness. By relying on file hashes and timestamps, the system can quickly detect changes without complex state tracking. This enables a straightforward conflict resolution process—either automatically favoring the latest change or prompting the user to decide. The tradeoff here is that, while this approach is reliable for many scenarios, it may struggle with extremely high concurrency or complex merges. Nonetheless, for most typical use cases, this file-based sync offers a reliable and transparent way to keep multiple devices in sync, making conflicts predictable and manageable.

Why one file per item makes everything safer and faster
Instead of a big JSON array for all cards, Threlmark uses one file per item. This prevents race conditions and makes updates atomic. When a change happens, only one file is touched, so external tools can safely update individual cards without locking or coordination.
This design choice is significant because it reduces the risk of data corruption and simplifies recovery. If a file gets corrupted, only that specific item is affected, and restoring it is straightforward—just replace or revert that file. Speed-wise, updating individual files is faster because it avoids rewriting large datasets, and atomic writes ensure that partial updates don’t leave the data in an inconsistent state. The tradeoff is that managing many small files can become complex at scale, but for most projects, this approach offers a clear advantage in safety and speed, especially when combined with proper version control and backups.
How the system heals itself and keeps the board in sync
Threlmark’s board isn’t just a static list; it’s a self-healing structure. Every time you read the board, it compares the list of item IDs to the actual files in `items/`. Missing or orphaned IDs are cleaned up automatically, ensuring the visual representation reflects the true state of your data.
This process is crucial because it maintains consistency without manual intervention. If a file is deleted or corrupted, the system detects discrepancies during the next sync and corrects them—either by removing orphaned IDs or flagging issues for review. This auto-healing capability reduces manual maintenance and prevents inconsistencies from snowballing, which can be common in decentralized systems. It also means that even if external tools or accidental deletions occur, the system can recover gracefully, maintaining the integrity of your project view over time.

What it takes to build and maintain a disk-first system
Building a disk-first app requires discipline—atomic writes, tolerant merges, and clear folder structure. Threlmark uses a simple pattern: write to a temp file, then rename, to guarantee atomicity. It also merges updates carefully, keeping unknown fields to stay compatible.
Maintaining such a system involves regular backups, version control, and careful handling of external tools to avoid corrupting data. The key is designing processes that respect the file structure and ensure data integrity during concurrent modifications. The advantage is that you avoid the complexity of database migrations and lock management—your entire system remains transparent and portable. However, it demands consistent discipline and good practices, especially as the project scales. If managed well, it offers a resilient, flexible foundation for a variety of workflows.
Real-world example: Threlmark in action
Imagine a team using Threlmark to manage multiple projects. Each project has its own folder with JSON files for cards, boards, and dependencies. They work offline, move cards around, and add new ideas on the fly.
When they reconnect, the system syncs changes across devices—conflicts are resolved automatically or flagged for review. They even use external scripts to analyze data or generate reports by reading the same files.
This setup means their project stays alive and consistent, whether they’re in the office or on the road, with no server dependency.
