GithubHelp home page GithubHelp logo

rap2hpoutre / voltaire Goto Github PK

View Code? Open in Web Editor NEW
6.0 2.0 0.0 10 KB

Proof-reading tool for PHP (spell checker, grammar fixer using LanguageTool)

License: MIT License

PHP 100.00%
languagetool spelling-checker proof-reading voltaire php composer

voltaire's Introduction

Voltaire

TL;DR

Proof-reading tool (spell checker, grammar fixer, etc.). Works for English, French, German, Polish, and more than 20 other languages, thanks to LanguageTool. Install via composer, works with any of your favorite framework: Laravel, Slim, Symfony, etc.

Install

Install via composer

composer require rap2hpoutre/voltaire

Usage

Quick start

// Initialize Voltaire with your language.
$voltaire = new Rap2hpoutre\Voltaire\Voltaire('fr');

// Process text and get the response.
$response = $voltaire->process('Bojnour tout le monde.');

// Display all errors
foreach($response->errors as $error) {
    echo $error->msg . "\n";
}

Production

According to LanguageTool Wiki, you should not use the public API of LanguageTool to send automated requests. Oops, that's what we have done in quick start 😇

Access is currently limited to 20 requests per IP per minute.

So, in production environment, you should use your own instance of LanguageTool, like this:

// Initialize Voltaire with your language and your own instance
$voltaire = new Rap2hpoutre\Voltaire\Voltaire('fr', 'http://localhost:8081');

About

François-Marie Arouet (French: [fʁɑ̃.swa ma.ʁi aʁ.wɛ]; 21 November 1694 – 30 May 1778), known by his nom de plume Voltaire (/voʊlˈtɛər/;[1] French: [vɔl.tɛːʁ]), was a French Enlightenment writer, historian, and philosopher famous for his wit, his attacks on the established Catholic Church, and his advocacy of freedom of religion, freedom of expression, and separation of church and state.

Drawing

source: Wikipedia

voltaire's People

Contributors

rap2hpoutre avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.