Science Score: 44.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (8.5%) to scientific vocabulary
Last synced: 6 months ago · JSON representation ·

Repository

Basic Info
  • Host: GitHub
  • Owner: leksialevin7700
  • Language: HTML
  • Default Branch: master
  • Size: 224 KB
Statistics
  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • Open Issues: 0
  • Releases: 0
Created 7 months ago · Last pushed 7 months ago
Metadata Files
Readme Citation

README.md

All-India-Developers-Hackathon

Hey folks! Introducing our hackathon project ,basically a Law Ecosystem: AI-Powered Legal Assistance Platform for Multilingual, Accessible Justice We can be feel proud if you people call us creators of "ParaLegal AI" as that's our website name!!!! Before knowing what we have proposed as solution and what we planned to build, Let's discuss about the problem statement 😉😎

Problem statement Let’s be real — the Indian legal system isn’t exactly easy to deal with. For many people, especially from marginalized communities, it’s confusing, expensive, and out of reach.

Here’s what they’re up against:

a) Legal help mostly exists in English or major languages

b) Lawyers can be costly and hard to access

c) Legal documents? Super hard to understand

d) Emergencies don’t wait, but legal support often does

e) Most people don’t even know their basic rights

🤔 So Why Did We Pick This? Okay, we’ll be honest — it wasn’t just about being “socially responsible” or “politically aware” 😅 We chose this because it felt different, real, and honestly, something that could make a massive impact. We saw a problem that affects millions and thought — what if we could simplify law with AI?

Our Solution: ParaLegal AI We’re building a smart, friendly, and multilingual AI platform that can guide people through their legal issues, even if they’ve never seen a courtroom or read a legal document before.

Imagine talking to a chatbot that:

1) Understands your language

2) Explains legal terms in plain words

3) Helps during emergencies

4) Fills out forms for you

5) Gives advice based on real legal cases

6) Works 24/7, anytime you need it

That’s ParaLegal AI in a nutshell.

🎯 Who’s This For? Honestly? Everyone. But especially:

-People in rural or remote areas

-Anyone who can’t afford a lawyer

-Women in distress or unsafe environments

-Migrant workers, students, or first-time legal users

-Anyone who just wants clear, fast answers

🚀 Our Mission We believe justice shouldn't be a luxury. With ParaLegal AI, we want to make legal help:

➡️Simple

➡️Accessible

➡️Affordable

➡️And most importantly, human-centered

Snaphots of the features present in ParaLegal AI: WhatsApp Image 2025-07-26 at 12 19 13_43975f14

WhatsApp Image 2025-07-26 at 12 20 28_66bfc346

WhatsApp Image 2025-07-26 at 12 21 09_ea573cc5

WhatsApp Image 2025-07-26 at 12 21 41_5d53483e

WhatsApp Image 2025-07-26 at 12 22 00_895eb72e

WhatsApp Image 2025-07-26 at 12 23 48_dbcd1b90

WhatsApp Image 2025-07-26 at 12 24 50_a0e34566

WhatsApp Image 2025-07-26 at 12 27 14_7e815dab

Final Thoughts This isn’t just another app. It’s a step toward making sure no one is left out of the justice system just because they didn’t know where to start.

So yeah — call us the creators of ParaLegal AI with pride 😊 Because we’re not just building a project — we’re building hope, support, and access for millions.

Demo video - https://youtu.be/QlP6YUpzQVE

Blog - https://morpho.hashnode.dev/paralegal-ai-making-legal-help-human-affordable-and-always-available

Owner

  • Name: Leksia Nagarajan
  • Login: leksialevin7700
  • Kind: user

Citation (citation_analyzer/app.py)

from flask import Flask, render_template, request
from markupsafe import Markup
import requests
import os
from dotenv import load_dotenv
import markdown as mk

load_dotenv()

app = Flask(__name__, template_folder='frontend')

GEMINI_API_KEY = os.getenv('GEMINI_API_KEY')

def format_response_as_bullet_points(text):
    """Convert text into properly formatted markdown bullet points"""
    # Split text into lines and clean them
    lines = [line.strip() for line in text.split('\n') if line.strip()]
    formatted_lines = []
    
    for line in lines:
        # If it's a citation or numbered item, make it a bullet point
        if line.startswith('*') and not line.startswith('* '):
            line = '* ' + line[1:].strip()
        elif line.startswith('•'):
            line = '* ' + line[1:].strip()
        elif not (line.startswith('* ') or line.startswith('- ')):
            # If it doesn't start with bullet point formatting already
            line = '* ' + line
        
        formatted_lines.append(line)
    
    return '\n'.join(formatted_lines)

def get_key_points(case_description):
    api_url = "https://generativelanguage.googleapis.com/v1beta/models/gemini-1.5-flash:generateContent"
    headers = {"Content-Type": "application/json"}
    payload = {
        "contents": [
            {
                "parts": [
                    {
                        "text": f"Extract important key points to handle this legal case. Format each point as a bullet point with an asterisk (*):\n{case_description}"
                    }
                ]
            }
        ]
    }
    params = {"key": GEMINI_API_KEY}
    response = requests.post(api_url, headers=headers, json=payload, params=params)
    result = response.json()
    
    try:
        key_points_text = result['candidates'][0]['content']['parts'][0]['text']
        key_points_text = format_response_as_bullet_points(key_points_text)
    except (KeyError, IndexError):
        key_points_text = "* Error: Unable to extract key points."
    
    return key_points_text

def get_court_questions(case_description):
    api_url = "https://generativelanguage.googleapis.com/v1beta/models/gemini-1.5-flash:generateContent"
    headers = {"Content-Type": "application/json"}
    payload = {
        "contents": [
            {
                "parts": [
                    {
                        "text": f"Suggest what questions a lawyer should ask in court based on this case. Format each question as a bullet point with an asterisk (*):\n{case_description}"
                    }
                ]
            }
        ]
    }
    params = {"key": GEMINI_API_KEY}
    response = requests.post(api_url, headers=headers, json=payload, params=params)
    result = response.json()
    
    try:
        questions_text = result['candidates'][0]['content']['parts'][0]['text']
        questions_text = format_response_as_bullet_points(questions_text)
    except (KeyError, IndexError):
        questions_text = "* Error: Unable to generate court questions."
    
    return questions_text

@app.route('/', methods=['GET'])
def index():
    return render_template('index.html')

@app.route('/process_case', methods=['POST'])
def process_case():
    case_description = request.form['case_description']
    key_points = get_key_points(case_description)
    court_questions = get_court_questions(case_description)
    
    # Convert markdown to HTML and mark as safe for rendering
    key_points_html = Markup(mk.markdown(key_points))
    court_questions_html = Markup(mk.markdown(court_questions))
    
    return render_template('index.html',
                          case_description=case_description,
                          key_points=key_points_html,
                          court_questions=court_questions_html)

if __name__ == '__main__':
    app.run(debug=True,port = 5045)

GitHub Events

Total
  • Watch event: 2
  • Push event: 5
  • Create event: 1
Last Year
  • Watch event: 2
  • Push event: 5
  • Create event: 1

Dependencies

doc summarizer/requirements.txt pypi
  • huggingface_hub *
  • streamlit *
  • torch *
  • transformers *
homePage/requirements.txt pypi
  • Flask ==1.1.2
  • Flask-RESTful ==0.3.8