-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Summary
Create a Streamlit-based prototype to expose core NLP features (QA, summarization, sentiment, entity lookup) via a simple web UI.
Motivation
- Quickly validate user flows and UX before investing in a full React/FastAPI frontend.
- Allow interns to see end-to-end integration of pipeline functions in a live interface.
- Iterate rapidly on feature set based on user feedback.
Scope
In scope: implementation, tests
Acceptance Criteria
- Streamlit app launches and sidebar navigation works
- QA page returns answer & snippets for a sample query
- Summarization page generates a TL;DR for a sample article
- Sentiment page displays label & score for a sample article
- Entities page lists extracted entities by type
-
/ui/README.mdclearly explains installation, run command, and feature usage
Additional Context
Details
-
Category: ui
-
Priority: P1
-
Estimate: 2d
-
Dependencies:
- Core NLP functions available:
retrieve_context,generate_answer,summarize,analyze_sentiment,extract_entities streamlitadded to/ui/requirements.txt- Database connection module (
nlp/db.py)
- Core NLP functions available:
-
Prototype feature set:
- Question-Answering: text input for question, slider for
top_k, displays answer + source snippets - Summarization: select article or paste text, button to generate TL;DR
- Sentiment: select article, button to show sentiment label & score
- Entity Lookup: select article, display detected entities by type
- Navigation: sidebar menu to switch between features
- Question-Answering: text input for question, slider for
Tasks
- Add dependencies
- Add
streamlitto/ui/requirements.txt.
- Add
- Prototype app
- Create
/ui/streamlit_app.pythat:- Imports core functions from
nlp/core.py - Uses
streamlit.sidebar.selectboxfor feature selection - For each feature, uses the appropriate widgets (
text_input,slider,button,write) to capture inputs and display outputs
- Imports core functions from
- Create
- Run instruction
- Document:
streamlit run ui/streamlit_app.py
- Document:
- Smoke test
- Verify the app launches locally and each feature page loads without errors
- Documentation
- Update
/ui/README.mdwith setup steps, run command, and screenshots of each feature
- Update
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
Type
Projects
Status
Ready