|
import os |
|
import argparse |
|
import asyncio |
|
import gradio as gr |
|
from difflib import Differ |
|
from string import Template |
|
from utils import load_prompt, setup_gemini_client |
|
from configs.responses import SummaryResponses |
|
from google.genai import types |
|
|
|
def main(args): |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
with gr.Blocks() as demo: |
|
|
|
state = gr.State({ |
|
"messages": [], |
|
"attached_files": [], |
|
"summary": "", |
|
"summary_history": [], |
|
"summary_diff_history": [] |
|
}) |
|
|
|
with gr.Column(): |
|
gr.Markdown("# Adaptive Summarization") |
|
gr.Markdown("AdaptSum stands for Adaptive Summarization. This project focuses on developing an LLM-powered system for dynamic summarization. Instead of generating entirely new summaries with each update, the system intelligently identifies and modifies only the necessary parts of the existing summary. This approach aims to create a more efficient and fluid summarization process within a continuous chat interaction with an LLM.") |
|
|
|
return demo |
|
|
|
if __name__ == "__main__": |
|
|
|
demo = main(None) |
|
demo.launch() |
|
|