Spaces:
Sleeping
Sleeping
A newer version of the Gradio SDK is available:
6.2.0
metadata
title: Requirements Management
emoji: 📄
colorFrom: blue
colorTo: purple
sdk: gradio
sdk_version: 5.27.0
app_file: app.py
pinned: false
Requirements Assistant (Gradio + RAG)
Interactive requirements assistant built with Gradio. Upload a requirements/spec document, ask questions, and the app will retrieve context and either draft a Jira-style ticket or produce a compliance matrix using a Qwen model on OpenRouter. Local sentence-transformer embeddings plus ChromaDB keep everything in-memory for fast, lightweight retrieval.
Features
- Gradio UI with multi-conversation history.
- File upload (.txt/.md/.json/.csv/.pdf) with on-the-fly chunking into an in-memory ChromaDB collection.
- Simple RAG summarizer that routes to one of two agents:
- Jira ticket generator (JSON shape).
- Compliance matrix generator (markdown table).
- OpenRouter model calls (defaults to
qwen/qwen3-4b:free) with streaming responses.
Prerequisites
- Python 3.10+ recommended.
- pip for installing dependencies.
Setup
- (Optional) Create/activate a virtual environment.
- Install dependencies:
pip install -r requirements.txt - Provide an API key (preferred: OpenRouter):
- Create a
.envalongsideapp.py(auto-loaded on startup):OPENROUTER_API_KEY=sk-or-...OPENAI_API_KEYis also accepted as a fallback.
- Create a
Run the app
python app.py
Gradio will print a local URL. Open it, start a new conversation, optionally upload a file, and ask your question.
Notes
- Embeddings use
zacCMU/miniLM2-ENG3and store data in an in-memory Chroma collection; restart clears uploaded context. - If you see 429 rate limits from OpenRouter’s free pool, add your own key or switch to a different model in
pipelines/requirements_pipe.py.