top of page

Levelfish API Overview

The LevelFish Paraphrase API allows you or your customers to generate multiple paraphrases from a single sentence. Designed to provide multiple-choice options for Conversational AI or chatbot training data, the API can take a single or multiple utterance input and return a number of paraphrases that match the original intent.

Download the Levelfish API guide here...

Access LevelFish docs here..

How does it work

LevelFish combines a number of AI NLG inference engines combined to generate the most relevant alternative phrasing. This is filtered through a set of quality filters to provide a high quality paraphrase set. Some of these engines are designed to focus on word use, while others are designed to focus on originality of rephrasing.

Getting Access

To use any of the LevelFish APIs you will require:

  • an account and an API token. Contact sales@levelfish.com if you don’t have these.

  • An API identifier - this is the name of the paraphrase engine you will use to generate your paraphrases.

Authentication

Adding your API Token to your request headers will authorise the transaction. Any requests to the LevelFish services using your API Token will be attributed to your contract, allowance or costs. If you feel the API Token may have been compromised, please request a replacement as soon as possible.

Using the API

To generate paraphrases we have several alternative methods:
 

For demonstrations and simple use:

  1. Synchronous, Single/Multiple-phrase, simple results

 

For production implementation:

  1. Synchronous, Single/Multiple-phrase, detailed results

  2. Asynchronous, Single/Multiple-phrase, detailed results

 

With an additional feedback loop

  1. Synchronous, Single/Multiple-phrase, detailed results with feedback (RECOMMENDED)

  2. Asynchronous, Single/Multiple-phrase, detailed results with feedback

Method 1:
    Synchronous, Single/Multiple-

    phrase, simple results

This is ideal for testing or demonstrating paraphrase examples. 

This is not recommended for a production implementation as it cannot be used alongside the feedback API. This API call requires the API authentication token

Method 2:
    Synchronous, Single/Multiple-

    phrase, detailed results

This is ideal for a simple implementation and gives information about the source of all the Engines used to generate the paraphrases, an indication of what has been removed by filters and provides the itemIDs needed for a feedback API implementation at some later date.

Method 3:

    Asynchronous, Single/Multiple-

    phrase, detailed results

This is ideal for batch processing paraphrase requests. If you wish to send more than 5 phrases at a time it may be better to batch those requests and asynchronously pick up the results.

Method 4: (RECOMMENDED)
    Synchronous, Single/Multiple-            phrase, detailed results with

    feedback

This method is the recommended implementation as it is a synchronous request which makes the reaction real-time.In addition, it provides the ItemIDs needed to be able to give feedback which paraphrases the user has selected.

Method 5:
    Asynchronous, Single/Multiple-

    phrase, detailed results with

    feedback

This method can be used for batch processing tasks as above, but with the added feedback call.

bottom of page