possibleworlds
Possible worlds are a formal device used in philosophy and semantics to model modality—that is, what could have been, what must be, and what might be true. They represent complete, internally consistent ways the world could have been. In this framework, the truth of a proposition can vary across worlds: a statement is necessarily true if it is true in all accessible worlds, and merely possible if it is true in at least one accessible world. The accessibility relation specifies which worlds are relevant for a given context, often reflecting logical, physical, or metaphysical constraints.
In Kripke-style semantics, a model comprises a set of possible worlds, an accessibility relation between them,
Philosophical stances differ on what possible worlds are. Modal realism, notably advanced by David Lewis, treats