TL;DR

Threlmark treats the disk as the system of record, making data portable, inspectable, and resilient. This approach boosts offline usability, simplifies sync, and enhances collaboration without relying on a central database.

Imagine a project management tool that works perfectly offline, is lightning-fast, and plays nicely with other tools—all without a cloud database in sight. That’s the promise of Threlmark’s local-first architecture. Here, the disk isn’t just storage; it’s the contract, the source of truth, and the backbone of the entire system.

In this article, you’ll see how this simple yet powerful decision shapes everything from concurrency to collaboration and how it can change how you think about building robust, flexible apps.

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
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.

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
Amazon

JSON file-based data storage tools

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
Real-World Android App Projects with Kotlin and Jetpack Compose: Build Production-Style Android Apps with Modern Architecture, API Integration, State Management, Local Data Storage, Practical Projects

Real-World Android App Projects with Kotlin and Jetpack Compose: Build Production-Style Android Apps with Modern Architecture, API Integration, State Management, Local Data Storage, Practical Projects

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
REXBETI 25Pcs Metal File Set, Premium Grade T12 Drop Forged Alloy Steel, Flat/Triangle/Half-round/Round Large File and 12pcs Needle Files with Carry Case, 6pcs Sandpaper, Brush, A Pair Working Gloves

REXBETI 25Pcs Metal File Set, Premium Grade T12 Drop Forged Alloy Steel, Flat/Triangle/Half-round/Round Large File and 12pcs Needle Files with Carry Case, 6pcs Sandpaper, Brush, A Pair Working Gloves

all the 16 pieces file are made by T12 Drop Forged Alloy Steel, the long lasting teeth were…

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

  • Design your system so the disk *is* the API—simple, transparent, and portable.
  • Making data portable and inspectable avoids lock-in and simplifies backups and migrations.
  • File-based, lock-free updates prevent race conditions and improve concurrency.
  • Offline-first means your system keeps working during outages, boosting reliability.
  • Open directory structures invite integrations, automation, and multi-tool collaboration.

How Threlmark Turns Disk Into the Single Source of Truth

In Threlmark, the on-disk layout isn’t just a storage choice—it’s the API. Every file, from project configs to individual cards, acts as a piece of the system’s heartbeat. This means no database, no server, just a well-structured folder of JSON files.

For example, each task card lives as its own file inside `items/`. Changes to a card are just atomic file writes. When you open Threlmark, it reads all these files—no need for network calls—and deduces what’s next based on the latest files. This setup makes the entire system transparent and portable.

How Threlmark Turns Disk Into the Single Source of Truth
How Threlmark Turns Disk Into the Single Source of Truth

Why Making Disk the Contract Supercharges Offline and Resilience

Making the disk the system’s contract means your data survives network outages without losing a beat. Threlmark can be used on a plane, in a basement, or in a remote cabin—anywhere with a disk and a file system.

Take a scenario: you plan a project while offline, update tasks, and the data stays safe on your local disk. When you reconnect, sync happens seamlessly, merging your changes with others’.

This approach ensures your work is never blocked by server issues, making your tools more reliable and your workflows smoother.

How Threlmark Handles Sync and Conflicts with Files

Syncing in Threlmark is all about file-based merges. When you connect devices, changes are merged based on timestamps and content, not locks or sessions. Conflicts get resolved by the system’s merge rules, preserving data integrity.

For example, if two devices edit the same task differently, the system compares the files, keeps the latest changes, and preserves any unknown fields—so no data gets lost or overwritten unexpectedly.

According to research, conflict resolution based on last-write-wins combined with tolerant merge strategies minimizes errors and keeps data consistent across devices [2].

How Threlmark Handles Sync and Conflicts with Files
How Threlmark Handles Sync and Conflicts with Files

How Performance and User Experience Benefit from Local-First Design

Because all reads and writes happen directly on your disk, responses are almost instant. No waiting for server round-trips. This makes the app feel snappy, like flipping through a deck of cards.

Imagine dragging a card from ‘To Do’ to ‘Done’—the update appears immediately, no lag, no loading spinner. Even on a slow internet connection, your experience remains smooth.

That speed isn’t just a nicety; it fundamentally changes how you work, making task management feel more natural and less frustrating.

The Practical Benefits of a File-Based, Lock-Free System

Using files instead of a database brings real-world advantages. You can back up your entire project by copying a folder. You can open and inspect individual JSON files with any editor. And you can migrate everything by copying files to a new system.

Threlmark’s design also avoids lock contention, so multiple tools or agents can update different parts of the system simultaneously, without stepping on each other’s toes.

Think of it like working with a set of interconnected notebooks—simple, transparent, and flexible.

The Practical Benefits of a File-Based, Lock-Free System
The Practical Benefits of a File-Based, Lock-Free System

How Threlmark’s Structure Supports Extensibility and Collaboration

Threlmark’s directory layout acts like a shared contract. External tools can add suggestions, report progress, or modify cards simply by reading and writing files in designated folders.

For example, an AI agent can place completed tasks into the `reports/` folder, then Threlmark picks them up and updates the system automatically. This openness encourages integrations and automation.

It’s a flexible system that invites others to participate without complex APIs or middleware.

Comparing Threlmark’s Approach with Traditional Client-Server Apps

AspectThrelmark (Local-First)Traditional Client-Server
Data StorageFiles on disk, API is filesystemDatabase + server API
Offline UsageFully functional offlineLimited, depends on server
SyncingMerge files, no lockSync engine, conflict resolution
ResilienceWorks during outagesFails without server
PortabilityEasy to backup/moveDependent on database format

Frequently Asked Questions

What does ‘disk is the contract’ really mean?

It means the on-disk files are the authoritative source of truth. The entire system reads, writes, and merges data directly from these files, making the data transparent, portable, and resilient.

How does this approach handle conflicts between devices?

Threlmark uses file-based merge strategies that compare timestamps and content. Conflicts are resolved by merging changes or choosing the latest, ensuring consistency without locks or complex protocols.

Can I still use cloud sync with this setup?

Absolutely. Because the data is just files, you can sync folders with Dropbox, Syncthing, or git. The architecture makes cloud sync an optional extension, not a requirement.

What happens if I lose my files?

Since everything is stored as plain files, backups are straightforward. Just copy the folder. For safety, use version control or cloud backups to keep your data secure.

Is this approach suitable for large-scale or multi-user systems?

It works well for personal, small-team, or automation-heavy setups. For large multi-user systems, you’ll need additional sync and conflict-resolution layers, but the core idea remains valuable.

Conclusion

Thinking of the disk as the system’s contract rewires how you build resilient, flexible software. It’s a tiny shift in perspective that unlocks offline resilience, effortless collaboration, and future-proof portability. When your data lives on the disk, you hold the entire system in your hands—safe, transparent, and ready to grow.

So, next time you architect a tool, ask yourself: does the disk *really* just hold data, or is it the contract that defines everything?

Comparing Threlmark’s Approach with Traditional Client-Server Apps
Comparing Threlmark’s Approach with Traditional Client-Server Apps
You May Also Like

Mac vs GPU Tower for Local LLMs: The Heat-and-Noise Tradeoff

Thorsten Meyer AI frames the local LLM hardware choice around speed, memory, heat and noise.

DuckDuckGo search saw 28% more visits after Google said people love AI mode

DuckDuckGo’s search traffic increased by 28% following Google’s assertion that users love AI Mode, highlighting shifts in user preferences amid AI-driven search changes.

Musk’s Colossus 1 AI supercomputer’s inefficient mixed-architecture design couldn’t be used to train Grok, so Anthropic’s using it for inference instead — Musk readies unified Blackwell-only Colossus 2 for frontier training and potential IPO

SpaceX’s Colossus 1 supercomputer, with mixed GPU architecture, is being leased to Anthropic to address its compute bottlenecks, raising questions about efficiency.

RoundupForge: The Data Layer

Thorsten Meyer AI has a RoundupForge data-layer page, but no technical details, release status or people behind it are confirmed.