tlaplus-spec-generator

Generate TLA+ specifications from C/C++ and Python source code.

142|14|Updated Feb 14, 2026
One-click install
npx skills add https://github.com/ArabelaTso/Skills-4-SE --skill tlaplus-spec-generator
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: tlaplus-spec-generator
Source: https://github.com/ArabelaTso/Skills-4-SE/tree/main/skills/tlaplus-spec-generator
Command: npx skills add https://github.com/ArabelaTso/Skills-4-SE --skill tlaplus-spec-generator

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires python3, and includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill automates the creation of TLA+ specifications from source code, simplifying the formal verification of distributed systems.

Core Features & Use Cases

  • Automated Spec Generation: Converts C/C++ and Python code into TLA+ modules.
  • Formal Verification: Enables model checking of distributed systems, consensus protocols, and concurrent algorithms using TLC.
  • Use Case: You have implemented a distributed consensus algorithm in Python. Use this Skill to generate a TLA+ specification, then formally verify its safety and liveness properties.

Quick Start

Use the tlaplus-spec-generator skill to generate a TLA+ specification from the file 'distributed_system.c'.

Frequently Asked Questions about tlaplus-spec-generator

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate TLA+ specifications from Python or C/C++ source code?▼

You can automate TLA+ specification generation by analyzing your C/C++ or Python source code to extract state variables, actions, and system behavior into TLA+ modules for model checking.

What is formal verification for distributed systems and when do I need TLA+?▼

Formal verification for distributed systems mathematically proves algorithm correctness, and you need TLA+ when validating safety and liveness properties of concurrent algorithms like consensus protocols or message passing.

Can I use model checking with TLC for consensus protocols implemented in Python?▼

Yes, you can use model checking with TLC for consensus protocols implemented in Python by converting the source code into TLA+ modules that define state transitions for the TLC model checker.

Do I need Python3 to generate TLA+ modules from C/C++ distributed system code?▼

Yes, you need Python3 installed as a dependency to run the generation scripts that analyze C/C++ distributed system code and output TLA+ modules for formal verification.

What are the limitations of automated TLA+ spec generation for complex message passing systems?▼

Automated TLA+ spec generation focuses on common distributed system patterns like message passing and consensus, meaning highly customized logic may require manual abstraction level adjustments for accurate model checking.