Skip to main content

Text-based Recommendation Engine using Cohere NLP

Project description

Osusume (おすすめ)

Text-Based Recommendation Engine using Cohere

Osusume is a library to implement text-based recommendation engine using Cohere Embeddings and Generation API. Initally was built for a Hacktahon Submission hosted by Lablab.AI and Cohere.

View Changelog

Quick Start

import pandas as pd

import nltk
nltk.download('wordnet')
nltk.download('omw-1.4')

from osusume import Osusume

anime_df = pd.read_json('anime_sm.json')

engine = Osusume.from_dict({
    'token': '<cohere-token>',
    'dataset': anime_df,
    'sentiment_column': 'synopsis',
    'response_prompt': 'anime_data.txt',
    'response_column': [
        ('Title', 'title'),
        ('Synopsis', 'synopsis')
    ]
}).fit()

engine.predict(
    query='animes about monsters and aliens from another world', 
    n_out=3
)

# Top 3 Anime's from given Query

Installation

~ pip install osusume --upgrade

You need to use Pip to install osusume. Conda package is currently unavailable.

Requirements

  • Python >= 3.8
  • Cohere
  • Pandas
  • Numpy
  • Scikit Learn
  • NLTK

Author

  • Abhishta Gatya (Email) - Software and Machine Learning Engineer

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

osusume-1.0.1.tar.gz (12.1 kB view details)

Uploaded Source

Built Distribution

osusume-1.0.1-py3-none-any.whl (16.9 kB view details)

Uploaded Python 3

File details

Details for the file osusume-1.0.1.tar.gz.

File metadata

  • Download URL: osusume-1.0.1.tar.gz
  • Upload date:
  • Size: 12.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.9

File hashes

Hashes for osusume-1.0.1.tar.gz
Algorithm Hash digest
SHA256 9df21335a66f1b23d134fbce66ef2c1c6443a7968e93dbc620016caf8a27d367
MD5 ac135bfbf1c97f8ca109ddac28867b86
BLAKE2b-256 6b482c9354ec06ae57ee16e7fa26e545a07ce7f8ca1304972c7ea76368f4631d

See more details on using hashes here.

File details

Details for the file osusume-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: osusume-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 16.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.9

File hashes

Hashes for osusume-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 dd5e6827f7827ba71f1f37e7dcc9e8ad5d3b0d0b0fbf5d1b74866c53347c0431
MD5 c684cc8d6edd2a89d9c80945515105e7
BLAKE2b-256 195976947758c88b54f642e40452a7eb39eac95e710ac20f54096f93b1f045b4

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page