AI Glossary / Graphs and symbolic AI / Beginner
Term
Definition
In first-order logic, a term is an expression that denotes an object in the domain under an interpretation and, when variables occur, a variable assignment. A term can be a constant, a variable, or a function symbol applied to other terms. Terms supply the objects about which formulas make claims. This entry uses the logical meaning, rather than a vocabulary item or a contractual condition.
What it means
The expression Parcel7 can be a term naming one parcel. The variable x can also be a term, whose denotation depends on an assignment. A structured expression such as OwnerOf(Parcel7) is a term if OwnerOf is a unary function symbol in the language.
A term is not normally true or false by itself. Delivered(Parcel7) is an atomic formula if Delivered is a predicate: it makes a claim about the object denoted by Parcel7. Keeping terms separate from formulas is essential when constructing logical representations, performing substitutions, and checking whether an expression is well formed.
How it works
Begin with a signature specifying constants, function symbols, predicate symbols, and their arities. Arity is the number of arguments a symbol accepts. Every variable and constant is a term. If f is an n-argument function symbol and t1 through tn are terms, then f(t1,...,tn) is also a term.
Interpret constants as domain objects and function symbols as functions on those objects. Evaluate a compound term from its inner terms outward. Variables obtain their values from an assignment; replacing a variable with another term is a syntactic substitution and must be applied consistently.
A ground term contains no variables. Different written terms can denote the same object unless additional assumptions rule that out. Standard first-order logic normally interprets function symbols as total functions. If an application needs an undefined or multi-valued relationship, its representation requires additional care, such as using a relation instead of casually assuming a single function result.
Three practical examples
1. Knowledge representation: a system uses constants for named entities and structured terms for functionally specified objects, then applies predicates to express facts about them.
2. Automated reasoning: a prover substitutes a term for a variable when instantiating a rule, preserving the expression's structure and shared variable occurrences.
3. Symbolic computation: an expression tree represents nested function applications. A reasoning system can inspect or rewrite the structure according to its formal rules, while distinguishing syntax from the values assigned by an interpretation.
Think of it this way
Think of a term as a way to point to something: a name, a placeholder, or a description such as “the designated owner of this parcel.” A sentence then says something about what was pointed to.
The analogy is limited because ordinary descriptions can be vague or fail to identify exactly one object. A formal function term has the interpretation required by its logical framework. The modeler must make sure that commitment matches the intended domain.
Worked example
Define a toy domain containing people Ada, Ben, and Cy. Let constants ada, ben, and cy denote those people. Introduce a unary function mentor, interpreted by mentor(Ada)=Ben, mentor(Ben)=Cy, and mentor(Cy)=Cy.
The expression mentor(mentor(ada)) is a ground term. First evaluate ada as Ada, then mentor(ada) as Ben, and finally mentor(Ben) as Cy. Thus this compound term and the constant cy denote the same object, although their written forms are different.
Now take the term mentor(x). Under the assignment x=Ada, it denotes Ben. Under x=Ben, it denotes Cy. Applying the syntactic substitution {x ↦ ada} produces mentor(ada), which is ground.
Introduce a predicate Available that is true only of Cy. Available(mentor(mentor(ada))) is then a true atomic formula in this interpretation. By contrast, mentor(mentor(ada)) alone denotes Cy and is not an assertion of availability. The expression mentor(ada,ben) is ill formed for this signature because mentor was declared unary, regardless of whether its intended meaning seems understandable to a human.
Illustrative case study
Fictional case: LogicDesk models responsibility for service tickets. Its first version uses Owner(ticket) as a function, but some tickets have two joint owners and others have none. The representation silently forces a single result where the business data do not support one.
The team replaces the function with an Owns(person,ticket) relation and writes the required constraints separately. It keeps function terms only where a unique designated result is part of the model. This fictional case illustrates the commitments of a representation, not an inherent limitation of all logical systems.
Common misconceptions and mistakes
A term is not the same as a predicate or a complete statement. Predicates applied to terms produce atomic formulas; function applications produce further terms.
Two different constants do not necessarily denote different objects in ordinary first-order logic. Unique-name assumptions must be stated when intended.
A ground term has no variables, but it can still be nested and structurally complex. Conversely, a variable is itself a term even before it is assigned a particular object.
Do not assume a function symbol runs a software procedure automatically. Its interpretation is mathematical; an implementation may compute, look up, or reason about its value in different ways.
Business use
The distinction matters when building knowledge bases, rule engines, and symbolic interfaces to AI systems. Confusing a value-denoting expression with a truth-valued statement can lead to malformed rules or incorrect expectations about inference.
Document the signature and intended denotations. Check arities, variable use, and whether proposed functions really have a unique defined output in the model. When integrating data sources, preserve the difference between identifier equality and real-world identity. Explicit equality facts or mapping policies may be needed before a reasoner can treat differently named objects as the same entity.
People also ask
Can a variable be a term?
Yes. It denotes an object relative to an assignment or receives a role within a quantified formula.
Is every term a name written as one word?
No. Function applications can create nested structured terms.
Can two different terms mean the same object?
Yes. The interpretation can assign them the same denotation even when their syntax differs.
Check your understanding
In the toy interpretation, is mentor(mentor(ada)) true?
Answer: That question confuses a term with a formula. The term denotes Cy. Available(mentor(mentor(ada))) is the formula that is true under the stated predicate interpretation.
Related terms
- First-order logic
- Variable
- Predicate (logic)
- Ground term
- Unification
- Interpretation
- constant
- function symbol
- predicate
- substitution
- equality
Learn next
Study substitution and unification next. Build three nested terms using a declared signature, identify their variables, and apply one substitution consistently. Then place the terms inside predicates and explain which expressions denote objects and which can be evaluated for truth.
More in Graphs and symbolic AI
- Temporal-difference - Temporal-difference, usually abbreviated TD, refers to a learning approach that updates a prediction using newly observed information and a later prediction.
- Temporal logic - Temporal logic is a family of formal languages for expressing how statements hold across time or sequences of states.
- Temporal-projection - Temporal-projection is the reasoning task of determining what will hold after specified actions or events, given an initial description and a model of change.
- Terminal states - Terminal states are states at which a modeled game, task, or episode has ended according to its rules.
- Terminal test - A terminal test is a procedure that decides whether a state is a genuine ending of a modeled game, task, or episode.
- Ternary search tree - A ternary search tree is a data structure for storing and finding strings one character at a time.
Sources
Primary reference: Russell and Norvig, AIMA first-order logic slides, https://aima.cs.berkeley.edu/slides-pdf/chapter08.pdf, syntax, interpretation, and equality sections. These passages were read directly. The mentor interpretation and ticket case are original teaching examples. The entry explicitly adopts standard first-order logical terminology.
Previous: Tensor sketch Next: Term-at-a-time