rishik1111 commited on
Commit
f29226d
Β·
1 Parent(s): 5bb2554

fix(docs): resolve Mermaid syntax error by using standard class assignments for GitHub markdown renderer

Browse files
Files changed (1) hide show
  1. README.md +38 -29
README.md CHANGED
@@ -48,57 +48,66 @@ The active runtime deployment loads **148,854 in-memory FAISS vectors** across 3
48
 
49
  ```mermaid
50
  graph LR
51
- %% Custom Styling Classes
52
- classDef inputStyle fill:#1E293B,stroke:#38BDF8,stroke-width:2px,color:#F8FAFC;
53
- classDef sttStyle fill:#0F172A,stroke:#818CF8,stroke-width:2px,color:#F8FAFC;
54
- classDef guardStyle fill:#311B92,stroke:#B388FF,stroke-width:2px,color:#FFFFFF;
55
- classDef cacheStyle fill:#064E3B,stroke:#34D399,stroke-width:2px,color:#F8FAFC;
56
- classDef faissStyle fill:#164E63,stroke:#22D3EE,stroke-width:2px,color:#F8FAFC;
57
- classDef synthStyle fill:#4C1D95,stroke:#C084FC,stroke-width:2px,color:#F8FAFC;
58
- classDef outStyle fill:#065F46,stroke:#10B981,stroke-width:2px,color:#FFFFFF;
59
- classDef blockStyle fill:#881337,stroke:#F43F5E,stroke-width:2px,color:#FFFFFF;
60
-
61
  subgraph PATH1 ["πŸŽ™οΈ Path 1: Audio & Text Ingestion"]
62
- A[Audio Upload / Microphone Stream] ::: inputStyle --> STT[Sarvam Saaras STT + ffmpeg 16kHz] ::: sttStyle
63
- T[Raw Text Input Bypass] ::: inputStyle --> ROUTER[Language Resolution Router] ::: sttStyle
64
  STT --> ROUTER
65
  end
66
 
67
  subgraph PATH2 ["πŸ›‘οΈ Path 2: 4-Tier Security Shield"]
68
- ROUTER --> G1[Tier-1 Stem Regex + Obfuscation Decoder] ::: guardStyle
69
- G1 -- Safe --> G2[Tier-2 Meta Prompt-Guard 86M DPI] ::: guardStyle
70
- G2 -- Safe --> G3[Tier-3 6-Class Query Intent Gate] ::: guardStyle
71
- G3 -- Factual --> G4[Tier-4 Own-Lang Centroid Distance Gate] ::: guardStyle
72
  end
73
 
74
  subgraph PATH3 ["⚑ Path 3: Sub-0.5ms Hot Cache Fast-Path"]
75
- G4 -- On-Topic --> CACHE{Hot Cache Lookup} ::: cacheStyle
76
- CACHE -- "Hit (<0.5ms)" --> FAST_OUT[Zero-Latency Response] ::: outStyle
77
  end
78
 
79
  subgraph PATH4 ["πŸ”Ž Path 4: Hybrid Vector Retrieval Engine"]
80
- CACHE -- "Miss" --> EMB[multilingual-e5-small INT8 ONNX] ::: faissStyle
81
- EMB --> FAISS[Parallel FAISS HNSW Native & LongDoc Search] ::: faissStyle
82
- FAISS --> RRF[Reciprocal Rank Fusion k=60] ::: faissStyle
83
- RRF --> BM25[Adaptive Script-Aware BM25 Fusion] ::: faissStyle
84
- BM25 --> GATE{Disqualification Gate} ::: faissStyle
85
  end
86
 
87
  subgraph PATH5 ["🧠 Path 5: Deterministic Synthesis & Grounding"]
88
- GATE -- High Relevance --> IPI[Batched Prompt-Guard IPI Context Scan] ::: synthStyle
89
- IPI -- Clean Chunks --> SYNTH[Continuous TextRank + SVD Energy Synthesis] ::: synthStyle
90
- SYNTH --> GROUND[Post-Gen Grounding Overlap Verifier] ::: synthStyle
91
- GROUND -- Grounded --> FINAL_OUT[JSON Response + 9-Stage Telemetry] ::: outStyle
92
  end
93
 
94
  %% Rejection Routing
95
- G1 -- Blocked --> REJECT[Declined Response: Safety Violation] ::: blockStyle
96
  G2 -- Injected --> REJECT
97
  G3 -- Non-Factual --> REJECT
98
  G4 -- Off-Topic --> REJECT
99
- GATE -- Score < 0.35 --> DECLINE[Declined Response: Insufficient Info] ::: blockStyle
100
  IPI -- Poisoned --> REJECT
101
  GROUND -- Ungrounded --> DECLINE
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
102
  ```
103
 
104
  ### πŸ›£οΈ Swimlane Pipeline Execution Breakdown
 
48
 
49
  ```mermaid
50
  graph LR
 
 
 
 
 
 
 
 
 
 
51
  subgraph PATH1 ["πŸŽ™οΈ Path 1: Audio & Text Ingestion"]
52
+ A[Audio Upload / Microphone Stream] --> STT[Sarvam Saaras STT + ffmpeg 16kHz]
53
+ T[Raw Text Input Bypass] --> ROUTER[Language Resolution Router]
54
  STT --> ROUTER
55
  end
56
 
57
  subgraph PATH2 ["πŸ›‘οΈ Path 2: 4-Tier Security Shield"]
58
+ ROUTER --> G1[Tier-1 Stem Regex + Obfuscation Decoder]
59
+ G1 -- Safe --> G2[Tier-2 Meta Prompt-Guard 86M DPI]
60
+ G2 -- Safe --> G3[Tier-3 6-Class Query Intent Gate]
61
+ G3 -- Factual --> G4[Tier-4 Own-Lang Centroid Distance Gate]
62
  end
63
 
64
  subgraph PATH3 ["⚑ Path 3: Sub-0.5ms Hot Cache Fast-Path"]
65
+ G4 -- On-Topic --> CACHE{Hot Cache Lookup}
66
+ CACHE -- "Hit (<0.5ms)" --> FAST_OUT[Zero-Latency Response]
67
  end
68
 
69
  subgraph PATH4 ["πŸ”Ž Path 4: Hybrid Vector Retrieval Engine"]
70
+ CACHE -- "Miss" --> EMB[multilingual-e5-small INT8 ONNX]
71
+ EMB --> FAISS[Parallel FAISS HNSW Native & LongDoc Search]
72
+ FAISS --> RRF[Reciprocal Rank Fusion k=60]
73
+ RRF --> BM25[Adaptive Script-Aware BM25 Fusion]
74
+ BM25 --> GATE{Disqualification Gate}
75
  end
76
 
77
  subgraph PATH5 ["🧠 Path 5: Deterministic Synthesis & Grounding"]
78
+ GATE -- High Relevance --> IPI[Batched Prompt-Guard IPI Context Scan]
79
+ IPI -- Clean Chunks --> SYNTH[Continuous TextRank + SVD Energy Synthesis]
80
+ SYNTH --> GROUND[Post-Gen Grounding Overlap Verifier]
81
+ GROUND -- Grounded --> FINAL_OUT[JSON Response + 9-Stage Telemetry]
82
  end
83
 
84
  %% Rejection Routing
85
+ G1 -- Blocked --> REJECT[Declined Response: Safety Violation]
86
  G2 -- Injected --> REJECT
87
  G3 -- Non-Factual --> REJECT
88
  G4 -- Off-Topic --> REJECT
89
+ GATE -- Score < 0.35 --> DECLINE[Declined Response: Insufficient Info]
90
  IPI -- Poisoned --> REJECT
91
  GROUND -- Ungrounded --> DECLINE
92
+
93
+ %% Custom Styling Classes
94
+ classDef inputStyle fill:#1E293B,stroke:#38BDF8,stroke-width:2px,color:#F8FAFC;
95
+ classDef sttStyle fill:#0F172A,stroke:#818CF8,stroke-width:2px,color:#F8FAFC;
96
+ classDef guardStyle fill:#311B92,stroke:#B388FF,stroke-width:2px,color:#FFFFFF;
97
+ classDef cacheStyle fill:#064E3B,stroke:#34D399,stroke-width:2px,color:#F8FAFC;
98
+ classDef faissStyle fill:#164E63,stroke:#22D3EE,stroke-width:2px,color:#F8FAFC;
99
+ classDef synthStyle fill:#4C1D95,stroke:#C084FC,stroke-width:2px,color:#F8FAFC;
100
+ classDef outStyle fill:#065F46,stroke:#10B981,stroke-width:2px,color:#FFFFFF;
101
+ classDef blockStyle fill:#881337,stroke:#F43F5E,stroke-width:2px,color:#FFFFFF;
102
+
103
+ class A,T inputStyle;
104
+ class STT,ROUTER sttStyle;
105
+ class G1,G2,G3,G4 guardStyle;
106
+ class CACHE cacheStyle;
107
+ class EMB,FAISS,RRF,BM25,GATE faissStyle;
108
+ class IPI,SYNTH,GROUND synthStyle;
109
+ class FAST_OUT,FINAL_OUT outStyle;
110
+ class REJECT,DECLINE blockStyle;
111
  ```
112
 
113
  ### πŸ›£οΈ Swimlane Pipeline Execution Breakdown