Usage
text_personality(text, userpwd, keep_data = "true", callback = NULL, model_id = "es-en-conversational", include_raw = "false", headers = "false", content_type = "text/plain; charset=utf-8", content_language = "en", accept = "application/json", accept_language = "en")
Arguments
userpwd
Character scalar that contains 'username:password' string.
keep_data
Character scalar specifying whether to share your data with
Watson services for the purpose of training their models.
callback
Function that can be applied to responses to examine http status,
headers, and content, to debug or to write a custom parser for content.
The default callback parses content into a data.frame while dropping other
response values to make the output easily passable to tidyverse packages like
dplyr or ggplot2. For further details or debugging one can pass a fail or a
more compicated function.
model_id
Character scalar formated as 'source-target-domain'.
Source language (Arabic, Brazilian Portuguese, English, French, Italian,
or Spanish), target language (Arabic, Brazilian Portuguese, English, French,
Italian, or Spanish) and domain of text (conversational, news, patent).
Check IBM documentation for other language mappings.
include_raw
Character scalar showing whether to include only normalized
statistics or also raw statistics.
headers
Character scalar showing whether to return column labels when
Accept-Content is set to 'text/csv'.
content_type
Character scalar setting input data type header. Alternatives
are 'application/json; charset=utf-8' and 'text/html; charset=ISO-8859-1'.
content_language
Character scalar setting input language. Alternatives are
'ar' (Arabic), 'es' (Spanish), 'ja' (Japanese).
accept
Character scalar that specifies response format. Alternative is
text/plain.
accept_language
Character scalar setting output langauge. Alternatives are
'ar' (Arabic), 'de' (German), 'es' (Spanish), 'fr' (French), 'it' (Italian),
'ja' (Japanese), 'ko' (Korean), 'pt-br' (Brazilian Portuguese),
'zh-cn' (Simplified Chinese), 'zh-tw' (Traditional Chinese).