Spaces:
Running
Running
Update README.md
Browse files
README.md
CHANGED
|
@@ -41,11 +41,11 @@ This app uses:
|
|
| 41 |
* **Large file handling**: If a file exceeds the soft cap, training will automatically use only the top 10K rows for processing
|
| 42 |
* This optimization speeds up the training process and returns model IDs and responses faster
|
| 43 |
|
| 44 |
-
###
|
| 45 |
|
| 46 |
Chat like a normal assistant — ask questions, discuss data, clarify tasks.
|
| 47 |
|
| 48 |
-
###
|
| 49 |
|
| 50 |
Upload any structured CSV and ask:
|
| 51 |
|
|
@@ -59,7 +59,7 @@ The agent will produce:
|
|
| 59 |
* Data quality issues
|
| 60 |
* Recommendations
|
| 61 |
|
| 62 |
-
###
|
| 63 |
|
| 64 |
Ask:
|
| 65 |
|
|
@@ -71,7 +71,7 @@ The agent will automatically:
|
|
| 71 |
* Evaluate metrics (Accuracy, F1, ROC-AUC…)
|
| 72 |
* Summarize key performance signals
|
| 73 |
|
| 74 |
-
###
|
| 75 |
|
| 76 |
Ask:
|
| 77 |
|
|
@@ -83,7 +83,7 @@ The MCP backend handles deployment and returns:
|
|
| 83 |
* Example Python inference code
|
| 84 |
* Example curl usage
|
| 85 |
|
| 86 |
-
###
|
| 87 |
|
| 88 |
Every response includes:
|
| 89 |
|
|
@@ -93,7 +93,7 @@ Every response includes:
|
|
| 93 |
* Python + curl examples outside the collapsible
|
| 94 |
* Tools, parameters, and logs inside a `<details>` block
|
| 95 |
|
| 96 |
-
###
|
| 97 |
|
| 98 |
All assistant messages stream token-by-token for fast UX.
|
| 99 |
|
|
@@ -156,32 +156,6 @@ python app.py
|
|
| 156 |
|
| 157 |
|
| 158 |
|
| 159 |
-
## ⚙️ Configuration
|
| 160 |
-
|
| 161 |
-
### 🔧 Environment Variables
|
| 162 |
-
|
| 163 |
-
| Variable | Description |
|
| 164 |
-
| - | |
|
| 165 |
-
| `OPENAI_API_KEY` | Your OpenAI key for GPT-5 / GPT-5-mini |
|
| 166 |
-
| `MCP_SERVER_URL` | URL of the MCP backend handling analysis/training/deployment |
|
| 167 |
-
|
| 168 |
-
### 🧩 Models
|
| 169 |
-
|
| 170 |
-
You can change:
|
| 171 |
-
|
| 172 |
-
```python
|
| 173 |
-
MODEL = "gpt-5-mini"
|
| 174 |
-
```
|
| 175 |
-
|
| 176 |
-
to:
|
| 177 |
-
|
| 178 |
-
```python
|
| 179 |
-
MODEL = "gpt-5"
|
| 180 |
-
```
|
| 181 |
-
|
| 182 |
-
for stronger reasoning on tool outputs.
|
| 183 |
-
|
| 184 |
-
|
| 185 |
|
| 186 |
## 🧬 Architecture
|
| 187 |
|
|
@@ -195,60 +169,6 @@ User → Gradio Chat UI
|
|
| 195 |
```
|
| 196 |
|
| 197 |
|
| 198 |
-
|
| 199 |
-
## 🧪 Example User Flow
|
| 200 |
-
|
| 201 |
-
### 1️⃣ Upload CSV
|
| 202 |
-
|
| 203 |
-
The app generates a public endpoint for the MCP tool to access.
|
| 204 |
-
|
| 205 |
-
### 2️⃣ Ask:
|
| 206 |
-
|
| 207 |
-
```
|
| 208 |
-
Analyze this dataset
|
| 209 |
-
```
|
| 210 |
-
|
| 211 |
-
### 3️⃣ Ask:
|
| 212 |
-
|
| 213 |
-
```
|
| 214 |
-
Train a model
|
| 215 |
-
```
|
| 216 |
-
|
| 217 |
-
### 4️⃣ Ask:
|
| 218 |
-
|
| 219 |
-
```
|
| 220 |
-
Deploy the model
|
| 221 |
-
```
|
| 222 |
-
|
| 223 |
-
### 5️⃣ Use Example Code
|
| 224 |
-
|
| 225 |
-
The assistant outputs example usable code:
|
| 226 |
-
|
| 227 |
-
**Python**
|
| 228 |
-
|
| 229 |
-
```python
|
| 230 |
-
import requests
|
| 231 |
-
url = "https://YOUR_ENDPOINT"
|
| 232 |
-
payload = {...}
|
| 233 |
-
print(requests.post(url, json=payload).json())
|
| 234 |
-
```
|
| 235 |
-
|
| 236 |
-
**curl**
|
| 237 |
-
|
| 238 |
-
```bash
|
| 239 |
-
curl -X POST https://YOUR_ENDPOINT -d '{...}'
|
| 240 |
-
```
|
| 241 |
-
|
| 242 |
-
|
| 243 |
-
## 📝 System Prompts
|
| 244 |
-
|
| 245 |
-
The app uses two prompts:
|
| 246 |
-
|
| 247 |
-
* **General Chat Prompt** — for simple conversations
|
| 248 |
-
* **Main MLOps Prompt** — for analysis, training, evaluation & deployment
|
| 249 |
-
|
| 250 |
-
Both enforce clean markdown, structured summaries, and technical transparency inside a collapsible block.
|
| 251 |
-
|
| 252 |
## 🛠️ Tech Stack
|
| 253 |
|
| 254 |
* Python 3.10+
|
|
|
|
| 41 |
* **Large file handling**: If a file exceeds the soft cap, training will automatically use only the top 10K rows for processing
|
| 42 |
* This optimization speeds up the training process and returns model IDs and responses faster
|
| 43 |
|
| 44 |
+
### 1. Natural Chat Interface
|
| 45 |
|
| 46 |
Chat like a normal assistant — ask questions, discuss data, clarify tasks.
|
| 47 |
|
| 48 |
+
### 2. Automatic CSV Analysis
|
| 49 |
|
| 50 |
Upload any structured CSV and ask:
|
| 51 |
|
|
|
|
| 59 |
* Data quality issues
|
| 60 |
* Recommendations
|
| 61 |
|
| 62 |
+
### 3. Model Training
|
| 63 |
|
| 64 |
Ask:
|
| 65 |
|
|
|
|
| 71 |
* Evaluate metrics (Accuracy, F1, ROC-AUC…)
|
| 72 |
* Summarize key performance signals
|
| 73 |
|
| 74 |
+
### 4. Automated Deployment
|
| 75 |
|
| 76 |
Ask:
|
| 77 |
|
|
|
|
| 83 |
* Example Python inference code
|
| 84 |
* Example curl usage
|
| 85 |
|
| 86 |
+
### 5. Clean, Structured Responses
|
| 87 |
|
| 88 |
Every response includes:
|
| 89 |
|
|
|
|
| 93 |
* Python + curl examples outside the collapsible
|
| 94 |
* Tools, parameters, and logs inside a `<details>` block
|
| 95 |
|
| 96 |
+
### 6. Full Streaming Output
|
| 97 |
|
| 98 |
All assistant messages stream token-by-token for fast UX.
|
| 99 |
|
|
|
|
| 156 |
|
| 157 |
|
| 158 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 159 |
|
| 160 |
## 🧬 Architecture
|
| 161 |
|
|
|
|
| 169 |
```
|
| 170 |
|
| 171 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 172 |
## 🛠️ Tech Stack
|
| 173 |
|
| 174 |
* Python 3.10+
|