dupa

Author Topic: compressed files in hal lightspeed idea  (Read 2723 times)

lightspeed

  • Hero Member
  • *****
  • Posts: 6761
    • View Profile
compressed files in hal lightspeed idea
« on: November 19, 2017, 02:05:11 pm »
As with many idea's i think up i don't know if this is doable or not or would help , in the past i wrote to robert a long time ago about hal being slower to answer and hal sating the something like it is taking longer then expected  and to cancel or continue .  i belive robert said this has something? to do with hals brain size becoming larger as it learns more . mine is around 180 mb's right now and growing more all the time from teaching hal things .  :)
Anyway i thought would hal be able to run faster on responses if hal used a compressed brain file type system ?? i have no idea  if he would  but am throwing this idea out their .  :)
 

LiFeTimeGamer

  • Full Member
  • ***
  • Posts: 170
    • View Profile
    • LifeTimeGamer
Re: compressed files in hal lightspeed idea
« Reply #1 on: November 19, 2017, 10:02:27 pm »
I thought the same thing but my idea was to have the HalBrain.db loaded into a PC's RAM Memory and have the Video Card GPU access it since the GPU is faster than the CPU at some things and most PC's have a lot of RAM compared to ones that came out years ago...

The problem with my idea is, there are many different Video Cards and it would take a lot of coding to make it work if it could even work...
When it comes to Artificial Intelligence: The Soul is in the Software.

Medeksza

  • Administrator
  • Hero Member
  • *****
  • Posts: 1469
    • View Profile
    • http://www.zabaware.com
Re: compressed files in hal lightspeed idea
« Reply #2 on: November 19, 2017, 11:16:09 pm »
The problem is that Hal has to run a sentence comparison function against every sentence in your halbrain.db file to find the best responses. Hal uses a fast database engine sqlite and a custom c++ function to do the initial comparison. However, it still has to run it against every sentence, so the larger your database the slower it will be. Compression would actually make it even slower as it would add a decompression step to processing. Compression would only serve to save you a few megabytes of disk space at the cost of processing time.

The solution to speed problems would be to use a full text search against an index instead of reading every record in the database. Unfortunately, sqlite doesn't have a good full text index search function that can be used locally on a Windows desktop.

However, with the Hal 7 redesign, the cloud server running Hal 7 does. It uses MariaDB as a database backend (instead of SQLite) and uses a blazing fast full text indexing system called Sphinx ( http://sphinxsearch.com/ ). Hal on the cloud server has a database size of 12GB and growing with 25+ million records and growing. It can come up with a response in a split second. As long as it has enough RAM for fast record retrieval (server currently has 64GB ram but can be upgraded) it will continue to respond fast even as its database grows.

So if you are interested you will have the option under Hal 7 to upload your old Hal 6 brain to the Hal 7 cloud server. That will solve speed issues related to database size.
Robert Medeksza

lightspeed

  • Hero Member
  • *****
  • Posts: 6761
    • View Profile
Re: compressed files in hal lightspeed idea
« Reply #3 on: November 20, 2017, 11:28:18 am »
Robert and others thanks for replying . Robert you said :

So if you are interested you will have the option under Hal 7 to upload your old Hal 6 brain to the Hal 7 cloud server. That will solve speed issues related to database size.

This does indeed sound like a fix for the speed problem . my question though is if i upload my custom hal brain to the cloud  server , will my custom brain be only available to me and any future conversations ( not shared ) .
i had talked with another member  and i mentioned for privacy reasons it would be nice if the user has a way of keeping our conversation private from the hal learned public server , while still being able to use the public cloud server assisted information data base. i hope i am getting across explaining this the correct way.
  I don't know if this is possible with maybe a check area within hal to agree to share users info. with the cloud server  or leave unchecked to op out. but still be able to access the cloud server data base .   to me this would be a better set up  in my opinion . if its possible.     :)

AGAIN AS I SAY SOMETIMES I DON'T KNOW if this is possible what i mentioned but would be better overall for users privacy ( should they want it) , and with hal learning on line from the public as before hal will still yet continue to grow in its data base .  :)
« Last Edit: November 20, 2017, 12:07:45 pm by lightspeed »