Skip to main content

MRAgent โ€” small, fast, secure, free & open-source AI agent

Project description

๐Ÿค– MRAgent

Small ยท Fast ยท Secure ยท Completely Free ยท Open Source

Your personal AI agent that runs anywhere โ€” terminal or browser.

License: MIT Python Free Built on nanobot


MRAgent is a lightweight, privacy-first personal AI agent you can run from your terminal or browser in seconds. It uses free API tiers from NVIDIA, Qwen, and Groq โ€” no credit card required.

Built on and inspired by nanobot โ€” full credit to the HKUDS team for the excellent foundation. MRAgent adds free provider integrations, a web UI, and a tighter focus on being completely cost-free.


โœจ Features

  • ๐Ÿ†“ Completely free โ€” NVIDIA NIM free credits, Qwen OAuth (no key!), Groq free tier
  • ๐Ÿง™ Interactive setup โ€” mragent setup fetches live models from NVIDIA, pick with arrow keys
  • ๐ŸŒ Web UI on port 6326 โ€” dark glassmorphism chat, markdown, streaming
  • โš™๏ธ In-browser model picker โ€” click โš™๏ธ, paste key, select model, save โ€” no config editing
  • ๐ŸŽ™๏ธ Voice input โ€” mic โ†’ Groq Whisper transcription โ†’ agent
  • ๐Ÿ”ง Tools โ€” web search, file system, shell, MCP servers, cron scheduler
  • ๐Ÿ“ก Channels โ€” Telegram, Discord, WhatsApp, Slack, Email, and more
  • ๐Ÿ”’ Secure โ€” runs 100% locally, no data sent anywhere except the LLM
  • โšก Fast โ€” lightweight Python, no heavy frameworks
  • ๐Ÿ Easy install โ€” pip install bonza-mragent

๐Ÿš€ Quick Start

# Install
pip install bonza-mragent

# Initialize config
mragent onboard

# Interactive setup โ€” pick your NVIDIA key + model with arrow keys
mragent setup

# Terminal chat
mragent agent -m "Hello!"

# Web UI (opens browser at http://localhost:6326)
mragent web

๐Ÿ’š Free Providers

MRAgent works out of the box with zero cost using these providers:

๐ŸŸข NVIDIA NIM โ€” Free GPU-Accelerated Models

Access Llama, Qwen, Nemotron, Mistral, and more โ€” live from NVIDIA's model catalog.

Option A โ€” Interactive wizard (recommended):

mragent setup

This fetches all available models from NVIDIA, lets you pick a family (Meta, Qwen, NVIDIA, Mistralโ€ฆ) and then a specific model using โ†‘โ†“ arrow keys, and saves everything to ~/.mragent/config.json automatically.

Option B โ€” Web UI settings drawer:

  1. Run mragent web
  2. Click the โš™๏ธ button in the top-right header
  3. Paste your nvapi-... key โ†’ click Fetch Available Models
  4. Filter by family, pick a model, click Save & Apply

Option C โ€” Manual config edit:

{
  "providers": {
    "nvidia_nim": { "apiKey": "nvapi-YOUR_KEY_HERE" }
  },
  "agents": {
    "defaults": { "model": "meta/llama-3.1-8b-instruct" }
  }
}

Option D โ€” Environment variable:

export MRAGENT_PROVIDERS__NVIDIA_NIM__API_KEY=nvapi-...
export MRAGENT_AGENTS__DEFAULTS__MODEL=meta/llama-3.1-8b-instruct

Get a free key at build.nvidia.com.

Popular free NIM models:

Model Context Notes
meta/llama-3.1-8b-instruct 128K Fast, great for chat
meta/llama-3.3-70b-instruct 128K High quality
nvidia/llama-3.1-nemotron-ultra-253b-v1 128K Most capable
qwen/qwen2.5-72b-instruct 128K Strong reasoning
mistralai/mistral-7b-instruct-v0.3 32K Very fast

๐ŸŸฃ Qwen OAuth โ€” No API Key, ~2000 Free Req/Day

Authenticate with your Alibaba/Qwen account โ€” no API key management.

mragent provider login qwen-oauth
# Opens browser โ†’ log in โ†’ paste token โ†’ done!

Then set in config:

{
  "agents": {
    "defaults": {
      "provider": "qwen_oauth",
      "model": "qwen-plus"
    }
  }
}

๐Ÿ”ต Groq โ€” Fast LLM + Voice Transcription

Groq's free tier provides ultra-fast inference and Whisper voice transcription.

  1. Sign up at console.groq.com (no credit card)
  2. Create an API key
  3. Add to config:
{
  "providers": {
    "groq": {
      "apiKey": "gsk_YOUR_KEY_HERE"
    }
  }
}

Voice: Set providers.groq.api_key and the ๐ŸŽ™๏ธ mic button in the web UI will transcribe your speech using whisper-large-v3-turbo.


๐ŸŒ Web UI

mragent web                    # port 6326 (default)
mragent web --port 8080        # custom port
mragent web --no-open          # don't auto-open browser

Features:

  • ๐Ÿ’ฌ Real-time streaming chat with markdown rendering
  • โš™๏ธ Settings drawer โ€” paste NVIDIA key, fetch live model list, pick with arrow keys, save
  • ๐ŸŽ™๏ธ Voice input via microphone (requires Groq key)
  • ๐ŸŒ™ Dark glassmorphism design
  • ๐Ÿ“ฑ Mobile responsive
  • โŒจ๏ธ Keyboard shortcuts (Enter to send, Shift+Enter for newline)

๐Ÿ’ป Terminal

# Single message
mragent agent -m "What's the weather like in Paris?"

# Interactive session
mragent agent

# Interactive setup (NVIDIA key + model picker)
mragent setup

# Gateway mode (runs channels: Telegram, Discord, etc.)
mragent gateway

# Check status
mragent status

โš™๏ธ Configuration

Config file: ~/.mragent/config.json

{
  "agents": {
    "defaults": {
      "model": "meta/llama-3.1-8b-instruct",
      "provider": "auto",
      "max_tokens": 8192,
      "temperature": 0.1
    }
  },
  "providers": {
    "nvidia_nim": { "apiKey": "nvapi-..." },
    "groq": { "apiKey": "gsk_..." }
  },
  "tools": {
    "web": {
      "search": { "apiKey": "" }
    }
  }
}

๐Ÿ“ก Channels (Gateway Mode)

Connect to messaging platforms by enabling them in config:

{
  "channels": {
    "telegram": { "enabled": true, "token": "YOUR_BOT_TOKEN" },
    "discord": { "enabled": true, "token": "YOUR_BOT_TOKEN" }
  }
}

Run: mragent gateway


๐Ÿ› ๏ธ Development

git clone https://github.com/your-fork/Bonza
cd Bonza
pip install -e ".[dev]"
pytest tests/ -v

# Run web UI in dev mode
mragent web --no-open

๐Ÿ“ License

MIT โ€” see LICENSE.


๐Ÿ™ Credits

MRAgent is built on nanobot by the HKUDS team. The core agent loop, channel integrations, cron scheduler, MCP support, and provider architecture are all from that excellent project.

MRAgent adds:

  • NVIDIA NIM free provider integration
  • mragent setup โ€” interactive wizard with live model fetching + arrow-key picker
  • Web UI โš™๏ธ settings drawer โ€” fetch + select NVIDIA models in-browser
  • Qwen OAuth (free, no API key) provider
  • Groq voice upgrade (whisper-large-v3-turbo)
  • Web UI on port 6326
  • MRAgent branding and config paths (~/.mragent)

๐Ÿค– MRAgent โ€” Free AI for everyone

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bonza_mragent-1.0.0.tar.gz (151.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

bonza_mragent-1.0.0-py3-none-any.whl (187.6 kB view details)

Uploaded Python 3

File details

Details for the file bonza_mragent-1.0.0.tar.gz.

File metadata

  • Download URL: bonza_mragent-1.0.0.tar.gz
  • Upload date:
  • Size: 151.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.2

File hashes

Hashes for bonza_mragent-1.0.0.tar.gz
Algorithm Hash digest
SHA256 81b681d39f0960ffb6257bacfb158e0a8a35e98dc0c4bf31d4ba08f87c7119eb
MD5 4fe773319c52126116eb725167cc9f49
BLAKE2b-256 a267c41e06b8f4b1cf8d46127d6cb2c2261e6fe2f1d68d22163b6a95d07615f6

See more details on using hashes here.

File details

Details for the file bonza_mragent-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: bonza_mragent-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 187.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.2

File hashes

Hashes for bonza_mragent-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 d32c1d3c7cce521db0dd94bf0eb1923edd58592f51a76e00cbee8bff339242ca
MD5 480cecfa7dce4512e941f1f679bd2160
BLAKE2b-256 158a4c22a8edbbd63cddf47972fd1c5eb39a5648528d9bb94459a3513c5e398f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page