How to paraphrase or rephrase English Text Sentences in C# .NET Framework using Deep Learning AI

Cloudmersive
1 min readJul 25, 2020

--

Deep Learning can be used for all sorts of interesting things these days, everything from image recognition to playing video games. A highly practical use of this cutting-edge tech is in the field of Natural Language Processing, allowing you to input a sentence and receive back a set of rephrasings of that sentence. No more writer’s block!

First we install our package using NuGet:

Install-Package Cloudmersive.APIClient.NET.NLP -Version 4.0.9

Next up, we call our function using this block of code here:

using System;using System.Diagnostics;using Cloudmersive.APIClient.NET.NLP.Api;using Cloudmersive.APIClient.NET.NLP.Client;using Cloudmersive.APIClient.NET.NLP.Model;namespace Example{public class RephraseTranslateDeuToEngExample{public void main(){// Configure API key authorization: ApikeyConfiguration.Default.AddApiKey("Apikey", "YOUR_API_KEY");// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed// Configuration.Default.AddApiKeyPrefix("Apikey", "Bearer");var apiInstance = new RephraseApi();var input = new RephraseRequest(); // RephraseRequest | Input rephrase requesttry{// Rephrase, paraphrase English text sentence-by-sentence using Deep Learning AIRephraseResponse result = apiInstance.RephraseTranslateDeuToEng(input);Debug.WriteLine(result);}catch (Exception e){Debug.Print("Exception when calling RephraseApi.RephraseTranslateDeuToEng: " + e.Message );}}}}

And now you just need to input your sentence and give it a test run. Easy.

--

--

Cloudmersive
Cloudmersive

Written by Cloudmersive

There’s an API for that. Cloudmersive is a leader in Highly Scalable Cloud APIs.

No responses yet