MCPcopy Index your code
hub / github.com/Fault-lang/Fault

github.com/Fault-lang/Fault @v1.0.0

Chat with this repo
repository ↗ · DeepWiki ↗ · release v1.0.0 ↗ · + Follow
8,020 symbols 14,860 edges 85 files 1,955 documented · 24% updated 4d agov1.0.0 · 2026-06-23★ 1711 open issues
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Fault

Fault is a modeling language for building system dynamic models and checking them using a combination of first order logic and probability

Project Status

Pre-alpha.

Install

Fault can be built from source if you like, but the best way to install Fault is by downloading the correct release for your machine.

Once installed the model checker of Fault needs access to a SMT solver, otherwise Fault will default to generating SMT of models only. Microsoft's Z3 is the recommended solver at this time and can be downloaded here

Then in order for Fault to find your solver you need to set two configuration variables

export SOLVERCMD="z3"
export SOLVERARG="-in"

For other install options please see the Fault documentation

Why "Fault"?

It is not possible to completely specify a system. All specifications must decide what parts of the system are in-scope and out-of-scope, and at what level of detail. Many formal specification approaches are designed to prove the system correct and it is very easy for an inexperienced practitioner to write a bad spec that gives a thumbs up to a flawed system.

Instead Fault is designed with the assumption that all systems will fail at some point, under some set of conditions. The name Fault was chosen to emphasize this point for users: Fault models that return no failure points are bad models. The user should keep trying until they've built a model that produces interesting and compelling failure scenarios.

Origin Story

The development Fault is documented in the series "Marianne Writes a Programming Language":

Extension points exported contracts — how you extend this code

Rule (Interface)
(no doc) [17 implementers]
generator/rules/rules.go
Node (Interface)
(no doc) [45 implementers]
ast/ast.go
Event (Interface)
(no doc) [5 implementers]
generator/scenario/log.go
FaultParserListener (Interface)
FaultParserListener is a complete listener for a parse tree produced by FaultParser. [1 implementers]
parser/faultparser_listener.go
FaultParserVisitor (Interface)
A complete Visitor for a parse tree produced by FaultParser. [1 implementers]
parser/faultparser_visitor.go
ISysSpecContext (Interface)
ISysSpecContext is an interface to support dynamic dispatch. [1 implementers]
parser/fault_parser.go
SMTLIBv2Visitor (Interface)
A complete Visitor for a parse tree produced by SMTLIBv2Parser. [1 implementers]
execute/parser/smtlibv2_visitor.go
LLUnit (Interface)
(no doc) [2 implementers]
generator/unroll/unroll.go

Core symbols most depended-on inside this repo

GetToken
called by 542
ast/ast.go
String
called by 220
ast/ast.go
GetState
called by 175
llvm/variables/lookup.go
Type
called by 132
ast/ast.go
Error
called by 118
tui/errors.go
push
called by 108
listener/listener.go
GenerateToken
called by 103
ast/ast_utils.go
EnterRule
called by 96
execute/parser/smtlibv2_parser.go

Shape

Method 6,096
Function 1,369
Struct 362
Interface 186
TypeAlias 7

Languages

Go100%

Modules by API surface

execute/parser/smtlibv2_parser.go2,444 symbols
parser/fault_parser.go2,180 symbols
ast/ast.go500 symbols
generator/rules/rules.go249 symbols
parser/faultparser_base_listener.go225 symbols
parser/faultparser_listener.go221 symbols
execute/parser/smtlibv2_base_listener.go197 symbols
execute/parser/smtlibv2_listener.go193 symbols
listener/listener_test.go120 symbols
parser/faultparser_visitor.go111 symbols
parser/faultparser_base_visitor.go111 symbols
listener/listener_exit.go98 symbols

For agents

$ claude mcp add Fault \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact