trustami/trustami-ai

A connector for the Trustami.AI API.

1.0.4 2023-10-09 14:25 UTC

This package is not auto-updated.

Last update: 2024-11-04 19:19:41 UTC


README

This repository aims to provide a simple and easy to use connector to the Trustami.AI API.

Installation

composer require trustami/trustami-ai

Usage

<?php

require 'vendor/autoload.php';

use Trustami\TrustamiAi\LangDetector;
use Trustami\TrustamiAi\Sentiment;
use Trustami\TrustamiAi\Summarizer;

$detector = new LangDetector("YOUR_TOKEN_HERE");

var_dump($detector->detect("This is a test text. It is used to test the Trustami.AI API.")); // string(2) "en"