<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Tlaplus on Andrew Helwer</title>
    <link>https://ahelwer.ca/tags/tlaplus/</link>
    <description>Recent content in Tlaplus on Andrew Helwer</description>
    <generator>Hugo</generator>
    <language>en-us</language>
    <lastBuildDate>Fri, 04 Jul 2025 00:00:00 +0000</lastBuildDate>
    <atom:link href="https://ahelwer.ca/tags/tlaplus/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>A supposedly worthwhile contract I&#39;ll never do again</title>
      <link>https://ahelwer.ca/post/2025-07-04-tla-contracts/</link>
      <pubDate>Fri, 04 Jul 2025 00:00:00 +0000</pubDate>
      <guid>https://ahelwer.ca/post/2025-07-04-tla-contracts/</guid>
      <description>&lt;p&gt;Here I&amp;rsquo;ll talk about a type of TLA⁺ contract I&amp;rsquo;ve worked on a few times, and why it didn&amp;rsquo;t work out as well as hoped.&#xA;I&amp;rsquo;m not trying to torpedo other peoples&amp;rsquo; contracts here - I just hope to share this experience so others can structure their TLA⁺ contracts differently, hopefully leading to greater success for both parties and industry usage of TLA⁺ as a whole.&lt;/p&gt;&#xA;&lt;h1 id=&#34;the-proposal&#34;&gt;The proposal&lt;/h1&gt;&#xA;&lt;p&gt;The contract proposal goes like this: a client wants to build a distributed system, and has read that TLA⁺ is effective at modeling such things.&#xA;Conventional wisdom holds that it&amp;rsquo;s always cheaper to catch bugs earlier in the development pipeline, and what&amp;rsquo;s earlier than the design stage?&#xA;However, they don&amp;rsquo;t have any in-house TLA⁺ knowledge and are unsure about whether they want to invest in training or hiring.&#xA;Instead, they email me a proposal: could I do a short 1-3 month contract where I specify their system in TLA⁺ for them?&#xA;The benefits of this setup are generally reasoned as follows:&lt;/p&gt;</description>
    </item>
    <item>
      <title>The current state of TLA⁺ development</title>
      <link>https://ahelwer.ca/post/2025-05-15-tla-dev-status/</link>
      <pubDate>Thu, 15 May 2025 00:00:00 +0000</pubDate>
      <guid>https://ahelwer.ca/post/2025-05-15-tla-dev-status/</guid>
      <description>&lt;p&gt;The &lt;a href=&#34;https://conf.tlapl.us/2025-etaps/&#34;&gt;2025 TLA⁺ Community Event&lt;/a&gt; was held last week on May 4th at McMaster University in Hamilton, Ontario, Canada.&#xA;It was a satellite event to &lt;a href=&#34;https://etaps.org/2025/&#34;&gt;ETAPS 2025&lt;/a&gt;, which I also attended, and plan to write about in the near future.&#xA;I gave a talk somewhat-hucksterishly titled &lt;em&gt;It&amp;rsquo;s never been easier to write TLA⁺ tooling!&lt;/em&gt; which I will spin into a general account of the state of TLA⁺ development here.&#xA;The conference talks were all recorded, so if you&amp;rsquo;d like this blog post in video form you can watch it below:&lt;/p&gt;</description>
    </item>
    <item>
      <title>TLA⁺ is more than a DSL for breadth-first search</title>
      <link>https://ahelwer.ca/post/2024-09-18-tla-bfs-dsl/</link>
      <pubDate>Wed, 18 Sep 2024 00:00:00 +0000</pubDate>
      <guid>https://ahelwer.ca/post/2024-09-18-tla-bfs-dsl/</guid>
      <description>&lt;p&gt;Although it isn&amp;rsquo;t usually taught that way, a lot of TLA⁺ newcomers develop the understanding that TLA⁺ is just a fancy domain-specific language (DSL) for breadth-first search.&#xA;If you want to model all possible executions of a concurrent system - so the thinking goes - all you have to do is define:&lt;/p&gt;&#xA;&lt;ol&gt;&#xA;&lt;li&gt;The set of variables modeling your system&lt;/li&gt;&#xA;&lt;li&gt;The values of those variables in the initial state(s)&lt;/li&gt;&#xA;&lt;li&gt;Possible actions changing those variables to generate successor states&lt;/li&gt;&#xA;&lt;li&gt;Safety invariants you want to be true in every state&lt;/li&gt;&#xA;&lt;/ol&gt;&#xA;&lt;p&gt;The model checker will then use breadth-first search (BFS) to churn through all possible states (&amp;amp; thus execution orders) of your system, validating your invariants.&#xA;If one of your invariants fails, BFS gives you the shortest execution path reaching that state.&#xA;It even checks for deadlock by finding states with no possible successor states.&lt;/p&gt;</description>
    </item>
    <item>
      <title>TLA⁺ Unicode support</title>
      <link>https://ahelwer.ca/post/2024-05-28-tla-unicode/</link>
      <pubDate>Tue, 28 May 2024 00:00:00 +0000</pubDate>
      <guid>https://ahelwer.ca/post/2024-05-28-tla-unicode/</guid>
      <description>&lt;p&gt;TLA⁺ was developed by Leslie Lamport, originator of \(\LaTeX\), so it&amp;rsquo;s unsurprising that TLA⁺ syntax looks pretty \(\LaTeX\)-y.&#xA;It&amp;rsquo;s a very mathy language, with much use of symbols like (among others) &lt;code&gt;\A&lt;/code&gt;,&lt;code&gt;\E&lt;/code&gt;, &lt;code&gt;/\&lt;/code&gt;, &lt;code&gt;\/&lt;/code&gt;, and &lt;code&gt;\in&lt;/code&gt; denoting \(\forall\), \(\exists\), \(\land\), \(\lor\), and \(\in\) respectively.&#xA;The language tools include a &lt;code&gt;tla2tex&lt;/code&gt; command to format TLA⁺ specs into \(\LaTeX\) for integration in research papers.&#xA;However, research papers are not where I spend the most time looking at TLA⁺.&#xA;Here&amp;rsquo;s the tale of how I brought those beautiful symbols into the code editor, and how I learned to work with others in FOSS along the way!&lt;/p&gt;</description>
    </item>
    <item>
      <title>Wrangling monotonic systems in TLA⁺</title>
      <link>https://ahelwer.ca/post/2023-11-01-tla-finite-monotonic/</link>
      <pubDate>Wed, 01 Nov 2023 00:00:00 +0000</pubDate>
      <guid>https://ahelwer.ca/post/2023-11-01-tla-finite-monotonic/</guid>
      <description>&lt;p&gt;TLA⁺ sees a lot of use modeling distributed systems.&#xA;The ability to explore all possible interleavings of events makes concurrency simple to reason about.&#xA;For this TLA⁺ uses something called finite model-checking, which is really just a breadth-first search through the entire state space.&#xA;The key here - and this really must be emphasized - is that the model is &lt;em&gt;finite&lt;/em&gt;.&#xA;There can&amp;rsquo;t be an infinite number of states, or of course the model checker will run forever.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Using TLA⁺ at Work</title>
      <link>https://ahelwer.ca/post/2023-04-05-checkpoint-coordination/</link>
      <pubDate>Wed, 05 Apr 2023 00:00:00 +0000</pubDate>
      <guid>https://ahelwer.ca/post/2023-04-05-checkpoint-coordination/</guid>
      <description>&lt;p&gt;Here&amp;rsquo;s a short report of a time I used TLA⁺ at work, with interesting results.&#xA;TLA⁺ is a formal specification language that is particularly effective when applied to concurrent &amp;amp; distributed systems.&#xA;TLA⁺ made it tractable for an ordinary software engineer to reason about a tricky distributed systems problem, and it found a bug introduced by an &amp;ldquo;optimization&amp;rdquo; I tried to add (classic).&#xA;The bug required 12 sequential steps to occur and would not have been uncovered by ordinary testing.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Pseudocode Showdown</title>
      <link>https://ahelwer.ca/post/2023-03-30-pseudocode/</link>
      <pubDate>Thu, 30 Mar 2023 00:00:00 +0000</pubDate>
      <guid>https://ahelwer.ca/post/2023-03-30-pseudocode/</guid>
      <description>&lt;p&gt;Last weekend I had a conversation with an undergraduate student new to computer science, who was reading &lt;a href=&#34;https://en.wikipedia.org/wiki/Introduction_to_Algorithms&#34;&gt;CLRS&lt;/a&gt;.&#xA;&amp;ldquo;I wish&amp;rdquo; they said, &amp;ldquo;that all the pseudocode in my algorithms textbook was just written in Python.&amp;rdquo;&#xA;&amp;ldquo;Ah&amp;rdquo; I said, &amp;ldquo;but textbook authors sometimes want their work to endure beyond a decade.&amp;rdquo;&#xA;&amp;ldquo;But Python&amp;rsquo;s been around for a long time&amp;rdquo; came the reply, &amp;ldquo;and it&amp;rsquo;s very readable, and you can&amp;rsquo;t execute pseudocode anyway so what&amp;rsquo;s the harm?&amp;rdquo;&lt;/p&gt;</description>
    </item>
    <item>
      <title>Writing a TLA⁺ tree-sitter grammar</title>
      <link>https://ahelwer.ca/post/2023-01-11-tree-sitter-tlaplus/</link>
      <pubDate>Wed, 11 Jan 2023 00:00:00 +0000</pubDate>
      <guid>https://ahelwer.ca/post/2023-01-11-tree-sitter-tlaplus/</guid>
      <description>&lt;p&gt;2021 saw the completion of my first substantial free software project: a &lt;a href=&#34;https://en.wikipedia.org/wiki/TLA%2B&#34;&gt;TLA⁺&lt;/a&gt; grammar for &lt;a href=&#34;https://tree-sitter.github.io/tree-sitter/&#34;&gt;tree-sitter&lt;/a&gt;, the error-tolerant incremental parser generator.&#xA;The project stabilized &amp;amp; found users over the course of 2022, then over the holidays I used it to build the &lt;a href=&#34;https://github.com/tlaplus-community/tlauc&#34;&gt;TLA⁺ Unicode Converter&lt;/a&gt;.&#xA;The new year is a time to reflect on the past and look to the future, so here in early 2023 seems ideal to publish my experience.&lt;/p&gt;&#xA;&lt;p&gt;Both TLA⁺ and tree-sitter itself ensured the project was fascinating on a technical level;&#xA;even more interesting were the social and psychological aspects of my first real involvement with the free software community!&#xA;I&amp;rsquo;ll go over why I wanted to create this project and the main technical challenges I faced doing so, then discuss the conditions that enabled me to create it and how free software development changed the way I think.&#xA;If you&amp;rsquo;d rather get the technical part in video form (with demos!), you can watch the presentation I gave at TLA⁺ Conf 2021 (slides: &lt;a href=&#34;https://ahelwer.ca/files/tla-tree-sitter.pdf&#34;&gt;pdf&lt;/a&gt;, &lt;a href=&#34;https://ahelwer.ca/files/tla-tree-sitter.odp&#34;&gt;odp&lt;/a&gt;):&#xA;&#xA;    &lt;div style=&#34;position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden;&#34;&gt;&#xA;      &lt;iframe allow=&#34;accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share&#34; allowfullscreen=&#34;allowfullscreen&#34; loading=&#34;eager&#34; referrerpolicy=&#34;strict-origin-when-cross-origin&#34; src=&#34;https://www.youtube-nocookie.com/embed/qlZQErIByWU?autoplay=0&amp;amp;controls=1&amp;amp;end=0&amp;amp;loop=0&amp;amp;mute=0&amp;amp;start=0&#34; style=&#34;position: absolute; top: 0; left: 0; width: 100%; height: 100%; border:0;&#34; title=&#34;YouTube video&#34;&gt;&lt;/iframe&gt;&#xA;    &lt;/div&gt;&#xA;&lt;/p&gt;</description>
    </item>
  </channel>
</rss>
