Giter Club home page Giter Club logo

lingva-translate's Introduction

Lingva Translate

Travis Build Vercel Status Cypress Tests License Awesome Humane Tech

Alternative front-end for Google Translate, serving as a Free and Open Source translator with over a hundred languages available

How does it work?

Inspired by projects like NewPipe, Nitter, Invidious or Bibliogram, Lingva scrappes through GTranslate and retrieves the translation without using any Google-related service, preventing them from tracking.

For this purpose, Lingva is built, among others, with the following Open Source resources:

  • TypeScript, the JavaScript superset, as the language.
  • React as the main front-end framework.
  • NextJS as the complementary React framework, that provides Server-Side Rendering, Static Site Generation or serverless API endpoints.
  • ChakraUI for the in-component styling.
  • Jest, Testing Library & Cypress for unit, integration & E2E testing.
  • Apollo Server for handling the GraphQL endpoint.
  • Inkscape for designing both the logo and the banner.

Deployment

As Lingva is a NextJS project you can deploy your own instance anywhere Next is supported.

The only requerement is to set an environment variable called NEXT_PUBLIC_SITE_DOMAIN with the domain you're deploying the instance under. This is used for the canonical URL and the meta tags.

The easiest way is to use their creators' own platform, Vercel, where you can deploy it for free with the following button.

Deploy with Vercel

Instances

These are the currently known Lingva instances. Feel free to make a Pull Request including yours (please remember to add [skip ci] to the last commit).

Domain Hosting SSL Provider
lingva.ml (Official) Vercel Let's Encrypt
translate.alefvanoon.xyz Vercel Let's Encrypt

Public APIs

Nearly all the Lingva instances should supply a pair of public developer APIs: a RESTful one and a GraphQL one.

Note: both APIs return the translation audio as a Uint8Array (served as number[] in JSON and [Int] in GraphQL) with the contents of the audio buffer.

REST API v1

  • GET /api/v1/:source/:target/:query
{
    translation?: string,
    errorMsg?: string
}
  • GET /api/v1/audio/:lang/:query
{
    audio?: number[],
    errorMsg?: string
}

GraphQL API

  • /api/graphql
query {
    translation(source: String target: String query: String!) {
        source: {
            lang: String!
            text: String
            audio: [Int]
        }
        target: {
            lang: String!
            text: String
            audio: [Int]
        }
    }
    audio(lang: String! query: String!) {
        lang: String!
        text: String
        audio: [Int]
    }
}

Contributors

Thanks goes to these wonderful people (emoji key):


David

️️️️♿️ 💻 📖 🎨 ⚠️

This project follows the all-contributors specification. Contributions of any kind welcome!

License

Copyright © 2021 TheDavidDelta & contributors.
This project is GNU AGPLv3 licensed.

lingva-translate's People

Contributors

alefvanoon avatar allcontributors[bot] avatar thedaviddelta 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.