GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  HAILO::STORAGE::SQLITE (3)

.ds Aq ’

NAME

Hailo::Storage::SQLite - A storage backend for Hailo using DBD::SQLite

CONTENTS

SYNOPSIS

As a module:



    my $hailo = Hailo->new(
        storage_class => SQLite,
    );
    $hailo->train("hailo.trn");



From the command line:



 hailo --train hailo.trn --storage SQLite



See Hailo’s documentation for other non-MySQL specific options.

DESCRIPTION

This backend maintains information in an SQLite database. It is the default storage backend.

ATTRIBUTES

CWstorage_args

This is a hash reference which can have the following keys:

pragma_*

Any option starting with <B>’pragma_’B> will be considered to be an SQLite pragma <http://www.sqlite.org/pragma.html> which will be set after we connect to the database. An example of this would be



    storage_args => {
        pragma_cache_size  => 10000,
        pragma_synchronous => OFF,
    }



Setting <B>’pragma_cache_size’B> in particular can be beneficial. It’s the size of the page cache used by SQLite. See SQLite’s documentation <http://www.sqlite.org/pragma.html#pragma_cache_size> for more information.

Increasing it might speed up Hailo, especially when disk IO is slow on your machine. Obviously, you shouldn’t bother with this option if <B>’in_memory’B> is enabled.

Setting <B>’pragma_synchronous’B> to <B>’OFFB> or <B>’pragma_journal_mode’B> to <B>’OFFB> will speed up operations at the expense of safety. Since Hailo is most likely not running as a mission-critical component this trade-off should be acceptable in most cases. If the database becomes corrupt it’s easy to rebuild it by retraining from the input it was trained on to begin with. For performance reasons, these two are set to <B>’OFFB> by default unless <B>’in_memory’B> is enabled.

in_memory

When set to a true value, Hailo behaves much like MegaHAL. The entire database will be kept in memory, and only written out to disk when the save method is called and/or when the Hailo object gets destroyed (unless you disabled save_on_exit). This is disabled by default.

AUTHOR

AEvar Arnfjoerd` Bjarmason <avar@cpan.org>

Hinrik Oern Sigurd`sson, hinrik.sig@gmail.com

LICENSE AND COPYRIGHT

Copyright 2010 AEvar Arnfjoerd` Bjarmason and Hinrik Oern Sigurd`sson

This program is free software, you can redistribute it and/or modify it under the same terms as Perl itself.

Search for    or go to Top of page |  Section 3 |  Main Index


perl v5.20.3 HAILO::STORAGE::SQLITE (3) 2011-09-18

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.