ai-svetlio-personal
v0.1.0
Published
Lightweight, self-hosted AI personal assistant with task management, notes, and project scaffolding. Powered by Google Gemini, OpenAI, or Ollama.
Downloads
105
Maintainers
Readme
AI SvetLio Personal
A lightweight, self-hosted AI personal assistant powered by Google Gemini (or any OpenAI-compatible LLM). Runs locally with SQLite — no cloud database, no subscriptions, no telemetry.
SvetLio (from Bulgarian "Светльо", a friendly name derived from "light") is your private AI assistant that manages tasks, notes, and projects through natural conversation — via a web interface or Telegram.
Features
- Natural task detection — say "I need to finish the report by Friday" and SvetLio asks "Should I create a task with a Friday deadline?"
- Task management — create, list, update, and complete tasks with priorities and due dates
- Notes — save quick notes with tags, searchable later
- Project scaffolding — create new projects with a full memory structure (
.memory/system for AI context persistence) - Deadline tracking — check upcoming and overdue tasks
- Web fetching — retrieve and summarize content from URLs
- Database queries — ask questions about your data in natural language (read-only SQL)
- Multi-channel — WebUI (localhost) + Telegram bot (optional)
- Multi-LLM — Google Gemini (free tier), OpenAI, Ollama, or any OpenAI-compatible provider
- Smart rate limiting — adaptive throttling based on your LLM tier (no wasted API calls)
- 66 unit tests — solid foundation with
node:test
Quick Start
# 1. Clone
git clone https://github.com/SPartenev/ai-svetlio-personal.git
cd ai-svetlio-personal
# 2. Install
npm install
# 3. Configure
cp .env.example .env
# Edit .env — add your GOOGLE_API_KEY (free from https://aistudio.google.com/apikey)
# 4. Initialize database
npm run init-db
# 5. Start
npm start
# Open http://localhost:3010Configuration
Copy .env.example to .env and configure your preferred LLM provider:
| Provider | Config | Cost | RPM |
|----------|--------|------|-----|
| Google Gemini API | GOOGLE_API_KEY=... | Free | 15 |
| OpenAI | OPENAI_API_KEY=... | Paid | Varies |
| Ollama | Just run ollama serve | Free (local) | Unlimited |
| Gemini OAuth | Run gemini CLI first | Free | 1 |
Telegram (optional)
- Create a bot via @BotFather
- Add to
.env:TELEGRAM_BOT_TOKEN=your-bot-token TELEGRAM_OWNER_ID=your-telegram-user-id - Run:
npm run telegram
Architecture
User (WebUI :3010) --> server.js
User (Telegram) --> bot.js
|
session-store --> chat_sessions (SQLite)
|
skill-engine --> dynamic system prompt
|
tool-executor --> LLM --> tool-runner
| |
rate-limit queue sqlite / web_fetch / ...
| |
LLM (next iteration) <-- tool result
|
Final response --> UserTools
| Tool | What it does |
|------|-------------|
| task_manage | CRUD for tasks — create, list, update, complete |
| notes_manage | CRUD for notes — save, search, tag |
| project_create | Scaffold a new project with .memory/ structure |
| deadline_check | Show upcoming and overdue tasks |
| db_query | Read-only SQL queries on the database |
| web_fetch | Fetch and process web pages |
Database
SQLite with WAL mode. 9 tables auto-created on first run:
chat_sessions, agent_definitions, agent_tools, agent_tool_access,
agent_flows, agent_flow_steps, tasks, notes, projectsScripts
npm start # Start WebUI on :3010
npm run dev # Start with --watch (auto-reload)
npm run init-db # Initialize/reset database
npm run telegram # Start Telegram bot
npm test # Run all 66 testsTech Stack
- Runtime: Node.js 18+
- Database: SQLite via better-sqlite3 (WAL mode)
- Web server: Express 4.x
- Telegram: grammY 1.x
- LLM SDKs: @google/genai, openai
- Frontend: Vanilla JS + marked.js (CDN)
- Tests:
node:test(built-in, zero dependencies)
Project Structure
ai-svetlio-personal/
├── core/
│ ├── db-adapter.js # Database adapter factory
│ ├── db-adapter-sqlite.js # SQLite implementation
│ ├── session-store.js # Chat session CRUD
│ ├── skill-engine.js # Dynamic system prompt builder
│ ├── tool-runner.js # Tool executors (sqlite, web_fetch, etc.)
│ ├── tool-executor.js # Agentic loop with rate limiting
│ ├── llm-router.js # Multi-provider LLM routing
│ ├── init-llm.js # LLM initialization from config
│ └── *.test.js # Unit tests
├── setup/
│ └── init-db.js # Schema + seed data
├── config/
│ ├── agents.json # Agent configuration
│ └── prompts/
│ └── personal.md # System prompt (reference)
├── channels/
│ ├── webui/ # Web interface (Express + vanilla JS)
│ └── telegram/ # Telegram bot (grammY)
└── data/
└── personal.db # SQLite database (auto-created)Related Projects
AI SvetLio is a family of AI assistant tools:
- ai-svetlio-personal (this repo) — Lightweight personal assistant
- ai-svetlio-office — Multi-agent office assistant (PostgreSQL, multi-user)
- ai-svetlio-brand — Brand guidelines and landing page
License
MIT
