1. Go to this page and download the library: Download galloverdedev/smart-textify library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
galloverdedev / smart-textify example snippets
php artisan smarttextify:install
return [
// Your OpenAI API key
'api_key' => env('ST_OPENAI_API_KEY'),
// The chat model to be used
'chat_model' => 'gpt-3.5-turbo-16k-0613',
// Sample temperatire (between 0=strict and 2=innovative)
'sample_temperature' => 0.5,
// The maximum number of input and output tokens per request
'max_tokens' => 2048,
];
use GalloVerdeDev\SmartTextify\Facades\SmartTextEditor;
...
$textsample = 'Excepteur fugiat tempor nisi esse tempor proident excepteur ea enim esse aliqua. Minim dolore adipisicing culpa enim nulla aliquip deserunt enim sint. Aute cillum incididunt eu dolor sint qui ut elit ea qui qui aliqua in consectetur.';
$shortText = SmartTextEditor::shorten($textsample);
$expandedText = SmartTextEditor::expand($textsample);
$summary = SmartTextEditor::summarize($textsample);
$formalText = SmartTextEditor::formalize($textsample);
$casualText = SmartTextEditor::casualize($textsample);
$keywordlist = SmartTextEditor::keywords($textsample, 3);
$translatedText = SmartTextEditor::translate($textsample, 'latin', 'german');
$glossary = SmartTextEditor::glossary($textsample);
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.