Step-by-step Algorithm Implementation: from Pseudo-code and Equations to Python Code. In this article, we will implement the Planning Graph and its planner — the GraphPlanner in Python, data structure and search algorithm for AI Planning.


Planning Graph was developed to solve the issues in complexity found in the classical AI…

Automatically build and update Behavior Trees during run-time.


We have seen how powerful the behavior tree is, in the previous post.

It is hierarchical, modular, and more importantly reactive to changes that happen in the agent’s environment.

It can be used to replace Hierarchical Finite State Machines (HFSMs), to make the systems more scalable and understandable to humans.

Designing and Implementing Behaviors for AI Agents

Introduction — Another way of implementing Acting Engine

In our previous posts, we discussed about Planning and Acting. Both are for planning, one with a Descriptive Model and the other with an Operational Model of actions.

Acting with Operational Model uses Refinement Methods to refine abstract tasks into subtasks or commands that can be executed by Execution Platform…

Why STL Containers can fragment your memory and how to avoid it

How STL Containers Allocate Memory — Blocks and Chunks

STL Containers offer a variety of data structures that we can conveniently use when coding in C++. There are three types of containers:

  • Sequence Containers
  • Associative Containers
  • Unordered Associative Containers

Sequence containers are containers that can be accessed sequentially while associative containers are those that are in the form of…

Understanding how we can control memory allocation/deallocation of small objects to avoid memory fragmentation in C++

Overview — Why Do We Need Memory Pools

Knowing how dynamic memory allocation/deallocation works helps us understand why our memory can become fragmented.

Memory fragmentation refers to a condition in which small blocks of memory are allocated across the memory among larger blocks. …

Understanding how Any Type like std::any can help us simplify our code and how it works under the hood so that we can determine whether it satisfies our needs when developing our applications

We first discuss why we need to use Any Type, with examples, followed by how it is implemented using the Type Erasure technique, and finally how it allocates memory to see whether it fits our needs for writing our applications in C++.

Passing Any Type — Why we need it

Dynamically Typed Language

In a dynamically typed programming language like Python…

Understanding how to write a wrapper of any type in a class in C++ to increase the level of abstraction in our code.


We start with some basics about Generic Programming, Object Oriented Programming, and Duck Typing concepts to understand what problems this technique tries to solve. We’ll cover the details step-by-step at the end of this post.

Generic Programming

Generic Programming refers to a style of programming in which functions or algorithms are written…

Debby Nirwan

Software Engineering Manager who loves reading, writing, and coding.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store