game-ai

Installation
SKILL.md

game-ai

Purpose

This skill develops AI algorithms for games, focusing on pathfinding (e.g., A* algorithm), decision trees for NPC behaviors, and machine learning integration (e.g., using TensorFlow for training models). It helps automate AI logic in game development workflows.

When to Use

  • When implementing NPC navigation in games, such as finding optimal paths in a grid-based world.
  • For creating decision-making systems, like enemy AI choosing actions based on game states.
  • Integrating ML for adaptive AI, such as training models to predict player moves in real-time simulations.

Key Capabilities

  • Pathfinding: Implements A* algorithm with configurable heuristics; supports grid-based maps up to 100x100 cells.
  • Decision Trees: Builds trees from JSON config files, e.g., {"node": "if health < 50 then flee"}; evaluates in under 10ms per decision.
  • Machine Learning Integration: Wraps TensorFlow APIs for model training; uses endpoints like /api/ml/train with input vectors for reinforcement learning in games.
  • Optimization: Includes flags for performance tuning, such as --optimize-memory to reduce heap usage by 20% in pathfinding routines.

Usage Patterns

To use this skill, invoke it via OpenClaw's CLI or API, passing required parameters. Always set the environment variable $GAME_AI_API_KEY for authentication. For pathfinding, call a function with a start/end point and grid; for decision trees, load a config and evaluate inputs. Structure code to handle asynchronous responses, e.g., wrap API calls in try-catch blocks.

Related skills
Installs
24
GitHub Stars
5
First Seen
Mar 5, 2026