LLM-API

Project Setup Instructions

Click here to see the Setup Instructions

LLM Project is a Python library Model for dealing with word pluralization.

1. Install Dependencies

Use the package manager pip to install Project.

pip install -r requirements.txt

2. Prepare CSV File (if applicable)

python app.py #run with CSV file
python app_without_CSV.py #run without CSV file

Usage

import requests

url = 'http://127.0.0.1:5000/evaluate'

data = [
    {
        'answer_1': 'The cat is on the mat.',
        'answer_2': 'There is a cat on the mat.',
        'answer_3': 'A cat is sitting on a mat.',
        'answer_4': 'On the mat, there is a cat.',
        'student_answer': 'A cat is on the mat.'
    },
    # Add more student answers here
]

response = requests.post(url, json=data)
print(response.json())

3. Run the API in Terminal

Using Postman:

1. Open Postman.
2. Set the request type to POST.
3. Enter http://127.0.0.1:5000/evaluate in the URL field.
4. Go to the “Body” tab, select “raw” and “JSON”, then paste your JSON data:

[
    {
        "answer_1": "The cat is on the mat.",
        "answer_2": "There is a cat on the mat.",
        "answer_3": "A cat is sitting on a mat.",
        "answer_4": "On the mat, there is a cat.",
        "question": "Where is the cat?",
        "student_answer": "A cat is on the mat."
    }
]

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.

License

Comming Soon