Skip to content

Latest commit

 

History

History
212 lines (170 loc) · 7.58 KB

README.md

File metadata and controls

212 lines (170 loc) · 7.58 KB

Emergency Response Assistance Solution

Team Name : L3K1
Explore Our Project »

Introduction · Demo Video · Slides

[Read in Korean]

Table of Contents

  1. Project Overview
  2. Getting Started
    • Clone the Repository
    • Setup
  3. Directory Structure
  4. Use Case Diagram
  5. Data Sources
  6. Authors and Acknowledgment

Project Overview

Goals:

  • Assist first responders and medical personnel
  • Enable rapid and efficient emergency response and medical care

What’s Pre-KTAS?

  • Patient classification system to determine treatment priority in emergencies.
  • In Korea, the format of triage used in emergency rescue activities is specified in the rules on emergency rescue response activities and field command.

Built With

Python fastapi langchain


Getting Started

1. Clone the Repository:

git clone https://github.com/seongyeon1/Fraiday.git
cd Fraiday

2. Setup

2-1 Using Makefile

To start the application for the first time:

make startapp
  • setup.sh will prompt you to enter your UPSTAGE_API_KEY during execution.

To rerun the application:

make rerun

2-2. Using setup.sh Script

chmod +x setup.sh
./setup.sh

Rerun the App

python app/main.py

2-2. Do it step-by-step

Create a Virtual Environment

python3 -m venv .venv
. .venv/bin/activate

pip install --upgrade pip
pip install -r requirements.txt

Create a .env File

cat > .env
UPSTAGE_API_KEY='Your API key' # e.g., UPSTAGE_API_KEY=up_YW~
  • After entering, close the cat command using Ctrl+C.

Run the App

cd app
python main.py

Result

L3K1._demo.MP4

Directory Structure

Fraiday
├── app
│   ├── main.py
│   ├── chat.py
│   ├── rag.py
│   └── template
│       └── (prompt templates)
├── preprocessing
│   ├── ocr.py
│   └── chunking.py
├── setup.sh
├── requirements.txt
└── .env(example)

app

  • app/main.py: The main page utilizing FastAPI and Langserve.
  • app/chat.py:
    • Uses the Upstage API(for model, embeddings) to fine-tune prompts for an emergency response chatbot demo (under development).
    • Excels in multi-turn conversations.
    • Chats like a real emergency responder but lacks precise knowledge for professional expertise.
  • app/rag.py: Uses RAG (Seoul National University First Aid).
    • A more specialized model compared to the chat page.
    • Proficient in explaining first aid using Upstage API(for model, embeddings) and RAG.
    • Informs about KTAS levels and summarizes conversations.
    • Lacks flexibility in conversations as it follows procedures to inform about KTAS levels.
  • app/templates: Stores prompt templates.

preprocessing

  • Functions for embedding and OCR processing for RAG.
  • Currently used for OCR processing and embedding Seoul National University data and the First Aid Guidebook.


Use Case Diagram

Now

Now

Future Work

Future Work

It will be implemented in the form of a router model that combines all of the following features

  • Multi-turn dialogue: It is possible to respond and respond quickly according to the context by being proficient in multi-turn dialogue (currently, it is possible to implement through chat.py model)
  • Provide first aid information: Provide accurate information based on clear knowledge (Currently, the rag.py model has been verified for implementation)
  • Conversation summary: Summarise the information received at the end of an emergency conversation and use it as an aid for emergency room visits (implemented by tuning the prompt to summarise specific conditions based on history)

Data Sources

First aid resources (for RAG)


Real emergency voice call dataset



Authors and Acknowledgment

FRAIDAY was created by L3K1

If you have any questions or comments about our project, please contact below.

EunkyungLee SungyeonKim JunghoonLee JunghuiLee

@ek0111

@seongyeon1

@coronarita1991

@wjdgml0526
eunkyung0111@gmail.com ksy974498@gmail.com coronarita1991@gmail.com wjdgml0526@gmail.com