Skip to content

Latest commit

 

History

History
129 lines (94 loc) · 2.19 KB

README.md

File metadata and controls

129 lines (94 loc) · 2.19 KB

Lingo

Have a conversation with our AI and get instant feedback on the language you are learning.

Tech Stack

  • Frontend: React, Material-UI, Axios
  • Backend: Flask, Gunicorn, LangChain
  • Database: Supabase (Postgres)
  • AI/NLP: OpenAI, LangChain
  • Deployment: Render.com
  • CI/CD: GitHub Actions

UI Flow

UI Flow

API Documentation

Chat Endpoint

  • POST /chat

Headers

  • Content-Type: application/json
  • Authorization: Bearer <token here>

Request Body

{
  "conversation_history": [
    {
      "text": "string",
      "is_user_message": "boolean"
    }
  ],
  "user_id": "string"
}

Response Body

{
  "response": "string"
}

Analyze Proficiency Endpoint

  • POST /analyze-proficiency

Headers

  • Content-Type: application/json
  • Authorization: Bearer <token here>

Request Body

{
  "conversation_history": [
    {
      "text": "string",
      "is_user_message": "boolean"
    }
  ],
  "user_id": "string"
}

Response Body

{
  "proficiency_level": "string",
  "feedback": "string"
}

Analyze Proficiency Endpoint

  • POST /create-user

Headers

  • Content-Type: application/json

Request Body

{
  "name": "string",
  "previous_knowledge": "string",
  "interests": "string"
}

Response Body

{
  "user_id": "string"
}

Database Schema

Users (users)

Column Name Data Type Constraints
id UUID PRIMARY KEY
name TEXT NOT NULL
previous_knowledge TEXT NOT NULL
interests TEXT NOT NULL

Previous Proficiency Feedback (previous_proficiency_feedback)

Column Name Data Type Constraints
id UUID PRIMARY KEY
timestamp TIMESTAMP NOT NULL
user_id UUID FOREIGN KEY
language TEXT NOT NULL
proficiency_level INT NOT NULL
feedback TEXT NOT NULL