Skip to content

Commit

Permalink
CG Pipeline Config Capabilities (#180)
Browse files Browse the repository at this point in the history
* endpoint for accessing configurations for a pipeline (either specific or default)

* added endpoint for stopping a pipeline
  • Loading branch information
fmatthies authored Aug 30, 2024
1 parent e9d838d commit ec61405
Show file tree
Hide file tree
Showing 2 changed files with 56 additions and 40 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

<groupId>care.smith.top</groupId>
<artifactId>top-api</artifactId>
<version>0.10.0</version>
<version>0.10.1</version>

<name>TOP API</name>
<description>REST API of the TOP framework</description>
Expand Down
94 changes: 55 additions & 39 deletions schemas/top-api.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
openapi: 3.0.0
info:
title: TOP API
version: 0.10.0
version: 0.10.1
description: |-
API to manage phenotypes, repositories, ontologies, external terminologies and organisations and to execute phenotypic queries.
Expand Down Expand Up @@ -458,6 +458,57 @@ paths:
$ref: '#/components/responses/UnexpectedError'
tags:
- conceptPipeline
'/concept_pipeline/configuration':
get:
operationId: getConceptGraphPipelineConfiguration
summary: Returns either a default configuration or the configuration for a specific pipeline if an ID is given
parameters:
- name: pipelineId
in: query
required: false
schema:
type: string
- name: language
in: query
required: false
schema:
type: string
responses:
'200':
description: A configuration in JSON format
content:
application/json:
schema:
type: string
'401':
$ref: '#/components/responses/Unauthorized'
'404':
$ref: '#/components/responses/NotFound'
default:
$ref: '#/components/responses/UnexpectedError'
tags:
- conceptPipeline
'/concept_pipeline/{pipelineId}/stop':
get:
operationId: stopConceptGraphPipeline
summary: Stops the pipeline for this specific ID after the currently running step is finished
parameters:
- name: pipelineId
in: path
required: true
schema:
type: string
responses:
'202':
description: Pipeline will be stopped
'401':
$ref: '#/components/responses/Unauthorized'
'404':
$ref: '#/components/responses/NotFound'
default:
$ref: '#/components/responses/UnexpectedError'
tags:
- conceptPipeline
'/concept_pipeline/{pipelineId}/concept_cluster':
parameters:
- name: pipelineId
Expand Down Expand Up @@ -2364,6 +2415,7 @@ components:
- running
- finished
- aborted
- stopped
- not present
PipelineResponse:
type: object
Expand All @@ -2382,6 +2434,7 @@ components:
- failed
- running
- successful
- stopped
Constant:
type: object
properties:
Expand Down Expand Up @@ -3100,44 +3153,7 @@ components:
required:
- id
ConceptPipelineConfigRequest:
type: object
properties:
pipelineId:
description: Unique identifier of the pipeline.
type: string
dataSourceId:
description: 'ID of the data source, the pipeline is issued for.'
type: string
skipPresent:
description: 'If a pipeline with the specified ID already exists, intermediate pipeline steps will be picked up.'
type: boolean
default: true
returnStatistics:
description: Whether statistics of the graph should be returned in a 200 response. Otherwise 202 response is returned.
type: boolean
default: false
language:
description: |
Use this property to specify the language of the documents contained in the corpus.
You can also use it to overwrite the language that is specified in a data source configuration.
type: string
documentServerConfig:
$ref: '#/components/schemas/ElasticsearchServerConfig'
dataConfig:
description: A simple mapping for configuration values for the preprocessing step.
type: object
embeddingConfig:
description: A simple mapping for configuration values for the embedding step.
type: object
clusteringConfig:
description: A simple mapping for configuration values for the clustering step.
type: object
graphConfig:
description: A simple mapping for configuration values for the graph creation step.
type: object
required:
- pipelineId
- documentServerConfig
type: string
ConceptPipelineRequest:
type: object
properties:
Expand Down

0 comments on commit ec61405

Please sign in to comment.