bdi-mental-states

2
0
Source

This skill should be used when the user asks to "model agent mental states", "implement BDI architecture", "create belief-desire-intention models", "transform RDF to beliefs", "build cognitive agent", or mentions BDI ontology, mental state modeling, rational agency, or neuro-symbolic AI integration.

Install

mkdir -p .claude/skills/bdi-mental-states && curl -L -o skill.zip "https://mcp.directory/api/skills/download/7571" && unzip -o skill.zip -d .claude/skills/bdi-mental-states && rm skill.zip

Installs to .claude/skills/bdi-mental-states

About this skill

BDI Mental State Modeling

Transform external RDF context into agent mental states (beliefs, desires, intentions) using formal BDI ontology patterns. This skill enables agents to reason about context through cognitive architecture, supporting deliberative reasoning, explainability, and semantic interoperability within multi-agent systems.

When to Activate

Activate this skill when:

  • Processing external RDF context into agent beliefs about world states
  • Modeling rational agency with perception, deliberation, and action cycles
  • Enabling explainability through traceable reasoning chains
  • Implementing BDI frameworks (SEMAS, JADE, JADEX)
  • Augmenting LLMs with formal cognitive structures (Logic Augmented Generation)
  • Coordinating mental states across multi-agent platforms
  • Tracking temporal evolution of beliefs, desires, and intentions
  • Linking motivational states to action plans

Core Concepts

Mental Reality Architecture

Separate mental states into two ontological categories because BDI reasoning requires distinguishing what persists from what happens:

Mental States (Endurants) -- model these as persistent cognitive attributes that hold over time intervals:

  • Belief: Represent what the agent holds true about the world. Ground every belief in a world state reference.
  • Desire: Represent what the agent wishes to bring about. Link each desire back to the beliefs that motivate it.
  • Intention: Represent what the agent commits to achieving. An intention must fulfil a desire and specify a plan.

Mental Processes (Perdurants) -- model these as events that create or modify mental states, because tracking causal transitions enables explainability:

  • BeliefProcess: Triggers belief formation/update from perception. Always connect to a generating world state.
  • DesireProcess: Generates desires from existing beliefs. Preserves the motivational chain.
  • IntentionProcess: Commits to selected desires as actionable intentions.

Cognitive Chain Pattern

Wire beliefs, desires, and intentions into directed chains using bidirectional properties (motivates/isMotivatedBy, fulfils/isFulfilledBy) because this enables both forward reasoning (what should the agent do?) and backward tracing (why did the agent act?):

:Belief_store_open a bdi:Belief ;
    rdfs:comment "Store is open" ;
    bdi:motivates :Desire_buy_groceries .

:Desire_buy_groceries a bdi:Desire ;
    rdfs:comment "I desire to buy groceries" ;
    bdi:isMotivatedBy :Belief_store_open .

:Intention_go_shopping a bdi:Intention ;
    rdfs:comment "I will buy groceries" ;
    bdi:fulfils :Desire_buy_groceries ;
    bdi:isSupportedBy :Belief_store_open ;
    bdi:specifies :Plan_shopping .

World State Grounding

Always ground mental states in world state references rather than free-text descriptions, because ungrounded beliefs break semantic querying and cross-agent interoperability:

:Agent_A a bdi:Agent ;
    bdi:perceives :WorldState_WS1 ;
    bdi:hasMentalState :Belief_B1 .

:WorldState_WS1 a bdi:WorldState ;
    rdfs:comment "Meeting scheduled at 10am in Room 5" ;
    bdi:atTime :TimeInstant_10am .

:Belief_B1 a bdi:Belief ;
    bdi:refersTo :WorldState_WS1 .

Goal-Directed Planning

Connect intentions to plans via bdi:specifies, and decompose plans into ordered task sequences using bdi:precedes, because this separation allows plan reuse across different intentions while keeping execution order explicit:

:Intention_I1 bdi:specifies :Plan_P1 .

:Plan_P1 a bdi:Plan ;
    bdi:addresses :Goal_G1 ;
    bdi:beginsWith :Task_T1 ;
    bdi:endsWith :Task_T3 .

:Task_T1 bdi:precedes :Task_T2 .
:Task_T2 bdi:precedes :Task_T3 .

T2B2T Paradigm

Implement Triples-to-Beliefs-to-Triples as a bidirectional pipeline because agents must both consume external RDF context and produce new RDF assertions. Structure every T2B2T implementation in two explicit phases:

Phase 1: Triples-to-Beliefs -- Translate incoming RDF triples into belief instances. Use bdi:triggers to connect the external world state to a BeliefProcess, and bdi:generates to produce the resulting belief. This preserves provenance from source data through to internal cognition:

:WorldState_notification a bdi:WorldState ;
    rdfs:comment "Push notification: Payment request $250" ;
    bdi:triggers :BeliefProcess_BP1 .

:BeliefProcess_BP1 a bdi:BeliefProcess ;
    bdi:generates :Belief_payment_request .

Phase 2: Beliefs-to-Triples -- After BDI deliberation selects an intention and executes a plan, project the results back into RDF using bdi:bringsAbout. This closes the loop so downstream systems can consume agent outputs as standard linked data:

:Intention_pay a bdi:Intention ;
    bdi:specifies :Plan_payment .

:PlanExecution_PE1 a bdi:PlanExecution ;
    bdi:satisfies :Plan_payment ;
    bdi:bringsAbout :WorldState_payment_complete .

Notation Selection by Level

Choose notation based on the C4 abstraction level being modeled, because mixing notations at the wrong level obscures rather than clarifies the cognitive architecture:

C4 LevelNotationMental State Representation
L1 ContextArchiMateAgent boundaries, external perception sources
L2 ContainerArchiMateBDI reasoning engine, belief store, plan executor
L3 ComponentUMLMental state managers, process handlers
L4 CodeUML/RDFBelief/Desire/Intention classes, ontology instances

Justification and Explainability

Attach bdi:Justification instances to every mental entity using bdi:isJustifiedBy, because unjustified mental states make agent reasoning opaque and untraceable. Each justification should capture the evidence or rule that produced the mental state:

:Belief_B1 a bdi:Belief ;
    bdi:isJustifiedBy :Justification_J1 .

:Justification_J1 a bdi:Justification ;
    rdfs:comment "Official announcement received via email" .

:Intention_I1 a bdi:Intention ;
    bdi:isJustifiedBy :Justification_J2 .

:Justification_J2 a bdi:Justification ;
    rdfs:comment "Location precondition satisfied" .

Temporal Dimensions

Assign validity intervals to every mental state using bdi:hasValidity with TimeInterval instances, because beliefs without temporal bounds cannot be garbage-collected or conflict-checked during diachronic reasoning:

:Belief_B1 a bdi:Belief ;
    bdi:hasValidity :TimeInterval_TI1 .

:TimeInterval_TI1 a bdi:TimeInterval ;
    bdi:hasStartTime :TimeInstant_9am ;
    bdi:hasEndTime :TimeInstant_11am .

Query mental states active at a specific moment using SPARQL temporal filters. Use this pattern to resolve conflicts when multiple beliefs about the same world state overlap in time:

SELECT ?mentalState WHERE {
    ?mentalState bdi:hasValidity ?interval .
    ?interval bdi:hasStartTime ?start ;
              bdi:hasEndTime ?end .
    FILTER(?start <= "2025-01-04T10:00:00"^^xsd:dateTime &&
           ?end >= "2025-01-04T10:00:00"^^xsd:dateTime)
}

Compositional Mental Entities

Decompose complex beliefs into constituent parts using bdi:hasPart relations, because monolithic beliefs force full replacement on partial updates. Structure composite beliefs so that each sub-belief can be independently updated, queried, or invalidated:

:Belief_meeting a bdi:Belief ;
    rdfs:comment "Meeting at 10am in Room 5" ;
    bdi:hasPart :Belief_meeting_time , :Belief_meeting_location .

# Update only location component without touching time
:BeliefProcess_update a bdi:BeliefProcess ;
    bdi:modifies :Belief_meeting_location .

Integration Patterns

Logic Augmented Generation (LAG)

Use LAG to constrain LLM outputs with ontological structure, because unconstrained generation produces triples that violate BDI class restrictions. Serialize the ontology into the prompt context, then validate generated triples against it before accepting them:

def augment_llm_with_bdi_ontology(prompt, ontology_graph):
    ontology_context = serialize_ontology(ontology_graph, format='turtle')
    augmented_prompt = f"{ontology_context}\n\n{prompt}"

    response = llm.generate(augmented_prompt)
    triples = extract_rdf_triples(response)

    is_consistent = validate_triples(triples, ontology_graph)
    return triples if is_consistent else retry_with_feedback()

SEMAS Rule Translation

Translate BDI ontology patterns into executable production rules when deploying to rule-based agent platforms. Map each cognitive chain link (belief-to-desire, desire-to-intention) to a HEAD/CONDITIONALS/TAIL rule, because this preserves the deliberative semantics while enabling runtime execution:

% Belief triggers desire formation
[HEAD: belief(agent_a, store_open)] /
[CONDITIONALS: time(weekday_afternoon)] »
[TAIL: generate_desire(agent_a, buy_groceries)].

% Desire triggers intention commitment
[HEAD: desire(agent_a, buy_groceries)] /
[CONDITIONALS: belief(agent_a, has_shopping_list)] »
[TAIL: commit_intention(agent_a, buy_groceries)].

Guidelines

  1. Model world states as configurations independent of agent perspectives, providing referential substrate for mental states.

  2. Distinguish endurants (persistent mental states) from perdurants (temporal mental processes), aligning with DOLCE ontology.

  3. Treat goals as descriptions rather than mental states, maintaining separation between cognitive and planning layers.

  4. Use hasPart relations for meronymic structures enabling selective belief updates.

  5. Associate every mental entity with temporal constructs via atTime or hasValidity.

  6. Use bidirectional property pairs (motivates/isMotivatedBy, generates/isGeneratedBy) for flexible querying.

  7. Link mental entities to Justification instances for explainability and trust.

  8. Implement T2B2T through: (1) translate RDF to beliefs, (2) execut


Content truncated.

context-compression

muratcankoylan

This skill should be used when the user asks to "compress context", "summarize conversation history", "implement compaction", "reduce token usage", or mentions context compression, structured summarization, tokens-per-task optimization, or long-running agent sessions exceeding context limits.

281

tool-design

muratcankoylan

This skill should be used when the user asks to "design agent tools", "create tool descriptions", "reduce tool complexity", "implement MCP tools", or mentions tool consolidation, architectural reduction, tool naming conventions, or agent-tool interfaces.

210

context-fundamentals

muratcankoylan

This skill should be used when the user asks to "understand context", "explain context windows", "design agent architecture", "debug context issues", "optimize context usage", or discusses context components, attention mechanics, progressive disclosure, or context budgeting. Provides foundational understanding of context engineering for AI agent systems.

250

digital-brain

muratcankoylan

This skill should be used when the user asks to "write a post", "check my voice", "look up contact", "prepare for meeting", "weekly review", "track goals", or mentions personal brand, content creation, network management, or voice consistency.

00

ralph-copywriter

muratcankoylan

Use this skill when the user asks to "analyze my content", "learn my writing style", "research competitors", "find content angles", "improve my blog", "write like me", "embody my brand voice", or mentions content strategy, voice analysis, competitive research, or iterative content improvement.

10

project-development

muratcankoylan

This skill should be used when the user asks to "start an LLM project", "design batch pipeline", "evaluate task-model fit", "structure agent project", or mentions pipeline architecture, agent-assisted development, cost estimation, or choosing between LLM and traditional approaches.

10

You might also like

flutter-development

aj-geddes

Build beautiful cross-platform mobile apps with Flutter and Dart. Covers widgets, state management with Provider/BLoC, navigation, API integration, and material design.

9521,094

drawio-diagrams-enhanced

jgtolentino

Create professional draw.io (diagrams.net) diagrams in XML format (.drawio files) with integrated PMP/PMBOK methodologies, extensive visual asset libraries, and industry-standard professional templates. Use this skill when users ask to create flowcharts, swimlane diagrams, cross-functional flowcharts, org charts, network diagrams, UML diagrams, BPMN, project management diagrams (WBS, Gantt, PERT, RACI), risk matrices, stakeholder maps, or any other visual diagram in draw.io format. This skill includes access to custom shape libraries for icons, clipart, and professional symbols.

846846

ui-ux-pro-max

nextlevelbuilder

"UI/UX design intelligence. 50 styles, 21 palettes, 50 font pairings, 20 charts, 8 stacks (React, Next.js, Vue, Svelte, SwiftUI, React Native, Flutter, Tailwind). Actions: plan, build, create, design, implement, review, fix, improve, optimize, enhance, refactor, check UI/UX code. Projects: website, landing page, dashboard, admin panel, e-commerce, SaaS, portfolio, blog, mobile app, .html, .tsx, .vue, .svelte. Elements: button, modal, navbar, sidebar, card, table, form, chart. Styles: glassmorphism, claymorphism, minimalism, brutalism, neumorphism, bento grid, dark mode, responsive, skeuomorphism, flat design. Topics: color palette, accessibility, animation, layout, typography, font pairing, spacing, hover, shadow, gradient."

571700

godot

bfollington

This skill should be used when working on Godot Engine projects. It provides specialized knowledge of Godot's file formats (.gd, .tscn, .tres), architecture patterns (component-based, signal-driven, resource-based), common pitfalls, validation tools, code templates, and CLI workflows. The `godot` command is available for running the game, validating scripts, importing resources, and exporting builds. Use this skill for tasks involving Godot game development, debugging scene/resource files, implementing game systems, or creating new Godot components.

548492

nano-banana-pro

garg-aayush

Generate and edit images using Google's Nano Banana Pro (Gemini 3 Pro Image) API. Use when the user asks to generate, create, edit, modify, change, alter, or update images. Also use when user references an existing image file and asks to modify it in any way (e.g., "modify this image", "change the background", "replace X with Y"). Supports both text-to-image generation and image-to-image editing with configurable resolution (1K default, 2K, or 4K for high resolution). DO NOT read the image file first - use this skill directly with the --input-image parameter.

673466

fastapi-templates

wshobson

Create production-ready FastAPI projects with async patterns, dependency injection, and comprehensive error handling. Use when building new FastAPI applications or setting up backend API projects.

514280

Stay ahead of the MCP ecosystem

Get weekly updates on new skills and servers.