Spaces:
Sleeping
Sleeping
File size: 10,492 Bytes
faf6c33 420bcec 55960a8 420bcec 4238455 420bcec 4238455 420bcec |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 |
---
title: Sherlock Project Assistant
emoji: 🔍
colorFrom: blue
colorTo: purple
sdk: gradio
sdk_version: "4.44.0"
app_file: app.py
pinned: false
license: cc-by-nc-sa-4.0
---
<div align="center">
<img src="assets/logo-transparent-bg.png" alt="Sherlock Logo" width="120">
<h1>Sherlock Project Assistant</h1>
<p><em>Your intelligent assistant for managing multiple projects through meeting summaries</em></p>
[](https://creativecommons.org/licenses/by-nc-sa/4.0/)
[](https://github.com/sebasmos/sherlock)
[](https://huggingface.co/spaces/sebasmos/sherlock-project-assistant)
</div>
---
An AI-powered project assistant that helps you manage and query your project meetings and documentation.
## Table of Contents
- [Demo](#demo)
- [Features](#features)
- [System Architecture](#system-architecture)
- [Tech Stack](#tech-stack)
- [Agentic Capabilities](#agentic-capabilities)
- [Quick Start](#quick-start)
- [Usage](#usage)
- [LLM Providers](#llm-providers)
- [Observability](#observability-langsmith)
- [Performance Features](#performance-features)
- [Agent Evaluation](#agent-evaluation)
- [Testing](#testing)
- [Project Structure](#project-structure)
- [Unsorted To-Dos](#unsorted-to-dos)
## Demo
🚀 [Try the live demo here](https://huggingface.co/spaces/sebasmos/sherlock-project-assistant)
## Features
- **RAG-powered Q&A** - Ask questions about your projects using ChromaDB vector search
- **LangGraph AI Agent** - Intelligent query routing for action items, blockers, and status
- **Multi-project support** - Manage and filter across multiple projects
- **Meeting structuring** - Upload raw notes and get AI-structured markdown
- **Action item tracking** - Track open/completed tasks with assignees and deadlines
- **Blocker & decision tracking** - Surface blockers and key decisions from meetings
- **Multiple LLM Providers** - Choose between HuggingFace (free) or Google Gemini (paid)
- **Meeting summary generation** - Get comprehensive summaries with key takeaways
- **Trend analysis** - Analyze patterns across meetings: recurring topics, blocker trends, progress
- **LangSmith Observability** - Trace LLM calls, monitor latency, token usage, and errors
- **Agent Evaluation** - Automated quality testing with keyword matching and latency metrics
- **Streaming Responses** - See LLM output in real-time as it generates (better UX)
- **Response Caching** - Faster repeated queries with 5-minute TTL cache (lower API costs)
- **Export Chat** - Download your conversation history as PDF
## System Architecture

## Tech Stack
| Category | Technology | Purpose |
|----------|------------|---------|
| **Frontend** | Gradio 4.44 | Web UI framework |
| **LLM Framework** | LangChain | LLM orchestration |
| **Agent Framework** | LangGraph | State machine for agent routing |
| **Vector Store** | ChromaDB | Persistent vector storage |
| **Embeddings** | Sentence Transformers | Text embeddings (all-MiniLM-L6-v2) |
| **LLM (Free)** | HuggingFace Inference | Llama 3.2 3B Instruct |
| **LLM (Paid)** | Google Generative AI | Gemini 2.5 Flash Lite |
| **Data Models** | Pydantic | Data validation |
| **Testing** | Pytest | Unit and integration tests |
| **Observability** | LangSmith | LLM tracing and monitoring |
## Agentic Capabilities
| Capability | Description | Trigger Keywords |
|------------|-------------|------------------|
| **Query Analysis** | Understands user intent and extracts project context | All queries |
| **Context Retrieval** | Semantic search across meeting notes | All queries |
| **Action Item Extraction** | Surfaces open tasks with assignees and deadlines | "action item", "todo", "task", "what's next", "what should" |
| **Blocker Detection** | Identifies and lists current blockers | "blocker", "issue", "problem", "stuck" |
| **Decision Tracking** | Retrieves decisions made in meetings | "decision", "decided", "agreed" |
| **Project Filtering** | Scopes queries to specific projects | Mention project name in query |
| **Meeting Structuring** | Converts raw notes to formatted markdown | Upload tab |
## Quick Start
### Using uv (recommended)
```bash
# Clone the repository
git clone https://github.com/sebasmos/sherlock.git
cd sherlock
# Create venv and install dependencies
uv venv --python 3.10
source .venv/bin/activate # On Windows: .venv\Scripts\activate
uv pip install -r requirements.txt
# Run the app
python app.py
```
### Using pip
```bash
# Clone the repository
git clone https://github.com/sebasmos/sherlock.git
cd sherlock
# Create virtual environment (Python 3.10)
python3.10 -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
# Install dependencies
pip install -r requirements.txt
# Run the app
python app.py
```
The app will be available at http://localhost:7860
## Usage
1. Choose your LLM provider and enter your API token
2. Add your meeting notes to `data/your_project/meetings/*.md`
3. Start asking questions about your projects
### Meeting Notes Format
```markdown
# Meeting: Sprint Planning
Date: 2025-01-15
Participants: Alice, Bob
## Discussion
Key points discussed...
## Decisions
- Decision 1
- Decision 2
## Action Items
- [ ] Alice: Implement login by Jan 20
- [x] Bob: Review PR (completed)
## Blockers
- Waiting for API credentials
```
## LLM Providers
### HuggingFace (Free)
| Property | Value |
|----------|-------|
| **Model** | Llama 3.2 3B Instruct |
| **Cost** | Free (rate limited) |
| **Token URL** | [huggingface.co/settings/tokens](https://huggingface.co/settings/tokens) |
| **Setup** | 1. Create account → 2. New token → 3. Select "Read" permission |
### Google AI (Paid)
| Property | Value |
|----------|-------|
| **Model** | Gemini 2.5 Flash Lite |
| **Cost** | Pay-per-use |
| **API Key URL** | [aistudio.google.com/apikey](https://aistudio.google.com/apikey) |
| **Setup** | 1. Create project → 2. Enable API → 3. Create API key |
## Observability (LangSmith)
Enable LLM tracing and monitoring with [LangSmith](https://smith.langchain.com):
| Property | Value |
|----------|-------|
| **Dashboard** | [smith.langchain.com](https://smith.langchain.com) |
| **Cost** | Free tier available |
| **Features** | Trace LLM calls, latency, token usage, errors |
### Setup
1. Create account at [smith.langchain.com](https://smith.langchain.com)
2. Get your API key from Settings
3. Set environment variables:
```bash
export LANGCHAIN_API_KEY=your_langsmith_api_key
export LANGCHAIN_PROJECT=sherlock # optional, defaults to "sherlock"
```
Or add to `.env` file:
```
LANGCHAIN_API_KEY=your_langsmith_api_key
LANGCHAIN_PROJECT=sherlock
```
Once configured, all LLM calls are automatically traced and visible in the LangSmith dashboard.
## Performance Features
### Streaming Responses
LLM responses are streamed token-by-token for a better user experience. You see the answer as it's being generated, reducing perceived latency.
### Response Caching
Repeated queries are cached for 5 minutes to reduce API costs and improve response times:
| Property | Value |
|----------|-------|
| **TTL** | 5 minutes |
| **Cache Key** | Query + Project + Provider |
| **Indicator** | "_⚡ Cached response_" shown for cached answers |
### Chat Export
Export your conversation history as a PDF file:
1. Click the **📥 Export** button in the chat interface
2. Download the `.pdf` file with all Q&A pairs
3. Includes project name, timestamp, and nicely formatted conversation
## Agent Evaluation
Automated evaluation measures agent quality across different query types.
| Metric | Value |
|--------|-------|
| **Test Cases** | 5 |
| **Pass Rate** | 100% |
| **Keyword Match** | 68% |
| **Avg Latency** | 5.2s |
| **Avg Response** | 1404 chars |
Run evaluation:
```bash
GOOGLE_API_KEY=your_key pytest tests/test_evaluation.py -v -s
```
## Testing
Run all tests:
```bash
HF_TOKEN=your_token GOOGLE_API_KEY=your_key pytest tests/ -v
```
| File | Description |
|------|-------------|
| `test_parsers.py` | Date & action item parsing |
| `test_rag.py` | RAG indexing & search |
| `test_app.py` | Upload & project management |
| `test_integration.py` | LLM provider tests |
| `test_evaluation.py` | Agent quality metrics |
## Project Structure
```
sherlock/
├── app.py # Main Gradio application
├── requirements.txt # Python dependencies
├── README.md # This file
├── assets/
│ ├── logo.png # Project logo
│ ├── logo-transparent-bg.png
│ └── favicon/ # Favicon assets
├── src/
│ ├── __init__.py
│ ├── agent.py # LangGraph AI agent
│ ├── rag.py # ChromaDB RAG system
│ └── parsers.py # Meeting note parsers
├── tests/
│ ├── conftest.py # Pytest fixtures
│ ├── test_parsers.py # Parser tests
│ ├── test_rag.py # RAG tests
│ ├── test_app.py # Upload meeting & project tests
│ ├── test_integration.py # LLM provider tests
│ └── test_evaluation.py # Agent quality evaluation
└── data/ # Sample projects included
├── quantum_computing/
│ └── meetings/ # Quantum Error Correction research
└── covid_prediction/
└── meetings/ # COVID-19 Variant Prediction ML project
```
## Sample Projects
The repository includes two realistic research project examples:
### Quantum Computing (Quantum Error Correction)
- **Team**: 5 researchers (physics, CS, mathematics)
- **Topics**: Surface codes, IBM Quantum hardware, decoder algorithms
- **Example queries**: "What's the decoder latency issue?", "What hardware access do we have?"
### COVID-19 Prediction (Variant Forecasting)
- **Team**: 5 researchers (epidemiology, ML, bioinformatics)
- **Topics**: ESM-2 model, GISAID data, CDC collaboration
- **Example queries**: "What's our model accuracy?", "What are the data quality issues?"
## Unsorted To-Dos
- [ ] Add support for more LLM providers (OpenAI, Anthropic, Ollama)
- [ ] Implement meeting calendar integration (Google Calendar, Outlook)
- [ ] Add user authentication for multi-user support |