Last updated: 30-Jun-2022 16:22
This document describes a session, using either HTML or command-line calls,
that uses the gate service to obtain the annotations resulting from applying
GATE to a newspaper article harvested from the Boston Globe on March 3, 2023.
This sequence is harvested from the tests used to confirm the expected behavior
of gate and gated.
Use URlEncoder to URL-encode parameter values for each URL.
The sequence of operations is the same for both HTML and the command line:
gated)Each numbered item is a link that will invoke the operation when clicked.
Endpoint: plugin
operation: mavenPlugin
parameters:
URL:
https://hoyo.zeetix.com:5101/gate/v0/plugin/mavenPlugin?group=uk.ac.gate.plugins&artifact=annie&version=9.1
Endpoint: document
operation: withPath
parameters:
URL:
https://hoyo.zeetix.com:5101/gate/v0/document/withPath?path=%2Fhome%2Ftms%2Fbackend%2Ftests%2Ftest_classes%2FBackendServices%2FGateService%2FinputData%2FgatePipelineTest_sample.html
Endpoint: corpus
operation: withName
parameters:
URL:
https://hoyo.zeetix.com:5101/gate/v0/corpus/withName?corpusName=testCorpus1
Add the loaded document to the corpus
Endpoint: corpus
operation: addDocument
parameters:
URL:
https://hoyo.zeetix.com:5101/gate/v0/corpus/addDocument?corpusName=testCorpus1&documentName=%2Fhome%2Ftms%2Fbackend%2Ftests%2Ftest_classes%2FBackendServices%2FGateService%2FinputData%2FgatePipelineTest_sample.html
Endpoint: pipeline
operation: withName
parameters:
URL:
https://hoyo.zeetix.com:5101/gate/v0/pipeline/withName?pipelineName=testPipeline1
Load the "AnnotationDeletePR" processing resource
Endpoint: pr
operation: withPR
parameters:
URL:
https://hoyo.zeetix.com:5101/gate/v0/pr/withPR?prName=anndeletePR&resourcePath=gate.creole.annotdelete.AnnotationDeletePR
Load the "DefaultTokenizer" processing resource
Endpoint: pr
operation: withPR
parameters:
URL:
https://hoyo.zeetix.com:5101/gate/v0/pr/withPR?prName=defToken&resourcePath=gate.creole.tokeniser.DefaultTokeniser
Set the corpus of the pipeline
Endpoint: pipeline
operation: corpusSet
parameters:
URL:
https://hoyo.zeetix.com:5101/gate/v0/pipeline/corpusSet?pipelineName=testPipeline1&corpusName=testCorpus1
Add the "AnnotationDeletePR" to the pipeline
Endpoint: pipeline
operation: prAdd
parameters:
URL:
https://hoyo.zeetix.com:5101/gate/v0/pipeline/prAdd?pipelineName=testPipeline1&prName=anndeletePR
Add the DefaultTokenizer" to the pipeline
Endpoint: pipeline
operation: prAdd
parameters:
URL:
https://hoyo.zeetix.com:5101/gate/v0/pipeline/prAdd?pipelineName=testPipeline1&prName=defToken
Configure the setsToKeep parameter of "AnnotationDeletePR"
Endpoint: pipeline
operation: parameterValueSet
parameters:
URL:
https://hoyo.zeetix.com:5101/gate/v0/pipeline/parameterValueSet?pipelineName=testPipeline1&prName=anndeletePR¶meterName=setsToKeep¶meterValue=Key%2CTarget¶meterType=List%3CString%3E
Endpoint: pipeline
operation: run
parameters:
URL:
https://hoyo.zeetix.com:5101/gate/v0/pipeline/run?pipelineName=testPipeline1
Get the annotations from the document
Endpoint: document
operation: annotations
parameters:
URL:
https://hoyo.zeetix.com:5101/gate/v0/document/annotations?documentName=%2Fhome%2Ftms%2Fbackend%2Ftests%2Ftest_classes%2FBackendServices%2FGateService%2FinputData%2FgatePipelineTest_sample.html
Endpoint: cleanup
operation: na
parameters: na
URL:
https://hoyo.zeetix.com:5101/gate/v0/cleanup
Endpoint: resetSharedState
operation: na
parameters: na
URL:
https://hoyo.zeetix.com:5101/gate/v0/resetSharedState
Load the ANNIE plugin
Endpoint: plugin
operation: mavenPlugin
parameters:
URL:
wget "https://hoyo.zeetix.com:5101/gate/v0/plugin/mavenPlugin?group=uk.ac.gate.plugins&artifact=annie&version=9.1"
Load a document from a file
Endpoint: document
operation: withPath
parameters:
URL:
wget "https://hoyo.zeetix.com:5101/gate/v0/document/withPath?path=%2Fhome%2Ftms%2Fbackend%2Ftests%2Ftest_classes%2FBackendServices%2FGateService%2FinputData%2FgatePipelineTest_sample.html"
Create a corpus
Endpoint: corpus
operation: withName
parameters:
URL:
wget "https://hoyo.zeetix.com:5101/gate/v0/corpus/withName?corpusName=testCorpus1"
Add the loaded document to the corpus
Endpoint: corpus
operation: addDocument
parameters:
URL:
wget "https://hoyo.zeetix.com:5101/gate/v0/corpus/addDocument?corpusName=testCorpus1&documentName=%2Fhome%2Ftms%2Fbackend%2Ftests%2Ftest_classes%2FBackendServices%2FGateService%2FinputData%2FgatePipelineTest_sample.html"
Create a pipeline
Endpoint: pipeline
operation: withName
parameters:
URL:
wget "https://hoyo.zeetix.com:5101/gate/v0/pipeline/withName?pipelineName=testPipeline1"
Load the "AnnotationDeletePR" processing resource
Endpoint: pr
operation: withPR
parameters:
URL:
wget "https://hoyo.zeetix.com:5101/gate/v0/pr/withPR?prName=anndeletePR&resourcePath=gate.creole.annotdelete.AnnotationDeletePR"
Load the "DefaultTokenizer" processing resource
Endpoint: pr
operation: withPR
parameters:
URL:
wget "https://hoyo.zeetix.com:5101/gate/v0/pr/withPR?prName=defToken&resourcePath=gate.creole.tokeniser.DefaultTokeniser"
Set the corpus of the pipeline
Endpoint: pipeline
operation: corpusSet
parameters:
URL:
wget "https://hoyo.zeetix.com:5101/gate/v0/pipeline/corpusSet?pipelineName=testPipeline1&corpusName=testCorpus1"
Add the "AnnotationDeletePR" to the pipeline
Endpoint: pipeline
operation: prAdd
parameters:
URL:
wget "https://hoyo.zeetix.com:5101/gate/v0/pipeline/prAdd?pipelineName=testPipeline1&prName=anndeletePR"
Add the DefaultTokenizer" to the pipeline
Endpoint: pipeline
operation: prAdd
parameters:
URL:
wget "https://hoyo.zeetix.com:5101/gate/v0/pipeline/prAdd?pipelineName=testPipeline1&prName=defToken"
Configure the setsToKeep parameter of "AnnotationDeletePR"
Endpoint: pipeline
operation: parameterValueSet
parameters:
URL:
wget "https://hoyo.zeetix.com:5101/gate/v0/pipeline/parameterValueSet?pipelineName=testPipeline1&prName=anndeletePR¶meterName=setsToKeep¶meterValue=Key%2CTarget¶meterType=List%3CString%3E"
Run the pipeline
Endpoint: pipeline
operation: run
parameters:
URL:
wget "https://hoyo.zeetix.com:5101/gate/v0/pipeline/run?pipelineName=testPipeline1"
Get the annotations from the document
Endpoint: document
operation: annotations
parameters:
URL:
wget "https://hoyo.zeetix.com:5101/gate/v0/document/annotations?documentName=%2Fhome%2Ftms%2Fbackend%2Ftests%2Ftest_classes%2FBackendServices%2FGateService%2FinputData%2FgatePipelineTest_sample.html"
Cleanup gate daemon (gated)
Endpoint: cleanup
operation: na
parameters: na
URL:
wget "https://hoyo.zeetix.com:5101/gate/v0/cleanup"
Reset shared state
Endpoint: resetSharedState
operation: na
parameters: na
URL:
wget "https://hoyo.zeetix.com:5101/gate/v0/resetSharedState"