🧠 TANGNET ARCHITECTURE 🛰️

Phase 2: Pi Mesh AI - Multi-node, Multi-model - ACTIVE

Current System Overview

2 Active Nodes
7B, 1.1B Model Parameters
16GB / 8GB RAM
8 / 4 CPU Cores
User Input Web/CLI/API Tailscale/SSH Pi Mesh Node 01
TinyLlama 1.1B
Pi Mesh Node 02
Llama 2 7B
Desktop
(future: GPU models)

Mesh Node Components

🖥️ Node 01: Pi 5 TinyLlama

IP: 192.168.1.31

Model: Pi 5 (8GB RAM), TinyLlama-1.1B-Chat Q4_K_M

Role: Fast, lightweight local chat, quick tasks

ssh brand@192.168.1.31 asktiny "Quick answer for mesh ops?"

🖥️ Node 02: Pi 5 16GB Llama 2 7B

IP: 192.168.1.43

Model: Pi 5 (16GB RAM), Llama-2-7B Q4_K_M

Role: Heavy LLM lifting, deeper answers, research

ssh brand@192.168.1.43 ask7b "What is the purpose of mesh AI?"

🖥️ Desktop Node

IP: 192.168.1.30

Model: RTX 3070 Ti (64GB RAM) [future]

Role: Central orchestration & GPU-based models

Data Flow & Control

Prompt/Inference Pipeline

1. Client Layer

  • Web, CLI, or script sends prompt
  • Tailscale/SSH for mesh access (LAN & remote)

2. Node Inference Layer

  • Aliases ask7b, asktiny run models directly
  • Model outputs piped to stdout, ready for mesh relay

3. API & Orchestration (future)

  • Central dashboard, queue, or chatbot picks node/model
  • Automated prompt routing based on node health/load

Mesh Ops & Health

🔧 Pi Health Check

vcgencmd measure_temp # Pi CPU temp htop # CPU/mem df -h # Disk free -h # RAM lsusb # USB/cams vcgencmd get_throttled # Voltage/cooling status uptime -s # Last boot cat /etc/os-release && uname -a # OS info

🗝️ Persistent Aliases (Pi Best Practice)

  1. Edit your aliases file:
  2. nano ~/.bash_aliases
  3. Add mesh chat aliases:
  4. alias ask7b='cd ~/llama.cpp/build && ./bin/llama-cli -m ../models/llama-2-7b.Q4_K_M.gguf -t 8 -n 128 -c 2048 --color -p'
    alias chat7b='cd ~/llama.cpp/build && ./bin/llama-cli -m ../models/llama-2-7b.Q4_K_M.gguf -t 8 -c 2048 --color -i'
    alias asktiny='cd ~/llama.cpp/build && ./bin/llama-cli -m ../models/tinyllama-1.1b-chat-v1.0.Q4_K_M.gguf -t 4 -n 128 -c 1024 --color -p'
  5. Activate them:
  6. source ~/.bash_aliases
  7. Test:
  8. ask7b "What is your quest?"
Tip: Aliases in ~/.bash_aliases persist across sessions.
If they ever stop working, check for typos, or run alias | grep ask7b to verify.

🛡️ SSH & Tailscale Meshing

# SSH keygen for passwordless login: ssh-keygen -t rsa -b 4096 ssh-copy-id brand@192.168.1.31 ssh-copy-id brand@192.168.1.43 # Tailscale for remote access (free/personal use): curl -fsSL https://tailscale.com/install.sh | sh sudo tailscale up # Use your Tailscale hostname in SSH: ssh brand@tangnet-node-02.tailnet-yourname.ts.net

Performance & Expansion Path

2-4 Tokens/sec
7B on Pi 5 (16GB)
10-15 Tokens/sec
TinyLlama
2048-4096 Context
3.8GB Model Size (7B)

🚀 Phase 3 Ready