{
  "version": "https://jsonfeed.org/version/1",
  "title": "logic on Context may be all you need",
  "icon": "https://www.gravatar.com/avatar/8d4e83e124462d944a8d448a6f213e9f?s=96&d=https%3A%2F%2Fmicro.blog%2Fimages%2Fblank_avatar.png",
  "home_page_url": "https://matt.thompson.gr/",
  "feed_url": "https://matt.thompson.gr/feed.json",
  "items": [
      {
        "id": "http://thompsonson.micro.blog/2026/08/13/125930.html",
        "title": "[IA Series 11/n] The Grammar of Logic — A Term Sheet",
        "content_html": "<p><em>This is a term sheet for the grammar of logic, in the same spirit as the original <a href=\"https://matt.thompson.gr/2025/05/16/ia-series-n-intelligent-agents.html\">Intelligent Agents Term Sheet</a>. Most terms come from Russell and Norvig&rsquo;s &lsquo;Artificial Intelligence: A Modern Approach&rsquo; (Chapters 7-8) and the standard literature on formal logic.</em></p>\n<h2 id=\"introduction\">Introduction</h2>\n<p>The ontology work has kept using a vocabulary I never formally defined — predicates, derived rules, well-formedness — all of it written in the language of logic. Before going further I wanted a term sheet for the <em>grammar</em> of that language: what the symbols are, what strings count as well-formed, and what a well-formed formula means. This post is that term sheet. It is deliberately lean; the aim is a shared vocabulary, not a textbook.</p>\n<h2 id=\"the-grammar--core-terminology\">The Grammar — Core Terminology</h2>\n<h3 id=\"the-symbols\">The symbols</h3>\n<ul>\n<li><strong>Formal language</strong>: A set of strings built from an alphabet according to formation rules.</li>\n<li><strong>Alphabet</strong>: The symbols a formal language is built from — logical constants, variables, predicates, functions, and punctuation.</li>\n<li><strong>Connectives</strong>: The logical constants that combine sentences.\n<ul>\n<li><strong>Negation (¬)</strong>: <em>not</em> — flips a sentence&rsquo;s truth value.</li>\n<li><strong>Conjunction (∧)</strong>: <em>and</em> — true only when both sides are true.</li>\n<li><strong>Disjunction (∨)</strong>: <em>or</em> — true when at least one side is true.</li>\n<li><strong>Implication (⇒)</strong>: <em>if &hellip; then &hellip;</em> — false only when the antecedent is true and the consequent is false.</li>\n<li><strong>Biconditional (⇔)</strong>: <em>if and only if</em> — true when both sides agree in truth value.</li>\n</ul>\n</li>\n<li><strong>Quantifiers</strong>: The logical constants that range over objects.\n<ul>\n<li><strong>Universal (∀)</strong>: <em>for all</em>.</li>\n<li><strong>Existential (∃)</strong>: <em>there exists</em>.</li>\n</ul>\n</li>\n<li><strong>Equality (=)</strong>: a predicate asserting two terms denote the same object.</li>\n<li><strong>Parentheses</strong>: grouping, and the grammar&rsquo;s only punctuation.</li>\n</ul>\n<h3 id=\"terms\">Terms</h3>\n<ul>\n<li><strong>Term</strong>: An expression that refers to an object — a constant, a variable, or a function applied to terms.\n<ul>\n<li><strong>Constant symbol</strong>: Names a specific object (e.g., <code>pr-42</code>).</li>\n<li><strong>Variable symbol</strong>: Ranges over objects (e.g., <code>x</code>).</li>\n<li><strong>Function symbol</strong>: Maps objects to objects (e.g., <code>parent(x)</code>).</li>\n</ul>\n</li>\n</ul>\n<h3 id=\"predicates-and-sentences\">Predicates and sentences</h3>\n<ul>\n<li><strong>Predicate symbol</strong>: A relation over objects. Applied to terms it yields an atomic sentence.</li>\n<li><strong>Atomic sentence (atom)</strong>: A predicate applied to terms — the smallest well-formed sentence (e.g., <code>merged(pr-42)</code>).</li>\n<li><strong>Compound sentence</strong>: Atoms combined with connectives and quantifiers.</li>\n<li><strong>Well-formed formula (wff)</strong>: A string that obeys the formation rules — the grammar&rsquo;s definition of a legal sentence.</li>\n<li><strong>Sentence</strong>: A well-formed formula with no free variables (a closed formula) — a claim that has a definite truth value in a model.</li>\n</ul>\n<h3 id=\"scope-and-binding\">Scope and binding</h3>\n<ul>\n<li><strong>Scope</strong>: The part of a formula governed by a quantifier.</li>\n<li><strong>Bound variable</strong>: A variable within the scope of its own quantifier.</li>\n<li><strong>Free variable</strong>: A variable not bound by any quantifier. A formula with free variables is <em>open</em>; it has no definite truth value until the variables are assigned.</li>\n</ul>\n<h2 id=\"the-grammar-stated\">The Grammar, stated</h2>\n<p>The formation rules, in BNF — this is the grammar of logic proper:</p>\n<pre tabindex=\"0\"><code>Sentence         → AtomicSentence | ComplexSentence\nAtomicSentence   → Predicate(Term, ...) | Term = Term\nComplexSentence  → ( Sentence )\n                 | ¬ Sentence\n                 | Sentence ∧ Sentence\n                 | Sentence ∨ Sentence\n                 | Sentence ⇒ Sentence\n                 | Sentence ⇔ Sentence\n                 | Quantifier Variable, ... Sentence\nTerm             → Function(Term, ...) | Constant | Variable\n</code></pre><p>Everything else is not a sentence of the language — no matter how plausible it reads.</p>\n<p>This grammar declares facts — predicates and the sentences built from them. Actions, operations with preconditions and effects, are the <em>planning</em> half, written over this grammar&rsquo;s sentences rather than inside it.</p>\n<h2 id=\"semantics--meaning\">Semantics — Meaning</h2>\n<ul>\n<li><strong>Interpretation</strong>: An assignment of meaning to a language — a domain plus a mapping that names the constants, predicates, and functions in it.</li>\n<li><strong>Model</strong>: An interpretation that makes a given sentence (or set of sentences) true.</li>\n<li><strong>Determination</strong>: A sentence has no intrinsic truth. The grammar determines what is well-formed; truth is determined relative to an interpretation, and which interpretation is intended is <em>attributed</em> — chosen by a human modeling the world, not discovered. No truth without a model; no model without an attributed interpretation.</li>\n<li><strong>Domain (universe)</strong>: The set of objects an interpretation ranges over.</li>\n<li><strong>Truth value</strong>: True or false — what a sentence receives relative to an interpretation.</li>\n<li><strong>Truth table</strong>: A complete enumeration of a connective&rsquo;s truth behaviour for all combinations of its arguments.</li>\n<li><strong>Satisfaction</strong>: A formula is satisfied by an interpretation when it is true in it.</li>\n<li><strong>Entailment (⊨)</strong>: <em>KB ⊨ α</em> — every model of the knowledge base is also a model of α. The semantic notion of logical consequence.</li>\n<li><strong>Validity</strong>: A sentence true in <em>every</em> interpretation (a tautology).</li>\n<li><strong>Satisfiability</strong>: A sentence true in <em>some</em> interpretation.</li>\n<li><strong>Contingency</strong>: A sentence true in some interpretations and false in others — neither valid nor contradictory.</li>\n<li><strong>Contradiction (unsatisfiability)</strong>: A sentence true in <em>no</em> interpretation.</li>\n<li><strong>Logical equivalence (≡)</strong>: Two sentences true in exactly the same interpretations.</li>\n</ul>\n<h2 id=\"reasoning--using-the-grammar\">Reasoning — Using the Grammar</h2>\n<ul>\n<li><strong>Knowledge base (KB)</strong>: The set of sentences an agent holds to be true.</li>\n<li><strong>Inference</strong>: Deriving new sentences from existing ones.</li>\n<li><strong>Derivation (⊢)</strong>: <em>KB ⊢ α</em> — α is reachable from the KB by applying inference rules. The syntactic notion of proof.</li>\n<li><strong>Sound inference</strong>: Never derives a false conclusion — every derived sentence is entailed.</li>\n<li><strong>Complete inference</strong>: Can derive every entailed sentence.</li>\n<li><strong>Inference rules</strong>: The grammar&rsquo;s rewrite moves — e.g., <strong>modus ponens</strong> (<em>if</em> α ⇒ β <em>and</em> α <em>then</em> β), <strong>conjunction introduction</strong> (α, β ⊢ α ∧ β), <strong>resolution</strong> (a complete rule for propositional and first-order clauses).</li>\n<li><strong>Entailment vs derivation</strong>: Entailment (⊨) says what is <em>true given</em> the KB; derivation (⊢) says what is <em>provable from</em> it.</li>\n<li><strong>Soundness theorem</strong>: If ⊢ then ⊨ — the proof system never lies.</li>\n<li><strong>Completeness theorem</strong>: If ⊨ then ⊢ — everything true is provable.</li>\n<li><strong>Decidability</strong>: Whether a proof procedure is guaranteed to terminate with an answer. Propositional entailment is decidable; first-order entailment is not in general.</li>\n</ul>\n<h2 id=\"closing\">Closing</h2>\n<p>The grammar is the substrate the world ontology is written in: predicates are atomic sentences, Kinds classify how their truth is determined, and a <code>derived</code> predicate is an entailment stated by a rule. This term sheet names the pieces so that work can be described precisely.</p>\n",
        "date_published": "2026-08-13T12:59:30+02:00",
        "url": "https://matt.thompson.gr/2026/08/13/125930.html",
        "tags": ["ia-series","logic"]
      }
  ]
}
