Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in
  • T Telegram Team
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 4
    • Issues 4
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
    • Requirements
  • Merge requests 1
    • Merge requests 1
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • software-project-WS25
  • Telegram Team
  • Merge requests
  • !3

Abinash feature lang

  • Review changes

  • Download
  • Email patches
  • Plain diff
Closed Anand requested to merge abinash-feature-lang into main Nov 25, 2025
  • Overview 0
  • Commits 2
  • Pipelines 2
  • Changes 3

🚀 Merge Request: Integrate Language Detection Into Telegram Listener

Task: Integrate Language Detection into the main project
Issue: #2
Branch: feature/language-detection


📌 Summary

This merge request introduces automatic language detection into the Telegram bot workflow.
All incoming messages—text, captions, or media—are now analyzed for language, and this metadata is added to the JSON output files generated by the system.

Running the listener now produces well-structured .json and .txt files inside the /output folder, enabling multilingual processing and more advanced analysis.

This enhancement prepares the project for broader NLP tasks and supports more sophisticated classification, threat assessment, and content evaluation.


📌 What Has Been Done

1. Language Detection Integration

  • Added langdetect.
  • Applied language detection to message text and media captions.
  • Added "language" field to JSON output.
  • Implemented safe fallback for undetectable language cases.
  • Ensured sentiment analysis continues to run properly.
  • Integrated the language field into both JSON and TXT file generation.

📌 Output Folder Generation

After running:

python services/telegram_listener.py

📌 Updated Dependencies

The requirements.txt file has been updated to support Python 3.13.9, which required specific compatible versions for core NLP libraries.

✅ Added

  • langdetect

🔄 Updated

  • transformers>=4.50.0,<5.0
    ✔ Compatible tokenizers build for Python 3.13
  • torch==2.9.1+cpu
    ✔ Official PyTorch CPU wheel available for Python 3.13

🧠 Reason for Changes

  • Older versions were not compatible with Python 3.13.
  • Prevents PyO3 + Rust tokenizers build failures.

Screenshots

Screenshot__65_

Screenshot__66_

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: abinash-feature-lang

Dies ist die Gitlab-Instanz des Transferportals der Hochschule für Technik Stuttgart. Hier geht es zurück zum Portal