Spaces:
Runtime error
Runtime error
Commit
Β·
42d68f2
1
Parent(s):
26dc68b
Added readme
Browse files
README.md
CHANGED
@@ -1,10 +1,63 @@
|
|
1 |
---
|
2 |
-
title:
|
3 |
-
emoji:
|
4 |
-
colorFrom:
|
5 |
-
colorTo:
|
6 |
sdk: docker
|
7 |
pinned: false
|
8 |
---
|
9 |
|
10 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
---
|
2 |
+
title: Paul Graham Essay Bot
|
3 |
+
emoji: π
|
4 |
+
colorFrom: pink
|
5 |
+
colorTo: pink
|
6 |
sdk: docker
|
7 |
pinned: false
|
8 |
---
|
9 |
|
10 |
+
# π Open Source RAG with Hugging Face Enpoints
|
11 |
+
|
12 |
+

|
13 |
+

|
14 |
+

|
15 |
+

|
16 |
+
|
17 |
+
## π About
|
18 |
+
|
19 |
+
Welcome to this **Paul Graham Essay Bot** - a friendly AI-powered system that demonstrates the power of Retrieval Augmented Generation using completely open source models! This application leverages modern AI technology to provide intelligent answers to your questions based on a collection of essays by Paul Graham, covering topics such as programming languages, startup culture, spam filtering, design principles, and the philosophy of hacking and innovation.
|
20 |
+
|
21 |
+
## β¨ Features
|
22 |
+
|
23 |
+
- **Open Source Models**: Powered by NousResearch/Meta-Llama-3.1-8B-Instruct for text generation and Snowflake/snowflake-arctic-embed-m for embeddings
|
24 |
+
- **HuggingFace Integration**: Models deployed as serving endpoints on HuggingFace
|
25 |
+
- **Intelligent Retrieval**: Utilizes RAG (Retrieval Augmented Generation) for accurate and contextual responses
|
26 |
+
- **Fast & Responsive**: Async processing for quick responses even with large document collections
|
27 |
+
- **Content-Focused**: Explore ideas and concepts from the essays, not just information about the author
|
28 |
+
|
29 |
+
## π§ How It Works
|
30 |
+
|
31 |
+
Behind the scenes, this application:
|
32 |
+
|
33 |
+
1. **Loads and Processes Documents**: Breaks down essay content into manageable chunks
|
34 |
+
2. **Creates Embeddings**: Converts text into numerical representations using Snowflake/snowflake-arctic-embed-m
|
35 |
+
3. **Builds a Vector Database**: Stores the embeddings in a FAISS vector store for efficient retrieval
|
36 |
+
4. **Retrieves Relevant Content**: Finds the most relevant essay sections based on your questions
|
37 |
+
5. **Generates Thoughtful Responses**: Uses Meta-Llama-3.1-8B-Instruct to craft helpful answers based on the retrieved content
|
38 |
+
|
39 |
+
## π€ Example Questions
|
40 |
+
|
41 |
+
- "What are some key strategies for starting a successful startup?"
|
42 |
+
- "Why is Silicon Valley considered a hub for tech innovation?"
|
43 |
+
- "How can good design improve user experience in technology products?"
|
44 |
+
|
45 |
+
## π οΈ Technical Details
|
46 |
+
|
47 |
+
This application uses:
|
48 |
+
- **LangChain**: For document processing and orchestrating the RAG pipeline
|
49 |
+
- **FAISS**: For efficient vector similarity search
|
50 |
+
- **HuggingFace Endpoints**:
|
51 |
+
- NousResearch/Meta-Llama-3.1-8B-Instruct for text generation
|
52 |
+
- Snowflake/snowflake-arctic-embed-m for embeddings
|
53 |
+
- **Chainlit**: For the interactive chat interface
|
54 |
+
- **Hugging Face Spaces**: For deployment and hosting
|
55 |
+
|
56 |
+
Happy exploring the fascinating content with open source AI! πβ¨
|
57 |
+
|
58 |
+
### HuggingFace Endpoint Usage
|
59 |
+
LLM Endpoint
|
60 |
+

|
61 |
+
|
62 |
+
Embedding Endpoint
|
63 |
+

|