Skip to content

Commit 9377d92

Browse files
[language-translation] updated jsdoc
1 parent 3774658 commit 9377d92

File tree

1 file changed

+16
-16
lines changed
  • services/language_translation

1 file changed

+16
-16
lines changed

services/language_translation/v2.js

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ var helper = require('../../lib/helper');
2424

2525
/**
2626
*
27-
* @param {string} [somebody=https://gateway.watsonplatform.net/language-translation/api] The service URL.
28-
* @param {string} username Username
29-
* @param {string} password Password
27+
* @param {string} [params.url=https://gateway.watsonplatform.net/language-translation/api] The service URL.
28+
* @param {string} params.username Username
29+
* @param {string} params.password Password
3030
* @constructor
3131
*/
3232
function LanguageTranslation(options) {
@@ -43,11 +43,11 @@ function LanguageTranslation(options) {
4343

4444
/**
4545
* Return the translation models
46-
* @param {string} default Query filters to check if the model is
46+
* @param {string} params.default Query filters to check if the model is
4747
* the default one used when only source
4848
* and target languages are specified.
49-
* @param {string} source Filter by source language
50-
* @param {string} target Filter by target language
49+
* @param {string} params.source Filter by source language
50+
* @param {string} params.target Filter by target language
5151
*/
5252
LanguageTranslation.prototype.getModels = function(params, callback) {
5353
params = params || {};
@@ -66,7 +66,7 @@ LanguageTranslation.prototype.getModels = function(params, callback) {
6666

6767
/**
6868
* Return the translation model
69-
* @param {string} model_id The model identifier
69+
* @param {string} params.model_id The model identifier
7070
*/
7171
LanguageTranslation.prototype.getModel = function(params, callback) {
7272
params = params || {};
@@ -86,11 +86,11 @@ LanguageTranslation.prototype.getModel = function(params, callback) {
8686

8787
/**
8888
* Creates a translation model
89-
* @param {string} base_model_id The base model identifier
90-
* @param {string} name The model name
91-
* @param {stream} forced_glossary A UTF-8 encoded TMX file that contains pairs of matching terms in the source and target language that are seen as absolute by the system. This file completely overwrites the original domain data.
92-
* @param {stream} parallel_corpus A UTF-8 encoded TMX file that contains matching phrases in the source and target language that serve as examples for Watson. Parallel corpora differ from glossaries because they do not overwrite the original domain data.
93-
* @param {stream} monolingual_corpus A UTF-8 encoded plain text file that contains a body of text in the target language that is related to what you are translating. A monolingual corpus helps improve literal translations to be more fluent and human.
89+
* @param {string} params.base_model_id The base model identifier
90+
* @param {string} params.name The model name
91+
* @param {stream} params.forced_glossary A UTF-8 encoded TMX file that contains pairs of matching terms in the source and target language that are seen as absolute by the system. This file completely overwrites the original domain data.
92+
* @param {stream} params.parallel_corpus A UTF-8 encoded TMX file that contains matching phrases in the source and target language that serve as examples for Watson. Parallel corpora differ from glossaries because they do not overwrite the original domain data.
93+
* @param {stream} params.monolingual_corpus A UTF-8 encoded plain text file that contains a body of text in the target language that is related to what you are translating. A monolingual corpus helps improve literal translations to be more fluent and human.
9494
*/
9595
LanguageTranslation.prototype.createModel = function(params, callback) {
9696
params = params || {};
@@ -127,7 +127,7 @@ LanguageTranslation.prototype.createModel = function(params, callback) {
127127

128128
/**
129129
* Deletes a model
130-
* @param {string} model_id The model identifier
130+
* @param {string} params.model_id The model identifier
131131
*/
132132
LanguageTranslation.prototype.deleteModel = function(params, callback) {
133133
params = params || {};
@@ -147,8 +147,8 @@ LanguageTranslation.prototype.deleteModel = function(params, callback) {
147147

148148
/**
149149
* Translate pharagraphs from one language into another
150-
* @param {string} source Source language
151-
* @param {string} target Target language
150+
* @param {string} params.source Source language
151+
* @param {string} params.target Target language
152152
*/
153153
LanguageTranslation.prototype.translate = function(params, callback) {
154154
params = params || {};
@@ -191,7 +191,7 @@ LanguageTranslation.prototype.getIdentifiableLanguages = function(params, callba
191191

192192
/**
193193
* Identify the text based on the identifiable languages
194-
* @param [string] text text to identify
194+
* @param {string} params.text text to identify
195195
*/
196196
LanguageTranslation.prototype.identify = function(params, callback) {
197197
if (!params || !params.text){

0 commit comments

Comments
 (0)