Spaces:
Running on Zero
Running on Zero
Update app.py
Browse files
app.py
CHANGED
|
@@ -138,34 +138,170 @@ def save_analysis(r1, r2, r3, r4):
|
|
| 138 |
|
| 139 |
CSS = """
|
| 140 |
@import url('https://fonts.googleapis.com/css2?family=Syne:wght@400;700;800&family=DM+Mono:wght@400;500&display=swap');
|
| 141 |
-
|
| 142 |
-
|
| 143 |
-
|
| 144 |
-
|
| 145 |
-
|
| 146 |
-
|
| 147 |
-
|
| 148 |
-
|
| 149 |
-
|
| 150 |
-
|
| 151 |
-
|
| 152 |
-
|
| 153 |
-
|
| 154 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 155 |
"""
|
| 156 |
|
| 157 |
with gr.Blocks(css=CSS, title="Metabolic Phoenix Framework") as demo:
|
| 158 |
|
| 159 |
gr.HTML("""
|
| 160 |
<div class="hdr">
|
| 161 |
-
<h1>
|
| 162 |
<p class="sub">Injectiv8 · Ms. Nala · Llama-3.3-70B</p>
|
| 163 |
<p class="own">Invented & Owned by Dwayne Anthony Brian Galloway · 2026</p>
|
| 164 |
</div>
|
| 165 |
""")
|
| 166 |
|
| 167 |
pdf_input = gr.File(label="Upload Document", file_types=[".pdf"], type="filepath")
|
| 168 |
-
run_btn = gr.Button("
|
| 169 |
|
| 170 |
with gr.Accordion("Cycle 1 — Fact Ledger", open=True):
|
| 171 |
out1 = gr.Textbox(label="", lines=12, elem_classes=["out"])
|
|
|
|
| 138 |
|
| 139 |
CSS = """
|
| 140 |
@import url('https://fonts.googleapis.com/css2?family=Syne:wght@400;700;800&family=DM+Mono:wght@400;500&display=swap');
|
| 141 |
+
|
| 142 |
+
:root {
|
| 143 |
+
--bg: #030712;
|
| 144 |
+
--surface: #0a0f1e;
|
| 145 |
+
--surface2: #0f1629;
|
| 146 |
+
--border: #1a2544;
|
| 147 |
+
--accent: #00CFFF;
|
| 148 |
+
--accent2: #FFE500;
|
| 149 |
+
--accent3: #0066FF;
|
| 150 |
+
--text: #E8F4FF;
|
| 151 |
+
--muted: #4A6080;
|
| 152 |
+
--r: 8px;
|
| 153 |
+
}
|
| 154 |
+
|
| 155 |
+
body, .gradio-container {
|
| 156 |
+
background: var(--bg) !important;
|
| 157 |
+
font-family: 'Syne', sans-serif !important;
|
| 158 |
+
color: var(--text) !important;
|
| 159 |
+
}
|
| 160 |
+
|
| 161 |
+
.hdr {
|
| 162 |
+
text-align: center;
|
| 163 |
+
padding: 2.4rem 1rem 1.6rem;
|
| 164 |
+
border-bottom: 1px solid var(--border);
|
| 165 |
+
background:
|
| 166 |
+
radial-gradient(ellipse at 30% 50%, rgba(0,102,255,0.12) 0%, transparent 60%),
|
| 167 |
+
radial-gradient(ellipse at 70% 50%, rgba(0,207,255,0.08) 0%, transparent 60%);
|
| 168 |
+
}
|
| 169 |
+
.hdr h1 {
|
| 170 |
+
font-size: 2.2rem;
|
| 171 |
+
font-weight: 800;
|
| 172 |
+
letter-spacing: -0.04em;
|
| 173 |
+
background: linear-gradient(135deg, var(--accent) 0%, var(--accent2) 100%);
|
| 174 |
+
-webkit-background-clip: text;
|
| 175 |
+
-webkit-text-fill-color: transparent;
|
| 176 |
+
margin: 0 0 0.3rem;
|
| 177 |
+
}
|
| 178 |
+
.hdr .sub {
|
| 179 |
+
color: var(--muted);
|
| 180 |
+
font-family: 'DM Mono', monospace;
|
| 181 |
+
font-size: .75rem;
|
| 182 |
+
letter-spacing: .06em;
|
| 183 |
+
}
|
| 184 |
+
.hdr .own {
|
| 185 |
+
color: var(--accent2);
|
| 186 |
+
font-family: 'DM Mono', monospace;
|
| 187 |
+
font-size: .68rem;
|
| 188 |
+
margin-top: .3rem;
|
| 189 |
+
letter-spacing: .1em;
|
| 190 |
+
text-transform: uppercase;
|
| 191 |
+
}
|
| 192 |
+
|
| 193 |
+
.tab-nav button {
|
| 194 |
+
background: transparent !important;
|
| 195 |
+
color: var(--muted) !important;
|
| 196 |
+
border: 1px solid transparent !important;
|
| 197 |
+
border-radius: var(--r) !important;
|
| 198 |
+
font-family: 'Syne', sans-serif !important;
|
| 199 |
+
font-weight: 700 !important;
|
| 200 |
+
font-size: 0.82rem !important;
|
| 201 |
+
padding: 0.5rem 1rem !important;
|
| 202 |
+
transition: all .18s !important;
|
| 203 |
+
}
|
| 204 |
+
.tab-nav button.selected {
|
| 205 |
+
background: var(--surface2) !important;
|
| 206 |
+
color: var(--accent) !important;
|
| 207 |
+
border-color: var(--accent3) !important;
|
| 208 |
+
}
|
| 209 |
+
.tab-nav button:hover { color: var(--text) !important; }
|
| 210 |
+
|
| 211 |
+
input[type=text], textarea {
|
| 212 |
+
background: var(--surface) !important;
|
| 213 |
+
border: 1px solid var(--border) !important;
|
| 214 |
+
border-radius: var(--r) !important;
|
| 215 |
+
color: var(--text) !important;
|
| 216 |
+
font-family: 'DM Mono', monospace !important;
|
| 217 |
+
font-size: .86rem !important;
|
| 218 |
+
padding: .6rem .85rem !important;
|
| 219 |
+
transition: border-color .18s !important;
|
| 220 |
+
}
|
| 221 |
+
input[type=text]:focus, textarea:focus {
|
| 222 |
+
border-color: var(--accent) !important;
|
| 223 |
+
outline: none !important;
|
| 224 |
+
box-shadow: 0 0 0 3px rgba(0,207,255,.12) !important;
|
| 225 |
+
}
|
| 226 |
+
|
| 227 |
+
label > span:first-child {
|
| 228 |
+
color: var(--muted) !important;
|
| 229 |
+
font-family: 'DM Mono', monospace !important;
|
| 230 |
+
font-size: .7rem !important;
|
| 231 |
+
letter-spacing: .08em !important;
|
| 232 |
+
text-transform: uppercase !important;
|
| 233 |
+
}
|
| 234 |
+
|
| 235 |
+
button.primary {
|
| 236 |
+
background: linear-gradient(135deg, var(--accent3), var(--accent)) !important;
|
| 237 |
+
color: #030712 !important;
|
| 238 |
+
border: none !important;
|
| 239 |
+
border-radius: var(--r) !important;
|
| 240 |
+
font-family: 'Syne', sans-serif !important;
|
| 241 |
+
font-weight: 800 !important;
|
| 242 |
+
font-size: .92rem !important;
|
| 243 |
+
padding: .75rem 2.8rem !important;
|
| 244 |
+
cursor: pointer !important;
|
| 245 |
+
transition: opacity .15s, transform .15s !important;
|
| 246 |
+
letter-spacing: .04em !important;
|
| 247 |
+
}
|
| 248 |
+
button.primary:hover {
|
| 249 |
+
opacity: .88 !important;
|
| 250 |
+
transform: translateY(-1px) !important;
|
| 251 |
+
}
|
| 252 |
+
|
| 253 |
+
button.secondary {
|
| 254 |
+
background: var(--surface2) !important;
|
| 255 |
+
color: var(--accent2) !important;
|
| 256 |
+
border: 1px solid var(--accent3) !important;
|
| 257 |
+
border-radius: var(--r) !important;
|
| 258 |
+
font-family: 'Syne', sans-serif !important;
|
| 259 |
+
font-weight: 700 !important;
|
| 260 |
+
font-size: .8rem !important;
|
| 261 |
+
padding: .5rem 1.2rem !important;
|
| 262 |
+
cursor: pointer !important;
|
| 263 |
+
transition: all .15s !important;
|
| 264 |
+
}
|
| 265 |
+
button.secondary:hover {
|
| 266 |
+
background: var(--accent3) !important;
|
| 267 |
+
color: #030712 !important;
|
| 268 |
+
}
|
| 269 |
+
|
| 270 |
+
.out textarea {
|
| 271 |
+
background: #020510 !important;
|
| 272 |
+
border: 1px solid var(--border) !important;
|
| 273 |
+
border-left: 3px solid var(--accent) !important;
|
| 274 |
+
border-radius: 0 var(--r) var(--r) 0 !important;
|
| 275 |
+
font-family: 'DM Mono', monospace !important;
|
| 276 |
+
font-size: .84rem !important;
|
| 277 |
+
line-height: 1.7 !important;
|
| 278 |
+
color: var(--text) !important;
|
| 279 |
+
}
|
| 280 |
+
|
| 281 |
+
.foot {
|
| 282 |
+
text-align: center;
|
| 283 |
+
padding: 1.5rem;
|
| 284 |
+
color: var(--muted);
|
| 285 |
+
font-family: 'DM Mono', monospace;
|
| 286 |
+
font-size: .68rem;
|
| 287 |
+
border-top: 1px solid var(--border);
|
| 288 |
+
margin-top: 2rem;
|
| 289 |
+
letter-spacing: .05em;
|
| 290 |
+
}
|
| 291 |
"""
|
| 292 |
|
| 293 |
with gr.Blocks(css=CSS, title="Metabolic Phoenix Framework") as demo:
|
| 294 |
|
| 295 |
gr.HTML("""
|
| 296 |
<div class="hdr">
|
| 297 |
+
<h1>⚡ The Metabolic Phoenix Framework</h1>
|
| 298 |
<p class="sub">Injectiv8 · Ms. Nala · Llama-3.3-70B</p>
|
| 299 |
<p class="own">Invented & Owned by Dwayne Anthony Brian Galloway · 2026</p>
|
| 300 |
</div>
|
| 301 |
""")
|
| 302 |
|
| 303 |
pdf_input = gr.File(label="Upload Document", file_types=[".pdf"], type="filepath")
|
| 304 |
+
run_btn = gr.Button("⚡ Analyse", variant="primary")
|
| 305 |
|
| 306 |
with gr.Accordion("Cycle 1 — Fact Ledger", open=True):
|
| 307 |
out1 = gr.Textbox(label="", lines=12, elem_classes=["out"])
|