The PTQ package

[Tags: lgpl, program]

An implementation of Montague's PTQ (Proper Treatment of Quantification). It translates simple plain English sentences into formulas of intentional logic.


[Skip to ReadMe]

Properties

Versions0.0.4, 0.0.5, 0.0.6, 0.0.7
Change logNone available
Dependenciesbase (==4.*), containers, haskell98, mtl, network, utf8-string, xml [details]
LicenseLGPL
AuthorMasahiro Sakai
MaintainerMasahiro Sakai <masahiro.sakai AT gmail.com>
Stabilityexperimental
CategoryNatural Language Processing
Home pagehttp://www.tom.sfc.keio.ac.jp/~sakai/hiki/?hsPTQ
Executablesptq.cgi, ptq
UploadedMon Nov 16 15:36:41 UTC 2009 by MasahiroSakai
DistributionsNixOS:0.0.7
Downloads723 total (44 in last 30 days)
Votes
0 []
StatusDocs not available [build log]
All reported builds failed as of 2015-05-22 [all 2 reports]

Flags

NameDescriptionDefaultType
utf8terminalUse UTF-8 for terminal I/ODisabledAutomatic
utf8cgiUse UTF-8 for HTTP contentsEnabledAutomatic

Use -f <flag> to enable a flag, or -f -<flag> to disable that flag. More info

Downloads

Maintainers' corner

For package maintainers and hackage trustees

Readme for PTQ-0.0.5

= An implementation of Montague's PTQ in Haskell

== Build and Install

You'll need GHC 6.7 or later.

  % runhaskell Setup.lhs configure
  % runhaskell Setup.lhs build
  % runhaskell Setup.lhs install

== Usage of interactive shell ptq

  % ptq
  PTQ> John seeks a unicorn.
  Parsed:
    F4 john (F5 seek (F2 a unicorn))
  
  Translation:
    (\x0. x0 {john}) (Int (seek (Int ((\x0. \x1. exists x2. x0 {x2} && x1 {x2}) (Int unicorn)))))
  
  Translation (simplified):
    seek (Int (\x0. exists x1. unicorn x1 && x0 {x1})) john
  
  ------------------------------------------------------
  
  Parsed:
    F10 0 (F2 a unicorn) (F4 john (F5 seek (He 0)))
  
  Translation:
    (\x0. \x1. exists x2. x0 {x2} && x1 {x2}) (Int unicorn) (Int (\x0. (\x1. x1 {john}) (Int (seek (Int (\x1. x1 {x0}))))))
  
  Translation (simplified):
    exists x0. unicorn x0 && seek (Int (\x1. x1 {x0})) john
  PTQ> quit
  %

== CGI interface

By locating ptq.cgi, cgi/index.html and cgi/main.html to the place
where CGI is executable, you can try it on the web.
Demo site runs at <http://www.tom.sfc.keio.ac.jp/~sakai/hsPTQ/>.