diff --git a/annif/rest.py b/annif/rest.py index f149afbcc..c50349cdc 100644 --- a/annif/rest.py +++ b/annif/rest.py @@ -48,9 +48,9 @@ def show_project(project_id): return project.dump() -def analyze(project_id, text, limit, threshold): - """analyze text and return a dict with results formatted according to - Swagger spec""" +def suggest(project_id, text, limit, threshold): + """suggest subjects for the given text and return a dict with results + formatted according to Swagger spec""" try: project = annif.project.get_project( diff --git a/annif/swagger/annif.yaml b/annif/swagger/annif.yaml index 18940a70a..164782377 100644 --- a/annif/swagger/annif.yaml +++ b/annif/swagger/annif.yaml @@ -47,10 +47,10 @@ paths: $ref: '#/definitions/Problem' tags: - Project administration - '/projects/{project_id}/analyze': + '/projects/{project_id}/suggest': post: summary: suggest subjects for a given text - operationId: annif.rest.analyze + operationId: annif.rest.suggest consumes: - application/x-www-form-urlencoded produces: @@ -60,7 +60,7 @@ paths: - $ref: '#/parameters/project_id' - name: text in: formData - description: text to analyze + description: input text required: true type: string - name: limit diff --git a/annif/templates/home.html b/annif/templates/home.html index 77759e603..1e87ab0bb 100644 --- a/annif/templates/home.html +++ b/annif/templates/home.html @@ -44,7 +44,7 @@

<% problem.title %>

-