Planning, Natural Language Processing and Multi-Agent Systems

This chapter covers three sub-items the syllabus groups near each other: planning (how an agent decides a SEQUENCE of actions to reach a goal, rather than a single reactive choice), natural language processing (parsing, semantic analysis, pragmatics), and multi-agent systems (agents that must coordinate, communicate or compete with other agents rather than acting alone).

Planning: STRIPS, Goal Stack, Hierarchical and Partial-Order Planning

STRIPS (Stanford Research Institute Problem Solver) represents each ACTION by its PRECONDITIONS (what must be true before it can be applied) and its EFFECTS, split into an ADD LIST (facts made true) and a DELETE LIST (facts made false) — this compact, purely propositional representation is what makes automated planning tractable at all, since a planner can now reason about which actions are APPLICABLE (preconditions satisfied by the current state) and update the state mechanically (apply add/delete lists) rather than needing a full simulation of the world. Goal stack planning works backward from the goal: push unsatisfied goal conditions onto a stack, pick an action whose effects satisfy the top of the stack, push that action's OWN preconditions on top in turn, and repeat until the stack empties into an executable action sequence — simple, but can fail on goals with interacting sub-goals where satisfying one undoes progress already made on another (the classic 'Sussman anomaly').

  • Hierarchical planning decomposes a high-level goal into progressively more detailed sub-plans across multiple levels of abstraction (e.g. 'plan a trip' → 'book flight, book hotel' → each further decomposed into concrete steps) rather than reasoning about primitive actions from the start — this mirrors the same abstraction-hides-detail idea seen in software engineering's modular design.
  • Partial-order planning does NOT commit to a total (linear) ordering of steps unless forced to — it only orders two steps relative to each other when one genuinely depends on the other (a 'least commitment' strategy), which avoids the wasted backtracking a totally-ordered planner suffers when it guesses an unnecessary ordering constraint and later has to undo it.

Natural Language Processing: Parsing, Semantic Analysis and Pragmatics

Four levels of language analysis, from surface to context
LevelWhat it establishes
Syntactic (parsing)Grammatical structure alone — 'Colourless green ideas sleep furiously' is syntactically valid (a well-formed sentence) despite being semantically nonsensical, which is exactly why syntax and semantics must be treated as separate levels.
Semantic analysisLiteral, context-independent meaning of the sentence's words and structure combined.
PragmaticsMeaning as it depends on CONTEXT beyond the sentence itself — 'Can you pass the salt?' is syntactically a yes/no question about ability, but pragmatically almost always a request for action, and only real-world/conversational context resolves which reading is intended.
🎯 Why syntax alone cannot resolve ambiguity that semantics/pragmatics can
'I saw the man with the telescope' is syntactically ambiguous between two valid parse trees — either the SEEING was done with a telescope, or the MAN had a telescope. Grammar alone cannot pick between them; only world knowledge or discourse context (semantic and pragmatic reasoning, respectively) can settle which reading a speaker actually intended, which is exactly why a complete NLP pipeline needs all three levels rather than syntax alone.

Multi-Agent Systems: Agents Versus Objects and Expert Systems

A multi-agent system consists of multiple autonomous agents that must coordinate, negotiate or compete within a shared environment, unlike a single-agent system where the only relevant dynamics are the agent's interaction with a passive environment. The AGENTS-VERSUS-OBJECTS distinction is worth holding precisely: a plain object exposes methods that are called by whoever holds a reference and simply executes them; an AGENT decides for itself whether and how to respond to a request, based on its own goals and state — autonomy is the defining difference, not merely 'having more code'. Comparing agents to EXPERT SYSTEMS is similarly precise: an expert system is typically a single, largely passive reasoner queried by a human; an agent is proactive (can initiate action on its own) and situated in an environment it continuously perceives and acts on, without necessarily waiting to be asked.

Semantic Web, Agent Communication and Development Tools

  • Semantic Web: extends the ordinary web with machine-processable metadata (via ontologies, covered in the previous chapter) so that AGENTS, not just human readers, can meaningfully interpret and act on web content — a page marked up with structured data about 'this is a restaurant, this is its opening hours' can be reasoned about automatically, unlike plain HTML meant only for human eyes.
  • Agent communication needs a shared PROTOCOL and shared VOCABULARY, exactly as human conversation does: an Agent Communication Language (ACL) defines the message-passing protocol (performatives like 'inform', 'request', 'query' — what KIND of speech act a message is), and a shared ONTOLOGY (again, the previous chapter's topic) supplies the vocabulary so both agents mean the same thing by a term — KNOWLEDGE SHARING USING ONTOLOGIES is precisely this: agreeing on vocabulary before agreeing on content.
  • Agent development tools: frameworks (e.g. JADE) that provide ready-made ACL messaging, agent lifecycle management and directory/lookup services (finding which other agents offer a needed capability) — the standard infrastructure so a developer builds the agent's own reasoning logic rather than reimplementing message transport and agent discovery from scratch.

Key takeaways

  • STRIPS represents each action by preconditions and add/delete effects, making automated planning tractable; goal stack planning can fail on interacting sub-goals.
  • Hierarchical planning decomposes across abstraction levels; partial-order planning commits to an ordering only when genuinely forced to, avoiding wasted backtracking.
  • Syntax, semantic analysis and pragmatics are three distinct levels — syntax alone cannot resolve ambiguity that requires world knowledge or context.
  • An agent is defined by autonomy (deciding for itself whether/how to respond) — distinct from a plain object (executes what is called) and an expert system (largely passive, queried by a human).
  • Agent communication needs both a shared protocol (an ACL's performatives) and a shared vocabulary (an ontology) — the same two ingredients human conversation needs.

Practice questions (8)

Attempt each one before opening the answer. Every explanation names the tempting wrong option as well as the right one, because that is where marks are lost.

  1. In STRIPS, an action's effects are split into:

    1. An add list and a delete list
    2. A syntax list and a semantics list
    3. A certainty factor and a probability
    4. Nothing; STRIPS has no effects at all
    Show answer

    Answer: A — An add list and a delete list

    The add list states facts the action makes true, the delete list facts it makes false — together with preconditions, this compact representation is what makes mechanical state updates and hence automated planning possible.
  2. Partial-order planning's 'least commitment' strategy means:

    1. Two steps are ordered relative to each other only when one genuinely depends on the other
    2. Every step must be given a total, linear order from the start
    3. No ordering is ever recorded at all
    4. Steps are chosen entirely at random
    Show answer

    Answer: A — Two steps are ordered relative to each other only when one genuinely depends on the other

    By avoiding unnecessary ordering commitments, a partial-order planner sidesteps the wasted backtracking a totally-ordered planner suffers when it guesses a constraint it did not actually need.
  3. 'Colourless green ideas sleep furiously' is often cited to show that:

    1. A sentence can be syntactically valid while being semantically nonsensical
    2. Syntax and semantics are the same thing
    3. No sentence can ever be parsed
    4. Pragmatics is unnecessary in every case
    Show answer

    Answer: A — A sentence can be syntactically valid while being semantically nonsensical

    The sentence follows English grammar rules perfectly (a valid parse tree exists) while conveying no coherent meaning, which is exactly the demonstration that syntactic validity and semantic sensibility must be treated as separate properties.
  4. The ambiguity in 'I saw the man with the telescope' can be resolved only by:

    1. World knowledge or discourse context, since grammar alone permits both readings
    2. Syntax alone
    3. Ignoring the sentence entirely
    4. Counting the number of words
    Show answer

    Answer: A — World knowledge or discourse context, since grammar alone permits both readings

    Both parse trees are grammatically valid, so only semantic/pragmatic reasoning beyond pure syntax can settle which reading (the seeing done with a telescope, or the man having one) was actually intended.
  5. The key property that distinguishes an agent from a plain object is:

    1. Autonomy — the agent decides for itself whether and how to respond, based on its own goals and state
    2. Simply having more lines of code
    3. Never being able to communicate with anything
    4. Being written only in one specific programming language
    Show answer

    Answer: A — Autonomy — the agent decides for itself whether and how to respond, based on its own goals and state

    A plain object simply executes whatever method is called on it; an agent's defining feature is that it can decide, based on its own state and goals, whether and how to act — autonomy, not code volume.
  6. Which of the following are needed for effective agent-to-agent communication? (More than one option may be correct.)

    1. A shared communication protocol (an Agent Communication Language)
    2. A shared ontology/vocabulary so both agents mean the same thing by a term
    3. Complete isolation with no message exchange at all
    4. Agreement on vocabulary before agreement on content
    Show answer

    Answer: A — A shared communication protocol (an Agent Communication Language); B — A shared ontology/vocabulary so both agents mean the same thing by a term; D — Agreement on vocabulary before agreement on content

    A shared protocol and a shared vocabulary are the two named ingredients, and knowledge sharing using ontologies is precisely the practice of settling vocabulary before content — complete isolation is the opposite of communication.
  7. Name the classic goal-stack planning failure, where satisfying one sub-goal undoes progress already made on another interacting sub-goal.

    Numerical answer — type the value.

    Show answer

    Answer: Sussman anomaly

    The Sussman anomaly is the standard textbook example (a three-block-stacking problem) showing that simple, non-interleaved goal stack planning can fail on goals whose sub-goals genuinely interact.
  8. Agent development frameworks such as JADE chiefly provide:

    1. Ready-made ACL messaging, lifecycle management and agent-discovery services
    2. A guarantee that every agent will always agree with every other agent
    3. A replacement for ontologies
    4. Nothing related to communication at all
    Show answer

    Answer: A — Ready-made ACL messaging, lifecycle management and agent-discovery services

    These frameworks supply the standard infrastructure (messaging, lifecycle, directory services) so a developer can focus on building the agent's own reasoning logic rather than reimplementing transport and discovery from scratch.