AgentSkillsCN

cognitive-systems-engineering

运用CoALA与ACT-R等框架,为AI智能体打造认知架构。涵盖记忆系统、决策循环(OODA),以及多智能体模式。 在以下场景中使用:架构复杂AI智能体、设计记忆系统,或定义多智能体协作模式。

SKILL.md
--- frontmatter
name: cognitive-systems-engineering
description: |
  Engineering cognitive architectures for AI agents using frameworks like CoALA and ACT-R. Covers memory systems, decision cycles (OODA), and multi-agent patterns.
  Use when: architecting complex AI agents, designing memory systems, or defining multi-agent collaboration patterns.

Cognitive Systems Engineering

This skill provides blueprints for building the "brain" of an AI agent, moving beyond simple prompt-response loops to persistent, stateful, and goal-oriented architectures.

How to design Memory Systems

Implement memory tiers inspired by CoALA and ACT-R:

See Architectures Deep Dive for detailed schemas.

  1. Working Memory (Short-Term):
    • Function: Active context window management.
    • Implementation: Sliding window of last $N$ messages or summary of current session.
  2. Episodic Memory (Long-Term):
    • Function: Recall past events.
    • Implementation: Vector Database (RAG) storing interactions as embeddings.
  3. Semantic Memory (Knowledge):
    • Function: Static facts and rules.
    • Implementation: .context/ files or Knowledge Graph.
  4. Procedural Memory (Skills):
    • Function: "How-to" knowledge.
    • Implementation: Tool definitions and Agent Skills (like this one).

How to implement Decision Cycles

Choose a cycle based on agent autonomy:

  • OODA Loop (Observe-Orient-Decide-Act): Best for dynamic environments.
    • Observe: Read user input + environment state.
    • Orient: Retrieve relevant memory + context.
    • Decide: Select tool or response strategy.
    • Act: Execute tool or generate text.
  • ReAct (Reason + Act): Interleave reasoning traces with actions.
    • Thought: "I need to check the file size."
    • Action: check_file_size("log.txt")
    • Observation: "10MB"

How to structure Multi-Agent Systems

Select a pattern based on task complexity:

PatternDescriptionBest For
Orchestrator-WorkersCentral brain delegates to specialists.Complex tasks with clear sub-steps.
BlackboardAgents read/write to a shared state file.Collaborative planning, non-linear tasks.
PipelineOutput of Agent A becomes Input of Agent B.Data processing, CI/CD chains.
DebateAgents propose and critique solutions.High-stakes verification.

References