{
  "service": "rosette_text_analytics",
  "displayName": "Rosette Text Analytics",
  "categories": [
    "AI"
  ],
  "authTypes": [
    "api_key"
  ],
  "auth": [
    {
      "type": "api_key",
      "label": "Babel Street API Key",
      "placeholder": "BABELSTREET_API_KEY",
      "description": "Babel Street Analytics API key sent in the X-BabelStreetAPI-Key header. Sign up for an Analytics API key in the Babel Street Developer Portal: https://developer.babelstreet.com/signup."
    }
  ],
  "homepageUrl": "https://www.babelstreet.com/babel-street-insights",
  "actions": [
    {
      "id": "rosette_text_analytics.analyze_sentiment",
      "service": "rosette_text_analytics",
      "name": "analyze_sentiment",
      "description": "Analyze document sentiment and entity sentiment with Rosette Text Analytics.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "content": {
            "type": "string",
            "minLength": 1,
            "description": "Text content to analyze."
          },
          "contentUri": {
            "type": "string",
            "description": "A URI that Rosette Text Analytics can fetch and analyze. This is mutually exclusive with content.",
            "format": "uri"
          },
          "language": {
            "type": "string",
            "description": "ISO 639 language code for the input document when Rosette needs a language hint."
          },
          "options": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "Optional Rosette endpoint options forwarded to the API. Use official option names for the selected action."
          }
        },
        "additionalProperties": false,
        "description": "Input document for Rosette Text Analytics. Provide exactly one of content or contentUri.",
        "oneOf": [
          {
            "required": [
              "content"
            ],
            "not": {
              "required": [
                "contentUri"
              ]
            }
          },
          {
            "required": [
              "contentUri"
            ],
            "not": {
              "required": [
                "content"
              ]
            }
          }
        ]
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "document": {
            "anyOf": [
              {
                "type": "object",
                "properties": {
                  "label": {
                    "anyOf": [
                      {
                        "type": "string",
                        "description": "The label returned by Rosette."
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "confidence": {
                    "anyOf": [
                      {
                        "type": "number",
                        "description": "The label confidence score returned by Rosette."
                      },
                      {
                        "type": "null"
                      }
                    ]
                  },
                  "raw": {
                    "type": "object",
                    "properties": {},
                    "additionalProperties": true,
                    "description": "The raw object returned by Rosette Text Analytics."
                  }
                },
                "additionalProperties": false,
                "required": [
                  "label",
                  "confidence",
                  "raw"
                ],
                "description": "One label and score returned by Rosette Text Analytics."
              },
              {
                "type": "null"
              }
            ]
          },
          "entities": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "type": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The entity type returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "mention": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The entity mention text returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "normalized": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The normalized entity text returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "count": {
                  "anyOf": [
                    {
                      "type": "integer",
                      "description": "The mention count returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "entityId": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The entity identifier returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "confidence": {
                  "anyOf": [
                    {
                      "type": "number",
                      "description": "The entity confidence score returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "linkingConfidence": {
                  "anyOf": [
                    {
                      "type": "number",
                      "description": "The entity linking confidence score returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "salience": {
                  "anyOf": [
                    {
                      "type": "number",
                      "description": "The entity salience score returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "mentionOffsets": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "startOffset": {
                        "type": "integer",
                        "description": "The starting character offset for the mention."
                      },
                      "endOffset": {
                        "type": "integer",
                        "description": "The ending character offset for the mention."
                      }
                    },
                    "additionalProperties": true,
                    "description": "One mention offset object returned by Rosette."
                  },
                  "description": "The mention offsets returned by Rosette."
                },
                "raw": {
                  "type": "object",
                  "properties": {},
                  "additionalProperties": true,
                  "description": "The raw object returned by Rosette Text Analytics."
                }
              },
              "additionalProperties": false,
              "required": [
                "type",
                "mention",
                "normalized",
                "count",
                "entityId",
                "confidence",
                "linkingConfidence",
                "salience",
                "mentionOffsets",
                "raw"
              ],
              "description": "One entity returned by Rosette Text Analytics."
            },
            "description": "The entities with sentiment context returned by Rosette."
          },
          "raw": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "The raw object returned by Rosette Text Analytics."
          }
        },
        "additionalProperties": false,
        "required": [
          "document",
          "entities",
          "raw"
        ],
        "description": "The sentiment analysis result returned by Rosette."
      }
    },
    {
      "id": "rosette_text_analytics.extract_entities",
      "service": "rosette_text_analytics",
      "name": "extract_entities",
      "description": "Extract named entities such as people, organizations, locations, dates, and emails.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "content": {
            "type": "string",
            "minLength": 1,
            "description": "Text content to analyze."
          },
          "contentUri": {
            "type": "string",
            "description": "A URI that Rosette Text Analytics can fetch and analyze. This is mutually exclusive with content.",
            "format": "uri"
          },
          "language": {
            "type": "string",
            "description": "ISO 639 language code for the input document when Rosette needs a language hint."
          },
          "options": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "Optional Rosette endpoint options forwarded to the API. Use official option names for the selected action."
          }
        },
        "additionalProperties": false,
        "description": "Input document for Rosette Text Analytics. Provide exactly one of content or contentUri.",
        "oneOf": [
          {
            "required": [
              "content"
            ],
            "not": {
              "required": [
                "contentUri"
              ]
            }
          },
          {
            "required": [
              "contentUri"
            ],
            "not": {
              "required": [
                "content"
              ]
            }
          }
        ]
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "entitiesResponse": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "type": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The entity type returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "mention": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The entity mention text returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "normalized": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The normalized entity text returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "count": {
                  "anyOf": [
                    {
                      "type": "integer",
                      "description": "The mention count returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "entityId": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The entity identifier returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "confidence": {
                  "anyOf": [
                    {
                      "type": "number",
                      "description": "The entity confidence score returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "linkingConfidence": {
                  "anyOf": [
                    {
                      "type": "number",
                      "description": "The entity linking confidence score returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "salience": {
                  "anyOf": [
                    {
                      "type": "number",
                      "description": "The entity salience score returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "mentionOffsets": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "startOffset": {
                        "type": "integer",
                        "description": "The starting character offset for the mention."
                      },
                      "endOffset": {
                        "type": "integer",
                        "description": "The ending character offset for the mention."
                      }
                    },
                    "additionalProperties": true,
                    "description": "One mention offset object returned by Rosette."
                  },
                  "description": "The mention offsets returned by Rosette."
                },
                "raw": {
                  "type": "object",
                  "properties": {},
                  "additionalProperties": true,
                  "description": "The raw object returned by Rosette Text Analytics."
                }
              },
              "additionalProperties": false,
              "required": [
                "type",
                "mention",
                "normalized",
                "count",
                "entityId",
                "confidence",
                "linkingConfidence",
                "salience",
                "mentionOffsets",
                "raw"
              ],
              "description": "One entity returned by Rosette Text Analytics."
            },
            "description": "The entities extracted from the document."
          },
          "raw": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "The raw object returned by Rosette Text Analytics."
          }
        },
        "additionalProperties": false,
        "required": [
          "entitiesResponse",
          "raw"
        ],
        "description": "The entity extraction result returned by Rosette."
      }
    },
    {
      "id": "rosette_text_analytics.identify_categories",
      "service": "rosette_text_analytics",
      "name": "identify_categories",
      "description": "Identify contextual content categories for a text document.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "content": {
            "type": "string",
            "minLength": 1,
            "description": "Text content to analyze."
          },
          "contentUri": {
            "type": "string",
            "description": "A URI that Rosette Text Analytics can fetch and analyze. This is mutually exclusive with content.",
            "format": "uri"
          },
          "language": {
            "type": "string",
            "description": "ISO 639 language code for the input document when Rosette needs a language hint."
          },
          "options": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "Optional Rosette endpoint options forwarded to the API. Use official option names for the selected action."
          }
        },
        "additionalProperties": false,
        "description": "Input document for Rosette Text Analytics. Provide exactly one of content or contentUri.",
        "oneOf": [
          {
            "required": [
              "content"
            ],
            "not": {
              "required": [
                "contentUri"
              ]
            }
          },
          {
            "required": [
              "contentUri"
            ],
            "not": {
              "required": [
                "content"
              ]
            }
          }
        ]
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "categories": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "label": {
                  "anyOf": [
                    {
                      "type": "string",
                      "description": "The category label returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "confidence": {
                  "anyOf": [
                    {
                      "type": "number",
                      "description": "The category confidence score returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "score": {
                  "anyOf": [
                    {
                      "type": "number",
                      "description": "The raw category score returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "raw": {
                  "type": "object",
                  "properties": {},
                  "additionalProperties": true,
                  "description": "The raw object returned by Rosette Text Analytics."
                }
              },
              "additionalProperties": false,
              "required": [
                "label",
                "confidence",
                "score",
                "raw"
              ],
              "description": "One contextual category returned by Rosette Text Analytics."
            },
            "description": "The contextual categories identified by Rosette."
          },
          "raw": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "The raw object returned by Rosette Text Analytics."
          }
        },
        "additionalProperties": false,
        "required": [
          "categories",
          "raw"
        ],
        "description": "The category identification result returned by Rosette."
      }
    },
    {
      "id": "rosette_text_analytics.identify_language",
      "service": "rosette_text_analytics",
      "name": "identify_language",
      "description": "Identify the language or languages of a text document with Rosette Text Analytics.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "content": {
            "type": "string",
            "minLength": 1,
            "description": "Text content to analyze."
          },
          "contentUri": {
            "type": "string",
            "description": "A URI that Rosette Text Analytics can fetch and analyze. This is mutually exclusive with content.",
            "format": "uri"
          },
          "language": {
            "type": "string",
            "description": "ISO 639 language code for the input document when Rosette needs a language hint."
          },
          "options": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "Optional Rosette endpoint options forwarded to the API. Use official option names for the selected action."
          }
        },
        "additionalProperties": false,
        "description": "Input document for Rosette Text Analytics. Provide exactly one of content or contentUri.",
        "oneOf": [
          {
            "required": [
              "content"
            ],
            "not": {
              "required": [
                "contentUri"
              ]
            }
          },
          {
            "required": [
              "contentUri"
            ],
            "not": {
              "required": [
                "content"
              ]
            }
          }
        ]
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "languageDetections": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "language": {
                  "type": "string",
                  "description": "The three-letter ISO 639-3 language code detected by Rosette."
                },
                "confidence": {
                  "anyOf": [
                    {
                      "type": "number",
                      "description": "The detection confidence score returned by Rosette."
                    },
                    {
                      "type": "null"
                    }
                  ]
                },
                "raw": {
                  "type": "object",
                  "properties": {},
                  "additionalProperties": true,
                  "description": "The raw object returned by Rosette Text Analytics."
                }
              },
              "additionalProperties": false,
              "required": [
                "language",
                "confidence",
                "raw"
              ],
              "description": "One language detected by Rosette Text Analytics."
            },
            "description": "The detected languages in descending confidence order."
          },
          "raw": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "The raw object returned by Rosette Text Analytics."
          }
        },
        "additionalProperties": false,
        "required": [
          "languageDetections",
          "raw"
        ],
        "description": "The language identification result returned by Rosette."
      }
    },
    {
      "id": "rosette_text_analytics.identify_tokens",
      "service": "rosette_text_analytics",
      "name": "identify_tokens",
      "description": "Identify word, number, affix, and punctuation tokens in a text document.",
      "requiredScopes": [],
      "providerPermissions": [],
      "inputSchema": {
        "type": "object",
        "properties": {
          "content": {
            "type": "string",
            "minLength": 1,
            "description": "Text content to analyze."
          },
          "contentUri": {
            "type": "string",
            "description": "A URI that Rosette Text Analytics can fetch and analyze. This is mutually exclusive with content.",
            "format": "uri"
          },
          "language": {
            "type": "string",
            "description": "ISO 639 language code for the input document when Rosette needs a language hint."
          },
          "options": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "Optional Rosette endpoint options forwarded to the API. Use official option names for the selected action."
          }
        },
        "additionalProperties": false,
        "description": "Input document for Rosette Text Analytics. Provide exactly one of content or contentUri.",
        "oneOf": [
          {
            "required": [
              "content"
            ],
            "not": {
              "required": [
                "contentUri"
              ]
            }
          },
          {
            "required": [
              "contentUri"
            ],
            "not": {
              "required": [
                "content"
              ]
            }
          }
        ]
      },
      "outputSchema": {
        "type": "object",
        "properties": {
          "tokens": {
            "type": "array",
            "items": {
              "type": "string",
              "description": "One token returned by Rosette."
            },
            "description": "The tokens returned by Rosette."
          },
          "raw": {
            "type": "object",
            "properties": {},
            "additionalProperties": true,
            "description": "The raw object returned by Rosette Text Analytics."
          }
        },
        "additionalProperties": false,
        "required": [
          "tokens",
          "raw"
        ],
        "description": "The tokenization result returned by Rosette."
      }
    }
  ]
}
