Fduv commited on
Commit
db219a4
·
verified ·
1 Parent(s): 01c92a0

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +225 -1
README.md CHANGED
@@ -8,6 +8,230 @@ sdk_version: 5.33.0
8
  app_file: app.py
9
  pinned: false
10
  short_description: Application for tracking personal spending habits
 
 
11
  ---
12
 
13
- Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
8
  app_file: app.py
9
  pinned: false
10
  short_description: Application for tracking personal spending habits
11
+ tags:
12
+ - agent-demo-track
13
  ---
14
 
15
+ # GreenSmokeLabs-Expensynth
16
+
17
+ ## Overview
18
+
19
+ GreenSmokeLabs-Expensynth is an AI-powered financial management platform designed to transform the way users track, analyze, and understand their expenses. By leveraging artificial intelligence and natural language processing, the system automatically categorizes transactions, provides financial insights, and offers an intelligent assistant for financial queries.
20
+
21
+ ## System Architecture
22
+
23
+ The application is built on a robust three-tier architecture:
24
+
25
+ ![alt text](image.png)
26
+
27
+ ### Database Schema
28
+
29
+ ![alt text](image-1.png)
30
+
31
+ ## Key Components
32
+
33
+ ### Backend
34
+
35
+ The backend is built with FastAPI and provides the following key services:
36
+
37
+ 1. **Transaction Parsing Service**: Uses CrewAI to analyze and categorize financial transactions.
38
+ 2. **User RAG Service**: Provides question-answering capabilities through Retrieval Augmented Generation.
39
+ 3. **Database Layer**: PostgreSQL for structured data and Vector DB for embeddings.
40
+ 4. **API Endpoints**: RESTful endpoints for all system functionalities.
41
+
42
+ ### Frontend
43
+
44
+ The frontend is a Gradio-based web application with the following features:
45
+
46
+ 1. **Financial Dashboard**: Shows key financial metrics and summaries.
47
+ 2. **Interactive Charts**: Visualizes financial data through various charts and graphs.
48
+ 3. **AI Assistant**: Chat interface for natural language queries about financial data.
49
+
50
+ ### Mobile App
51
+
52
+ A mobile application will provide:
53
+
54
+ 1. Transaction Message Categorization
55
+ 2. Transaction Message Syncing
56
+ 3. Mobile dashboard access
57
+
58
+ ## Installation & Setup
59
+
60
+
61
+ ### Prerequisites
62
+
63
+ - Python 3.10-3.12
64
+ - PostgreSQL
65
+ - Node.js (for optional frontend development)
66
+
67
+
68
+ ### Backend Setup
69
+
70
+
71
+ 1. Clone the repository:
72
+
73
+ ```bash
74
+ git clone https://github.com/yourusername/GreenSmokeLabs-Expensynth.git
75
+ cd GreenSmokeLabs-Expensynth
76
+ ```
77
+
78
+ 2. Set up a Python virtual environment:
79
+
80
+ ```bash
81
+ python -m venv .venv
82
+ source .venv/bin/activate # On Windows: .venv\Scripts\activate
83
+ ```
84
+
85
+ 3. Install backend dependencies:
86
+
87
+ ```bash
88
+ cd backend
89
+ pip install -e .
90
+ ```
91
+
92
+ 4. Configure environment variables:
93
+
94
+ ```bash
95
+ cp .env.example .env
96
+ # Edit .env with your configuration
97
+ ```
98
+
99
+ 5. Run database migrations:
100
+
101
+ ```bash
102
+ alembic upgrade head
103
+ ```
104
+
105
+ 6. Start the backend server:
106
+
107
+ ```bash
108
+ uvicorn green_smoke_labs_expensynth.main:app --reload
109
+ ```
110
+
111
+
112
+ ### Frontend Setup
113
+
114
+
115
+ 1. Install frontend dependencies:
116
+
117
+ ```bash
118
+ cd frontend
119
+ pip install -r requirements.txt
120
+ ```
121
+
122
+ 2. Start the frontend server:
123
+
124
+ ```bash
125
+ python server.py
126
+ ```
127
+
128
+
129
+ ## Usage Guide
130
+
131
+
132
+ ### Transaction Processing
133
+
134
+
135
+ 1. Submit transaction messages through the API:
136
+
137
+ ```bash
138
+ curl -X POST http://localhost:8000/transaction-parsing/parse-transaction \
139
+ -H "Content-Type: application/json" \
140
+ -d '{"transaction_message": "You spent $75.40 at Whole Foods Market on June 10th, 2025"}'
141
+ ```
142
+
143
+
144
+ 2. The system will automatically:
145
+ - Parse the transaction details
146
+ - Categorize the transaction
147
+ - Store it in the database
148
+ - Update the vector embeddings for search
149
+
150
+
151
+ ### Financial Dashboard
152
+
153
+ Access the dashboard at [http://localhost:7860](http://localhost:7860) to:
154
+
155
+ - View financial summaries
156
+ - Explore interactive charts
157
+ - Analyze spending patterns
158
+ - Query your financial data using natural language
159
+
160
+
161
+ ### AI Assistant
162
+
163
+ Use the chatbot interface to ask questions such as:
164
+
165
+ - "What were my biggest expenses last month?"
166
+ - "How has my spending on groceries changed over time?"
167
+ - "What is my current balance?"
168
+
169
+
170
+ ## API Documentation
171
+
172
+
173
+ ### Transaction Parsing API
174
+
175
+ - `POST /transaction-parsing/parse-transaction`: Parse and process a new transaction
176
+ - `GET /transaction-parsing/transactions`: Get all transactions
177
+
178
+
179
+ ### User Query API
180
+ - `POST /bot/query`: Submit a natural language query about financial data
181
+
182
+
183
+ ### Health Check API
184
+ - `GET /health`: Check system health status
185
+
186
+
187
+ ## Technologies Used
188
+
189
+
190
+ - **Backend**:
191
+ - FastAPI
192
+ - SQLAlchemy
193
+ - CrewAI
194
+ - Modal (serverless deployment)
195
+ - Alembic (migrations)
196
+ - Pydantic
197
+ - PostgreSQL
198
+
199
+ - **Frontend**:
200
+ - Gradio
201
+ - Plotly
202
+ - Pandas
203
+
204
+ - **AI & Machine Learning**:
205
+ - Vector Embeddings
206
+ - LLM APIs
207
+ - CrewAI Agents
208
+ - Retrieval Augmented Generation
209
+
210
+
211
+ ## Future Roadmap
212
+
213
+
214
+ 1. Mobile Application Development
215
+ 2. Banking API Integrations
216
+ 3. Advanced Financial Planning Features
217
+ 4. Multi-currency Support
218
+ 5. Budget Management
219
+ 6. Export to Accounting Software
220
+
221
+
222
+ ## Contributors
223
+
224
+
225
+ - Shrijeeth S ([[email protected]](mailto:[email protected]))
226
+ - Sethuram SV ([[email protected]](mailto:[email protected]))
227
+ - Shankar Mahadevan ([[email protected]](mailto:[email protected]))
228
+
229
+
230
+ ## License
231
+
232
+ This project is proprietary and confidential. All rights reserved.
233
+
234
+ ---
235
+
236
+ © 2025 Green Smoke Labs. All rights reserved.
237
+