--------------020002050208070100090908
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

Here's my solution. Note that I hadn't enough time to comment it, and 
the implementation isn't as understandable as I'd like.

Only to test whether it's possible, I chose irb for the user interface. 
After loading the file, you can enter facts and queries in plain text:

   irb(main):001:0> require "ie"
   true
   irb(main):002:0> all mammals are hairy animals
   OK.
   irb(main):003:0> all dogs are mammals
   OK.
   irb(main):004:0> are all dogs hairy animals?
   Yes, all dogs are hairy animals.
   irb(main):005:0> describe dogs
   All dogs are hairy animals.
      All dogs are mammals.
   irb(main):006:0>

If you want to try it, note that you aren't allowed to enter dots (".") 
after facts and that you have to enter question marks ("?") after queries.

Regards,
Pit

--------------020002050208070100090908
Content-Type: application/x-zip-compressed;
 namee.zip"
Content-Transfer-Encoding: base64
Content-Disposition: inline;
 filenamee.zip"

UEsDBBQAAAAIALCz5TKR8s7HyQUAALkVAAAFAAAAaWUucmKlWG1PIzcQ/s6v8C3omqDV0oRv
J1JoJT6gVod0qJUqoNGS9SZ7bOzUdsqlJP+9M35Z25tsyFFQiNcz88yM57F3zNGcF8uakptr
Qr8pygoiaV0eHRHy5fffru/IiLzCmJB7kqiyTMgjGf0EQ6WStJlXfr4M50E/jc30DIhKpUWl
t9QzbcsAWFlLtWWpIksMbDvUwCc+785CtX2WKvIZWJbWcoMLdcXyOZUpuZJUSVywTQoflBS0
JJQpKsZ5XfcI6g1S/TUkfe1YSxtJgg61GFPUeSZaEeoS4zH+vXBqH5zkc/ouQLUHEIJU70q6
A7SxWHA5aEzgAf7+k9cWfJJLChxWh2m/zCgjSiypfiIkuf01S7ykzGvZiO64EKuUqFmuyIQz
JfKimkDFX3DihuS1oHmxIs+Mv4QYrKodwk0oxPSiJP9eUrHqZIqW7lm0zxwmuIIwanzEz5/I
SnxuL6fx1MGhPY6Uc4Tljbww3uEkZ6t3edGooRuTX7eXTra9tXCRJ3RhnXUu3D5mIZXGcznF
WM23phAOQ35O9/EzpCaE68hz/OrAN+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