AI Telegram Bot powered by SimpleContext โ one-command setup, auto-downloads engine and agents.
Project description
๐ค SimpleContext-Bot
AI Telegram Bot powered by SimpleContext
Setup wizard ยท 15 agents ยท Dynamic plugins ยท Works with Gemini, OpenAI, Ollama
โจ What is this?
SimpleContext-Bot is a ready-to-run Telegram bot powered by SimpleContext โ a structured AI brain with tiered memory, intent planning, and context scoring.
A built-in setup wizard automatically downloads the engine, 15 agents, and optional plugins โ then walks you through configuration step by step.
๐ Installation
Option A โ pip (recommended)
pip install simplecontext-bot
simplecontext-bot setup
simplecontext-bot start
Option B โ from source
git clone https://github.com/zacxyonly/SimpleContext-Bot.git
cd SimpleContext-Bot
pip install .
simplecontext-bot setup
simplecontext-bot start
๐ง Setup Wizard
simplecontext-bot setup
The wizard handles everything in 6 steps:
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
๐ง SimpleContext-Bot โ Setup Wizard
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Step 1/6 Download SimpleContext engine โ
Step 2/6 Download 15 agent definitions โ
Step 3/6 Plugin Ecosystem (Optional)
Install Vector Search? [y/N]: y โ
Install Summarizer? [y/N]: y โ
Step 4/6 Telegram Bot Token โ paste from @BotFather
Step 5/6 LLM Provider & API Key โ Gemini / OpenAI / Ollama
Step 6/6 Final configuration โ
Done!
๐ Getting Your Tokens
Telegram Bot Token
- Open Telegram โ search
@BotFather - Send
/newbotโ follow the steps โ copy the token
Gemini API Key (free, recommended)
- Go to aistudio.google.com/app/apikey
- Click Create API Key โ copy
OpenAI API Key
- Go to platform.openai.com/api-keys
- Click Create new secret key โ copy
Ollama (local, free, no API key)
- Install from ollama.ai
ollama pull llama3- Make sure Ollama is running before starting the bot
๐ฏ Auto-Routing
No need to manually switch agents. The bot detects the best agent automatically:
"ada bug di python saya" โ ๐ฅ๏ธ coding
"deploy ke server nginx" โ ๐ devops
"tulis caption instagram" โ โ๏ธ writer
"terjemahkan ke english" โ ๐ translator
"jelaskan konsep ini" โ ๐ tutor
"ringkas artikel ini" โ ๐ summarizer
"cek fakta berita ini" โ ๐ researcher
"komplain order saya" โ ๐ง customer_service
"analisis data penjualan" โ ๐ analyst
"bantu investasi saham" โ ๐ฐ finance
"cek kontrak ini" โ โ๏ธ legal
"brainstorm ide startup" โ ๐จ creative
"tips produktivitas" โ โก productivity
"olahraga untuk pemula" โ ๐ช health
๐ค Available Agents (15)
Core
| Agent | Description | |
|---|---|---|
| ๐ง | general |
Default fallback โ smart routing to specialized agents |
| ๐ฅ๏ธ | coding |
Expert programmer โ debug, review, all languages |
| ๐ | devops |
Server, Docker, CI/CD, Linux infrastructure |
| โ๏ธ | writer |
Content, copywriting, email, social media |
Knowledge & Research
| Agent | Description | |
|---|---|---|
| ๐ | researcher |
Fact-checking, research, source evaluation |
| ๐ | tutor |
Patient adaptive teacher for any subject |
| ๐ | summarizer |
Condense any content into clear summaries |
| ๐ | translator |
Multi-language, idiom-aware translation |
Business & Professional
| Agent | Description | |
|---|---|---|
| ๐ | analyst |
Data analysis, business insights, KPIs |
| ๐ง | customer_service |
Empathetic CS, complaint handling |
| ๐ฐ | finance |
Budgeting, investing, financial planning |
| โ๏ธ | legal |
Contracts, rights, Indonesian law reference |
Lifestyle & Creativity
| Agent | Description | |
|---|---|---|
| ๐จ | creative |
Brainstorming, storytelling, naming, worldbuilding |
| โก | productivity |
Time management, habits, GTD, focus systems |
| ๐ช | health |
Fitness, nutrition, sleep, mental wellness |
๐ฌ Bot Commands
Built-in Commands
| Command | Description |
|---|---|
/start |
Welcome message, saves your name |
/help |
Show all commands including plugin commands |
/agents |
List all available agents |
/agent <n> |
Switch to a specific agent |
/agent auto |
Back to auto-routing |
/clear |
Clear conversation history (keeps profile) |
/status |
Show current agent, message count, active plugins |
/memory |
Show your saved profile |
/plugins |
List active plugins and their commands |
Plugin Commands (auto-registered)
Plugin commands register automatically when a plugin is loaded:
| Command | Plugin Required | Description |
|---|---|---|
/semantic <query> |
vector-search |
Search memory by meaning |
/summary |
summarizer |
Summarize conversation |
/search <query> |
web-search |
Search the internet |
/translate <lang> |
translate |
Set language or translate |
/sentiment |
sentiment |
View sentiment analysis |
/analytics |
analytics |
View usage statistics |
/usage |
rate-limiter |
Check your usage quota |
๐ Plugin Ecosystem
Extend the bot with plugins from SimpleContext-Plugin.
Available Official Plugins
| Plugin | Description |
|---|---|
vector-search |
Semantic memory search โ find by meaning, not exact words |
analytics |
Usage statistics per user and agent |
summarizer |
Auto-compress conversation to episodic memory via LLM |
web-search |
Real-time internet search (DuckDuckGo free, Bing, Google) |
translate |
Multi-language โ auto-detect 20+ languages |
sentiment |
Sentiment analysis โ adapts agent tone when user is frustrated |
rate-limiter |
Limit requests per hour/day, token estimation |
Install Plugins
simplecontext-bot plugins list # fetch list from GitHub registry
simplecontext-bot plugins install vector-search # install a plugin
simplecontext-bot plugins install summarizer
simplecontext-bot plugins remove vector-search # remove a plugin
Manual (community plugins):
cp my_plugin.py ~/.simplecontext-bot/plugins/
simplecontext-bot start # auto-detected on startup
How Plugin Commands Work
Plugins declare their own Telegram commands via app_commands (SimpleContext v4.3 standard).
The bot registers them automatically โ no code changes needed:
class MyPlugin(BasePlugin):
app_commands = {
"mycommand": {
"description": "What this does",
"usage": "/mycommand <arg>",
"handler": "handle_mycommand",
}
}
async def handle_mycommand(self, ctx: AppCommandContext) -> str:
return f"Hello from {ctx.platform}! Query: {ctx.args_str}"
Drop the file โ restart โ /mycommand is live in Telegram.
โ๏ธ CLI Commands
# Setup & Start
simplecontext-bot setup # First-time setup wizard
simplecontext-bot start # Start the bot
simplecontext-bot start --debug # Start with verbose logging
# Status & Info
simplecontext-bot status # Show configuration summary
simplecontext-bot status --test # Check + test LLM connection
simplecontext-bot dashboard # Show usage stats and system info
simplecontext-bot agents # List installed agents
# Update
simplecontext-bot update # Update engine + agents + plugins
simplecontext-bot update --engine-only # Update engine only
simplecontext-bot update --agents-only # Update agents only
simplecontext-bot update --plugins-only # Update installed plugins only
# Plugins
simplecontext-bot plugins list # List plugins (fetches from GitHub)
simplecontext-bot plugins install <id> # Install a plugin
simplecontext-bot plugins remove <id> # Remove a plugin
# Config (change any value without re-running setup)
simplecontext-bot set llm.api_key <key> # Update API key
simplecontext-bot set llm.model <model> # Change LLM model
simplecontext-bot set llm.provider <p> # Switch provider (gemini/openai/ollama)
simplecontext-bot set telegram.token <t> # Update Telegram token
simplecontext-bot set bot.debug true # Enable debug logging
simplecontext-bot set bot.memory_limit 30 # Increase memory limit
๐ Dashboard
simplecontext-bot dashboard
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ SimpleContext-Bot Dashboard โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
๐ง System
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Engine : โ
Installed
DB size : 2.4 MB
Telegram : โ
Configured
๐ค Agents & Plugins
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Agents : 15 installed
Plugins : 2 installed (vector_search_plugin, summarizer_plugin)
๐ง LLM
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Provider : gemini
Model : gemini/gemini-2.0-flash
๐ Usage Stats
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Users : 42
Nodes : 1,847
๐ Files After Setup
~/.simplecontext-bot/
โโโ config.json โ settings (tokens, LLM, plugins)
โโโ bot.db โ conversation memory (SQLite)
โโโ simplecontext/ โ engine (auto-downloaded)
โโโ agents/ โ 15 agent YAML files (auto-downloaded)
โ โโโ general.yaml
โ โโโ coding.yaml
โ โโโ ...
โโโ plugins/ โ installed plugins
โโโ vector_search_plugin.py
โโโ summarizer_plugin.py
๐ง Troubleshooting
Diagnose issues:
simplecontext-bot status --test
Update everything:
simplecontext-bot update
Change a config value without re-running setup:
simplecontext-bot set llm.api_key <new-key>
simplecontext-bot set llm.model gemini/gemini-2.5-flash
simplecontext-bot set telegram.token <new-token>
Start fresh:
rm -rf ~/.simplecontext-bot
simplecontext-bot setup
๐ง Powered By
| Repo | Role |
|---|---|
| SimpleContext | AI brain โ tiered memory, context scoring, intent planning |
| SimpleContext-Agents | 15 ready-to-use agent definitions |
| SimpleContext-Plugin | Official plugin registry |
| LiteLLM | Universal LLM connector |
๐ Ecosystem
| Repo | Description |
|---|---|
| SimpleContext | Core engine โ Universal AI Brain |
| SimpleContext-Agents | Ready-to-use agent definitions |
| SimpleContext-Plugin | Plugin registry |
| SimpleContext-Bot | This repo |
| SimpleContext-Docs | Full documentation |
Built with โค๏ธ on top of SimpleContext
โญ Star the engine repo if you find this useful!
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file simplecontext_bot-1.3.0.post1.tar.gz.
File metadata
- Download URL: simplecontext_bot-1.3.0.post1.tar.gz
- Upload date:
- Size: 30.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8dd1d7506ecab4d42450a5af80dbefaad9888715bd4210872eae3884a21f531c
|
|
| MD5 |
144c9cc573f28d9b4433534bec81b8d6
|
|
| BLAKE2b-256 |
4f2be21744a06b4e3f03ab716f97084e055e822316e0a95f20737fc772d39c46
|
File details
Details for the file simplecontext_bot-1.3.0.post1-py3-none-any.whl.
File metadata
- Download URL: simplecontext_bot-1.3.0.post1-py3-none-any.whl
- Upload date:
- Size: 28.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
802aa5e85a7967d67ad64ef9e733a9cf1e04dae234cf739d1d3136e50929eb1f
|
|
| MD5 |
4aee6dcacf61168b52ba3696e95dba6a
|
|
| BLAKE2b-256 |
5270a5335e0e53e3ffce5bd2b7e1b23a103cb2c7303b57e343b10e8e39ffbd4f
|