Help for this page

Select Code to Download


  1. or download this
    use My::Translator;
    
    my $trans = My::Translator->new(Config => 'config.txt');
    my ($ret, $conf) = $trans->translate("abc xyz");
    print "output is '$ret' with confidence $conf %\n";
    
  2. or download this
    use My::Translator;
    my $conf = Config::Tiny...
    my $prep = My::Translator::prepare_with_some_transformations("abc xyz"
    +);
    my ($ret, $conf) = My::Translator::translate($prep, $conf);
    print "output is '$ret' (via $prep) with confidence $conf %\n";