I am facing a major memory problem on a research project that I am working on right now. The project is designing a graphmaster for an Artificial Intelligent chatterbot. The AI bot requires
patterns to be loaded in memory for answering questions posed to it by users.
So for efficient pattern searching I used the B* Tree to hash patterns and store the answers to those patterns at those nodes.
Now comes the problem. The entire pattern database is around 25 MB. So I need to load the whole database in memory. However I am able to load only around 4 MB data. After that the JVM crashes complaining about insufficient memory. I tried to perform a lot of optimizations relating to the structure of the B* tree, but without success. Any idea what can be done in this particular scenario. Without loading those patterns in memory the AI bot cannot work..
Any help would be appreciated.
Thanks in advance