Skip to content

πŸ€– A Telegram bot that transforms your messages into beautifully formatted Obsidian notes using Google Gemini AI. Automatically processes text and media, adds tags, and creates markdown files ready for your Obsidian vault.

Notifications You must be signed in to change notification settings

Sppqq/obsidianAI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

3 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Obsidian Telegram Bot

πŸ‡·πŸ‡Ί Русская вСрсия

A powerful Telegram bot for managing notes and media files with automatic processing using Google's Gemini AI. The bot helps organize and format your notes in Markdown, making them perfect for Obsidian.

πŸ†• Latest Updates

  • ✨ Updated Gemini model to gemini-2.0-flash-exp
  • πŸ› οΈ Improved text processing and formatting
  • πŸ“Š Optimized performance
  • πŸ”„ Enhanced proxy stability
  • 🌐 Added support for embedding various links

🌟 Features

  • πŸ€– AI-powered note processing using Google Gemini
  • πŸ“ Automatic Markdown formatting
  • 🏷️ Custom tag management system
  • πŸ“Έ Support for various media files (photos, audio, video, documents)
  • ☁️ Dropbox integration
  • πŸ”„ Proxy support for stable connection
  • πŸ‘₯ Multi-user support
  • πŸ“± Mobile-friendly experience

πŸ› οΈ Prerequisites

  • Python 3.8+
  • Telegram Bot Token
  • Google Gemini API Key
  • Dropbox API credentials (optional)
  • Proxy (optional)

βš™οΈ Installation

  1. Clone the repository:
git clone https://github.com/Sppqq/obsidianAI.git
cd obsidianAI
  1. Install required dependencies:
pip install -r requirements.txt

πŸ“‹ Configuration

  1. The bot will automatically create a config.json file on first run. Configure it with your credentials:
{
    "user1": {
        "chat_id": YOUR_CHAT_ID,
        "bot_token": "YOUR_BOT_TOKEN",
        "gemini_api": "YOUR_GEMINI_API",
        "gemini_model": "gemini-2.0-flash-exp",
        "tags": ["#code", "#study", "#files", "#ai", "#other"],
        "db_app_key": "your-dropbox-key",
        "db_app_secret": "your-dropbox-secret",
        "db_redirect_uri": "http://localhost:8080",
        "proxy": {
            "http": "http://your-proxy-server",
            "https": "http://your-proxy-server"
        }
    }
}

πŸ”‘ Getting API Keys

  1. Telegram Bot Token:

    • Message @BotFather on Telegram
    • Create new bot with /newbot
    • Copy the provided token
  2. Google Gemini API:

  3. Dropbox API (optional):

πŸ”’ Proxy Configuration

For stable connection in some regions, you may need to use a proxy:

"proxy": {
    "http": "http://username:password@proxy-server:port",
    "https": "http://username:password@proxy-server:port"
}

πŸš€ Usage

  1. Start the bot:
python main.py
  1. Send /start to your bot on Telegram

  2. Use the following commands:

    • /start - Initialize the bot
    • /tags - Manage your tags
  3. Send any text or media to the bot:

    • The bot will process it using Gemini AI
    • Format it in Markdown
    • Add appropriate tags
    • Save it as a .md file

πŸ“ Note Format

The bot automatically formats notes with:

  • Clear, concise titles
  • Markdown formatting
  • Embedded media
  • Custom tags
  • Proper text formatting with bold emphasis
  • Emoji enhancements
  • Working links

🀝 Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

πŸ“ž Support

If you have any questions or issues, please create an issue in the repository or contact the author via Telegram.

About

πŸ€– A Telegram bot that transforms your messages into beautifully formatted Obsidian notes using Google Gemini AI. Automatically processes text and media, adds tags, and creates markdown files ready for your Obsidian vault.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages