# boost-ext/sml

C++14 State Machine library

Repository: https://github.com/boost-ext/sml
Canonical: https://ross.abutalabs.com/products/sml
Homepage: https://boost-ext.github.io/sml/
Language: C++
License: BSL-1.0
License Family: other
Topics: metaprogramming, design-patterns, state-machine
Last push: 2026-08-09T01:10:30+00:00

## Health v2 (maintenance only)
Score: 82/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 96, release rhythm 54, longevity 100
- inputs: {"age_days": 3924, "days_push": 25, "days_rel": 93, "gap_med": 212.0, "n_releases_24m": 3}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1392, forks 203 (observed 2026-08-28T04:04:36.090187+00:00)

## What it is
Boost::ext.SML is a C++14 one-header-only state machine library with no dependencies, providing a UML-compliant transition table DSL (src_state + event [guard] / action = dst_state). It is designed for fast compilation, small binaries, and scalable use in large projects as an alternative to Boost.MSM eUML.

## Use cases
- implement a finite state machine in C++
- replace spaghetti conditional logic with a state machine
- model protocol state transitions like TCP connection handling
- define UML-compliant state machines with guards and actions
- add a lightweight header-only FSM to an embedded or large-scale C++ project

## When to choose
- you need a fast-compiling, dependency-free C++ state machine library
- you want a UML-compliant transition table DSL without macros
- you want to pass dependencies to states/actions via constructor injection
- you need O(1) event processing with low memory overhead

## When to avoid
- you need runtime-defined or dynamically reconfigurable state machines
- you require Boost.MSM's full feature set or data stored in states
- your project targets a language other than C++14 or later

## Facets
- artifact type: library
- maturity: stable
- function: state-management, developer-tools
- domain: developer-tools, programming-languages
- platform: cpp, cross-platform
- tags: state-machine, header-only, cpp14, metaprogramming, uml, fsm, boost-ext, algorithms

## Member repositories
- boost-ext/sml (main) score 82

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:04:36.090187+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T04:39:31.735934+00:00, confidence not recorded.
  - readme: https://github.com/boost-ext/sml (fetched 2026-08-28T04:04:36.090187+00:00, sha be27f246a75b)
  - homepage: https://boost-ext.github.io/sml/ (fetched 2026-08-29T11:54:21.021894+00:00, sha b374454c0a80)
- Data as of 2026-08-30T08:39:29.467469+00:00.
