Logo Lanfrica
  • Home
  • Atlas
  • Insights
  • Docs
  • Sign in

Β© 2026 Lanfrica. All rights reserved. All copyrights of the resources shown on the Lanfrica website belong to the original copyright holders, unless explicitly stated otherwise.

Henryle-hd/swahili-english-translator

Domain:

natural language processing

Record type:

software
Creator:
Hen
Host:
A simple npm package for translating between English and Swahili # Swahili-English Translator πŸŒπŸ—£οΈ A simple npm package for translating between English and Swahili. This tool offers quick and accurate translations, complete with word meanings, grammatical types, and usage examples. Whether you're a developer building multilingual applications, a language learner, or someone working with Swahili and English content, Swahili-English Translator provides an efficient solution for your translation needs. Let's explore how to integrate and utilize this versatile package in your projects. ## Installation πŸ“¦ To install the package, run: ``` npm install swahili-english-translator ``` ## Usage πŸš€ First, import the translation functions: ``` const { translateEng, translateKsw } = require('swahili-english-translator'); ``` ### Translating English to Swahili πŸ‡¬πŸ‡§πŸ‡ΉπŸ‡Ώ To translate an English word to Swahili: ``` const result = translateEng('abandon'); console.log(result); ``` Output: Example 01 ``` { meaning: ' kuachana', type: 'Verb', example: { eng: 'They decided to abandon the project.', ksw: 'Waliamua kuachana na mradi.', } } ``` ### Translating Swahili to English πŸ‡ΉπŸ‡ΏπŸ‡¬πŸ‡§ To translate a Swahili word to English: ``` const result = translateKsw('uwezo'); console.log(result); ``` Output: Example 02 ``` { meaning: ' ability', type: 'Noun', example: { eng: 'She has the ability to solve complex problems.', ksw: 'Ana uwezo wa kutatua matatizo magumu.', } } ``` ### Getting Specific Information πŸ” 1. To get only the meaning: ``` const result = translateEng('abandon'); console.log(result.meaning); // Output: ' kuachana' ``` 2. To get the type of word: ``` const result = translateKsw('uwezo'); console.log(result.type); // Output: 'Noun' ``` 3. To get an example: ``` const result = translateEng('abandon'); console.log(result.example); // Output: // { // eng: 'They decided to abandon the project.', // ksw: 'Waliamua kuachana na mradi.' // } ``` Example 03 ## API Reference πŸ“š ### translateEng(word) Translates an English word to Swahili. …

Visit

github.com

Tasks

machine translation

Languages

Swahili

Licenses

MIT

Similar

Henryle-hd/Swahili-english-translator-ExampleHenryle-hd/swahili-english-translator-nextjs-app-exampleHenryle-hd/English-words-to-Swahili-wordsHenryle-hd/doctor_mtandaoHenryle-hd/BongoScamDetectionHenryle-hd/Soma_Smart

Henryle-hd/Swahili-english-translator-Example

Swahili-english-translator-Example ### swahili-english-translator ``` https://github.com/Henryle-hd

Henryle-hd/swahili-english-translator-nextjs-app-example

# Swahili-English Translator Example This project demonstrates the usage of the `swahili-english-tr

Henryle-hd/English-words-to-Swahili-words

# English words to Swahili words or Swahili words to English words A Program allow user input words

Henryle-hd/doctor_mtandao

πŸ₯ Doctor Mtandao A fun AI-powered medical assistant that speaks both English and Swahili! # πŸ₯ Docto

Henryle-hd/BongoScamDetection

BongoScam - Ni tumie kwa namba hii SMS Detection with Machine Learning & a dataset of 1,508 Tanzani

Henryle-hd/Soma_Smart

SomaSmart is an intelligent AI-powered chatbot designed to assist students in Tanzania with managing