Skip to content

Instantly share code, notes, and snippets.

View BigLobsterito's full-sized avatar
🏠
Working from home

BigLobsterito

🏠
Working from home
  • Millenium Inc.
  • Berlin
View GitHub Profile

How to Detect Language for a String in PHP

Installation

To install unirest-php with Composer, just add the following to your composer.json file:

{
    "require-dev": {
        "mashape/unirest-php": "3.*"

Python: How to determine the language?

Installing

To use Unirest for Python, install it using pip:

pip install unirest
{
"name": "Language Identification",
"description": "Identifies the language in which the input text is written.",
"url": "https://gist.githubusercontent.com/BigLobsterito/32ea27a260ca4ff93490abbe032f2a6c/raw/935b472e04c26ab8b163e8131dda9e940d58964f/apis.json",
"image": "https://i.imgur.com/CX1YPjf.jpg",
"specificationVersion": "0.14",
"apis": [
{
"name": "Language Identification",
"description": "Identifies the language in which the input text is written.",
swagger: '2.0'
info:
title: Language Identification (Prediction)
version: ''
description: Automatic language detection for any texts. Supports over 150 languages.
contact:
name: Forum
url: https://rapidapi.com/BigLobster/api/language-identification-prediction/discussions
schemes:
- https