Skip to content

Ramsi-K/EdgeMind

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

20 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

EdgeMind: 5G-MEC Intelligence Orchestration

๐Ÿ† 5G Edge Computing Showcase Real-time AI orchestration at telecom edge with Strands agent swarms Live Demo

๐ŸŽฏ Project Overview

Problem: Todayโ€™s AI systems trade speed for intelligence. Edge devices process fast but lack complexity; the cloud processes deeply but adds latency. For real-time applicationsโ€”autonomous vehicles, industrial control, or competitive gamingโ€”milliseconds matter.

Solution: EdgeMind brings intelligence to the edge. It deploys Strands-based multi-agent swarms directly at 5G MEC (Multi-access Edge Computing) sites. These agents monitor local metrics, detect performance degradation, and self-orchestrate routing and resource decisionsโ€”all without cloud dependence.

๐Ÿš€ Key Innovation

  • Threshold-Based Orchestration: Monitors latency, CPU/GPU load, and queue depth to trigger intelligent swarm responses
  • MEC-Native Intelligence: Strands agents deployed directly at telecom edge sites near RAN controllers
  • Swarm Coordination: Agents collaborate across MEC sites to balance load without cloud involvement
  • Real-Time Decision Making: Sub-100ms routing decisions for time-critical applications

๐Ÿ—๏ธ Architecture

User Devices (5G) โ†’ MEC Site A (Primary) โ†’ Swarm Coordination โ†’ MEC Sites B & C (Fallback) โ†“ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”‚ MEC Site A (5G Radio Tower) โ”‚ โ”‚ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”‚ โ”‚ โ”‚ Complete Strands Agent Set โ”‚ โ”‚ โ”‚ โ”‚ โ€ข Orchestrator โ€ข Load Balancer โ”‚ โ”‚ โ”‚ โ”‚ โ€ข Resource Mon โ€ข Decision Coordinator โ”‚ โ”‚ โ”‚ โ”‚ โ€ข Cache Manager โ”‚ โ”‚ โ”‚ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ”‚ โ”‚ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”‚ โ”‚ โ”‚ Local MCP Tools โ”‚ โ”‚ โ”‚ โ”‚ โ€ข metrics_monitor โ€ข container_ops โ”‚ โ”‚ โ”‚ โ”‚ โ€ข inference_engine โ€ข telemetry_logger โ”‚ โ”‚ โ”‚ โ”‚ โ€ข memory_sync โ”‚ โ”‚ โ”‚ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ”‚ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ†“ AWS Cloud (Passive Observer) - AgentCore Memory Only - AgentCore Orchestration Only 

๐ŸŽฎ Business Use Cases

Gaming & Esports

  • Real-time NPC dialogue: Device SLM for instant responses
  • Game state analysis: MEC swarm coordination for regional multiplayer
  • Performance analytics: Cloud observability (passive)

Autonomous Vehicles

  • Collision detection: Device SLM for ultra-low latency safety
  • Traffic coordination: MEC orchestrator manages regional traffic flow
  • Fleet analytics: Cloud monitoring and long-term insights

Smart Cities & IoT

  • Sensor processing: Device SLM for immediate responses
  • City-wide coordination: MEC swarm balances infrastructure load
  • Urban planning: Cloud analytics from aggregated MEC data

๐Ÿค– MEC Agent Architecture

Agent Role Deployment
Orchestrator Agent Threshold monitoring & swarm triggering MEC Site Controller
Load Balancer Agent Distribute workload across MEC sites Strands Swarm Member
Resource Monitor Agent Track CPU/GPU/latency metrics Strands Swarm Member
Decision Coordinator Agent Coordinate swarm consensus Strands Swarm Member
Cache Manager Agent Local model and data caching Strands Swarm Member

๐Ÿ› ๏ธ Technology Stack

  • Edge Agents: Strands framework with Claude 3.5 Sonnet integration
  • AI Model: Claude API for real agent coordination (optional for demo)
  • MEC Infrastructure: Docker/Kubernetes on edge compute nodes
  • Dashboard: Streamlit with real-time simulation and dual-mode operation
  • Orchestration: Threshold-based swarm coordination with MCP tools
  • AWS Integration: AgentCore Memory + Orchestration only
  • Communication: Direct MEC-to-MEC networking

๐Ÿ”‘ Claude API Setup (Optional)

For full Strands agent experience:

  1. Get API key: Anthropic Console
  2. Create .env file: ANTHROPIC_API_KEY=your-key-here
  3. Test agents: python tests/run_all_tests.py

Dashboard works without API key in simulation mode!

๐Ÿ“Š Expected Outcomes

  • Sub-100ms decision making for real-time applications
  • Autonomous load balancing without cloud dependency
  • 99.9% availability through MEC site redundancy
  • Intelligent swarm coordination adapting to network conditions

๐Ÿš€ Quick Start

# Clone repository git clone https://github.com/yourusername/mec-inference-routing.git cd mec-inference-routing # Install dependencies pip install -r requirements.txt # Launch the live dashboard streamlit run app.py

๐ŸŽฏ Try the Dashboard:

  1. Normal Operation: See healthy MEC sites (green dots)
  2. Switch to "Threshold Breach": Watch swarm coordination activate
  3. Try "Failover Test": See how system handles MEC site failure
  4. Adjust thresholds: Test different latency/CPU limits

The dashboard shows real-time simulation of your 5G-MEC orchestration system!

๐Ÿ“ Project Structure

mec-inference-routing/ โ”œโ”€โ”€ app.py # Streamlit dashboard entry point โ”œโ”€โ”€ README.md โ”œโ”€โ”€ requirements.txt # Dependencies โ”œโ”€โ”€ generated-diagrams/ # Architecture diagrams (Mermaid) โ”‚ โ”œโ”€โ”€ mec_orchestration_architecture.mmd โ”‚ โ””โ”€โ”€ threshold_breach_sequence.mmd โ”œโ”€โ”€ src/ โ”‚ โ”œโ”€โ”€ agents/ # 5 Strands agents (Orchestrator, Load Balancer, etc.) โ”‚ โ”œโ”€โ”€ swarm/ # Swarm coordination logic โ”‚ โ”œโ”€โ”€ mcp_tools/ # MCP tools (metrics, containers, inference, telemetry) โ”‚ โ”œโ”€โ”€ dashboard/ # Streamlit UI components with dual-mode support โ”‚ โ”œโ”€โ”€ data/ # Data generation and simulation โ”‚ โ”œโ”€โ”€ device/ # Device layer simulation โ”‚ โ””โ”€โ”€ orchestrator/ # Threshold monitoring and orchestration โ”œโ”€โ”€ architecture/ # Consolidated architecture documentation โ”‚ โ”œโ”€โ”€ ARCHITECTURE_GUIDE.md # Comprehensive architecture guide โ”‚ โ”œโ”€โ”€ architecture_decision_records.md # ADRs and design decisions โ”‚ โ””โ”€โ”€ enterprise_aws_deployment.md # AWS deployment architecture โ”œโ”€โ”€ docs/ # Enhanced demo scenarios and technical specs โ”œโ”€โ”€ tests/ # Comprehensive agent and swarm tests โ””โ”€โ”€ demo_data/ # Demo data and session management 

๐Ÿ† 5G Edge Computing Showcase

๐ŸŽฏ What Makes This Special:

  • Real 5G-MEC Architecture: Designed for deployment at radio towers
  • Strands Agent Swarms: 5 specialized agents per MEC site
  • Sub-100ms Performance: Aggressive latency targets for real-time apps
  • Multi-Site Coordination: Intelligent failover between MEC sites
  • Enterprise AWS Integration: Only 2 services (AgentCore Memory + Orchestration)

๐Ÿš€ Live Demo Features:

๐Ÿ”— Interactive Dashboard

  • Dual-Mode Operation: Mock Data Mode (no API key) vs Real Strands Agents Mode (with Claude API)
  • Interactive Dashboard: Real-time MEC orchestration simulation
  • Enhanced Demo Scenarios: Gaming, Automotive, Healthcare, IoT use cases
  • Automated Demo Mode: 15-second scenario transitions with start/stop controls
  • Threshold Testing: Watch swarm activation during overload
  • Failover Scenarios: See how system handles MEC site failures
  • Performance Metrics: Track latency, CPU, GPU, queue depth with scenario-specific patterns
  • Agent Activity: Live stream of Strands agent coordination and MCP tool calls

๐ŸŽ›๏ธ Live Dashboard Overview

The Streamlit dashboard simulates real-time orchestration behavior at 5G MEC sites.

๐ŸŽฏ Top Left โ€“ Real-Time Metrics

  • Latency (ms) โ€” target <100 ms
  • CPU Usage โ€” trigger >80%
  • GPU Usage โ€” monitoring utilization
  • Queue Depth โ€” request backlog โœ… Displays live performance indicators from simulated MEC nodes.

๐Ÿค Bottom Left โ€“ Swarm Visualization

  • Green: Healthy MEC sites
  • Red: Overloaded sites
  • Gray: Failed sites
  • Lines: MEC interconnections โœ… Visualizes agent coordination and failover behavior.

๐Ÿšจ Top Right โ€“ Agent Activity Stream

  • ๐Ÿ”ต Info: Normal operations
  • ๐ŸŸข Success: Consensus achieved
  • ๐ŸŸก Warning: Threshold breach
  • ๐Ÿ”ด Error: System failure โœ… Shows live Strands agent events.

๐Ÿ“ˆ Bottom Right โ€“ Performance Analytics

  • Blue line: Real latency
  • Red line: 100 ms threshold โœ… Demonstrates sub-100 ms orchestration goal.

๐ŸŽš Sidebar Controls

  • Dashboard Mode: Mock Data Mode vs Real Strands Agents Mode
  • Demo Scenarios: Gaming, Automotive, Healthcare, Normal
  • Automated Demo: 15-second scenario transitions with โ–ถ๏ธ Start/โน๏ธ Stop
  • Operation Mode: Normal / Threshold Breach / Swarm Active / Failover Test
  • Active MEC Sites toggle
  • Adjustable Latency/CPU thresholds

๐Ÿงช Enhanced Demo Scenarios

  • โ€œThreshold Breachโ€: triggers swarm response
  • โ€œSwarm Activeโ€: shows coordination logs
  • โ€œFailover Testโ€: disables one MEC site โœ… Replicates telecom-grade orchestration under stress.

Scenario Types:

  • ๐ŸŽฎ Gaming: High GPU usage (85-95%), multiplayer synchronization, NPC AI processing
  • ๐Ÿš— Automotive: Ultra-low latency (<30ms), safety-critical systems, V2X communication
  • ๐Ÿฅ Healthcare: Patient monitoring (50-200 patients), HIPAA compliance, medical alerts
  • ๐Ÿ”„ Normal: Balanced resource utilization and standard MEC operations

๐ŸŽฌ Automated Demo Features

  • Auto Demo Mode: Cycles through all scenarios every 15 seconds
  • Scenario-Specific Metrics: Context-aware thresholds and performance indicators
  • Enhanced Visualizations: Scenario-specific icons, colors, and coordination patterns
  • Real-Time Integration: Works seamlessly in both Mock and Real agent modes โœ… Demonstrates comprehensive MEC orchestration across diverse use cases.

dashboard

dashboard charts


Whatโ€™s Next โ€” Toward ICEO (Intelligence-Centric Edge Orchestration)

The next phase extends toward ICEO, where each MEC site acts as a learning agent within a distributed intelligence fabric. Planned research and implementation:

  • Build multi-MEC simulation for latency and consensus testing
  • Add reinforcement-based learning between edge and cloud layers
  • Formalize and publish ICEO as a framework for autonomous 5G orchestration

๐Ÿ“š Documentation

Architecture Documentation

  • Architecture Guide: Comprehensive system architecture, agent design, deployment patterns, and key design decisions

Technical Specifications

Development

  • Tests: Comprehensive test suite for agents, swarm coordination, and integration scenarios
  • Generated Diagrams: Mermaid architecture diagrams and visualizations

Showcasing the future of 5G-MEC intelligence - where real decisions happen at the edge, not in the cloud

About

Intelligent AI Inference Routing

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published