Add demo disclaimers to clarify simulated statistics and features
Browse files
app.py
CHANGED
|
@@ -193,18 +193,24 @@ def format_response_with_metadata(response: str, domain: str, question: str, gen
|
|
| 193 |
# Format metadata display
|
| 194 |
metadata = f"""
|
| 195 |
## π― Response Quality Metrics
|
|
|
|
| 196 |
|
| 197 |
**Confidence Score:** {confidence:.1%} {'π’' if confidence > 0.8 else 'π‘' if confidence > 0.6 else 'π΄'}
|
| 198 |
-
**Domain:** {DOMAINS[domain]['name']} ({DOMAINS[domain]['tiles']} verified tiles)
|
| 199 |
**Generation Time:** {gen_time:.2f}s
|
| 200 |
-
**Hallucination Risk:** {hallucination['risk_level']} ({hallucination['risk_score']:.1%})
|
|
|
|
|
|
|
| 201 |
|
| 202 |
---
|
| 203 |
|
| 204 |
## π Knowledge Tiles Retrieved
|
|
|
|
| 205 |
|
| 206 |
{tiles}
|
| 207 |
|
|
|
|
|
|
|
| 208 |
---
|
| 209 |
|
| 210 |
## π Verification Markers
|
|
@@ -215,9 +221,12 @@ def format_response_with_metadata(response: str, domain: str, question: str, gen
|
|
| 215 |
---
|
| 216 |
|
| 217 |
## β οΈ Hallucination Detection
|
|
|
|
| 218 |
|
| 219 |
{chr(10).join(f"- {flag}" for flag in hallucination['flags'])}
|
| 220 |
|
|
|
|
|
|
|
| 221 |
---
|
| 222 |
|
| 223 |
## π‘ About NullAI
|
|
@@ -228,7 +237,9 @@ NullAI uses a revolutionary **Knowledge Tile System** where each piece of inform
|
|
| 228 |
3. Assigned spatial coordinates for semantic relationships
|
| 229 |
4. Continuously monitored for accuracy and relevance
|
| 230 |
|
| 231 |
-
This
|
|
|
|
|
|
|
| 232 |
"""
|
| 233 |
|
| 234 |
return response, metadata
|
|
@@ -417,11 +428,14 @@ with gr.Blocks(title="NullAI - Knowledge Reasoning System", css=custom_css, them
|
|
| 417 |
with gr.Column(scale=1):
|
| 418 |
gr.Markdown("""
|
| 419 |
### π System Statistics
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 420 |
|
| 421 |
-
|
| 422 |
-
**Expert Contributors:** 342
|
| 423 |
-
**Domains Covered:** 55+
|
| 424 |
-
**Average Confidence:** 87.3%
|
| 425 |
|
| 426 |
### β¨ What Makes NullAI Different?
|
| 427 |
|
|
@@ -489,10 +503,26 @@ with gr.Blocks(title="NullAI - Knowledge Reasoning System", css=custom_css, them
|
|
| 489 |
|
| 490 |
**Model:** DeepSeek R1 Distill Qwen 7B (8-bit quantized)
|
| 491 |
**License:** Apache 2.0
|
| 492 |
-
**Status:**
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 493 |
|
| 494 |
-
*
|
| 495 |
-
expert verification system, and real-time tile retrieval.*
|
| 496 |
""")
|
| 497 |
|
| 498 |
|
|
|
|
| 193 |
# Format metadata display
|
| 194 |
metadata = f"""
|
| 195 |
## π― Response Quality Metrics
|
| 196 |
+
***(Simulated for Demo)***
|
| 197 |
|
| 198 |
**Confidence Score:** {confidence:.1%} {'π’' if confidence > 0.8 else 'π‘' if confidence > 0.6 else 'π΄'}
|
| 199 |
+
**Domain:** {DOMAINS[domain]['name']} ({DOMAINS[domain]['tiles']} verified tiles*)
|
| 200 |
**Generation Time:** {gen_time:.2f}s
|
| 201 |
+
**Hallucination Risk:** {hallucination['risk_level']} ({hallucination['risk_score']:.1%})*
|
| 202 |
+
|
| 203 |
+
*_Simulated metrics - Production system calculates from actual knowledge base_
|
| 204 |
|
| 205 |
---
|
| 206 |
|
| 207 |
## π Knowledge Tiles Retrieved
|
| 208 |
+
***(Demo - Randomly Generated)***
|
| 209 |
|
| 210 |
{tiles}
|
| 211 |
|
| 212 |
+
*_In production, these would be actual tiles from the knowledge database with real ORCID verification_
|
| 213 |
+
|
| 214 |
---
|
| 215 |
|
| 216 |
## π Verification Markers
|
|
|
|
| 221 |
---
|
| 222 |
|
| 223 |
## β οΈ Hallucination Detection
|
| 224 |
+
***(Basic Pattern Matching - Demo)***
|
| 225 |
|
| 226 |
{chr(10).join(f"- {flag}" for flag in hallucination['flags'])}
|
| 227 |
|
| 228 |
+
*_Production system uses advanced semantic analysis and Judge System (Alpha/Beta Lobes)_
|
| 229 |
+
|
| 230 |
---
|
| 231 |
|
| 232 |
## π‘ About NullAI
|
|
|
|
| 237 |
3. Assigned spatial coordinates for semantic relationships
|
| 238 |
4. Continuously monitored for accuracy and relevance
|
| 239 |
|
| 240 |
+
**This Demo:** Uses DeepSeek R1 (7B) with 8-bit quantization. Features are simulated to showcase the concept.
|
| 241 |
+
|
| 242 |
+
**Production System:** Connects to real knowledge base with actual expert verification and spatial encoding.
|
| 243 |
"""
|
| 244 |
|
| 245 |
return response, metadata
|
|
|
|
| 428 |
with gr.Column(scale=1):
|
| 429 |
gr.Markdown("""
|
| 430 |
### π System Statistics
|
| 431 |
+
***(Demo Values - For Illustration)***
|
| 432 |
+
|
| 433 |
+
**Total Knowledge Tiles:** 16,503*
|
| 434 |
+
**Expert Contributors:** 342*
|
| 435 |
+
**Domains Covered:** 55+*
|
| 436 |
+
**Average Confidence:** 87.3%*
|
| 437 |
|
| 438 |
+
*_Simulated statistics for demonstration purposes. Production system would display real-time data from connected database._
|
|
|
|
|
|
|
|
|
|
| 439 |
|
| 440 |
### β¨ What Makes NullAI Different?
|
| 441 |
|
|
|
|
| 503 |
|
| 504 |
**Model:** DeepSeek R1 Distill Qwen 7B (8-bit quantized)
|
| 505 |
**License:** Apache 2.0
|
| 506 |
+
**Status:** π¬ **Concept Demonstration / Prototype**
|
| 507 |
+
|
| 508 |
+
### β οΈ Important Notice
|
| 509 |
+
|
| 510 |
+
This is a **demonstration interface** showcasing NullAI's innovative architecture and features.
|
| 511 |
+
|
| 512 |
+
**Simulated Features in this Demo:**
|
| 513 |
+
- Knowledge tile IDs and verification badges (randomly generated)
|
| 514 |
+
- Expert contributor statistics (sample values)
|
| 515 |
+
- Confidence scores (heuristic-based approximation)
|
| 516 |
+
- Hallucination detection (basic pattern matching)
|
| 517 |
+
|
| 518 |
+
**Production System Includes:**
|
| 519 |
+
- Real-time connection to knowledge tile database
|
| 520 |
+
- Actual ORCID-authenticated expert verification
|
| 521 |
+
- True multi-dimensional spatial coordinate system
|
| 522 |
+
- Advanced Judge System (Alpha/Beta Lobe) with full validation pipeline
|
| 523 |
+
- Live hallucination detection with deep semantic analysis
|
| 524 |
|
| 525 |
+
*For production deployment with full backend integration, contact the development team.*
|
|
|
|
| 526 |
""")
|
| 527 |
|
| 528 |
|