diff --git a/source/RobotAPI/components/armem/client/ExampleMemoryClient/ExampleMemoryClient.cpp b/source/RobotAPI/components/armem/client/ExampleMemoryClient/ExampleMemoryClient.cpp
index 39e68a5ca0b45dc29c8c301022cbc885289050d9..a8d5f925e4b4097040b94b0e17607cfdb6d72ef7 100644
--- a/source/RobotAPI/components/armem/client/ExampleMemoryClient/ExampleMemoryClient.cpp
+++ b/source/RobotAPI/components/armem/client/ExampleMemoryClient/ExampleMemoryClient.cpp
@@ -30,7 +30,7 @@
 #include <RobotAPI/libraries/armem/server/MemoryRemoteGui.h>
 #include <RobotAPI/libraries/armem/client/query/Builder.h>
 #include <RobotAPI/libraries/armem/client/query/query_fns.h>
-#include <RobotAPI/libraries/armem/core/ice_conversions.h>
+#include <RobotAPI/libraries/armem/core/workingMemory/ice_conversions.h>
 
 #include <RobotAPI/components/armem/server/ExampleMemory/aron/ExampleData.aron.generated.h>
 
@@ -223,17 +223,17 @@ namespace armarx
         {
             armem::workingmemory::Memory& memory = qResult.memory;
 
-            ARMARX_CHECK_EQUAL(memory.coreSegments.size(), 1);
-            armem::workingmemory::CoreSegment& coreSeg = memory.coreSegments.begin()->second;
+            ARMARX_CHECK_EQUAL(memory.coreSegments().size(), 1);
+            armem::workingmemory::CoreSegment& coreSeg = memory.coreSegments().begin()->second;
 
-            ARMARX_CHECK_EQUAL(coreSeg.providerSegments.size(), 1);
-            armem::workingmemory::ProviderSegment& provSeg = coreSeg.providerSegments.begin()->second;
+            ARMARX_CHECK_EQUAL(coreSeg.providerSegments().size(), 1);
+            armem::workingmemory::ProviderSegment& provSeg = coreSeg.providerSegments().begin()->second;
 
-            ARMARX_CHECK_EQUAL(provSeg.entities.size(), 1);
-            armem::workingmemory::Entity& entity = provSeg.entities.begin()->second;
+            ARMARX_CHECK_EQUAL(provSeg.entities().size(), 1);
+            armem::workingmemory::Entity& entity = provSeg.entities().begin()->second;
 
-            ARMARX_CHECK_GREATER_EQUAL(entity.history.size(), 1);
-            armem::workingmemory::EntitySnapshot& snapshot = entity.history.begin()->second;
+            ARMARX_CHECK_GREATER_EQUAL(entity.history().size(), 1);
+            armem::workingmemory::EntitySnapshot& snapshot = entity.history().begin()->second;
 
             ARMARX_INFO << "Result: "
                         << "\n- memory:       \t" << memory.name()
@@ -265,7 +265,7 @@ namespace armarx
     void ExampleMemoryClient::queryExactSnapshot(const armem::MemoryID& snapshotID)
     {
         ARMARX_IMPORTANT
-                << "Querying exact smapshot: "
+                << "Querying exact snapshot: "
                 << "\n- snapshotID:     \t'" << snapshotID << "'"
                 ;
 
diff --git a/source/RobotAPI/libraries/armem/client/Query.h b/source/RobotAPI/libraries/armem/client/Query.h
index 842fdf55c53ea5dfddbeb40e6dd9d9128cfda570..5c0fb0f2b17a374bd1af884185c8fad659128c7c 100644
--- a/source/RobotAPI/libraries/armem/client/Query.h
+++ b/source/RobotAPI/libraries/armem/client/Query.h
@@ -3,7 +3,7 @@
 // RobotAPI
 #include <RobotAPI/interface/armem/query.h>
 
-#include <RobotAPI/libraries/armem/core/ice_conversions.h>
+#include <RobotAPI/libraries/armem/core/workingMemory/ice_conversions.h>
 #include <RobotAPI/libraries/armem/core/SuccessHeader.h>
 #include <RobotAPI/libraries/armem/core/DataMode.h>
 #include <RobotAPI/libraries/armem/core/workingMemory/Memory.h>
diff --git a/source/RobotAPI/libraries/armem/client/Reader.h b/source/RobotAPI/libraries/armem/client/Reader.h
index 8fd5277e6bfb82c1c2c8c503e654de2b1194b02f..8164cc7f7775b7f3cb22f63bbb625c3d56df3ae3 100644
--- a/source/RobotAPI/libraries/armem/client/Reader.h
+++ b/source/RobotAPI/libraries/armem/client/Reader.h
@@ -9,7 +9,7 @@
 // RobotAPI
 #include <RobotAPI/interface/armem/server/ReadingMemoryInterface.h>
 #include <RobotAPI/interface/armem/client/MemoryListenerInterface.h>
-#include <RobotAPI/libraries/armem/core/ice_conversions.h>
+#include <RobotAPI/libraries/armem/core/workingMemory/ice_conversions.h>
 #include <RobotAPI/libraries/armem/core/workingMemory/Memory.h>
 #include <RobotAPI/libraries/armem/core/longtermMemory/Memory.h>
 
diff --git a/source/RobotAPI/libraries/armem/client/Writer.h b/source/RobotAPI/libraries/armem/client/Writer.h
index f4c0754a10c129062f482d581d3d81f5bc0977ce..7a7160fcb2f8a8125468b890e53b64c090412cc6 100644
--- a/source/RobotAPI/libraries/armem/client/Writer.h
+++ b/source/RobotAPI/libraries/armem/client/Writer.h
@@ -2,7 +2,7 @@
 
 #include <RobotAPI/interface/armem/server/WritingMemoryInterface.h>
 
-#include <RobotAPI/libraries/armem/core/ice_conversions.h>
+#include <RobotAPI/libraries/armem/core/workingMemory/ice_conversions.h>
 
 
 namespace armarx::armem::client
diff --git a/source/RobotAPI/libraries/armem/client/query/selectors.cpp b/source/RobotAPI/libraries/armem/client/query/selectors.cpp
index 13d4e14c87054ce1010c81957563965d70c2b3e6..8383570717a6a5b0d5476e0b8f6355e9f7964877 100644
--- a/source/RobotAPI/libraries/armem/client/query/selectors.cpp
+++ b/source/RobotAPI/libraries/armem/client/query/selectors.cpp
@@ -1,6 +1,6 @@
 #include "selectors.h"
 
-#include <RobotAPI/libraries/armem/core/ice_conversions.h>
+#include <RobotAPI/libraries/armem/core/workingMemory/ice_conversions.h>
 
 
 namespace dq = ::armarx::armem::query::data;
diff --git a/source/RobotAPI/libraries/armem/core/base/CoreSegment.h b/source/RobotAPI/libraries/armem/core/base/CoreSegment.h
index 75f604a825981c881d0dd1d27d2cacb95ab1d4fd..64223917aae31bd8baa96d3f570345f748304d8d 100644
--- a/source/RobotAPI/libraries/armem/core/base/CoreSegment.h
+++ b/source/RobotAPI/libraries/armem/core/base/CoreSegment.h
@@ -63,9 +63,21 @@ namespace armarx::armem
             return const_cast<std::string&>(const_cast<const CoreSegmentBase*>(this)->name());
         }
 
+
+        using Base::container;
+        inline const std::map<std::string, ProviderSegmentT>& providerSegments() const
+        {
+            return container;
+        }
+        inline std::map<std::string, ProviderSegmentT>& providerSegments()
+        {
+            return const_cast<std::map<std::string, ProviderSegmentT>&>(const_cast<const CoreSegmentBase*>(this)->providerSegments());
+        }
+
+
         bool hasProviderSegment(const std::string& name) const
         {
-            return providerSegments.count(name) > 0;
+            return container.count(name) > 0;
         }
 
         ProviderSegmentT& getProviderSegment(const std::string& name)
@@ -75,8 +87,8 @@ namespace armarx::armem
 
         const ProviderSegmentT& getProviderSegment(const std::string& name) const
         {
-            auto it = this->providerSegments.find(name);
-            if (it != providerSegments.end())
+            auto it = this->container.find(name);
+            if (it != container.end())
             {
                 return it->second;
             }
@@ -97,8 +109,8 @@ namespace armarx::armem
         {
             _checkContainerName(update.entityID.coreSegmentName, this->name());
 
-            auto it = this->providerSegments.find(update.entityID.providerSegmentName);
-            if (it != providerSegments.end())
+            auto it = this->container.find(update.entityID.providerSegmentName);
+            if (it != container.end())
             {
                 return it->second.update(update);
             }
@@ -135,7 +147,7 @@ namespace armarx::armem
                     providerSegment.getLevelName(), providerSegment.name(), getLevelName(), this->getKeyString());
             }
 
-            auto it = providerSegments.emplace(providerSegment.name(), std::move(providerSegment)).first;
+            auto it = container.emplace(providerSegment.name(), std::move(providerSegment)).first;
             it->second.id.setCoreSegmentID(id);
             it->second.setMaxHistorySize(maxHistorySize);
             return it->second;
@@ -150,7 +162,7 @@ namespace armarx::armem
         void setMaxHistorySize(long maxSize) override
         {
             MaxHistorySize::setMaxHistorySize(maxSize);
-            for (auto& [name, seg] : providerSegments)
+            for (auto& [name, seg] : container)
             {
                 seg.setMaxHistorySize(maxSize);
             }
@@ -164,7 +176,7 @@ namespace armarx::armem
             {
                 return false;
             }
-            for (const auto& [key, provider] : providerSegments)
+            for (const auto& [key, provider] : container)
             {
                 if (not other.hasProviderSegment(key))
                 {
@@ -188,36 +200,7 @@ namespace armarx::armem
             return this->name();
         }
 
-        virtual Derived copy() const override
-        {
-            Derived d;
-            this->_copySelf(d);
-            return d;
-        }
-
-        virtual Derived copyEmpty() const override
-        {
-            Derived d;
-            this->_copySelfEmpty(d);
-            return d;
-        }
-
-    protected:
-        virtual void _copySelf(Derived& other) const override
-        {
-            Base::_copySelf(other);
-            providerSegments = other.providerSegments;
-        }
-
-        virtual void _copySelfEmpty(Derived& other) const override
-        {
-            Base::_copySelfEmpty(other);
-            providerSegments = other.providerSegments;
-        }
-
     public:
-        /// The provider segments.
-        std::map<std::string, ProviderSegmentT>& providerSegments = Base::container;
 
     };
 
diff --git a/source/RobotAPI/libraries/armem/core/base/Entity.h b/source/RobotAPI/libraries/armem/core/base/Entity.h
index 70bda50c06b02b0f954c26828f4ba304c76038b6..05cd45008a930bdc8be70c7fde218e27ffb186f7 100644
--- a/source/RobotAPI/libraries/armem/core/base/Entity.h
+++ b/source/RobotAPI/libraries/armem/core/base/Entity.h
@@ -78,7 +78,7 @@ namespace armarx::armem
             {
                 return false;
             }
-            for (const auto& [key, snapshot] : history)
+            for (const auto& [key, snapshot] : container)
             {
                 if (not other.hasSnapshot(key))
                 {
@@ -94,22 +94,33 @@ namespace armarx::armem
 
 
         using Base::id;
-        const std::string& name() const
+        inline const std::string& name() const
         {
             return id.entityName;
         }
-        std::string& name()
+        inline std::string& name()
         {
             return const_cast<std::string&>(const_cast<const EntityBase*>(this)->name());
         }
 
 
+        using Base::container;
+        inline const std::map<Time, _EntitySnapshotT>& history() const
+        {
+            return container;
+        }
+        inline std::map<Time, _EntitySnapshotT>& history()
+        {
+            return const_cast<std::map<Time, _EntitySnapshotT>&>(const_cast<const EntityBase*>(this)->history());
+        }
+
+
         /**
          * @brief Indicates whether a history entry for the given time exists.
          */
         bool hasSnapshot(Time time) const
         {
-            return history.count(time) > 0;
+            return container.count(time) > 0;
         }
 
         /**
@@ -126,7 +137,7 @@ namespace armarx::armem
          */
         std::vector<Time> getTimestamps() const
         {
-            return simox::alg::get_keys(history);
+            return simox::alg::get_keys(container);
         }
 
 
@@ -145,8 +156,8 @@ namespace armarx::armem
 
         const EntitySnapshotT& getSnapshot(Time time) const
         {
-            auto it = history.find(time);
-            if (it != history.end())
+            auto it = container.find(time);
+            if (it != container.end())
             {
                 return it->second;
             }
@@ -196,8 +207,8 @@ namespace armarx::armem
 
             EntitySnapshotT* snapshot;
 
-            auto it = history.find(update.timeCreated);
-            if (it == history.end())
+            auto it = container.find(update.timeCreated);
+            if (it == container.end())
             {
                 // Insert into history.
                 snapshot = &addSnapshot(update.timeCreated);
@@ -225,7 +236,7 @@ namespace armarx::armem
 
         EntitySnapshotT& addSnapshot(EntitySnapshotT&& snapshot)
         {
-            auto it = history.emplace(snapshot.time(), std::move(snapshot)).first;
+            auto it = container.emplace(snapshot.time(), std::move(snapshot)).first;
             it->second.id.setEntityID(id);
             return it->second;
         }
@@ -274,13 +285,11 @@ namespace armarx::armem
         virtual void _copySelf(Derived& other) const override
         {
             Base::_copySelf(other);
-            history = other.history;
         }
 
         virtual void _copySelfEmpty(Derived& other) const override
         {
             Base::_copySelfEmpty(other);
-            history = other.history;
         }
 
     private:
@@ -289,11 +298,11 @@ namespace armarx::armem
         {
             if (maxHistorySize >= 0)
             {
-                while (history.size() > size_t(maxHistorySize))
+                while (container.size() > size_t(maxHistorySize))
                 {
-                    history.erase(history.begin());
+                    container.erase(container.begin());
                 }
-                ARMARX_CHECK_LESS_EQUAL(history.size(), maxHistorySize);
+                ARMARX_CHECK_LESS_EQUAL(container.size(), maxHistorySize);
             }
         }
 
@@ -312,16 +321,14 @@ namespace armarx::armem
          */
         const typename std::map<Time, EntitySnapshotT>::value_type& getLatestItem() const
         {
-            if (history.empty())
+            if (container.empty())
             {
                 throw armem::error::EntityHistoryEmpty(name(), "when getting the latest snapshot.");
             }
-            return *history.rbegin();
+            return *container.rbegin();
         }
 
     public:
-        std::map<Time, EntitySnapshotT>& history = Base::container;
-
         /**
          * @brief Maximum size of `history`
          *
diff --git a/source/RobotAPI/libraries/armem/core/base/EntitySnapshot.h b/source/RobotAPI/libraries/armem/core/base/EntitySnapshot.h
index 7ad3680cd09cd14da708ed11b4f49c3f3019c812..e4b527b6e881ab0d2c6d960ef77c79b6db86a308 100644
--- a/source/RobotAPI/libraries/armem/core/base/EntitySnapshot.h
+++ b/source/RobotAPI/libraries/armem/core/base/EntitySnapshot.h
@@ -35,7 +35,7 @@ namespace armarx::armem
         EntitySnapshotBase(const MemoryID& id) : Base(id)
         {}
 
-        /// Copy the instances from `other` to this.
+        /// Copy the container from `other` to this.
         EntitySnapshotBase(const EntitySnapshotBase& other) : Base(other)
         {
             // *this = other;
@@ -56,7 +56,7 @@ namespace armarx::armem
                 return false;
             }
             int i = 0;
-            for (const auto& instance : instances)
+            for (const auto& instance : container)
             {
                 if (not instance.equalsDeep(other.getInstance(i)))
                 {
@@ -78,6 +78,18 @@ namespace armarx::armem
             return id.timestamp;
         }
 
+
+        using Base::container;
+        inline const std::vector<_EntityInstanceT>& instances() const
+        {
+            return container;
+        }
+        inline std::vector<_EntityInstanceT>& instances()
+        {
+            return const_cast<std::vector<_EntityInstanceT>&>(const_cast<const EntitySnapshotBase*>(this)->instances());
+        }
+
+
         void update(const EntityUpdate& update, std::optional<MemoryID> parentID = std::nullopt)
         {
             if (parentID)
@@ -86,10 +98,10 @@ namespace armarx::armem
             }
             time() = update.timeCreated;
 
-            instances.clear();
+            container.clear();
             for (int i = 0; i < int(update.instancesData.size()); ++i)
             {
-                EntityInstanceT& data = instances.emplace_back(i, id);
+                EntityInstanceT& data = container.emplace_back(i, id);
                 data.update(update, i);
             }
         }
@@ -98,7 +110,7 @@ namespace armarx::armem
         bool hasInstance(int index) const
         {
             size_t si = size_t(index);
-            return index >= 0 && si < instances.size();
+            return index >= 0 && si < container.size();
         }
 
         /**
@@ -117,7 +129,7 @@ namespace armarx::armem
             if (hasInstance(index))
             {
                 size_t si = size_t(index);
-                return instances[si];
+                return container[si];
             }
             else
             {
@@ -151,7 +163,7 @@ namespace armarx::armem
          * @brief Add a single instance with data.
          * @param instance The instance.
          * @return The stored instance.
-         * @throw `armem::error::InvalidArgument` If the given index is invalid. Must be equal to instances.size() or -1 (meaning push_back)
+         * @throw `armem::error::InvalidArgument` If the given index is invalid. Must be equal to container.size() or -1 (meaning push_back)
          */
         EntityInstanceT& addInstance(const EntityInstanceT& instance)
         {
@@ -160,19 +172,19 @@ namespace armarx::armem
 
         EntityInstanceT& addInstance(EntityInstanceT&& instance)
         {
-            if (instance.index() > 0 && (size_t) instance.index() < instances.size())
+            if (instance.index() > 0 && (size_t) instance.index() < container.size())
             {
                 throw error::InvalidArgument(std::to_string(instance.index()), "EntitySnapshot::addInstance",
                                              "Cannot add an EntityInstance because its index already exists.");
             }
-            if (instance.index() > 0 && (size_t) instance.index() > instances.size())
+            if (instance.index() > 0 && (size_t) instance.index() > container.size())
             {
                 throw error::InvalidArgument(std::to_string(instance.index()), "EntitySnapshot::addInstance",
                                              "Cannot add an EntityInstance because its index is too big.");
             }
 
-            int new_index = instances.size();
-            auto& it = instances.emplace_back(std::move(instance));
+            int new_index = container.size();
+            auto& it = container.emplace_back(std::move(instance));
             it.index() = new_index;
             return it;
         }
@@ -187,35 +199,7 @@ namespace armarx::armem
             return "entity snapshot";
         }
 
-        virtual Derived copy() const override
-        {
-            Derived d;
-            this->_copySelf(d);
-            return d;
-        }
-
-        virtual Derived copyEmpty() const override
-        {
-            Derived d;
-            this->_copySelfEmpty(d);
-            return d;
-        }
-
-    protected:
-        virtual void _copySelf(Derived& other) const override
-        {
-            Base::_copySelf(other);
-            instances = other.instances;
-        }
-
-        virtual void _copySelfEmpty(Derived& other) const override
-        {
-            Base::_copySelfEmpty(other);
-            instances = other.instances;
-        }
-
     public:
-        std::vector<_EntityInstanceT>& instances = Base::container;
     };
 
 }
diff --git a/source/RobotAPI/libraries/armem/core/base/Memory.h b/source/RobotAPI/libraries/armem/core/base/Memory.h
index 717927b976adc07b317e4030ab8cbc1cbde91e69..cf1a180207cf525da73ff8cf59170e74c41ca6cd 100644
--- a/source/RobotAPI/libraries/armem/core/base/Memory.h
+++ b/source/RobotAPI/libraries/armem/core/base/Memory.h
@@ -14,7 +14,7 @@ namespace armarx::armem
      */
     template <class _CoreSegmentT, class _EntityT, class _EntitySnapshotT, class _EntityInstanceT, class Derived>
     class MemoryBase :
-            virtual public detail::EntityContainerBase<_CoreSegmentT, _EntityT, _EntitySnapshotT, _EntityInstanceT, Derived>
+        virtual public detail::EntityContainerBase<_CoreSegmentT, _EntityT, _EntitySnapshotT, _EntityInstanceT, Derived>
     {
         using Base = detail::EntityContainerBase<_CoreSegmentT, _EntityT, _EntitySnapshotT, _EntityInstanceT, Derived>;
 
@@ -58,9 +58,21 @@ namespace armarx::armem
             return const_cast<std::string&>(const_cast<const MemoryBase*>(this)->name());
         }
 
+
+        using Base::container;
+        inline const std::map<std::string, CoreSegmentT>& coreSegments() const
+        {
+            return container;
+        }
+        inline std::map<std::string, CoreSegmentT>& coreSegments()
+        {
+            return const_cast<std::map<std::string, CoreSegmentT>&>(const_cast<const MemoryBase*>(this)->coreSegments());
+        }
+
+
         bool hasCoreSegment(const std::string& name) const
         {
-            return coreSegments.count(name) > 0;
+            return container.count(name) > 0;
         }
 
         CoreSegmentT& getCoreSegment(const std::string& name)
@@ -70,8 +82,8 @@ namespace armarx::armem
 
         const CoreSegmentT& getCoreSegment(const std::string& name) const
         {
-            auto it = this->coreSegments.find(name);
-            if (it != coreSegments.end())
+            auto it = this->container.find(name);
+            if (it != container.end())
             {
                 return it->second;
             }
@@ -106,12 +118,12 @@ namespace armarx::armem
         /// Move and insert a core segment.
         CoreSegmentT& addCoreSegment(CoreSegmentT&& coreSegment)
         {
-            if (coreSegments.count(coreSegment.name()) > 0)
+            if (container.count(coreSegment.name()) > 0)
             {
                 throw armem::error::ContainerEntryAlreadyExists(coreSegment.getLevelName(), coreSegment.name(),
                         this->getLevelName(), this->name());
             }
-            auto it = coreSegments.emplace(coreSegment.name(), std::move(coreSegment)).first;
+            auto it = container.emplace(coreSegment.name(), std::move(coreSegment)).first;
             it->second.id.setMemoryID(id);
             return it->second;
         }
@@ -142,8 +154,8 @@ namespace armarx::armem
         {
             _checkContainerName(update.entityID.memoryName, this->name());
 
-            auto it = this->coreSegments.find(update.entityID.coreSegmentName);
-            if (it != coreSegments.end())
+            auto it = this->container.find(update.entityID.coreSegmentName);
+            if (it != container.end())
             {
                 return it->second.update(update);
             }
@@ -161,7 +173,7 @@ namespace armarx::armem
             {
                 return false;
             }
-            for (const auto& [key, core] : coreSegments)
+            for (const auto& [key, core] : container)
             {
                 if (not other.hasCoreSegment(key))
                 {
@@ -185,34 +197,6 @@ namespace armarx::armem
             return this->name();
         }
 
-        virtual Derived copy() const override
-        {
-            Derived d;
-            this->_copySelf(d);
-            return d;
-        }
-
-        virtual Derived copyEmpty() const override
-        {
-            Derived d;
-            this->_copySelfEmpty(d);
-            return d;
-        }
-
-    protected:
-        virtual void _copySelf(Derived& other) const override
-        {
-            Base::_copySelf(other);
-            coreSegments = other.coreSegments;
-        }
-
-        virtual void _copySelfEmpty(Derived& other) const override
-        {
-            Base::_copySelfEmpty(other);
-            coreSegments = other.coreSegments;
-        }
-
     public:
-        std::map<std::string, CoreSegmentT>& coreSegments = Base::container;
     };
 }
diff --git a/source/RobotAPI/libraries/armem/core/base/ProviderSegment.h b/source/RobotAPI/libraries/armem/core/base/ProviderSegment.h
index 26f22688dd99a15180b1c1a62a051009e918006b..1ef59929ba1241d501e7ce3ac42d7125a8e78e51 100644
--- a/source/RobotAPI/libraries/armem/core/base/ProviderSegment.h
+++ b/source/RobotAPI/libraries/armem/core/base/ProviderSegment.h
@@ -63,9 +63,20 @@ namespace armarx::armem
         }
 
 
+        using Base::container;
+        inline const std::map<std::string, EntityT>& entities() const
+        {
+            return container;
+        }
+        inline std::map<std::string, EntityT>& entities()
+        {
+            return const_cast<std::map<std::string, EntityT>&>(const_cast<const ProviderSegmentBase*>(this)->entities());
+        }
+
+
         bool hasEntity(const std::string& name) const
         {
-            return entities.count(name) > 0;
+            return container.count(name) > 0;
         }
 
         using Base::_checkContainerName;
@@ -82,8 +93,8 @@ namespace armarx::armem
 
         const EntityT& getEntity(const std::string& name) const
         {
-            auto it = this->entities.find(name);
-            if (it != entities.end())
+            auto it = this->container.find(name);
+            if (it != container.end())
             {
                 return it->second;
             }
@@ -103,8 +114,8 @@ namespace armarx::armem
             _checkContainerName(update.entityID.providerSegmentName, this->name());
 
             EntityT* entity;
-            auto it = this->entities.find(update.entityID.providerSegmentName);
-            if (it == entities.end())
+            auto it = this->container.find(update.entityID.providerSegmentName);
+            if (it == container.end())
             {
                 // Add entity entry.
                 entity = &addEntity(update.entityID.entityName);
@@ -131,21 +142,21 @@ namespace armarx::armem
         /// Move and insert an entity.
         EntityT& addEntity(EntityT&& entity)
         {
-            auto it = entities.emplace(entity.name(), std::move(entity)).first;
+            auto it = container.emplace(entity.name(), std::move(entity)).first;
             it->second.id.setProviderSegmentID(id);
             return it->second;
         }
 
 
         /**
-         * @brief Sets the maximum history size of entities in this segment.
-         * This affects all current entities as well as new ones.
+         * @brief Sets the maximum history size of container in this segment.
+         * This affects all current container as well as new ones.
          * @see Entity::setMaxHistorySize()
          */
         void setMaxHistorySize(long maxSize) override
         {
             MaxHistorySize::setMaxHistorySize(maxSize);
-            for (auto& [name, entity] : entities)
+            for (auto& [name, entity] : container)
             {
                 entity.setMaxHistorySize(maxSize);
             }
@@ -160,7 +171,7 @@ namespace armarx::armem
             {
                 return false;
             }
-            for (const auto& [key, value] : entities)
+            for (const auto& [key, value] : container)
             {
                 if (not other.hasEntity(key))
                 {
@@ -185,37 +196,7 @@ namespace armarx::armem
             return this->name();
         }
 
-        virtual Derived copy() const override
-        {
-            Derived d;
-            this->_copySelf(d);
-            return d;
-        }
-
-        virtual Derived copyEmpty() const override
-        {
-            Derived d;
-            this->_copySelfEmpty(d);
-            return d;
-        }
-
-    protected:
-        virtual void _copySelf(Derived& other) const override
-        {
-            Base::_copySelf(other);
-            entities = other.entities;
-        }
-
-        virtual void _copySelfEmpty(Derived& other) const override
-        {
-            Base::_copySelfEmpty(other);
-            entities = other.entities;
-        }
-
-
     public:
-        /// The entities.
-        std::map<std::string, EntityT>& entities = Base::container;
 
     };
 
diff --git a/source/RobotAPI/libraries/armem/core/base/detail/MemoryContainer.h b/source/RobotAPI/libraries/armem/core/base/detail/MemoryContainer.h
index bb53d65565bc8920bf3cce07359041e1386fbe9a..c8454892d311ec02d01260400e1dee4510a24a0b 100644
--- a/source/RobotAPI/libraries/armem/core/base/detail/MemoryContainer.h
+++ b/source/RobotAPI/libraries/armem/core/base/detail/MemoryContainer.h
@@ -16,7 +16,7 @@ namespace armarx::armem::detail
      */
     template <class _ContainerT, class Derived>
     class MemoryContainerBase :
-            virtual public armarx::armem::detail::MemoryItem
+        virtual public armarx::armem::detail::MemoryItem
     {
         using Base = armarx::armem::detail::MemoryItem;
 
diff --git a/source/RobotAPI/libraries/armem/core/ice_conversions_templates.h b/source/RobotAPI/libraries/armem/core/ice_conversions_templates.h
index 1cc826f45230df2c031f1ba71911bf3af822edd7..dc5c3fff5e6298a74585479ef57df289eedc3900 100644
--- a/source/RobotAPI/libraries/armem/core/ice_conversions_templates.h
+++ b/source/RobotAPI/libraries/armem/core/ice_conversions_templates.h
@@ -28,14 +28,14 @@ namespace armarx::armem
     IceT toIce(const CppT& cpp)
     {
         IceT ice = {};
-        //toIce(ice, cpp);
+        toIce(ice, cpp);
         return ice;
     }
     template <class CppT, class IceT>
     CppT fromIce(const IceT& ice)
     {
         CppT cpp;
-        //fromIce(ice, cpp);
+        fromIce(ice, cpp);
         return cpp;
     }
 
@@ -63,14 +63,14 @@ namespace armarx::armem
     void toIce(::IceInternal::Handle<IceT>& ice, const CppT& cpp)
     {
         ice = new IceT();
-        //toIce(*ice, cpp);
+        toIce(*ice, cpp);
     }
     template <class IceT, class CppT>
     void fromIce(const ::IceInternal::Handle<IceT>& ice, CppT& cpp)
     {
         if (ice)
         {
-            //fromIce(*ice, cpp);
+            fromIce(*ice, cpp);
         }
     }
 
diff --git a/source/RobotAPI/libraries/armem/core/longtermMemory/CoreSegment.cpp b/source/RobotAPI/libraries/armem/core/longtermMemory/CoreSegment.cpp
index 76d86ba9f410a3845ab46be23c34aff7c070504f..3d42bbbe5a93c021871e97038aa9de61f8418c10 100644
--- a/source/RobotAPI/libraries/armem/core/longtermMemory/CoreSegment.cpp
+++ b/source/RobotAPI/libraries/armem/core/longtermMemory/CoreSegment.cpp
@@ -13,12 +13,14 @@ namespace armarx::armem::longtermmemory
     }
 
     CoreSegment::CoreSegment(const std::string& name, aron::typenavigator::ObjectNavigatorPtr aronType) :
-        CoreSegment(name, MemoryID(), aronType)
+        armarx::armem::detail::MemoryItem(MemoryID().withCoreSegmentName(name)),
+        armarx::armem::detail::TypedEntityContainerBase<ProviderSegment, Entity, EntitySnapshot, EntityInstance, CoreSegment>(MemoryID().withCoreSegmentName(name), aronType)
     {
     }
 
     CoreSegment::CoreSegment(const std::string& name, const MemoryID& parentID, aron::typenavigator::ObjectNavigatorPtr aronType) :
-        CoreSegment(parentID.getMemoryID().withCoreSegmentName(name), aronType)
+        armarx::armem::detail::MemoryItem(MemoryID().withCoreSegmentName(name)),
+        armarx::armem::detail::TypedEntityContainerBase<ProviderSegment, Entity, EntitySnapshot, EntityInstance, CoreSegment>(parentID.withCoreSegmentName(name), aronType)
     {
     }
 
@@ -33,13 +35,11 @@ namespace armarx::armem::longtermmemory
         MemoryContainerBase<std::map<std::string, ProviderSegment>, CoreSegment>(other),
         armarx::armem::detail::TypedEntityContainerBase<ProviderSegment, Entity, EntitySnapshot, EntityInstance, CoreSegment>(other)
     {
-        // *this = other;
     }
 
     CoreSegment& CoreSegment::operator=(const CoreSegment& other)
     {
         other._copySelf(*this);
-        //other._copyElements(*this, true);
         return *this;
     }
 }
diff --git a/source/RobotAPI/libraries/armem/core/longtermMemory/CoreSegment.h b/source/RobotAPI/libraries/armem/core/longtermMemory/CoreSegment.h
index d41c7288f22b46fc44cbc3c626aa1ff2011ced62..c2bc57f8ff359d1aba36ebf780846e4aef93b461 100644
--- a/source/RobotAPI/libraries/armem/core/longtermMemory/CoreSegment.h
+++ b/source/RobotAPI/libraries/armem/core/longtermMemory/CoreSegment.h
@@ -13,8 +13,8 @@ namespace armarx::armem::longtermmemory
      * @brief Data of a core segment containing multiple provider segments.
      */
     class CoreSegment :
-            virtual public CoreSegmentBase<ProviderSegment, Entity, EntitySnapshot, EntityInstance, CoreSegment>,
-            virtual public detail::TypedEntityContainer<ProviderSegment, CoreSegment>
+        virtual public CoreSegmentBase<ProviderSegment, Entity, EntitySnapshot, EntityInstance, CoreSegment>,
+        virtual public detail::TypedEntityContainer<ProviderSegment, CoreSegment>
     {
     public:
         CoreSegment();
diff --git a/source/RobotAPI/libraries/armem/core/longtermMemory/Entity.cpp b/source/RobotAPI/libraries/armem/core/longtermMemory/Entity.cpp
index 2ed158416fbada7b7b3d78fbc7c9ace403d36a39..09ea28d251736049ac9331e96c6b6760df27c545 100644
--- a/source/RobotAPI/libraries/armem/core/longtermMemory/Entity.cpp
+++ b/source/RobotAPI/libraries/armem/core/longtermMemory/Entity.cpp
@@ -8,7 +8,7 @@ namespace armarx::armem::longtermmemory
     }
 
     Entity::Entity(const std::string& name, const MemoryID& parentID) :
-        Entity(parentID.withEntityName(name))
+        armarx::armem::detail::MemoryItem(parentID.withEntityName(name))
     {
     }
 
@@ -21,13 +21,11 @@ namespace armarx::armem::longtermmemory
         armarx::armem::detail::MemoryItem(other),
         armarx::armem::detail::MemoryContainerBase<std::map<Time, EntitySnapshot>, Entity>(other)
     {
-        // *this = other;
     }
 
     Entity& Entity::operator=(const Entity& other)
     {
         other._copySelf(*this);
-        //other._copyElements(*this, true);
         return *this;
     }
 }
diff --git a/source/RobotAPI/libraries/armem/core/longtermMemory/EntityInstance.cpp b/source/RobotAPI/libraries/armem/core/longtermMemory/EntityInstance.cpp
index 6b2a6898f157bc777399a56da6e27c92a9e8c787..e1800f72aa2e0a3bfe1950d9cc464ae2c760e3af 100644
--- a/source/RobotAPI/libraries/armem/core/longtermMemory/EntityInstance.cpp
+++ b/source/RobotAPI/libraries/armem/core/longtermMemory/EntityInstance.cpp
@@ -18,6 +18,12 @@ namespace armarx::armem::longtermmemory
     {
     }
 
+    EntityInstance::EntityInstance(const EntityInstance& other) :
+        MemoryItem(other.id),
+        _metadata(other._metadata)
+    {
+    }
+
     EntityInstance::EntityInstance(int index, const MemoryID& parentID) :
         EntityInstance(parentID.withInstanceIndex(index))
     {
@@ -28,6 +34,12 @@ namespace armarx::armem::longtermmemory
     {
     }
 
+    EntityInstance& EntityInstance::operator=(const EntityInstance& other)
+    {
+        other._copySelf(*this);
+        return *this;
+    }
+
 
     bool EntityInstance::equalsDeep(const EntityInstance& other) const
     {
diff --git a/source/RobotAPI/libraries/armem/core/longtermMemory/EntityInstance.h b/source/RobotAPI/libraries/armem/core/longtermMemory/EntityInstance.h
index 764d941ed61fb5f947165a5762735f20578fb139..4884b43fb156e92aede47d365c1ecc3967e4148b 100644
--- a/source/RobotAPI/libraries/armem/core/longtermMemory/EntityInstance.h
+++ b/source/RobotAPI/libraries/armem/core/longtermMemory/EntityInstance.h
@@ -32,14 +32,17 @@ namespace armarx::armem::longtermmemory
      * @brief Data of a single entity instance.
      */
     class EntityInstance :
-            virtual public EntityInstanceBase<EntityInstance>
+        virtual public EntityInstanceBase<EntityInstance>
     {
 
     public:
         EntityInstance();
+        EntityInstance(const EntityInstance&);
         EntityInstance(int index, const MemoryID& parentID = {});
         EntityInstance(const MemoryID& id);
 
+        EntityInstance& operator=(const EntityInstance& other);
+
         EntityInstanceMetadata& metadata()
         {
             return _metadata;
diff --git a/source/RobotAPI/libraries/armem/core/longtermMemory/EntitySnapshot.cpp b/source/RobotAPI/libraries/armem/core/longtermMemory/EntitySnapshot.cpp
index f82a54ca70a2349e4b5151fcdc62ed63b3f5d6e1..11b2045e550e522c16a5c0956897103500242cec 100644
--- a/source/RobotAPI/libraries/armem/core/longtermMemory/EntitySnapshot.cpp
+++ b/source/RobotAPI/libraries/armem/core/longtermMemory/EntitySnapshot.cpp
@@ -27,19 +27,11 @@ namespace armarx::armem::longtermmemory
         armarx::armem::detail::MemoryItem(other),
         armarx::armem::detail::MemoryContainerBase<std::vector<EntityInstance>, EntitySnapshot>(other)
     {
-        // *this = other;
     }
 
     EntitySnapshot& EntitySnapshot::operator=(const EntitySnapshot& other)
     {
         other._copySelf(*this);
-        //other._copyElements(*this, true);
         return *this;
     }
-
-    /*EntitySnapshot EntitySnapshot::copy(bool withData) const
-    {
-        //auto cast = dynamic_cast<const Derived*>(this);
-        return Base2::copy(withData);
-    }*/
 }
diff --git a/source/RobotAPI/libraries/armem/core/longtermMemory/Memory.cpp b/source/RobotAPI/libraries/armem/core/longtermMemory/Memory.cpp
index 9ad01dec5d32a3fcad8330ba8945b7af871674e7..ee58ef2ab95581278bae1aeb3d6f868f66605e7a 100644
--- a/source/RobotAPI/libraries/armem/core/longtermMemory/Memory.cpp
+++ b/source/RobotAPI/libraries/armem/core/longtermMemory/Memory.cpp
@@ -14,7 +14,7 @@ namespace armarx::armem::longtermmemory
     }
 
     Memory::Memory(const std::string& name) :
-        Memory(MemoryID().withMemoryName(name))
+        armarx::armem::detail::MemoryItem(MemoryID().withMemoryName(name))
     {
     }
 
@@ -33,7 +33,7 @@ namespace armarx::armem::longtermmemory
     Memory& Memory::operator=(const Memory& other)
     {
         other._copySelf(*this);
-        //other._copyElements(*this, true);
         return *this;
     }
+
 }
diff --git a/source/RobotAPI/libraries/armem/core/longtermMemory/Memory.h b/source/RobotAPI/libraries/armem/core/longtermMemory/Memory.h
index dae9522a663ec878a2fe65bc122acd2aed8563a7..5dc1262cf02849420dbf15ba45320861422ff842 100644
--- a/source/RobotAPI/libraries/armem/core/longtermMemory/Memory.h
+++ b/source/RobotAPI/libraries/armem/core/longtermMemory/Memory.h
@@ -12,8 +12,8 @@ namespace armarx::armem::longtermmemory
      * @brief Data of a memory consisting of multiple core segments.
      */
     class Memory :
-            virtual public MemoryBase<CoreSegment, Entity, EntitySnapshot, EntityInstance, Memory>,
-            virtual public detail::EntityContainer<CoreSegment, Memory>
+        virtual public MemoryBase<CoreSegment, Entity, EntitySnapshot, EntityInstance, Memory>,
+        virtual public detail::EntityContainer<CoreSegment, Memory>
     {
     public:
         Memory();
diff --git a/source/RobotAPI/libraries/armem/core/longtermMemory/ProviderSegment.cpp b/source/RobotAPI/libraries/armem/core/longtermMemory/ProviderSegment.cpp
index b53148e18a4b03201a2c894e0b01de4879852a01..dac106c1e97124d25bfc48272b5ef6d08108ecff 100644
--- a/source/RobotAPI/libraries/armem/core/longtermMemory/ProviderSegment.cpp
+++ b/source/RobotAPI/libraries/armem/core/longtermMemory/ProviderSegment.cpp
@@ -13,12 +13,14 @@ namespace armarx::armem::longtermmemory
     }
 
     ProviderSegment::ProviderSegment(const std::string& name, aron::typenavigator::ObjectNavigatorPtr aronType) :
-        ProviderSegment(name, MemoryID(), aronType)
+        armarx::armem::detail::MemoryItem(MemoryID().withProviderSegmentName(name)),
+        armarx::armem::detail::TypedEntityContainerBase<Entity, Entity, EntitySnapshot, EntityInstance, ProviderSegment>(MemoryID().withProviderSegmentName(name), aronType)
     {
     }
 
     ProviderSegment::ProviderSegment(const std::string& name, const MemoryID parentID, aron::typenavigator::ObjectNavigatorPtr aronType) :
-        ProviderSegment(parentID.withProviderSegmentName(name), aronType)
+        armarx::armem::detail::MemoryItem(parentID.withProviderSegmentName(name)),
+        armarx::armem::detail::TypedEntityContainerBase<Entity, Entity, EntitySnapshot, EntityInstance, ProviderSegment>(parentID.withProviderSegmentName(name), aronType)
     {
     }
 
@@ -33,13 +35,12 @@ namespace armarx::armem::longtermmemory
         MemoryContainerBase<std::map<std::string, Entity>, ProviderSegment>(other),
         armarx::armem::detail::TypedEntityContainerBase<Entity, Entity, EntitySnapshot, EntityInstance, ProviderSegment>(other)
     {
-        // *this = other;
     }
 
     ProviderSegment& ProviderSegment::operator=(const ProviderSegment& other)
     {
         other._copySelf(*this);
-        //other._copyElements(*this, true);
         return *this;
     }
+
 }
diff --git a/source/RobotAPI/libraries/armem/core/workingMemory/CoreSegment.cpp b/source/RobotAPI/libraries/armem/core/workingMemory/CoreSegment.cpp
index 9310d7963b89e5feb5a2f8e9515a4a935eaaad79..e91e5fa4c4ea9467968bb1d1ff4a649529ceddb0 100644
--- a/source/RobotAPI/libraries/armem/core/workingMemory/CoreSegment.cpp
+++ b/source/RobotAPI/libraries/armem/core/workingMemory/CoreSegment.cpp
@@ -35,13 +35,27 @@ namespace armarx::armem::workingmemory
         MemoryContainerBase<std::map<std::string, ProviderSegment>, CoreSegment>(other),
         armarx::armem::detail::TypedEntityContainerBase<ProviderSegment, Entity, EntitySnapshot, EntityInstance, CoreSegment>(other)
     {
-        // *this = other;
     }
 
     CoreSegment& CoreSegment::operator=(const CoreSegment& other)
     {
         other._copySelf(*this);
-        //other._copyElements(*this, true);
         return *this;
     }
+
+    CoreSegment CoreSegment::copyWithoutData() const
+    {
+        CoreSegment m;
+        _copySelfWithoutData(m);
+        return m;
+    }
+
+    void CoreSegment::_copySelfWithoutData(CoreSegment& o) const
+    {
+        detail::TypedEntityContainer<ProviderSegment, CoreSegment>::_copySelfWithoutData(o);
+        for (const auto& [k, s] : o.container)
+        {
+            o.addProviderSegment(s.copyWithoutData());
+        }
+    }
 }
diff --git a/source/RobotAPI/libraries/armem/core/workingMemory/CoreSegment.h b/source/RobotAPI/libraries/armem/core/workingMemory/CoreSegment.h
index 1da46fbf3c5f6cc5571ad56b0a886f4e2bbacd06..e1fe33469f099c2e3e2439599bd3a60c0423c1bd 100644
--- a/source/RobotAPI/libraries/armem/core/workingMemory/CoreSegment.h
+++ b/source/RobotAPI/libraries/armem/core/workingMemory/CoreSegment.h
@@ -13,8 +13,8 @@ namespace armarx::armem::workingmemory
      * @brief Data of a core segment containing multiple provider segments.
      */
     class CoreSegment :
-            virtual public CoreSegmentBase<ProviderSegment, Entity, EntitySnapshot, EntityInstance, CoreSegment>,
-            virtual public detail::TypedEntityContainer<ProviderSegment, CoreSegment>
+        virtual public CoreSegmentBase<ProviderSegment, Entity, EntitySnapshot, EntityInstance, CoreSegment>,
+        virtual public detail::TypedEntityContainer<ProviderSegment, CoreSegment>
     {
     public:
         CoreSegment();
@@ -25,7 +25,10 @@ namespace armarx::armem::workingmemory
         CoreSegment(const CoreSegment& other);
         CoreSegment& operator=(const CoreSegment& other);
 
-        //CoreSegment copyWithoutData() const override;
+        CoreSegment copyWithoutData() const override;
+
+    protected:
+        virtual void _copySelfWithoutData(CoreSegment& o) const override;
     };
 
 }
diff --git a/source/RobotAPI/libraries/armem/core/workingMemory/Entity.cpp b/source/RobotAPI/libraries/armem/core/workingMemory/Entity.cpp
index 8308070cf2c460a3b27e23fa748cd8e710e191c9..4880da0ea2fc3ea7a86cc6308802da1e458714bd 100644
--- a/source/RobotAPI/libraries/armem/core/workingMemory/Entity.cpp
+++ b/source/RobotAPI/libraries/armem/core/workingMemory/Entity.cpp
@@ -21,13 +21,27 @@ namespace armarx::armem::workingmemory
         armarx::armem::detail::MemoryItem(other),
         armarx::armem::detail::MemoryContainerBase<std::map<Time, EntitySnapshot>, Entity>(other)
     {
-        // *this = other;
     }
 
     Entity& Entity::operator=(const Entity& other)
     {
         other._copySelf(*this);
-        //other._copyElements(*this, true);
         return *this;
     }
+
+    Entity Entity::copyWithoutData() const
+    {
+        Entity m;
+        _copySelfWithoutData(m);
+        return m;
+    }
+
+    void Entity::_copySelfWithoutData(Entity& o) const
+    {
+        detail::MemoryContainer<std::map<Time, EntitySnapshot>, Entity>::_copySelfWithoutData(o);
+        for (const auto& [k, s] : o.container)
+        {
+            o.addSnapshot(s.copyWithoutData());
+        }
+    }
 }
diff --git a/source/RobotAPI/libraries/armem/core/workingMemory/Entity.h b/source/RobotAPI/libraries/armem/core/workingMemory/Entity.h
index 571f02fbdfeaf63c36a6155133a2bac70abd9c25..3484406ae4445ef062b0e1a0bd7e64384a19d955 100644
--- a/source/RobotAPI/libraries/armem/core/workingMemory/Entity.h
+++ b/source/RobotAPI/libraries/armem/core/workingMemory/Entity.h
@@ -42,7 +42,10 @@ namespace armarx::armem::workingmemory
         /// Copy the history from `other` to this.
         Entity& operator=(const Entity& other);
 
-        //Entity copyWithoutData() const override;
+        Entity copyWithoutData() const override;
+
+    protected:
+        virtual void _copySelfWithoutData(Entity& o) const override;
     };
 
 }
diff --git a/source/RobotAPI/libraries/armem/core/workingMemory/EntityInstance.cpp b/source/RobotAPI/libraries/armem/core/workingMemory/EntityInstance.cpp
index 624b8ee9a5728e7e7c727fecd99901657c493f46..cffa83499501201bfd56ae82fe0e76206d5d970c 100644
--- a/source/RobotAPI/libraries/armem/core/workingMemory/EntityInstance.cpp
+++ b/source/RobotAPI/libraries/armem/core/workingMemory/EntityInstance.cpp
@@ -18,6 +18,13 @@ namespace armarx::armem::workingmemory
     {
     }
 
+    EntityInstance::EntityInstance(const EntityInstance& other) :
+        MemoryItem(other.id),
+        _metadata(other._metadata),
+        _data(other._data)
+    {
+    }
+
     EntityInstance::EntityInstance(int index, const MemoryID& parentID) :
         EntityInstance(parentID.withInstanceIndex(index))
     {
@@ -28,10 +35,16 @@ namespace armarx::armem::workingmemory
     {
     }
 
+    EntityInstance& EntityInstance::operator=(const EntityInstance& other)
+    {
+        other._copySelf(*this);
+        return *this;
+    }
+
 
     bool EntityInstance::equalsDeep(const EntityInstance& other) const
     {
-        return _metadata == other.metadata() && _data->equalsDeep(other.data());
+        return id == other.id && _metadata == other.metadata() && _data->equalsDeep(other.data());
     }
 
     void EntityInstance::update(const EntityUpdate& update, int index)
diff --git a/source/RobotAPI/libraries/armem/core/workingMemory/EntityInstance.h b/source/RobotAPI/libraries/armem/core/workingMemory/EntityInstance.h
index 45a1c3e76a180f66b304f12cd5f6ff61005dc855..38709d42fc6e41b50d8a1c26721cea1954d3aa24 100644
--- a/source/RobotAPI/libraries/armem/core/workingMemory/EntityInstance.h
+++ b/source/RobotAPI/libraries/armem/core/workingMemory/EntityInstance.h
@@ -32,14 +32,17 @@ namespace armarx::armem::workingmemory
      * @brief Data of a single entity instance.
      */
     class EntityInstance :
-            virtual public EntityInstanceBase<EntityInstance>
+        virtual public EntityInstanceBase<EntityInstance>
     {
 
     public:
         EntityInstance();
+        EntityInstance(const EntityInstance&);
         EntityInstance(int index, const MemoryID& parentID = {});
         EntityInstance(const MemoryID& id);
 
+        EntityInstance& operator=(const EntityInstance& other);
+
         EntityInstanceMetadata& metadata()
         {
             return _metadata;
diff --git a/source/RobotAPI/libraries/armem/core/workingMemory/EntitySnapshot.cpp b/source/RobotAPI/libraries/armem/core/workingMemory/EntitySnapshot.cpp
index ad4bc9ef6efc8e549ddd360235a5346adfe629e7..be3f082047778c330bdae3c961b51898f2a888bf 100644
--- a/source/RobotAPI/libraries/armem/core/workingMemory/EntitySnapshot.cpp
+++ b/source/RobotAPI/libraries/armem/core/workingMemory/EntitySnapshot.cpp
@@ -27,19 +27,27 @@ namespace armarx::armem::workingmemory
         armarx::armem::detail::MemoryItem(other),
         armarx::armem::detail::MemoryContainerBase<std::vector<EntityInstance>, EntitySnapshot>(other)
     {
-        // *this = other;
     }
 
     EntitySnapshot& EntitySnapshot::operator=(const EntitySnapshot& other)
     {
         other._copySelf(*this);
-        //other._copyElements(*this, true);
         return *this;
     }
 
-    /*EntitySnapshot EntitySnapshot::copy(bool withData) const
+    EntitySnapshot EntitySnapshot::copyWithoutData() const
     {
-        //auto cast = dynamic_cast<const Derived*>(this);
-        return Base2::copy(withData);
-    }*/
+        EntitySnapshot m;
+        _copySelfWithoutData(m);
+        return m;
+    }
+
+    void EntitySnapshot::_copySelfWithoutData(EntitySnapshot& o) const
+    {
+        detail::MemoryContainer<std::vector<EntityInstance>, EntitySnapshot>::_copySelfWithoutData(o);
+        for (const auto& s : o.container)
+        {
+            o.addInstance(s.copyWithoutData());
+        }
+    }
 }
diff --git a/source/RobotAPI/libraries/armem/core/workingMemory/EntitySnapshot.h b/source/RobotAPI/libraries/armem/core/workingMemory/EntitySnapshot.h
index b5671aaafdd049f01d3802c5b509e374fb3e9489..95af4a5e80ff66e0e8c679e53b439931652c2888 100644
--- a/source/RobotAPI/libraries/armem/core/workingMemory/EntitySnapshot.h
+++ b/source/RobotAPI/libraries/armem/core/workingMemory/EntitySnapshot.h
@@ -28,6 +28,9 @@ namespace armarx::armem::workingmemory
         /// Copy the instances from `other` to this.
         EntitySnapshot& operator=(const EntitySnapshot& other);
 
-        //EntitySnapshot copyWithoutData() const override;
+        EntitySnapshot copyWithoutData() const override;
+
+    protected:
+        virtual void _copySelfWithoutData(EntitySnapshot& o) const override;
     };
 }
diff --git a/source/RobotAPI/libraries/armem/core/workingMemory/Memory.cpp b/source/RobotAPI/libraries/armem/core/workingMemory/Memory.cpp
index 2506490915102a4e0d25fbebc968c63e7b24f11e..31e3805228b8d985695f223afe5c71959d1855db 100644
--- a/source/RobotAPI/libraries/armem/core/workingMemory/Memory.cpp
+++ b/source/RobotAPI/libraries/armem/core/workingMemory/Memory.cpp
@@ -16,7 +16,6 @@ namespace armarx::armem::workingmemory
     Memory::Memory(const std::string& name) :
         armarx::armem::detail::MemoryItem(MemoryID().withMemoryName(name))
     {
-        std::cout << "Memory: My name is: " << this->name() << std::endl;
     }
 
     Memory::Memory(const MemoryID& id) :
@@ -34,7 +33,22 @@ namespace armarx::armem::workingmemory
     Memory& Memory::operator=(const Memory& other)
     {
         other._copySelf(*this);
-        //other._copyElements(*this, true);
         return *this;
     }
+
+    Memory Memory::copyWithoutData() const
+    {
+        Memory m;
+        _copySelfWithoutData(m);
+        return m;
+    }
+
+    void Memory::_copySelfWithoutData(Memory& o) const
+    {
+        detail::EntityContainer<CoreSegment, Memory>::_copySelfWithoutData(o);
+        for (const auto& [k, s] : o.container)
+        {
+            o.addCoreSegment(s.copyWithoutData());
+        }
+    }
 }
diff --git a/source/RobotAPI/libraries/armem/core/workingMemory/Memory.h b/source/RobotAPI/libraries/armem/core/workingMemory/Memory.h
index 18e748cbb700562cc8561c7143ba87e50df93281..1b29e3afd26c483b6f8d68e02b40b5bd090f7618 100644
--- a/source/RobotAPI/libraries/armem/core/workingMemory/Memory.h
+++ b/source/RobotAPI/libraries/armem/core/workingMemory/Memory.h
@@ -12,8 +12,8 @@ namespace armarx::armem::workingmemory
      * @brief Data of a memory consisting of multiple core segments.
      */
     class Memory :
-            virtual public MemoryBase<CoreSegment, Entity, EntitySnapshot, EntityInstance, Memory>,
-            virtual public detail::EntityContainer<CoreSegment, Memory>
+        virtual public MemoryBase<CoreSegment, Entity, EntitySnapshot, EntityInstance, Memory>,
+        virtual public detail::EntityContainer<CoreSegment, Memory>
     {
     public:
         Memory();
@@ -23,6 +23,9 @@ namespace armarx::armem::workingmemory
         Memory(const Memory& other);
         Memory& operator=(const Memory& other);
 
-        //CoreSegment copyWithoutData() const override;
+        Memory copyWithoutData() const override;
+
+    protected:
+        virtual void _copySelfWithoutData(Memory& o) const override;
     };
 }
diff --git a/source/RobotAPI/libraries/armem/core/workingMemory/ProviderSegment.cpp b/source/RobotAPI/libraries/armem/core/workingMemory/ProviderSegment.cpp
index 2e43d2ceb287d1415ce6fb0fac37d18daf2567f4..832e9c6c9848c5925a70fb91a6bdb73e3bde643b 100644
--- a/source/RobotAPI/libraries/armem/core/workingMemory/ProviderSegment.cpp
+++ b/source/RobotAPI/libraries/armem/core/workingMemory/ProviderSegment.cpp
@@ -35,14 +35,28 @@ namespace armarx::armem::workingmemory
         MemoryContainerBase<std::map<std::string, Entity>, ProviderSegment>(other),
         armarx::armem::detail::TypedEntityContainerBase<Entity, Entity, EntitySnapshot, EntityInstance, ProviderSegment>(other)
     {
-        // *this = other;
     }
 
     ProviderSegment& ProviderSegment::operator=(const ProviderSegment& other)
     {
         other._copySelf(*this);
-        //other._copyElements(*this, true);
         return *this;
     }
 
+    ProviderSegment ProviderSegment::copyWithoutData() const
+    {
+        ProviderSegment m;
+        _copySelfWithoutData(m);
+        return m;
+    }
+
+    void ProviderSegment::_copySelfWithoutData(ProviderSegment& o) const
+    {
+        detail::TypedEntityContainer<Entity, ProviderSegment>::_copySelfWithoutData(o);
+        for (const auto& [k, s] : o.container)
+        {
+            o.addEntity(s.copyWithoutData());
+        }
+    }
+
 }
diff --git a/source/RobotAPI/libraries/armem/core/workingMemory/ProviderSegment.h b/source/RobotAPI/libraries/armem/core/workingMemory/ProviderSegment.h
index 482e189be9a896e4700a576390ffb0f1dbac32f1..d80f531729a421f82fcb8755046f8346fc83f10e 100644
--- a/source/RobotAPI/libraries/armem/core/workingMemory/ProviderSegment.h
+++ b/source/RobotAPI/libraries/armem/core/workingMemory/ProviderSegment.h
@@ -25,7 +25,10 @@ namespace armarx::armem::workingmemory
         ProviderSegment(const ProviderSegment& other);
         ProviderSegment& operator=(const ProviderSegment& other);
 
-        //ProviderSegment copyWithoutData() const override;
+        ProviderSegment copyWithoutData() const override;
+
+    protected:
+        virtual void _copySelfWithoutData(ProviderSegment& o) const override;
     };
 
 }
diff --git a/source/RobotAPI/libraries/armem/core/workingMemory/detail/MemoryContainer.h b/source/RobotAPI/libraries/armem/core/workingMemory/detail/MemoryContainer.h
index 06d98823e95f35b4b64b257716ecb2fae81066ef..c3633b6512d95b3c7b79bf7522b6d48c4fc3e573 100644
--- a/source/RobotAPI/libraries/armem/core/workingMemory/detail/MemoryContainer.h
+++ b/source/RobotAPI/libraries/armem/core/workingMemory/detail/MemoryContainer.h
@@ -16,7 +16,7 @@ namespace armarx::armem::workingmemory::detail
      */
     template <class _ContainerT, class Derived>
     class MemoryContainer :
-            virtual public armarx::armem::detail::MemoryContainerBase<_ContainerT, Derived>
+        virtual public armarx::armem::detail::MemoryContainerBase<_ContainerT, Derived>
     {
     public:
         MemoryContainer& operator=(const MemoryContainer& other)
@@ -28,8 +28,15 @@ namespace armarx::armem::workingmemory::detail
         // Copying
         virtual Derived copyWithoutData() const
         {
-            //auto cast = dynamic_cast<const Derived*>(this);
-            return armarx::armem::detail::MemoryContainerBase<_ContainerT, Derived>::copy();
+            Derived t;
+            _copySelfWithoutData(t);
+            return t;
+        }
+
+    protected:
+        virtual void _copySelfWithoutData(Derived& o) const
+        {
+            armarx::armem::detail::MemoryContainerBase<_ContainerT, Derived>::_copySelfEmpty(o);
         }
     };
 }
diff --git a/source/RobotAPI/libraries/armem/core/workingMemory/ice_conversions.cpp b/source/RobotAPI/libraries/armem/core/workingMemory/ice_conversions.cpp
index 03c0e1f8468e0fd2c9bbb5fa89328e4406180161..f218de3838b1d6e337f7bf22c050cbbc6343e1a3 100644
--- a/source/RobotAPI/libraries/armem/core/workingMemory/ice_conversions.cpp
+++ b/source/RobotAPI/libraries/armem/core/workingMemory/ice_conversions.cpp
@@ -1,17 +1,15 @@
 #include "ice_conversions.h"
 
-using namespace armarx::armem::workingmemory;
-
-namespace armarx
+namespace armarx::armem
 {
-    void armem::toIce(data::EntityInstanceMetadata& ice, const EntityInstanceMetadata& metadata)
+    void toIce(data::EntityInstanceMetadata& ice, const workingmemory::EntityInstanceMetadata& metadata)
     {
         ice.confidence = metadata.confidence;
         toIce(ice.timeArrivedMicroSeconds, metadata.timeArrived);
         toIce(ice.timeCreatedMicroSeconds, metadata.timeCreated);
         toIce(ice.timeSentMicroSeconds, metadata.timeSent);
     }
-    void armem::fromIce(const data::EntityInstanceMetadata& ice, EntityInstanceMetadata& metadata)
+    void fromIce(const data::EntityInstanceMetadata& ice, workingmemory::EntityInstanceMetadata& metadata)
     {
         metadata.confidence = ice.confidence;
         fromIce(ice.timeArrivedMicroSeconds, metadata.timeArrived);
@@ -19,7 +17,7 @@ namespace armarx
         fromIce(ice.timeSentMicroSeconds, metadata.timeSent);
     }
 
-    void armem::toIce(data::EntityInstance& ice, const EntityInstance& data)
+    void toIce(data::EntityInstance& ice, const workingmemory::EntityInstance& data)
     {
         detail::toIceItem(ice, data);
 
@@ -29,7 +27,7 @@ namespace armarx
         }
         toIce(ice.metadata, data.metadata());
     }
-    void armem::fromIce(const data::EntityInstance& ice, EntityInstance& data)
+    void fromIce(const data::EntityInstance& ice, workingmemory::EntityInstance& data)
     {
         detail::fromIceItem(ice, data);
 
@@ -41,34 +39,34 @@ namespace armarx
     }
 
 
-    void armem::toIce(data::EntitySnapshot& ice, const EntitySnapshot& snapshot)
+    void toIce(data::EntitySnapshot& ice, const workingmemory::EntitySnapshot& snapshot)
     {
         detail::toIceItem(ice, snapshot);
 
-        toIce(ice.instances, snapshot.instances);
+        toIce(ice.instances, snapshot.container);
     }
-    void armem::fromIce(const data::EntitySnapshot& ice, EntitySnapshot& snapshot)
+    void fromIce(const data::EntitySnapshot& ice, workingmemory::EntitySnapshot& snapshot)
     {
         detail::fromIceItem(ice, snapshot);
 
-        fromIce(ice.instances, snapshot.instances);
+        fromIce(ice.instances, snapshot.container);
     }
 
-    void armem::toIce(data::Entity& ice, const Entity& entity)
+    void toIce(data::Entity& ice, const workingmemory::Entity& entity)
     {
         detail::toIceItem(ice, entity);
 
-        toIce(ice.history, entity.history);
+        toIce(ice.history, entity.container);
     }
-    void armem::fromIce(const data::Entity& ice, Entity& entity)
+    void fromIce(const data::Entity& ice, workingmemory::Entity& entity)
     {
         detail::fromIceItem(ice, entity);
 
-        fromIce(ice.history, entity.history);
+        fromIce(ice.history, entity.container);
     }
 
 
-    void armem::toIce(data::ProviderSegment& ice, const ProviderSegment& providerSegment)
+    void toIce(data::ProviderSegment& ice, const workingmemory::ProviderSegment& providerSegment)
     {
         detail::toIceItem(ice, providerSegment);
 
@@ -76,9 +74,9 @@ namespace armarx
         {
             ice.aronType = providerSegment.aronType->getResult();
         }
-        toIce(ice.entities, providerSegment.entities);
+        toIce(ice.entities, providerSegment.container);
     }
-    void armem::fromIce(const data::ProviderSegment& ice, ProviderSegment& providerSegment)
+    void fromIce(const data::ProviderSegment& ice, workingmemory::ProviderSegment& providerSegment)
     {
         detail::fromIceItem(ice, providerSegment);
 
@@ -86,10 +84,10 @@ namespace armarx
         {
             providerSegment.aronType = aron::typenavigator::ObjectNavigator::DynamicCastAndCheck(aron::typenavigator::Navigator::FromAronType(ice.aronType));
         }
-        fromIce(ice.entities, providerSegment.entities);
+        fromIce(ice.entities, providerSegment.container);
     }
 
-    void armem::toIce(data::CoreSegment& ice, const CoreSegment& coreSegment)
+    void toIce(data::CoreSegment& ice, const workingmemory::CoreSegment& coreSegment)
     {
         detail::toIceItem(ice, coreSegment);
 
@@ -97,9 +95,9 @@ namespace armarx
         {
             ice.aronType = coreSegment.aronType->getResult();
         }
-        toIce(ice.providerSegments, coreSegment.providerSegments);
+        toIce(ice.providerSegments, coreSegment.container);
     }
-    void armem::fromIce(const data::CoreSegment& ice, CoreSegment& coreSegment)
+    void fromIce(const data::CoreSegment& ice, workingmemory::CoreSegment& coreSegment)
     {
         detail::fromIceItem(ice, coreSegment);
 
@@ -107,20 +105,20 @@ namespace armarx
         {
             coreSegment.aronType = aron::typenavigator::ObjectNavigator::DynamicCastAndCheck(aron::typenavigator::Navigator::FromAronType(ice.aronType));
         }
-        fromIce(ice.providerSegments, coreSegment.providerSegments);
+        fromIce(ice.providerSegments, coreSegment.container);
     }
 
-    void armem::toIce(data::Memory& ice, const Memory& memory)
+    void toIce(data::Memory& ice, const workingmemory::Memory& memory)
     {
         detail::toIceItem(ice, memory);
 
-        toIce(ice.coreSegments, memory.coreSegments);
+        toIce(ice.coreSegments, memory.container);
     }
-    void armem::fromIce(const data::Memory& ice, Memory& memory)
+    void fromIce(const data::Memory& ice, workingmemory::Memory& memory)
     {
         detail::fromIceItem(ice, memory);
 
-        fromIce(ice.coreSegments, memory.coreSegments);
+        fromIce(ice.coreSegments, memory.container);
     }
 
 }
diff --git a/source/RobotAPI/libraries/armem/core/workingMemory/ice_conversions.h b/source/RobotAPI/libraries/armem/core/workingMemory/ice_conversions.h
index e5996b001a770d0073d991b931aa9fab9a3952a9..a48fe734ba145bf05c8a1b31f71e5c6ccb2e4f82 100644
--- a/source/RobotAPI/libraries/armem/core/workingMemory/ice_conversions.h
+++ b/source/RobotAPI/libraries/armem/core/workingMemory/ice_conversions.h
@@ -3,8 +3,6 @@
 #include <RobotAPI/interface/armem/commit.h>
 #include <RobotAPI/interface/armem/memory.h>
 
-#include "../ice_conversions.h"
-
 #include "Memory.h"
 
 
@@ -33,3 +31,6 @@ namespace armarx::armem
     void toIce(data::Memory& ice, const workingmemory::Memory& memory);
     void fromIce(const data::Memory& ice, workingmemory::Memory& memory);
 }
+
+// Must be included after the prototypes. Otherwise the compiler cannot find the correct methods in ice_coversion_templates.h
+#include "../ice_conversions.h"
diff --git a/source/RobotAPI/libraries/armem/server/MemoryRemoteGui.cpp b/source/RobotAPI/libraries/armem/server/MemoryRemoteGui.cpp
index b6a1ffc5db6fe88a16b3dd2eb7889218db9f8dc4..870bba1c56f807bfea6aa9d8c76ceb73350847ce 100644
--- a/source/RobotAPI/libraries/armem/server/MemoryRemoteGui.cpp
+++ b/source/RobotAPI/libraries/armem/server/MemoryRemoteGui.cpp
@@ -16,13 +16,13 @@ namespace armarx::armem::server
     MemoryRemoteGui::GroupBox MemoryRemoteGui::makeGroupBox(const workingmemory::Memory& memory) const
     {
         GroupBox group;
-        group.setLabel(makeGroupLabel("Memory", memory.name(), memory.coreSegments.size()));
+        group.setLabel(makeGroupLabel("Memory", memory.name(), memory.coreSegments().size()));
 
-        if (memory.coreSegments.empty())
+        if (memory.coreSegments().empty())
         {
             group.addChild(Label(makeNoItemsMessage("core segments")));
         }
-        for (const auto& [name, coreSegment] : memory.coreSegments)
+        for (const auto& [name, coreSegment] : memory.coreSegments())
         {
             group.addChild(makeGroupBox(coreSegment));
         }
@@ -35,13 +35,13 @@ namespace armarx::armem::server
     MemoryRemoteGui::GroupBox MemoryRemoteGui::makeGroupBox(const workingmemory::CoreSegment& coreSegment) const
     {
         GroupBox group;
-        group.setLabel(makeGroupLabel("Core Segment", coreSegment.name(), coreSegment.providerSegments.size()));
+        group.setLabel(makeGroupLabel("Core Segment", coreSegment.name(), coreSegment.providerSegments().size()));
 
-        if (coreSegment.providerSegments.empty())
+        if (coreSegment.providerSegments().empty())
         {
             group.addChild(Label(makeNoItemsMessage("provider segments")));
         }
-        for (const auto& [name, providerSegment] : coreSegment.providerSegments)
+        for (const auto& [name, providerSegment] : coreSegment.providerSegments())
         {
             group.addChild(makeGroupBox(providerSegment));
         }
@@ -54,13 +54,13 @@ namespace armarx::armem::server
     MemoryRemoteGui::GroupBox MemoryRemoteGui::makeGroupBox(const workingmemory::ProviderSegment& providerSegment) const
     {
         GroupBox group;
-        group.setLabel(makeGroupLabel("Provider Segment", providerSegment.name(), providerSegment.entities.size()));
+        group.setLabel(makeGroupLabel("Provider Segment", providerSegment.name(), providerSegment.entities().size()));
 
-        if (providerSegment.entities.empty())
+        if (providerSegment.entities().empty())
         {
             group.addChild(Label(makeNoItemsMessage("entities")));
         }
-        for (const auto& [name, entity] : providerSegment.entities)
+        for (const auto& [name, entity] : providerSegment.entities())
         {
             group.addChild(makeGroupBox(entity));
         }
@@ -73,15 +73,15 @@ namespace armarx::armem::server
     MemoryRemoteGui::GroupBox MemoryRemoteGui::makeGroupBox(const workingmemory::Entity& entity) const
     {
         GroupBox group;
-        group.setLabel(makeGroupLabel("Entity", entity.name(), entity.history.size()));
+        group.setLabel(makeGroupLabel("Entity", entity.name(), entity.history().size()));
 
-        if (entity.history.empty())
+        if (entity.history().empty())
         {
             group.addChild(Label(makeNoItemsMessage("snapshots")));
         }
-        if (int(entity.history.size()) <= maxHistorySize)
+        if (int(entity.history().size()) <= maxHistorySize)
         {
-            for (const auto& [time, snapshot] : entity.history)
+            for (const auto& [time, snapshot] : entity.history())
             {
                 group.addChild(makeGroupBox(snapshot));
             }
@@ -89,8 +89,8 @@ namespace armarx::armem::server
         else
         {
             int margin = 2;
-            auto it = entity.history.begin();
-            auto rit = entity.history.end();
+            auto it = entity.history().begin();
+            auto rit = entity.history().end();
             --rit;
             for (int i = 0; i < margin; ++i, ++it)
             {
@@ -98,7 +98,7 @@ namespace armarx::armem::server
                 --rit;
             }
             group.addChild(Label("..."));
-            for (; rit != entity.history.end(); ++rit)
+            for (; rit != entity.history().end(); ++rit)
             {
                 group.addChild(makeGroupBox(rit->second));
             }
@@ -114,13 +114,13 @@ namespace armarx::armem::server
     {
         GroupBox group;
         group.setLabel(makeGroupLabel("t", armem::toDateTimeMilliSeconds(snapshot.time()),
-                                      snapshot.instances.size(), " = ", ""));
+                                      snapshot.instances().size(), " = ", ""));
 
-        if (snapshot.instances.empty())
+        if (snapshot.instances().empty())
         {
             group.addChild(Label(makeNoItemsMessage("instances")));
         }
-        for (const workingmemory::EntityInstance& instance : snapshot.instances)
+        for (const workingmemory::EntityInstance& instance : snapshot.instances())
         {
             group.addChild(makeGroupBox(instance));
         }
diff --git a/source/RobotAPI/libraries/armem/server/MemoryToIceAdapter.cpp b/source/RobotAPI/libraries/armem/server/MemoryToIceAdapter.cpp
index 955fb203f9cb94af27233ff9224db4b1e9371ba7..d1ed7fc92c8d1804c2223721ccbd89b48a27c17b 100644
--- a/source/RobotAPI/libraries/armem/server/MemoryToIceAdapter.cpp
+++ b/source/RobotAPI/libraries/armem/server/MemoryToIceAdapter.cpp
@@ -3,7 +3,7 @@
 #include <ArmarXCore/core/exceptions/local/ExpressionException.h>
 
 #include "../error.h"
-#include "../core/ice_conversions.h"
+#include "../core/workingMemory/ice_conversions.h"
 #include "query_proc/MemoryQueryProcessor.h"
 
 //#include "../core/io/diskWriter/NlohmannJSON/NlohmannJSONDiskWriter.h"
diff --git a/source/RobotAPI/libraries/armem/server/query_proc/BaseQueryProcessor.cpp b/source/RobotAPI/libraries/armem/server/query_proc/BaseQueryProcessor.cpp
index c9f25c5d279a896f34f4d72e252a427b24549e07..5bb5942e8b89d450af5450219c3420e070d34c1a 100644
--- a/source/RobotAPI/libraries/armem/server/query_proc/BaseQueryProcessor.cpp
+++ b/source/RobotAPI/libraries/armem/server/query_proc/BaseQueryProcessor.cpp
@@ -4,7 +4,7 @@
 #include <ArmarXCore/core/exceptions/local/ExpressionException.h>
 
 #include <RobotAPI/libraries/armem/core/error.h>
-#include <RobotAPI/libraries/armem/core/ice_conversions.h>
+#include <RobotAPI/libraries/armem/core/workingMemory/ice_conversions.h>
 
 
 namespace armarx::armem::query_proc
diff --git a/source/RobotAPI/libraries/armem/server/query_proc/CoreSegmentQueryProcessor.cpp b/source/RobotAPI/libraries/armem/server/query_proc/CoreSegmentQueryProcessor.cpp
index 77c0cadab99dac7c5680b6801d79087fafe90c4a..cce5b13cc6af4779145360c1f5a9526d06c584b0 100644
--- a/source/RobotAPI/libraries/armem/server/query_proc/CoreSegmentQueryProcessor.cpp
+++ b/source/RobotAPI/libraries/armem/server/query_proc/CoreSegmentQueryProcessor.cpp
@@ -5,7 +5,7 @@
 #include <ArmarXCore/core/logging/Logging.h>
 #include <ArmarXCore/core/exceptions/local/ExpressionException.h>
 
-#include <RobotAPI/libraries/armem/core/ice_conversions.h>
+#include <RobotAPI/libraries/armem/core/workingMemory/ice_conversions.h>
 #include <RobotAPI/libraries/armem/core/error.h>
 
 
@@ -36,7 +36,7 @@ namespace armarx::armem::query_proc
     void CoreSegmentQueryProcessor::process(workingmemory::CoreSegment& result,
                                             const armem::query::data::core::All& query, const workingmemory::CoreSegment& coreSegment) const
     {
-        for (const auto& [name, providerSegment] : coreSegment.providerSegments)
+        for (const auto& [name, providerSegment] : coreSegment.providerSegments())
         {
             result.addProviderSegment(providerSegmentProcessor.process(query.providerSegmentQueries, providerSegment));
         }
@@ -60,7 +60,7 @@ namespace armarx::armem::query_proc
                                             const armem::query::data::core::Regex& query, const workingmemory::CoreSegment& coreSegment) const
     {
         std::regex regex(query.providerSegmentNameRegex);
-        for (const auto& [name, providerSegment] : coreSegment.providerSegments)
+        for (const auto& [name, providerSegment] : coreSegment.providerSegments())
         {
             if (std::regex_search(providerSegment.name(), regex))
             {
diff --git a/source/RobotAPI/libraries/armem/server/query_proc/EntityQueryProcessor.cpp b/source/RobotAPI/libraries/armem/server/query_proc/EntityQueryProcessor.cpp
index 48d40fb059297058f5421781e8417b25b74a846c..d840425d39c022fa8b98bd4bdfac420848ff1694 100644
--- a/source/RobotAPI/libraries/armem/server/query_proc/EntityQueryProcessor.cpp
+++ b/source/RobotAPI/libraries/armem/server/query_proc/EntityQueryProcessor.cpp
@@ -4,7 +4,7 @@
 #include <ArmarXCore/core/exceptions/local/ExpressionException.h>
 
 #include <RobotAPI/libraries/armem/core/error.h>
-#include <RobotAPI/libraries/armem/core/ice_conversions.h>
+#include <RobotAPI/libraries/armem/core/workingMemory/ice_conversions.h>
 
 
 namespace armarx::armem::query_proc
@@ -79,8 +79,8 @@ namespace armarx::armem::query_proc
             return;
         }
 
-        size_t first = negativeIndexSemantics(query.first, entity.history.size());
-        size_t last = negativeIndexSemantics(query.last, entity.history.size());
+        size_t first = negativeIndexSemantics(query.first, entity.history().size());
+        size_t last = negativeIndexSemantics(query.last, entity.history().size());
 
         if (first <= last)
         {
@@ -111,11 +111,11 @@ namespace armarx::armem::query_proc
         (void) query;
 
         // Returns an iterator pointing to the first element that is not less than (i.e. greater or equal to) key.
-        auto begin = min.toMicroSeconds() > 0 ? entity.history.lower_bound(min) : entity.history.begin();
+        auto begin = min.toMicroSeconds() > 0 ? entity.history().lower_bound(min) : entity.history().begin();
         // Returns an iterator pointing to the first element that is *greater than* key.
-        auto end = max.toMicroSeconds() > 0 ? entity.history.upper_bound(max) : entity.history.end();
+        auto end = max.toMicroSeconds() > 0 ? entity.history().upper_bound(max) : entity.history().end();
 
-        for (auto it = begin; it != end && it != entity.history.end(); ++it)
+        for (auto it = begin; it != end && it != entity.history().end(); ++it)
         {
             addResultSnapshot(result, it);
         }
diff --git a/source/RobotAPI/libraries/armem/server/query_proc/MemoryQueryProcessor.cpp b/source/RobotAPI/libraries/armem/server/query_proc/MemoryQueryProcessor.cpp
index c239b6c8b2d220497a6f14910906af636767101d..1982845a0fcd7c3f9dfc8f676acd93fd3157317c 100644
--- a/source/RobotAPI/libraries/armem/server/query_proc/MemoryQueryProcessor.cpp
+++ b/source/RobotAPI/libraries/armem/server/query_proc/MemoryQueryProcessor.cpp
@@ -6,7 +6,7 @@
 #include <ArmarXCore/core/exceptions/local/ExpressionException.h>
 
 #include <RobotAPI/libraries/armem/core/error.h>
-#include <RobotAPI/libraries/armem/core/ice_conversions.h>
+#include <RobotAPI/libraries/armem/core/workingMemory/ice_conversions.h>
 
 
 namespace armarx::armem::query_proc
@@ -54,7 +54,7 @@ namespace armarx::armem::query_proc
 
     void MemoryQueryProcessor::process(workingmemory::Memory& result, const armem::query::data::memory::All& query, const workingmemory::Memory& memory) const
     {
-        for (const auto& [name, coreSegment] : memory.coreSegments)
+        for (const auto& [name, coreSegment] : memory.coreSegments())
         {
             result.addCoreSegment(coreSegmentProcessor.process(query.coreSegmentQueries, coreSegment));
         }
@@ -76,7 +76,7 @@ namespace armarx::armem::query_proc
     void MemoryQueryProcessor::process(workingmemory::Memory& result, const armem::query::data::memory::Regex& query, const workingmemory::Memory& memory) const
     {
         std::regex regex(query.coreSegmentNameRegex);
-        for (const auto& [name, coreSegment] : memory.coreSegments)
+        for (const auto& [name, coreSegment] : memory.coreSegments())
         {
             if (std::regex_search(coreSegment.name(), regex))
             {
diff --git a/source/RobotAPI/libraries/armem/server/query_proc/ProviderSegmentQueryProcessor.cpp b/source/RobotAPI/libraries/armem/server/query_proc/ProviderSegmentQueryProcessor.cpp
index 8a07b2116c66b900b03999c482072d74426390a4..d6bc87a69efaf4107c6be794050c59143e6c6a7a 100644
--- a/source/RobotAPI/libraries/armem/server/query_proc/ProviderSegmentQueryProcessor.cpp
+++ b/source/RobotAPI/libraries/armem/server/query_proc/ProviderSegmentQueryProcessor.cpp
@@ -6,7 +6,7 @@
 #include <ArmarXCore/core/exceptions/local/ExpressionException.h>
 
 #include <RobotAPI/libraries/armem/core/error.h>
-#include <RobotAPI/libraries/armem/core/ice_conversions.h>
+#include <RobotAPI/libraries/armem/core/workingMemory/ice_conversions.h>
 
 
 namespace armarx::armem::query_proc
@@ -36,7 +36,7 @@ namespace armarx::armem::query_proc
     void ProviderSegmentQueryProcessor::process(workingmemory::ProviderSegment& result,
             const armem::query::data::provider::All& query, const workingmemory::ProviderSegment& providerSegment) const
     {
-        for (const auto& [name, entity] : providerSegment.entities)
+        for (const auto& [name, entity] : providerSegment.entities())
         {
             result.addEntity(entityProcessor.process(query.entityQueries, entity));
         }
@@ -60,7 +60,7 @@ namespace armarx::armem::query_proc
             const armem::query::data::provider::Regex& query, const workingmemory::ProviderSegment& providerSegment) const
     {
         std::regex regex(query.entityNameRegex);
-        for (const auto& [name, entity] : providerSegment.entities)
+        for (const auto& [name, entity] : providerSegment.entities())
         {
             if (std::regex_search(entity.name(), regex))
             {
diff --git a/source/RobotAPI/libraries/armem/test/ArMemIceConversionsTest.cpp b/source/RobotAPI/libraries/armem/test/ArMemIceConversionsTest.cpp
index e139931d828f69494299b69fb4bd87677fd40465..171e406140dfdf549a90014e52fbe15d9f24b1d4 100644
--- a/source/RobotAPI/libraries/armem/test/ArMemIceConversionsTest.cpp
+++ b/source/RobotAPI/libraries/armem/test/ArMemIceConversionsTest.cpp
@@ -25,7 +25,10 @@
 #define ARMARX_BOOST_TEST
 
 #include <RobotAPI/Test.h>
+#include "../core/ice_conversions_templates.h"
 #include "../core/ice_conversions.h"
+#include "../core/workingMemory/ice_conversions.h"
+
 
 #include <iostream>
 #include <SimoxUtility/algorithm/get_map_keys_values.h>
@@ -37,11 +40,11 @@ namespace aron = armarx::aron;
 
 BOOST_AUTO_TEST_CASE(test_entity)
 {
-    armem::Entity entity("entity");
+    armem::workingmemory::Entity entity("entity");
 
     std::vector<armem::Time> expectedTimestamps;
 
-    armem::EntitySnapshot snapshot;
+    armem::workingmemory::EntitySnapshot snapshot;
     snapshot.time() = armem::Time::milliSeconds(100);
     expectedTimestamps.push_back(snapshot.time());
     entity.addSnapshot(snapshot);
@@ -53,13 +56,19 @@ BOOST_AUTO_TEST_CASE(test_entity)
     armem::data::EntityPtr ice;
     armem::toIce(ice, entity);
 
-    armem::Entity entityOut;
+    BOOST_CHECK_EQUAL(ice->id.memoryName, entity.id.memoryName);
+    BOOST_CHECK_EQUAL(ice->id.coreSegmentName, entity.id.coreSegmentName);
+    BOOST_CHECK_EQUAL(ice->id.providerSegmentName, entity.id.providerSegmentName);
+    BOOST_CHECK_EQUAL(ice->id.entityName, entity.id.entityName);
+
+    BOOST_CHECK_EQUAL(ice->history.size(), entity.history().size());
+
+    armem::workingmemory::Entity entityOut;
     armem::fromIce(ice, entityOut);
 
-    BOOST_CHECK_EQUAL(entityOut.history.size(), entity.history.size());
+    BOOST_CHECK_EQUAL(entityOut.history().size(), entity.history().size());
 
     std::vector<armem::Time> timestamps = entityOut.getTimestamps();
-    BOOST_CHECK_EQUAL_COLLECTIONS(timestamps.begin(), timestamps.end(),
-                                  expectedTimestamps.begin(), expectedTimestamps.end());
+    BOOST_CHECK_EQUAL_COLLECTIONS(timestamps.begin(), timestamps.end(), expectedTimestamps.begin(), expectedTimestamps.end());
 }
 
diff --git a/source/RobotAPI/libraries/armem/test/ArMemLTMTest.cpp b/source/RobotAPI/libraries/armem/test/ArMemLTMTest.cpp
index 1cc71d15c66995f519e5ba8e1b2ac372aeed3443..1370c064933f1b92dcf4c1bd908744f7a83e16b1 100644
--- a/source/RobotAPI/libraries/armem/test/ArMemLTMTest.cpp
+++ b/source/RobotAPI/libraries/armem/test/ArMemLTMTest.cpp
@@ -102,8 +102,8 @@ namespace ArMemLTMTest
             BOOST_CHECK_EQUAL(providerSegment.name(), "TestProvider");
             BOOST_CHECK(coreSegment.hasProviderSegment(providerSegment.name()));
 
-            coreSegment.aronType() = t1;
-            providerSegment.aronType() = t2;
+            //coreSegment.aronType() = t1;
+            //providerSegment.aronType() = t2;
 
             aron::typenavigator::ObjectNavigatorPtr t = t2 != nullptr ? t2 : t1;
 
@@ -122,7 +122,7 @@ namespace ArMemLTMTest
                 update.instancesData = q;
                 update.timeCreated = armem::Time::now();
                 BOOST_CHECK_NO_THROW(providerSegment.update(update));
-                BOOST_CHECK_EQUAL(providerSegment.entities.size(), 1);
+                BOOST_CHECK_EQUAL(providerSegment.entities().size(), 1);
             }
             BOOST_CHECK(providerSegment.hasEntity("TestEntity"));
 
diff --git a/source/RobotAPI/libraries/armem/test/ArMemMemoryTest.cpp b/source/RobotAPI/libraries/armem/test/ArMemMemoryTest.cpp
index 3d9588118e9463ed206a622a933fd8af23f1b1d3..11bb8af097d827a75ca7edcd40793166fddbe338 100644
--- a/source/RobotAPI/libraries/armem/test/ArMemMemoryTest.cpp
+++ b/source/RobotAPI/libraries/armem/test/ArMemMemoryTest.cpp
@@ -119,17 +119,17 @@ BOOST_AUTO_TEST_CASE(test_segment_setup)
     update.timeCreated = armem::Time::milliSeconds(1000);
     BOOST_CHECK_NO_THROW(providerSegment.update(update));
 
-    BOOST_CHECK_EQUAL(providerSegment.entities.size(), 1);
+    BOOST_CHECK_EQUAL(providerSegment.entities().size(), 1);
     BOOST_CHECK(providerSegment.hasEntity("image"));
     BOOST_CHECK(!providerSegment.hasEntity("other_image"));
 
     armem::workingmemory::Entity& entity = providerSegment.getEntity("image");
     BOOST_CHECK_EQUAL(entity.name(), "image");
-    BOOST_CHECK_EQUAL(entity.history.size(), 1);
-    BOOST_CHECK_EQUAL(entity.history.count(update.timeCreated), 1);
+    BOOST_CHECK_EQUAL(entity.history().size(), 1);
+    BOOST_CHECK_EQUAL(entity.history().count(update.timeCreated), 1);
 
-    armem::workingmemory::EntitySnapshot& entitySnapshot = entity.history.at(update.timeCreated);
-    BOOST_CHECK_EQUAL(entitySnapshot.instances.size(), update.instancesData.size());
+    armem::workingmemory::EntitySnapshot& entitySnapshot = entity.history().at(update.timeCreated);
+    BOOST_CHECK_EQUAL(entitySnapshot.instances().size(), update.instancesData.size());
 
 
     // Another update (on memory).
@@ -137,16 +137,16 @@ BOOST_AUTO_TEST_CASE(test_segment_setup)
     update.instancesData = { std::make_shared<aron::datanavigator::DictNavigator>() };
     update.timeCreated = armem::Time::milliSeconds(2000);
     memory.update(update);
-    BOOST_CHECK_EQUAL(entity.history.size(), 2);
-    BOOST_CHECK_EQUAL(entity.history.count(update.timeCreated), 1);
-    BOOST_CHECK_EQUAL(entity.history.at(update.timeCreated).instances.size(), update.instancesData.size());
+    BOOST_CHECK_EQUAL(entity.history().size(), 2);
+    BOOST_CHECK_EQUAL(entity.history().count(update.timeCreated), 1);
+    BOOST_CHECK_EQUAL(entity.history().at(update.timeCreated).instances().size(), update.instancesData.size());
 
 
     // A third update (on entity).
     update.instancesData = { std::make_shared<aron::datanavigator::DictNavigator>() };
     update.timeCreated = armem::Time::milliSeconds(3000);
     entity.update(update);
-    BOOST_CHECK_EQUAL(entity.history.size(), 3);
+    BOOST_CHECK_EQUAL(entity.history().size(), 3);
 
 }
 
@@ -166,32 +166,32 @@ BOOST_AUTO_TEST_CASE(test_history_size_in_entity)
     entity.update(update);
     update.timeCreated = armem::Time::milliSeconds(3000);
     entity.update(update);
-    BOOST_CHECK_EQUAL(entity.history.size(), 3);
+    BOOST_CHECK_EQUAL(entity.history().size(), 3);
 
     // Now with maximum history size.
     entity.setMaxHistorySize(2);
-    BOOST_CHECK_EQUAL(entity.history.size(), 2);
-    BOOST_CHECK_EQUAL(entity.history.count(armem::Time::milliSeconds(1000)), 0);
-    BOOST_CHECK_EQUAL(entity.history.count(armem::Time::milliSeconds(2000)), 1);
-    BOOST_CHECK_EQUAL(entity.history.count(armem::Time::milliSeconds(3000)), 1);
+    BOOST_CHECK_EQUAL(entity.history().size(), 2);
+    BOOST_CHECK_EQUAL(entity.history().count(armem::Time::milliSeconds(1000)), 0);
+    BOOST_CHECK_EQUAL(entity.history().count(armem::Time::milliSeconds(2000)), 1);
+    BOOST_CHECK_EQUAL(entity.history().count(armem::Time::milliSeconds(3000)), 1);
 
 
     update.timeCreated = armem::Time::milliSeconds(4000);
     entity.update(update);
-    BOOST_CHECK_EQUAL(entity.history.size(), 2);
-    BOOST_CHECK_EQUAL(entity.history.count(armem::Time::milliSeconds(2000)), 0);
-    BOOST_CHECK_EQUAL(entity.history.count(armem::Time::milliSeconds(3000)), 1);
-    BOOST_CHECK_EQUAL(entity.history.count(armem::Time::milliSeconds(4000)), 1);
+    BOOST_CHECK_EQUAL(entity.history().size(), 2);
+    BOOST_CHECK_EQUAL(entity.history().count(armem::Time::milliSeconds(2000)), 0);
+    BOOST_CHECK_EQUAL(entity.history().count(armem::Time::milliSeconds(3000)), 1);
+    BOOST_CHECK_EQUAL(entity.history().count(armem::Time::milliSeconds(4000)), 1);
 
     // Disable maximum history size.
     entity.setMaxHistorySize(-1);
 
     update.timeCreated = armem::Time::milliSeconds(5000);
     entity.update(update);
-    BOOST_CHECK_EQUAL(entity.history.size(), 3);
-    BOOST_CHECK_EQUAL(entity.history.count(armem::Time::milliSeconds(3000)), 1);
-    BOOST_CHECK_EQUAL(entity.history.count(armem::Time::milliSeconds(4000)), 1);
-    BOOST_CHECK_EQUAL(entity.history.count(armem::Time::milliSeconds(5000)), 1);
+    BOOST_CHECK_EQUAL(entity.history().size(), 3);
+    BOOST_CHECK_EQUAL(entity.history().count(armem::Time::milliSeconds(3000)), 1);
+    BOOST_CHECK_EQUAL(entity.history().count(armem::Time::milliSeconds(4000)), 1);
+    BOOST_CHECK_EQUAL(entity.history().count(armem::Time::milliSeconds(5000)), 1);
 }
 
 
@@ -220,22 +220,22 @@ BOOST_AUTO_TEST_CASE(test_history_size_in_provider_segment)
     update.timeCreated = armem::Time::milliSeconds(4000);
     providerSegment.update(update);
 
-    BOOST_CHECK_EQUAL(providerSegment.getEntity("A").history.size(), 3);
-    BOOST_CHECK_EQUAL(providerSegment.getEntity("B").history.size(), 4);
+    BOOST_CHECK_EQUAL(providerSegment.getEntity("A").history().size(), 3);
+    BOOST_CHECK_EQUAL(providerSegment.getEntity("B").history().size(), 4);
 
 
     // Employ maximum history size.
     providerSegment.setMaxHistorySize(3);
-    BOOST_CHECK_EQUAL(providerSegment.getEntity("A").history.size(), 3);
-    BOOST_CHECK_EQUAL(providerSegment.getEntity("B").history.size(), 3);
+    BOOST_CHECK_EQUAL(providerSegment.getEntity("A").history().size(), 3);
+    BOOST_CHECK_EQUAL(providerSegment.getEntity("B").history().size(), 3);
 
     providerSegment.setMaxHistorySize(2);
-    BOOST_CHECK_EQUAL(providerSegment.getEntity("A").history.size(), 2);
-    BOOST_CHECK_EQUAL(providerSegment.getEntity("B").history.size(), 2);
+    BOOST_CHECK_EQUAL(providerSegment.getEntity("A").history().size(), 2);
+    BOOST_CHECK_EQUAL(providerSegment.getEntity("B").history().size(), 2);
 
     providerSegment.setMaxHistorySize(3);
-    BOOST_CHECK_EQUAL(providerSegment.getEntity("A").history.size(), 2);
-    BOOST_CHECK_EQUAL(providerSegment.getEntity("B").history.size(), 2);
+    BOOST_CHECK_EQUAL(providerSegment.getEntity("A").history().size(), 2);
+    BOOST_CHECK_EQUAL(providerSegment.getEntity("B").history().size(), 2);
 
     // Add new entity.
     providerSegment.setMaxHistorySize(2);
@@ -251,7 +251,7 @@ BOOST_AUTO_TEST_CASE(test_history_size_in_provider_segment)
     // Check correctly inherited history size.
     BOOST_CHECK_EQUAL(providerSegment.getEntity("C").maxHistorySize, 2);
     // Check actual history size.
-    BOOST_CHECK_EQUAL(providerSegment.getEntity("C").history.size(), 2);
+    BOOST_CHECK_EQUAL(providerSegment.getEntity("C").history().size(), 2);
 
     // Remove maximum.
     providerSegment.setMaxHistorySize(-1);
@@ -262,6 +262,6 @@ BOOST_AUTO_TEST_CASE(test_history_size_in_provider_segment)
         update.entityID.entityName = name;
         update.timeCreated = armem::Time::milliSeconds(5000);
         providerSegment.update(update);
-        BOOST_CHECK_EQUAL(providerSegment.getEntity(name).history.size(), 3);
+        BOOST_CHECK_EQUAL(providerSegment.getEntity(name).history().size(), 3);
     }
 }
diff --git a/source/RobotAPI/libraries/armem/test/ArMemQueryBuilderTest.cpp b/source/RobotAPI/libraries/armem/test/ArMemQueryBuilderTest.cpp
index 5b9a09f097cc55f3e8343b55c58d0aa09109e890..c9dea813f684129b6ff6893b1774fa3b3a0d809a 100644
--- a/source/RobotAPI/libraries/armem/test/ArMemQueryBuilderTest.cpp
+++ b/source/RobotAPI/libraries/armem/test/ArMemQueryBuilderTest.cpp
@@ -27,7 +27,7 @@
 #include <RobotAPI/Test.h>
 #include "../client/query/Builder.h"
 #include "../client/query/query_fns.h"
-#include "../core/ice_conversions.h"
+#include "../core/workingMemory/ice_conversions.h"
 
 #include <iostream>
 
diff --git a/source/RobotAPI/libraries/armem/test/ArMemQueryTest.cpp b/source/RobotAPI/libraries/armem/test/ArMemQueryTest.cpp
index 5c51491af0c1fed64b4202c51f7b9a5d2e7a56fd..51227ab817c1ccfd842f13de7b265c93d36c5abe 100644
--- a/source/RobotAPI/libraries/armem/test/ArMemQueryTest.cpp
+++ b/source/RobotAPI/libraries/armem/test/ArMemQueryTest.cpp
@@ -123,8 +123,8 @@ BOOST_AUTO_TEST_CASE(test_entity_Single_latest)
     {
         BOOST_CHECK_EQUAL(result.name(), entity.name());
         BOOST_CHECK_EQUAL(result.size(), 1);
-        BOOST_CHECK_EQUAL(result.history.begin()->second.time(), entity.getLatestSnapshot().time());
-        BOOST_CHECK_NE(&result.history.begin()->second, &entity.history.rbegin()->second);
+        BOOST_CHECK_EQUAL(result.history().begin()->second.time(), entity.getLatestSnapshot().time());
+        BOOST_CHECK_NE(&result.history().begin()->second, &entity.history().rbegin()->second);
     }
 }
 
@@ -138,7 +138,7 @@ BOOST_AUTO_TEST_CASE(test_entity_Single_existing)
     {
         BOOST_CHECK_EQUAL(result.name(), entity.name());
         BOOST_CHECK_EQUAL(result.size(), 1);
-        BOOST_CHECK_EQUAL(result.history.begin()->second.time(), armem::Time::microSeconds(3000));
+        BOOST_CHECK_EQUAL(result.history().begin()->second.time(), armem::Time::microSeconds(3000));
     }
 }
 
@@ -165,8 +165,8 @@ BOOST_AUTO_TEST_CASE(test_entity_All)
     {
         BOOST_CHECK_EQUAL(result.name(), entity.name());
         BOOST_CHECK_EQUAL(result.size(), entity.size());
-        auto jt = entity.history.begin();
-        for (auto it = result.history.begin(); it != result.history.end(); ++it, ++jt)
+        auto jt = entity.history().begin();
+        for (auto it = result.history().begin(); it != result.history().end(); ++it, ++jt)
         {
             BOOST_CHECK_EQUAL(it->first, jt->first);
             BOOST_CHECK_EQUAL(it->second.time(), jt->second.time());
@@ -188,7 +188,7 @@ BOOST_AUTO_TEST_CASE(test_entity_TimeRange_slice)
 
         BOOST_CHECK_EQUAL(result.size(), 2);
 
-        std::vector<armem::Time> times = simox::alg::get_keys(result.history);
+        std::vector<armem::Time> times = simox::alg::get_keys(result.history());
         std::vector<armem::Time> expected
         {
             armem::Time::microSeconds(2000), armem::Time::microSeconds(3000)
@@ -209,7 +209,7 @@ BOOST_AUTO_TEST_CASE(test_entity_TimeRange_exact)
 
         BOOST_CHECK_EQUAL(result.size(), 3);
 
-        std::vector<armem::Time> times = simox::alg::get_keys(result.history);
+        std::vector<armem::Time> times = simox::alg::get_keys(result.history());
         std::vector<armem::Time> expected
         {
             armem::Time::microSeconds(2000), armem::Time::microSeconds(3000), armem::Time::microSeconds(4000)
@@ -230,8 +230,8 @@ BOOST_AUTO_TEST_CASE(test_entity_TimeRange_all)
 
         BOOST_CHECK_EQUAL(result.size(), entity.size());
 
-        std::vector<armem::Time> times = simox::alg::get_keys(result.history);
-        std::vector<armem::Time> expected = simox::alg::get_keys(entity.history);
+        std::vector<armem::Time> times = simox::alg::get_keys(result.history());
+        std::vector<armem::Time> expected = simox::alg::get_keys(entity.history());
         BOOST_CHECK_EQUAL_COLLECTIONS(times.begin(), times.end(), expected.begin(), expected.end());
     }
 }
@@ -263,7 +263,7 @@ BOOST_AUTO_TEST_CASE(test_entity_TimeRange_from_start)
 
         BOOST_CHECK_EQUAL(result.size(), 2);
 
-        std::vector<armem::Time> times = simox::alg::get_keys(result.history);
+        std::vector<armem::Time> times = simox::alg::get_keys(result.history());
         std::vector<armem::Time> expected
         {
             armem::Time::microSeconds(1000), armem::Time::microSeconds(2000)
@@ -284,7 +284,7 @@ BOOST_AUTO_TEST_CASE(test_entity_TimeRange_to_end)
 
         BOOST_CHECK_EQUAL(result.size(), 3);
 
-        std::vector<armem::Time> times = simox::alg::get_keys(result.history);
+        std::vector<armem::Time> times = simox::alg::get_keys(result.history());
         std::vector<armem::Time> expected
         {
             armem::Time::microSeconds(3000), armem::Time::microSeconds(4000), armem::Time::microSeconds(5000)
@@ -338,8 +338,8 @@ BOOST_AUTO_TEST_CASE(test_entity_IndexRange_all_default)
 
         BOOST_CHECK_EQUAL(result.size(), entity.size());
 
-        std::vector<armem::Time> times = simox::alg::get_keys(result.history);
-        std::vector<armem::Time> expected = simox::alg::get_keys(entity.history);
+        std::vector<armem::Time> times = simox::alg::get_keys(result.history());
+        std::vector<armem::Time> expected = simox::alg::get_keys(entity.history());
         BOOST_CHECK_EQUAL_COLLECTIONS(times.begin(), times.end(), expected.begin(), expected.end());
     }
 
@@ -361,7 +361,7 @@ BOOST_AUTO_TEST_CASE(test_entity_IndexRange_slice)
 
         BOOST_CHECK_EQUAL(result.size(), 3);
 
-        std::vector<armem::Time> times = simox::alg::get_keys(result.history);
+        std::vector<armem::Time> times = simox::alg::get_keys(result.history());
         std::vector<armem::Time> expected
         {
             armem::Time::microSeconds(2000), armem::Time::microSeconds(3000), armem::Time::microSeconds(4000)
diff --git a/source/RobotAPI/libraries/armem/util/util.h b/source/RobotAPI/libraries/armem/util/util.h
index e295131c2fa27ad558e88d11ff0410d7f61f99aa..675ac16e4ce275919b6cf47eef43386686fd88b4 100644
--- a/source/RobotAPI/libraries/armem/util/util.h
+++ b/source/RobotAPI/libraries/armem/util/util.h
@@ -77,9 +77,9 @@ namespace armarx::armem
         // loop over all entities and their snapshots
         for (const auto &[s, entity] : entities)
         {
-            for (const auto &[ss, entitySnapshot] : entity.history)
+            for (const auto &[ss, entitySnapshot] : entity.history())
             {
-                for (const auto& entityInstance : entitySnapshot.instances)
+                for (const auto& entityInstance : entitySnapshot.instances())
                 {
                     const auto o = tryCast<AronClass>(entityInstance);
 
@@ -129,16 +129,16 @@ namespace armarx::armem
         // loop over all entities and their snapshots
         for (const auto &[s, entity] : entities)
         {
-            if (entity.history.empty())
+            if (entity.history().empty())
             {
                 ARMARX_WARNING << "Empty history for " << s;
             }
 
-            ARMARX_INFO << "History size: " << entity.history.size();
+            ARMARX_INFO << "History size: " << entity.history().size();
 
-            for (const auto &[ss, entitySnapshot] : entity.history)
+            for (const auto &[ss, entitySnapshot] : entity.history())
             {
-                for (const auto& entityInstance : entitySnapshot.instances)
+                for (const auto& entityInstance : entitySnapshot.instances())
                 {
                     const auto o = tryCast<AronClass>(entityInstance);
 
diff --git a/source/RobotAPI/libraries/armem_gui/memory/TreeWidget.cpp b/source/RobotAPI/libraries/armem_gui/memory/TreeWidget.cpp
index 1da781d097d7af7bda4d595c1c66cb18145cb872..cb3dc4671b74bc2a5d2dc31217b98f2dd5aec99f 100644
--- a/source/RobotAPI/libraries/armem_gui/memory/TreeWidget.cpp
+++ b/source/RobotAPI/libraries/armem_gui/memory/TreeWidget.cpp
@@ -225,27 +225,27 @@ namespace armarx::armem::gui::memory
 
     void TreeWidget::updateChildren(const armem::workingmemory::Memory& memory, QTreeWidgetItem* memoryItem)
     {
-        workingmemoryCoreSegmentBuilder.updateTree(memoryItem, memory.coreSegments);
+        workingmemoryCoreSegmentBuilder.updateTree(memoryItem, memory.coreSegments());
     }
 
     void TreeWidget::updateChildren(const armem::workingmemory::CoreSegment& coreSeg, QTreeWidgetItem* coreSegItem)
     {
-        workingmemoryProvSegmentBuilder.updateTree(coreSegItem, coreSeg.providerSegments);
+        workingmemoryProvSegmentBuilder.updateTree(coreSegItem, coreSeg.providerSegments());
     }
 
     void TreeWidget::updateChildren(const armem::workingmemory::ProviderSegment& provSeg, QTreeWidgetItem* provSegItem)
     {
-        workingmemoryEntityBuilder.updateTree(provSegItem, provSeg.entities);
+        workingmemoryEntityBuilder.updateTree(provSegItem, provSeg.entities());
     }
 
     void TreeWidget::updateChildren(const armem::workingmemory::Entity& entity, QTreeWidgetItem* entityItem)
     {
-        workingmemorySnapshotBuilder.updateTree(entityItem, entity.history);
+        workingmemorySnapshotBuilder.updateTree(entityItem, entity.history());
     }
 
     void TreeWidget::updateChildren(const armem::workingmemory::EntitySnapshot& snapshot, QTreeWidgetItem* snapshotItem)
     {
-        workingmemoryInstanceBuilder.updateTree(snapshotItem, snapshot.instances);
+        workingmemoryInstanceBuilder.updateTree(snapshotItem, snapshot.instances());
     }
 
     void TreeWidget::updateChildren(const armem::workingmemory::EntityInstance& data, QTreeWidgetItem* dataItem)
diff --git a/source/RobotAPI/libraries/armem_robot_localization/TransformReader.cpp b/source/RobotAPI/libraries/armem_robot_localization/TransformReader.cpp
index 12d56558e3a27cadd6babc3f0afef6d4aff0ee70..89f85100f6e3b51007500a40cc13e024615e7639 100644
--- a/source/RobotAPI/libraries/armem_robot_localization/TransformReader.cpp
+++ b/source/RobotAPI/libraries/armem_robot_localization/TransformReader.cpp
@@ -128,7 +128,7 @@ namespace armarx::armem
 
     // }
 
-    std::vector<std::string> TransformReader::buildTransformChain(const armem::Memory& memory,
+    std::vector<std::string> TransformReader::buildTransformChain(const armem::workingmemory::Memory& memory,
             const TransformQuery& query) const
     {
         ARMARX_DEBUG << "Building transform chain";
@@ -202,7 +202,7 @@ namespace armarx::armem
         return chain;
     }
 
-    inline Transform convertEntityToTransform(const armem::EntityInstance& item)
+    inline Transform convertEntityToTransform(const armem::workingmemory::EntityInstance& item)
     {
         aron::Transform aronTransform;
         aronTransform.fromAron(item.data());
@@ -271,14 +271,14 @@ namespace armarx::armem
         return simox::math::interpolatePose(posePreIt->transform, poseNextIt->transform, t);
     }
 
-    Eigen::Affine3f TransformReader::obtainTransform(const std::string& entityName, const armem::ProviderSegment& agentProviderSegment, const int64_t timestamp) const
+    Eigen::Affine3f TransformReader::obtainTransform(const std::string& entityName, const armem::workingmemory::ProviderSegment& agentProviderSegment, const int64_t timestamp) const
     {
 
         ARMARX_DEBUG << "getEntity:" + entityName;
         const auto& entity = agentProviderSegment.getEntity(entityName);
 
-        ARMARX_DEBUG << "History (size: " << entity.history.size() << ")"
-                     << simox::alg::get_keys(entity.history);
+        ARMARX_DEBUG << "History (size: " << entity.history().size() << ")"
+                     << simox::alg::get_keys(entity.history());
 
         // if (entity.history.empty())
         // {
@@ -289,9 +289,9 @@ namespace armarx::armem
 
 
         std::vector<Transform> transforms;
-        transforms.reserve(entity.history.size());
+        transforms.reserve(entity.history().size());
 
-        const auto entitySnapshots = simox::alg::get_values(entity.history);
+        const auto entitySnapshots = simox::alg::get_values(entity.history());
         std::transform(entitySnapshots.begin(),
                        entitySnapshots.end(),
                        std::back_inserter(transforms),
@@ -329,13 +329,13 @@ namespace armarx::armem
     }
 
     std::vector<Eigen::Affine3f>
-    TransformReader::obtainTransforms(const armem::Memory& memory,
+    TransformReader::obtainTransforms(const armem::workingmemory::Memory& memory,
                                       const std::vector<std::string>& tfChain,
                                       const std::string& agent,
                                       const std::int64_t& timestamp) const
     {
 
-        ARMARX_DEBUG << "Core segments" << simox::alg::get_keys(memory.coreSegments);
+        ARMARX_DEBUG << "Core segments" << simox::alg::get_keys(memory.coreSegments());
 
         const auto& agentProviderSegment =
             memory.getCoreSegment(properties.localizationMemoryName).getProviderSegment(agent);
@@ -343,9 +343,9 @@ namespace armarx::armem
         ARMARX_DEBUG << "Provider segments"
                      << simox::alg::get_keys(
                          memory.getCoreSegment(properties.localizationMemoryName)
-                         .providerSegments);
+                         .providerSegments());
 
-        ARMARX_DEBUG << "Entities: " << simox::alg::get_keys(agentProviderSegment.entities);
+        ARMARX_DEBUG << "Entities: " << simox::alg::get_keys(agentProviderSegment.entities());
 
         try
         {
diff --git a/source/RobotAPI/libraries/armem_robot_mapping/MappingDataReader.cpp b/source/RobotAPI/libraries/armem_robot_mapping/MappingDataReader.cpp
index 6f57909c671fb2c5766c487b1ac5c5744e944fc0..f5577f9abf2c34e596cd47e28593f2ab7c8645a2 100644
--- a/source/RobotAPI/libraries/armem_robot_mapping/MappingDataReader.cpp
+++ b/source/RobotAPI/libraries/armem_robot_mapping/MappingDataReader.cpp
@@ -8,8 +8,6 @@
 
 #include <ArmarXCore/core/logging/Logging.h>
 
-#include <RobotAPI/libraries/armem/core/EntityInstance.h>
-#include <RobotAPI/libraries/armem/core/EntitySnapshot.h>
 #include <RobotAPI/libraries/armem/util/util.h>
 #include <RobotAPI/libraries/armem_robot_mapping/aron/LaserScan.aron.generated.h>
 #include <RobotAPI/libraries/armem_robot_mapping/aron_conversions.h>
@@ -120,7 +118,7 @@ namespace armarx::armem
         const auto& entities =
             qResult.memory.getCoreSegment(properties.mappingMemoryName)
             .getProviderSegment(query.agent)
-            .entities;
+            .entities();
 
         auto laserScans = transformAllOfType<aron::LaserScanStamped>(
                               entities,