Interactions-HSG / Reader-Aware-Congruence-Assistant

GNU General Public License v3.0
0 stars 0 forks source link

Reader-Aware-Congruence-Assistant

Overview

We propose a Reader-aware Congruence Assistant (RaCA), which supports writers to create texts that are adapted to target readers. Similar to user-centered design which is based on user profiles, RaCA features reader-centered writing through reader profiles(RP) that are dynamically computed from information discovered through academic search engines. Our assistant then leverages large language models to measure the congruence of a written text with a given reader profile, and provides feedback to the writer. We demonstrate our approach with an implemented prototype that illustrates how RaCA exploits information available on the Web to construct reader profiles, assesses writer-reader congruence and offers writers color-coded visual feedback accordingly.

👀 demo: here

Prerequisites

Before setting up the project, ensure you have the following installed:

Also, you'll need an OpenAI API key to use the text analysis features.

Installation

  1. Clone the project repository.

  2. Navigate to the project directory and create a virtual environment:

    
    python -m venv venv
    source venv/bin/activate  # Unix/macOS
    venv\Scripts\activate.bat  # Windows
  3. Install the required Python packages:

    
    pip install Flask Flask-CORS OpenAI

Configuration

Before running the application, configure your OpenAI API key in app.py by replacing OPENAI_API_KEY with your actual key.

Project Structure

Reference: image image

Server (app.server.py)

Defines Flask routes for:

Client (app.client.py)

Handles:

Running the Application

To run the application:

  1. Start the Flask server by executing app.py:

    
    python app.py
  2. Access the web application via your browser at http://localhost:5000.

Usage

Users can interact with the system through the web interface provided by the app.client.py routes. This includes submitting texts for analysis, choosing reader profiles, and viewing suggestions and scores for text coherence.

Contributing

We welcome contributions to TLCA. Feel free to fork the repository, make improvements, and submit pull requests. For bugs and feature requests, please use the issue tracker.

License

This project is licensed under GPL-3.0 license.

Contact

For support or collaboration, please contact ge.li2@studio.unibo.it.