|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcsli.dialog.app.calo.parse.GeminiJasper
public class GeminiJasper
Provides a Java interface to Gemini through the SICStus Prolog Jasper API. The interface provides methods to parse sentences and Word Confusion Networks (WCN)). The primary methods are
| Nested Class Summary | |
|---|---|
class |
GeminiJasper.invokePrologThread
The class invokePrologThread is the sister thread to the invokeProlog method. |
class |
GeminiJasper.npThread
|
class |
GeminiJasper.parseThread
parseThread is a Thread that supports sending a parse command to Gemini. |
class |
GeminiJasper.parseWcnThread
parseWcnThread implements a Thread to ask Gemini to parse a Word Confusion Network. |
| Constructor Summary | |
|---|---|
GeminiJasper()
Constructor initializes the SICStus Prolog instance, and restores Gemini. |
|
GeminiJasper(String[] argv)
Constructor initializes the SICStus Prolog instance, and restores Gemini. |
|
| Method Summary | |
|---|---|
ArrayList<String> |
findNPs(String sN)
|
JPanel |
getGui()
Get a Swing JPanel which provides a GUI to this service. |
static GeminiJasper |
getInstance()
Get the single static instance. |
String |
getTitle()
Get the name of this service as it should appear in the GUI. |
void |
invokeProlog(String goal)
Each unique way to invoke Prolog to execute a query requires a class which extends Thread, and a method to invoke the thread. |
boolean |
isServiceAlive()
Is the service happy and alive? |
static void |
main(String[] args)
|
ArrayList<LFTerm> |
parse(String utterance)
|
ArrayList<LFTerm> |
parse(String utterance,
boolean expandDelayList)
parse() preparses a parseThread to ask Gemini to parse a single sentence. |
ArrayList<Phrase> |
parseWcn(File wcnFile)
parseWcn(File wcnFile) prepares a parseWcnThread to ask Gemini to parse the Word Confusion Network contained in the file. |
ArrayList<Phrase> |
parseWcn(SausageUtterance wcn)
parseWcn(SausageUtterance wcn) prepares a parseWcnThread to ask Gemini to parse the Word Confusion Network. |
ArrayList<Phrase> |
parseWcn(String wcnString)
|
ArrayList<Phrase> |
parseWcnBestNonOverlappingPhrases(File wcnFile)
parseWcnBestNonOverlappingPhrases() prepares a parseWcnThread to ask Gemini to parse a Word Confusion Network. |
ArrayList<Phrase> |
parseWcnBestNonOverlappingPhrases(SausageUtterance wcn)
parseWcnBestNonOverlappingPhrases() prepares a parseWcnThread to ask Gemini to parse a Word Confusion Network. |
ArrayList<Phrase> |
parseWcnSortPhrases(File wcnFile,
String sortName)
parseWcnSortPhrases() parses a Word Confusion Network, and returns the set of Noun Phrase phrases with a given sort found by the parser. |
ArrayList<Phrase> |
parseWcnSortPhrases(SausageUtterance wcn,
String sortName)
parseWcnSortPhrases() parses a Word Confusion Network, and returns the set of Noun Phrase phrases with a given sort found by the parser. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public GeminiJasper()
public GeminiJasper(String[] argv)
argv - a string array containing command line arguments for SICStus Prolog.| Method Detail |
|---|
public static void main(String[] args)
public static GeminiJasper getInstance()
public ArrayList<String> findNPs(String sN)
findNPs in interface RobustParserServicepublic JPanel getGui()
Service
getGui in interface Servicepublic String getTitle()
Service
getTitle in interface Servicepublic void invokeProlog(String goal)
RobustParserService
invokeProlog in interface RobustParserServicegoal - -
a String containing the Prolog term to call. It must end with a ".".public boolean isServiceAlive()
Service
isServiceAlive in interface Servicepublic ArrayList<LFTerm> parse(String utterance)
parse in interface RobustParserService
public ArrayList<LFTerm> parse(String utterance,
boolean expandDelayList)
RobustParserService
parse in interface RobustParserServiceutterance - A String to parseexpandDelayList - a boolean to control whether under-constrained sort equations get assigned arbitrary values or not. If
TRUE, then all sort expressions in the logical form will be unified with some sortally consistent
value. If FALSE, then the DelayList term will contain the set of under-constrained sort equations.
public ArrayList<Phrase> parseWcn(File wcnFile)
RobustParserService
parseWcn in interface RobustParserServicepublic ArrayList<Phrase> parseWcn(String wcnString)
parseWcn in interface RobustParserServicepublic ArrayList<Phrase> parseWcn(SausageUtterance wcn)
RobustParserService
parseWcn in interface RobustParserServicewcn - -
A SausageUtterance object containing the word confusion network to parse.
public ArrayList<Phrase> parseWcnBestNonOverlappingPhrases(File wcnFile)
RobustParserService
parseWcnBestNonOverlappingPhrases in interface RobustParserServicepublic ArrayList<Phrase> parseWcnBestNonOverlappingPhrases(SausageUtterance wcn)
RobustParserService
parseWcnBestNonOverlappingPhrases in interface RobustParserServicewcn - -A SausageUtterance object containing the word confusion network to parse.
public ArrayList<Phrase> parseWcnSortPhrases(File wcnFile,
String sortName)
RobustParserService
parseWcnSortPhrases in interface RobustParserServicesortName - -
the sortName of the semantic sort of Noun Phrase to look for. This should match a sort name defined in
the Gemini hierarchy, in calo/src/broadcoverage/sorts_hierarchy.pl.
public ArrayList<Phrase> parseWcnSortPhrases(SausageUtterance wcn,
String sortName)
RobustParserService
parseWcnSortPhrases in interface RobustParserServicewcn - A SausageUtterance object containing the word confusion network to parse.sortName - -
the sortName of the semantic sort of Noun Phrase to look for. This should match a sort name defined in
the Gemini hierarchy, in calo/src/broadcoverage/sorts_hierarchy.pl.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||