"use client"; import { useState } from "react"; import { syncDatabase } from "../lib/api"; import { translations, Language } from "../lib/translations"; import { avatarBase64 } from "../lib/avatar"; import { userPhotoBase64 } from "../lib/user_photo"; type Props = { lang: Language; }; export default function SystemInfo({ lang }: Props) { const t = translations[lang]; const [isSyncing, setIsSyncing] = useState(false); const [syncStatus, setSyncStatus] = useState(null); const [debugInfo, setDebugInfo] = useState(""); const [amdUrl, setAmdUrl] = useState(""); const [amdKey, setAmdKey] = useState(""); const [isConnectingAMD, setIsConnectingAMD] = useState(false); const testConnection = async () => { try { const res1 = await fetch("/api/health"); const healthData = await res1.json(); const res2 = await fetch("/api/health/db-status"); const dbData = await res2.json(); setDebugInfo(`Health: ${JSON.stringify(healthData)} | DB: ${JSON.stringify(dbData)}`); } catch (e: any) { setDebugInfo(`Connection Failed: ${e.message}`); } }; const handleSync = async () => { setIsSyncing(true); setSyncStatus("Syncing..."); try { await syncDatabase(); setSyncStatus("Success! Refreshing..."); setTimeout(() => window.location.reload(), 1500); } catch (e) { setSyncStatus("Failed to sync."); console.error(e); } finally { setIsSyncing(false); } }; const handleConnectAMD = async () => { setIsConnectingAMD(true); try { // Simulate validation request to the backend or direct to the node const res = await fetch("/api/health/db-status"); // Just a placeholder for connectivity check if (res.ok) { // In a real app, we'd save this to the backend settings DB localStorage.setItem("AMD_INFERENCE_URL", amdUrl); localStorage.setItem("AMD_API_KEY", amdKey); setSyncStatus("AMD Node Linked Successfully!"); setTimeout(() => setSyncStatus(null), 3000); } } catch (e) { setSyncStatus("Connection failed. Check IP/Key."); } finally { setIsConnectingAMD(false); } }; const techStack = [ { name: "AMD Instinct™", role: "Hardware Acceleration", desc: t.techAMD }, { name: "AMD Developer Cloud", role: "GPU Infrastructure", desc: t.techAMDCloud }, { name: "Llama-3.2-Vision", role: "OCR & Analysis", desc: t.techLlama }, { name: "Qwen-2.5", role: "Reasoning & Coding", desc: t.techQwen }, { name: "FastAPI / Python", role: "Backend Engine", desc: t.techFastAPI }, { name: "Hugging Face Hub", role: "Model Registry", desc: t.techHF }, { name: "Next.js 14 / TS", role: "Frontend Framework", desc: t.techNextJS }, { name: "SQLite", role: "Persistence", desc: "Reliable local database for lightning-fast search." }, ]; const agentTeam = [ { name: t.agentLegal, model: "Gemini 2.5 Flash", desc: t.agentLegalDesc }, { name: t.agentTech, model: "Llama-3.2-Vision (AMD)", desc: t.agentTechDesc }, { name: t.agentStrategy, model: "Qwen-2.5-Coder", desc: t.agentStrategyDesc }, ]; return (
{/* Brand & Personal Bio Section */}
RV

Álvaro Valenzuela Valdés

IT Engineer | CEO @ REW.cl

{t.aboutBio}

📍 Chile | Global Operations
Álvaro Valenzuela { console.log("Avatar load failed, using dynamic placeholder..."); (e.target as HTMLImageElement).src = `https://ui-avatars.com/api/?name=Alvaro+Valenzuela&background=0f172a&color=fff&size=512`; }} />

{lang === "en" ? "Project Founder, Lead Architect & REW Agency CEO" : "Fundador del Proyecto, Arquitecto Líder y CEO de REW Agency"}

{/* Agents Section */}

{lang === "en" ? "Elite Multi-Agent Consensus (AMD Powered)" : "Consenso Multi-Agente de Élite (Potenciado por AMD)"}

{agentTeam.map((agent) => (
{agent.model}

{agent.name}

{agent.desc}

))}
{/* Tech Grid */}
{techStack.map((tech) => (
{tech.role}

{tech.name}

{tech.desc}

))}
{/* Legal & Status */}

System Status: Operational

v1.2.6 | AMD_INSTINCT_ACCELERATED

Licensing & Intellectual Property

Released under MIT License for Hackathon 2026.
© {new Date().getFullYear()} REW Agency Chile. All Rights Reserved.

{/* NEW: AMD GPU Node Monitor (Simulated for Demo) */}
MI300X

📊 AMD Instinct™ Computing Node

Remote Access via AMD Developer Cloud | ROCm™ 6.1 Stack

Active Connection

VRAM Usage

42.8 / 192GB

Power Consumption

345 W

Core Temp

54 °C

Optimal Range

Compute Load

12.4 %

Idle Orchestration

ROCm Driver: 6.1.2
hipBLAS: Enabled
vLLM Container: Ready
{/* NEW: AMD Configuration Settings */}
⚙️

Inference Settings

Manage your private AMD Instinct™ MI300X endpoints

setAmdUrl(e.target.value)} placeholder="http://:8000/v1" className="w-full bg-black/40 border border-white/10 rounded-xl px-4 py-3 text-sm text-white placeholder:text-slate-700 focus:outline-none focus:border-cyan-500/50 transition-all" />
setAmdKey(e.target.value)} placeholder="••••••••••••••••" className="w-full bg-black/40 border border-white/10 rounded-xl px-4 py-3 text-sm text-white placeholder:text-slate-700 focus:outline-none focus:border-cyan-500/50 transition-all" />
{syncStatus && (

{syncStatus}

)}
); }