first commit
This commit is contained in:
Binary file not shown.
Binary file not shown.
Binary file not shown.
+139
@@ -0,0 +1,139 @@
|
|||||||
|
# Byte-compiled / optimized / DLL files
|
||||||
|
__pycache__/
|
||||||
|
*.py[cod]
|
||||||
|
*$py.class
|
||||||
|
|
||||||
|
# C extensions
|
||||||
|
*.so
|
||||||
|
|
||||||
|
# Distribution / packaging
|
||||||
|
.Python
|
||||||
|
build/
|
||||||
|
develop-eggs/
|
||||||
|
dist/
|
||||||
|
downloads/
|
||||||
|
eggs/
|
||||||
|
.eggs/
|
||||||
|
lib/
|
||||||
|
lib64/
|
||||||
|
parts/
|
||||||
|
sdist/
|
||||||
|
var/
|
||||||
|
wheels/
|
||||||
|
pip-wheel-metadata/
|
||||||
|
share/python-wheels/
|
||||||
|
*.egg-info/
|
||||||
|
.installed.cfg
|
||||||
|
*.egg
|
||||||
|
MANIFEST
|
||||||
|
.pytest_cache/
|
||||||
|
|
||||||
|
# PyInstaller
|
||||||
|
# Usually these files are written by a python script from a template
|
||||||
|
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
||||||
|
*.manifest
|
||||||
|
*.spec
|
||||||
|
|
||||||
|
# Installer logs
|
||||||
|
pip-log.txt
|
||||||
|
pip-delete-this-directory.txt
|
||||||
|
|
||||||
|
# Unit test / coverage reports
|
||||||
|
htmlcov/
|
||||||
|
.tox/
|
||||||
|
.nox/
|
||||||
|
.coverage
|
||||||
|
.coverage.*
|
||||||
|
.cache
|
||||||
|
nosetests.xml
|
||||||
|
coverage.xml
|
||||||
|
*.cover
|
||||||
|
*.py,cover
|
||||||
|
.hypothesis/
|
||||||
|
.pytest_cache/
|
||||||
|
|
||||||
|
# Translations
|
||||||
|
*.mo
|
||||||
|
*.pot
|
||||||
|
|
||||||
|
# Django stuff:
|
||||||
|
*.log
|
||||||
|
local_settings.py
|
||||||
|
db.sqlite3
|
||||||
|
db.sqlite3-journal
|
||||||
|
|
||||||
|
# Flask stuff:
|
||||||
|
instance/
|
||||||
|
.webassets-cache
|
||||||
|
|
||||||
|
# Scrapy stuff:
|
||||||
|
.scrapy
|
||||||
|
|
||||||
|
# Sphinx documentation
|
||||||
|
docs/_build/
|
||||||
|
|
||||||
|
# PyBuilder
|
||||||
|
target/
|
||||||
|
|
||||||
|
# Jupyter Notebook
|
||||||
|
.ipynb_checkpoints
|
||||||
|
|
||||||
|
# IPython
|
||||||
|
profile_default/
|
||||||
|
ipython_config.py
|
||||||
|
|
||||||
|
# pyenv
|
||||||
|
.python-version
|
||||||
|
|
||||||
|
# pipenv
|
||||||
|
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
||||||
|
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
||||||
|
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
||||||
|
# install all needed dependencies.
|
||||||
|
#Pipfile.lock
|
||||||
|
|
||||||
|
# PEP 582; used by e.g. github.com/David-OConnor/pyflow
|
||||||
|
__pypackages__/
|
||||||
|
|
||||||
|
# Celery stuff
|
||||||
|
celerybeat-schedule
|
||||||
|
celerybeat.pid
|
||||||
|
|
||||||
|
# SageMath parsed files
|
||||||
|
*.sage.py
|
||||||
|
|
||||||
|
# Environments
|
||||||
|
.env
|
||||||
|
.venv
|
||||||
|
env/
|
||||||
|
venv/
|
||||||
|
ENV/
|
||||||
|
env.bak/
|
||||||
|
venv.bak/
|
||||||
|
|
||||||
|
# Spyder project settings
|
||||||
|
.spyderproject
|
||||||
|
.spyproject
|
||||||
|
|
||||||
|
# Rope project settings
|
||||||
|
.ropeproject
|
||||||
|
|
||||||
|
# mkdocs documentation
|
||||||
|
/site
|
||||||
|
|
||||||
|
# mypy
|
||||||
|
.mypy_cache/
|
||||||
|
.dmypy.json
|
||||||
|
dmypy.json
|
||||||
|
|
||||||
|
# Pyre type checker
|
||||||
|
.pyre/
|
||||||
|
test/test_main.py
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#projet
|
||||||
|
subtitle/
|
||||||
|
in_record/
|
||||||
|
working_bot/twitch-recordAudio/
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
|
||||||
|
# twitchBot-intelligent
|
||||||
|
|
||||||
|
a twitch bot that listens to and records the audio and translates it into text, analyzes it using a text chat bot and sends a response over the chat.
|
||||||
|
|
||||||
|
|
||||||
|
## Installation
|
||||||
|
|
||||||
|
clone project
|
||||||
|
|
||||||
|
```bash
|
||||||
|
git clone https://github.com/Foufure13/twitchBot-intelligent.git
|
||||||
|
cd twitchBot-intelligent
|
||||||
|
```
|
||||||
|
Install my-project with pip venv
|
||||||
|
|
||||||
|
```bash
|
||||||
|
python3.10 -m venv env
|
||||||
|
source env/bin/activate
|
||||||
|
pip install -r requirements.txt
|
||||||
|
sudo pacman -S cuda cudnn
|
||||||
|
|
||||||
|
```
|
||||||
|
|
||||||
|
clone other projects
|
||||||
|
|
||||||
|
twitch-recordAudio for stream audio recording
|
||||||
|
|
||||||
|
whisperX for audio-to-text translation
|
||||||
|
|
||||||
|
```bash
|
||||||
|
git clone https://github.com/Foufure13/twitch-recordAudio
|
||||||
|
git clone https://github.com/m-bain/whisperX
|
||||||
|
cd whisperX
|
||||||
|
python setup.py install
|
||||||
|
python -c "import whisperx"
|
||||||
|
|
||||||
|
```
|
||||||
|
|
||||||
|
install bin tgpt
|
||||||
|
|
||||||
|
tgpt for text chat bot
|
||||||
|
|
||||||
|
https://github.com/aandrew-me/tgpt
|
||||||
|
|
||||||
|
## Error
|
||||||
|
|
||||||
|
To Repair pip
|
||||||
|
|
||||||
|
```bash
|
||||||
|
deactivate
|
||||||
|
rm -rf env
|
||||||
|
python -m venv env
|
||||||
|
source env/bin/activate
|
||||||
|
pip install -r requirements.txt
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
debug error see
|
||||||
|
https://github.com/openai/whisper/discussions/1027
|
||||||
|
si tout le reste ne suffit pas
|
||||||
|
sudo pacman -S python-openai-whisper
|
||||||
+35
@@ -0,0 +1,35 @@
|
|||||||
|
{
|
||||||
|
"language":"fr",
|
||||||
|
"tw_acc_pseudo": "foufure13",
|
||||||
|
"tw_acc_token": "oauth:nmpw9bypx9emht7hn5z3vlgbwitaz5",
|
||||||
|
"bad_answer":["suis un assistant","Je ne comprends pas.","pas un humain","je suis désolé"],
|
||||||
|
"list_prompt":["Je vais te donner plusieur a respecter pour répondre a mon texte, 1er règles tu doit répondre en moins de 15mots et tu répondre seulement avec la réponse pas d'affiramtion pour dire que tu comprend, 2eme regle tu doit répondre a ce texte de mainière a réagir avec une blague ou une explication : Voici le texte : ",
|
||||||
|
"réagis avec au text donnée a la fin avec seulement ta réponse au texte en moins de 15mots et soit créatif : ",
|
||||||
|
"Répond en 10 mots avec un charatère gentils comme si tu fesait une remarque en regardant la tv : ",
|
||||||
|
"Réponds en 1 phrase à ce texte avec un peu de sarcasme, comme si tu étais un personnage un peu exaspéré mais sympathique.",
|
||||||
|
"Réponds de manière décontractée et courte, avec une pointe d'humour.",
|
||||||
|
"Réponds de manière concise avec un ton un peu moqueur mais gentil.",
|
||||||
|
"Réponds de façon simple et courte, mais avec une touche d’humour pince-sans-rire.",
|
||||||
|
"Réponds en 1 phrase de manière enthousiaste mais décalée, comme si tu étais un peu trop excité.",
|
||||||
|
"Réponds en 1 phrase avec un peu d'ironie, comme si tu ne prenais pas la situation trop au sérieux.",
|
||||||
|
"Réponds en 1 phrase de façon très simple et directe, mais avec un petit côté humoristique.",
|
||||||
|
"Réponds en 1 phrase comme si tu étais un coach un peu excentrique, motivant mais drôle.",
|
||||||
|
"Réponds en 1 phrase avec une touche de légèreté et de bienveillance, mais en ajoutant un brin d’humour.",
|
||||||
|
"Réponds en 1 phrase de manière décalée, mais avec un fond de vérité sous le ton léger.",
|
||||||
|
|
||||||
|
"Réponds avec humour en 1 phrase, sans trop te prendre au sérieux.",
|
||||||
|
"Réponds avec un peu de sarcasme, mais reste concis.",
|
||||||
|
"Sois direct, avec une touche d'humour, mais ne dépasse pas 15 mots.",
|
||||||
|
"Réponds en mode décalé, mais garde la réponse courte et punchy.",
|
||||||
|
"Réponds avec un ton léger et drôle, en 1 phrase seulement.",
|
||||||
|
"Réponds de manière concise, avec un brin d’ironie.",
|
||||||
|
"Réponds avec une touche d’humour rapide et percutante.",
|
||||||
|
"Réponds de manière brève mais amusante, sans fioritures.",
|
||||||
|
"Réponds avec un peu de moquerie gentille, mais court.",
|
||||||
|
"Sois concis et drôle, avec une touche de légèreté."
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
@@ -0,0 +1,35 @@
|
|||||||
|
{
|
||||||
|
"language":"fr",
|
||||||
|
"tw_acc_pseudo": "foufure13",
|
||||||
|
"tw_acc_token": "oauth:nmpw9bypx9emht7hn5z3vlgbwitaz5",
|
||||||
|
"bad_answer":["suis un assistant","Je ne comprends pas.","pas un humain","je suis désolé"],
|
||||||
|
"list_prompt":["Je vais te donner plusieur a respecter pour répondre a mon texte, 1er règles tu doit répondre en moins de 15mots et tu répondre seulement avec la réponse pas d'affiramtion pour dire que tu comprend, 2eme regle tu doit répondre a ce texte de mainière a réagir avec une blague ou une explication : Voici le texte : ",
|
||||||
|
"réagis avec au text donnée a la fin avec seulement ta réponse au texte en moins de 15mots et soit créatif : ",
|
||||||
|
"Répond en 10 mots avec un charatère gentils comme si tu fesait une remarque en regardant la tv : ",
|
||||||
|
"Réponds en 1 phrase à ce texte avec un peu de sarcasme, comme si tu étais un personnage un peu exaspéré mais sympathique.",
|
||||||
|
"Réponds de manière décontractée et courte, avec une pointe d'humour.",
|
||||||
|
"Réponds de manière concise avec un ton un peu moqueur mais gentil.",
|
||||||
|
"Réponds de façon simple et courte, mais avec une touche d’humour pince-sans-rire.",
|
||||||
|
"Réponds en 1 phrase de manière enthousiaste mais décalée, comme si tu étais un peu trop excité.",
|
||||||
|
"Réponds en 1 phrase avec un peu d'ironie, comme si tu ne prenais pas la situation trop au sérieux.",
|
||||||
|
"Réponds en 1 phrase de façon très simple et directe, mais avec un petit côté humoristique.",
|
||||||
|
"Réponds en 1 phrase comme si tu étais un coach un peu excentrique, motivant mais drôle.",
|
||||||
|
"Réponds en 1 phrase avec une touche de légèreté et de bienveillance, mais en ajoutant un brin d’humour.",
|
||||||
|
"Réponds en 1 phrase de manière décalée, mais avec un fond de vérité sous le ton léger.",
|
||||||
|
|
||||||
|
"Réponds avec humour en 1 phrase, sans trop te prendre au sérieux.",
|
||||||
|
"Réponds avec un peu de sarcasme, mais reste concis.",
|
||||||
|
"Sois direct, avec une touche d'humour, mais ne dépasse pas 15 mots.",
|
||||||
|
"Réponds en mode décalé, mais garde la réponse courte et punchy.",
|
||||||
|
"Réponds avec un ton léger et drôle, en 1 phrase seulement.",
|
||||||
|
"Réponds de manière concise, avec un brin d’ironie.",
|
||||||
|
"Réponds avec une touche d’humour rapide et percutante.",
|
||||||
|
"Réponds de manière brève mais amusante, sans fioritures.",
|
||||||
|
"Réponds avec un peu de moquerie gentille, mais court.",
|
||||||
|
"Sois concis et drôle, avec une touche de légèreté."
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
@@ -0,0 +1,19 @@
|
|||||||
|
[
|
||||||
|
{
|
||||||
|
"tw_acc_pseudo": "foufure13",
|
||||||
|
"tw_acc_token": "oauth:nmpw9bypx9emht7hn5z3vlgbwitaz5",
|
||||||
|
"charactere": "Kappa"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"tw_acc_pseudo": "SnowLunaSoft",
|
||||||
|
"tw_acc_token": "oauth:f9rt5mvhtjx3naiz1or9x7ims8ssm6",
|
||||||
|
"charactere": "Kappa"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"tw_acc_pseudo": "exoticnaturees",
|
||||||
|
"tw_acc_token": "oauth:57ht6937k5du8bex534eetd1epydvg",
|
||||||
|
"charactere": "Kappa"
|
||||||
|
}
|
||||||
|
|
||||||
|
]
|
||||||
|
|
||||||
@@ -0,0 +1,268 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
import os
|
||||||
|
import signal
|
||||||
|
import sys
|
||||||
|
import argparse
|
||||||
|
import json
|
||||||
|
import time
|
||||||
|
import pprint
|
||||||
|
import random
|
||||||
|
import requests
|
||||||
|
import datetime
|
||||||
|
import glob
|
||||||
|
import threading
|
||||||
|
# import keyboard
|
||||||
|
from pynput import keyboard
|
||||||
|
from threading import Thread, Semaphore
|
||||||
|
from streamlink import Streamlink
|
||||||
|
from fake_useragent import UserAgent
|
||||||
|
from rich.console import Console
|
||||||
|
from rich.live import Live
|
||||||
|
from rich.prompt import Prompt
|
||||||
|
from rich.spinner import Spinner
|
||||||
|
from rich.table import Table
|
||||||
|
from rich.text import Text
|
||||||
|
import subprocess
|
||||||
|
import pty
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
console = Console()
|
||||||
|
|
||||||
|
class MessageTwitch:
|
||||||
|
def __init__(self, channel_name):
|
||||||
|
with open("config.json", 'r') as file:
|
||||||
|
self.config = json.load(file)
|
||||||
|
|
||||||
|
self.channel_name = channel_name
|
||||||
|
self.channel_url = "https://www.twitch.tv/" + self.channel_name
|
||||||
|
self.dir_twitchrecord = "twitch-recordAudio"
|
||||||
|
self.dir_whisperX = "whisperX"
|
||||||
|
self.subtitle = {}
|
||||||
|
self.all_subtitle = ""
|
||||||
|
self.response_stream = "Hello !"
|
||||||
|
self.current_record = ""
|
||||||
|
|
||||||
|
self.language = self.get_value_json("language")
|
||||||
|
self.list_prompt = self.get_value_json("list_prompt")
|
||||||
|
self.bad_answer = self.get_value_json("bad_answer")
|
||||||
|
self.tw_acc_pseudo = self.get_value_json("tw_acc_pseudo")
|
||||||
|
self.tw_acc_token = self.get_value_json("tw_acc_token")
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
def get_value_json(self, var_name):
|
||||||
|
return self.config.get(var_name)
|
||||||
|
|
||||||
|
def hprint(self,color, texte):
|
||||||
|
timestamp = datetime.datetime.now().strftime("%Hh %Mm %Ss")
|
||||||
|
console.print("[bold "+color+"] ["+timestamp+"] "+texte+" [/bold "+color+"]")
|
||||||
|
|
||||||
|
def del_file(self, dossier, file):
|
||||||
|
motif = os.path.join(dossier, file)
|
||||||
|
for file in glob.glob(motif):
|
||||||
|
os.remove(file)
|
||||||
|
self.hprint("",f"file deleted : {file}")
|
||||||
|
|
||||||
|
|
||||||
|
# Fonction pour convertir l'heure en secondes
|
||||||
|
# def time_to_seconds(time_str):
|
||||||
|
# h, m = map(int, time_str.split(':'))
|
||||||
|
# return h * 3600 + m * 60
|
||||||
|
def time_to_seconds(time_str):
|
||||||
|
h, m, s = map(int, time_str.split(':'))
|
||||||
|
return h * 3600 + m * 60 + s
|
||||||
|
|
||||||
|
# Fonction pour obtenir l'heure actuelle sous forme de chaîne
|
||||||
|
def get_current_time(self):
|
||||||
|
current_time = time.time()
|
||||||
|
return time.strftime('%H:%M:%S', time.localtime(current_time))
|
||||||
|
# now = datetime.now()
|
||||||
|
# return now.strftime("%H:%M")
|
||||||
|
|
||||||
|
# Fonction pour rechercher dans le dictionnaire
|
||||||
|
def search_dict(d, key):
|
||||||
|
return d.get(key, "Key not found")
|
||||||
|
|
||||||
|
def get_last_values(self, n):
|
||||||
|
values = list(self.subtitle.values())
|
||||||
|
return ''.join(values[-n:])
|
||||||
|
|
||||||
|
def get_value_by_index(self, index):
|
||||||
|
values = list(self.subtitle.values())
|
||||||
|
if index < len(values):
|
||||||
|
return values[index]
|
||||||
|
else:
|
||||||
|
return None
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
def verif_file_transcribe(self, dir):
|
||||||
|
for file in os.listdir(dir):
|
||||||
|
file_path = os.path.join(dir, file)
|
||||||
|
if os.path.isfile(file_path):
|
||||||
|
self.hprint("blue",f"File find -> transcribe.")
|
||||||
|
# Exécuter une fonction sur le fichier
|
||||||
|
self.auto_create_subtitle(file, dir)
|
||||||
|
|
||||||
|
# Supprimer le fichier après le traitement
|
||||||
|
os.remove(file_path)
|
||||||
|
print(f"Fichier {file_path} supprimé.")
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
def boucle_traitement(self, intervalle):
|
||||||
|
count_loop = 0
|
||||||
|
try:
|
||||||
|
while True:
|
||||||
|
self.hprint("blue",f"wait {intervalle} loop main.")
|
||||||
|
self.verif_file_transcribe("record")
|
||||||
|
|
||||||
|
if (count_loop >= 4):
|
||||||
|
self.hprint("blue",f"count_loop ==4 on lance gpt + message")
|
||||||
|
count_loop = 0
|
||||||
|
imagine_response = Thread(target=self.imagine_response)
|
||||||
|
imagine_response.start()
|
||||||
|
imagine_response.join() # Wait for the recording to finish
|
||||||
|
|
||||||
|
|
||||||
|
time.sleep(intervalle) # Attend 'intervalle' secondes avant la prochaine itération
|
||||||
|
count_loop += 1
|
||||||
|
except KeyboardInterrupt:
|
||||||
|
print("Arrêt du script.")
|
||||||
|
|
||||||
|
|
||||||
|
def imagine_response(self):
|
||||||
|
self.hprint("green",f"start imagine_response\n")
|
||||||
|
|
||||||
|
streamer_word = ""
|
||||||
|
self.hprint("blue",f"word in streamer_word : \n"+str(len(streamer_word)))
|
||||||
|
if len(self.subtitle) >= 6:
|
||||||
|
index = 6
|
||||||
|
streamer_word = self.get_last_values(index)
|
||||||
|
while len(streamer_word) < 100:
|
||||||
|
self.hprint("yellow",f"streamer_word to short add text\n")
|
||||||
|
index=index+1
|
||||||
|
if len(self.subtitle) >= index:
|
||||||
|
streamer_word = self.get_last_values(index)
|
||||||
|
else:
|
||||||
|
break
|
||||||
|
elif len(self.subtitle) >= 4:
|
||||||
|
streamer_word = self.get_last_values(4)
|
||||||
|
elif len(self.subtitle) >= 2:
|
||||||
|
streamer_word = self.get_last_values(2)
|
||||||
|
else :
|
||||||
|
streamer_word = self.all_subtitle
|
||||||
|
|
||||||
|
values = list(self.subtitle.values())
|
||||||
|
index = len(values)
|
||||||
|
while len(streamer_word) < 100 and index > 0:
|
||||||
|
index -= 1
|
||||||
|
streamer_word += values[index]
|
||||||
|
|
||||||
|
|
||||||
|
self.hprint("magenta","streamer_word : "+str(streamer_word)+"\n")
|
||||||
|
|
||||||
|
load_reponse = True
|
||||||
|
well_response = True
|
||||||
|
countload = 0
|
||||||
|
while load_reponse:
|
||||||
|
|
||||||
|
prompt_gpt = ['tgpt','-q','-w', '"'+self.list_prompt[countload]+' "'+ streamer_word+'"']
|
||||||
|
# self.hprint("DARKCYAN","\nPrompt demandé : "+str(prompt_gpt)+"\n")
|
||||||
|
process = subprocess.run(prompt_gpt, capture_output=True, text=True, check=False)
|
||||||
|
self.response_stream = process.stdout.replace("'", "").replace('"', "").replace("\n", "")
|
||||||
|
# console.print("réponse imaginé : "+self.response_stream)
|
||||||
|
|
||||||
|
nombre_de_mots = len(self.response_stream.split())
|
||||||
|
nombre_de_caracteres = len(self.response_stream)
|
||||||
|
|
||||||
|
self.hprint("CYAN","réponse imaginé : "+self.response_stream+"\n\n")
|
||||||
|
# load_reponse = False
|
||||||
|
|
||||||
|
# if (self.string_contient(self.bad_answer, self.response_stream)):
|
||||||
|
# console.print("[bold red] contient mot incorect [/bold red]\n")
|
||||||
|
# countload+=1
|
||||||
|
# continue
|
||||||
|
|
||||||
|
|
||||||
|
if (nombre_de_mots < 22):
|
||||||
|
load_reponse = False
|
||||||
|
console.print("[bold green]result create : "+self.response_stream+"[/bold green]\n\n")
|
||||||
|
else:
|
||||||
|
self.hprint("red","incorect result\n")
|
||||||
|
|
||||||
|
if (countload > 3):
|
||||||
|
self.hprint("red","tentative de load trop grosse\n")
|
||||||
|
self.response_stream = "Kappa"
|
||||||
|
load_reponse = False
|
||||||
|
countload+=1
|
||||||
|
|
||||||
|
console.print("finish imagine_response")
|
||||||
|
if (well_response):
|
||||||
|
self.hprint("green","send message")
|
||||||
|
send_message = Thread(target=self.send_message)
|
||||||
|
send_message.start()
|
||||||
|
send_message.join() # Wait for the recording to finish
|
||||||
|
|
||||||
|
|
||||||
|
def send_message(self):
|
||||||
|
self.hprint("green","startsend_message")
|
||||||
|
|
||||||
|
command = '-pseudo "'+self.tw_acc_pseudo+'" -token "'+self.tw_acc_token+'" -twitchname "'+self.channel_name+'" -message " Kappa '+self.response_stream+'"'
|
||||||
|
message_tosend = 'python send_message.py '+command
|
||||||
|
console.print("[bold yellow]"+str(message_tosend)+"[/bold yellow]")
|
||||||
|
subprocess.run(message_tosend, shell=True)
|
||||||
|
console.print("finish send_message")
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
def main(self):
|
||||||
|
|
||||||
|
self.hprint("blue", "wait 30")
|
||||||
|
time.sleep(30)
|
||||||
|
|
||||||
|
self.hprint("blue", "start loop all")
|
||||||
|
boucle_traitement = Thread(target=self.boucle_traitement(30))
|
||||||
|
boucle_traitement.start()
|
||||||
|
# boucle_traitement.join() # Wait for the recording to finish
|
||||||
|
|
||||||
|
|
||||||
|
# #console.print("[bold green]Enregistrement terminé, le programme va se terminer.[/bold green]")
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -0,0 +1,710 @@
|
|||||||
|
45.144.65.29:4444
|
||||||
|
45.95.203.159:4444
|
||||||
|
220.248.70.237:9002
|
||||||
|
5.255.97.208:80
|
||||||
|
38.180.112.116:80
|
||||||
|
62.33.207.202:80
|
||||||
|
61.133.66.69:9002
|
||||||
|
45.95.203.100:4444
|
||||||
|
45.144.65.15:4444
|
||||||
|
117.160.250.163:80
|
||||||
|
142.93.2.226:8000
|
||||||
|
5.135.83.214:80
|
||||||
|
181.28.111.161:8080
|
||||||
|
117.160.250.163:8828
|
||||||
|
72.10.164.178:18587
|
||||||
|
72.10.160.174:1885
|
||||||
|
47.88.3.19:8080
|
||||||
|
67.43.227.228:11135
|
||||||
|
60.12.168.114:9002
|
||||||
|
45.11.95.165:6033
|
||||||
|
213.217.30.69:3128
|
||||||
|
77.238.123.226:80
|
||||||
|
3.127.203.145:8888
|
||||||
|
45.90.219.26:4444
|
||||||
|
112.30.155.83:12792
|
||||||
|
221.231.13.198:1080
|
||||||
|
117.160.250.132:80
|
||||||
|
157.25.92.74:3128
|
||||||
|
213.233.177.134:80
|
||||||
|
175.139.233.76:80
|
||||||
|
111.16.50.12:9002
|
||||||
|
62.33.207.202:3128
|
||||||
|
91.189.177.190:3128
|
||||||
|
72.10.160.90:4165
|
||||||
|
188.165.213.106:80
|
||||||
|
117.160.250.133:80
|
||||||
|
43.231.22.228:80
|
||||||
|
181.65.200.53:80
|
||||||
|
39.165.0.137:9002
|
||||||
|
82.165.105.48:80
|
||||||
|
111.247.40.246:80
|
||||||
|
72.10.164.178:17137
|
||||||
|
45.144.65.20:4444
|
||||||
|
72.10.160.173:13387
|
||||||
|
67.43.228.253:26621
|
||||||
|
67.43.227.226:22227
|
||||||
|
72.10.160.90:15581
|
||||||
|
117.160.250.163:82
|
||||||
|
103.163.51.254:80
|
||||||
|
103.115.31.181:8090
|
||||||
|
45.144.65.13:4444
|
||||||
|
47.100.206.238:8080
|
||||||
|
45.144.65.8:4444
|
||||||
|
62.33.207.201:3128
|
||||||
|
66.225.246.238:8080
|
||||||
|
91.189.177.189:3128
|
||||||
|
103.59.44.33:2022
|
||||||
|
45.95.203.92:4444
|
||||||
|
176.65.240.15:80
|
||||||
|
185.212.60.62:80
|
||||||
|
82.223.102.92:9443
|
||||||
|
72.10.160.170:18935
|
||||||
|
38.145.211.246:8899
|
||||||
|
182.106.220.252:9091
|
||||||
|
5.252.23.206:3128
|
||||||
|
123.233.245.158:9080
|
||||||
|
178.128.200.87:80
|
||||||
|
36.226.245.61:80
|
||||||
|
182.176.164.41:8080
|
||||||
|
146.59.202.70:80
|
||||||
|
159.69.230.19:80
|
||||||
|
3.127.203.145:999
|
||||||
|
72.169.65.145:87
|
||||||
|
58.20.248.139:9002
|
||||||
|
37.1.199.18:80
|
||||||
|
111.225.153.104:8089
|
||||||
|
88.51.214.182:80
|
||||||
|
119.39.68.76:2323
|
||||||
|
45.95.203.137:4444
|
||||||
|
190.60.35.50:8080
|
||||||
|
45.95.203.201:4444
|
||||||
|
45.95.203.114:4444
|
||||||
|
3.127.203.145:80
|
||||||
|
41.65.236.56:1976
|
||||||
|
124.158.153.218:8180
|
||||||
|
72.10.164.178:9577
|
||||||
|
117.160.250.134:80
|
||||||
|
72.10.160.171:7639
|
||||||
|
65.109.203.176:80
|
||||||
|
103.179.46.49:6789
|
||||||
|
51.89.14.70:80
|
||||||
|
116.63.129.202:6000
|
||||||
|
123.233.245.158:9443
|
||||||
|
91.189.177.188:3128
|
||||||
|
45.184.128.45:8181
|
||||||
|
116.203.239.33:80
|
||||||
|
45.71.185.242:999
|
||||||
|
72.10.164.178:5775
|
||||||
|
189.151.117.130:999
|
||||||
|
45.90.219.34:4444
|
||||||
|
47.242.49.10:8888
|
||||||
|
154.85.58.149:80
|
||||||
|
72.10.164.178:1769
|
||||||
|
117.160.250.138:80
|
||||||
|
120.48.62.239:8080
|
||||||
|
142.147.114.50:8080
|
||||||
|
45.231.142.22:3128
|
||||||
|
45.11.95.165:5219
|
||||||
|
69.160.9.166:8080
|
||||||
|
37.195.222.7:52815
|
||||||
|
207.246.105.172:8899
|
||||||
|
45.191.75.176:999
|
||||||
|
103.5.108.129:8085
|
||||||
|
210.212.39.130:8080
|
||||||
|
110.164.175.110:8080
|
||||||
|
123.182.59.177:8089
|
||||||
|
80.66.89.213:4000
|
||||||
|
45.144.65.30:4444
|
||||||
|
61.110.5.2:80
|
||||||
|
62.40.157.231:32650
|
||||||
|
67.43.236.20:19007
|
||||||
|
45.178.133.78:999
|
||||||
|
84.39.112.144:3128
|
||||||
|
181.31.225.234:3128
|
||||||
|
103.59.44.75:8080
|
||||||
|
103.52.36.49:32650
|
||||||
|
103.105.76.214:9090
|
||||||
|
67.43.227.228:30125
|
||||||
|
72.10.164.178:2509
|
||||||
|
45.11.95.165:5033
|
||||||
|
103.13.120.116:3128
|
||||||
|
103.169.130.49:8080
|
||||||
|
78.29.36.210:9080
|
||||||
|
103.247.23.202:8080
|
||||||
|
103.84.235.162:8789
|
||||||
|
123.182.58.193:8089
|
||||||
|
212.224.107.147:80
|
||||||
|
8.222.152.158:55555
|
||||||
|
105.112.140.218:8080
|
||||||
|
140.238.220.85:80
|
||||||
|
45.178.133.77:999
|
||||||
|
51.75.206.209:80
|
||||||
|
49.13.161.231:80
|
||||||
|
72.10.160.90:1279
|
||||||
|
103.127.220.74:8181
|
||||||
|
72.10.160.93:21397
|
||||||
|
162.144.233.16:80
|
||||||
|
202.29.215.78:8080
|
||||||
|
195.114.209.50:80
|
||||||
|
186.215.87.194:6020
|
||||||
|
45.144.65.10:4444
|
||||||
|
115.178.49.181:8080
|
||||||
|
123.182.59.204:8089
|
||||||
|
46.101.179.49:3129
|
||||||
|
181.10.181.107:999
|
||||||
|
46.101.115.59:80
|
||||||
|
62.162.90.212:80
|
||||||
|
82.113.157.122:31280
|
||||||
|
67.43.228.254:5025
|
||||||
|
72.10.160.90:31365
|
||||||
|
189.203.181.34:8080
|
||||||
|
35.185.196.38:3128
|
||||||
|
117.160.250.131:8899
|
||||||
|
45.5.139.241:8080
|
||||||
|
188.132.222.7:8080
|
||||||
|
103.113.71.230:3128
|
||||||
|
103.174.238.105:8090
|
||||||
|
172.93.213.177:80
|
||||||
|
45.95.203.115:4444
|
||||||
|
117.4.50.142:32650
|
||||||
|
64.159.159.124:3129
|
||||||
|
45.95.203.225:4444
|
||||||
|
45.89.65.217:4444
|
||||||
|
82.210.56.251:80
|
||||||
|
83.169.17.201:80
|
||||||
|
2.47.51.18:8080
|
||||||
|
45.234.61.12:999
|
||||||
|
88.79.243.103:3128
|
||||||
|
202.142.158.114:8080
|
||||||
|
72.10.160.93:11633
|
||||||
|
82.64.77.30:80
|
||||||
|
111.59.4.88:9002
|
||||||
|
111.225.152.30:8089
|
||||||
|
201.77.108.72:999
|
||||||
|
202.191.123.195:8090
|
||||||
|
92.242.212.50:8080
|
||||||
|
50.62.183.223:80
|
||||||
|
94.131.107.45:3128
|
||||||
|
190.108.12.117:8080
|
||||||
|
82.180.139.155:80
|
||||||
|
186.215.87.194:6009
|
||||||
|
190.97.233.22:999
|
||||||
|
206.81.31.215:80
|
||||||
|
120.253.104.21:4444
|
||||||
|
74.48.7.43:80
|
||||||
|
91.204.239.189:8080
|
||||||
|
120.234.203.171:9002
|
||||||
|
103.30.30.73:8080
|
||||||
|
67.43.227.227:26659
|
||||||
|
103.153.247.102:8181
|
||||||
|
38.253.88.242:999
|
||||||
|
217.197.237.74:8080
|
||||||
|
146.196.110.13:3888
|
||||||
|
181.78.95.48:999
|
||||||
|
103.125.240.237:8080
|
||||||
|
123.13.218.68:9002
|
||||||
|
45.90.219.12:4444
|
||||||
|
103.179.246.30:8080
|
||||||
|
190.97.238.83:999
|
||||||
|
187.190.49.166:999
|
||||||
|
43.133.136.208:8800
|
||||||
|
181.10.160.156:8080
|
||||||
|
111.20.217.178:9091
|
||||||
|
103.156.15.212:8080
|
||||||
|
79.106.33.26:8079
|
||||||
|
122.54.105.109:8082
|
||||||
|
45.95.203.138:4444
|
||||||
|
181.129.130.18:8154
|
||||||
|
186.148.195.165:999
|
||||||
|
45.95.203.167:4444
|
||||||
|
89.211.187.195:8080
|
||||||
|
46.232.248.164:80
|
||||||
|
94.154.152.41:8079
|
||||||
|
148.230.206.229:8080
|
||||||
|
72.10.160.171:18889
|
||||||
|
91.189.177.186:3128
|
||||||
|
45.71.185.245:999
|
||||||
|
157.245.95.247:443
|
||||||
|
111.95.41.44:8080
|
||||||
|
80.13.43.193:80
|
||||||
|
111.225.152.140:8089
|
||||||
|
103.250.130.111:8080
|
||||||
|
103.124.137.203:3128
|
||||||
|
190.103.177.131:80
|
||||||
|
118.97.164.19:8080
|
||||||
|
222.64.104.82:9000
|
||||||
|
103.159.46.41:83
|
||||||
|
106.51.62.106:8080
|
||||||
|
103.177.10.139:8080
|
||||||
|
64.188.4.202:80
|
||||||
|
202.12.80.7:84
|
||||||
|
67.43.227.227:24887
|
||||||
|
38.158.202.8:999
|
||||||
|
119.93.148.191:8080
|
||||||
|
103.153.154.6:80
|
||||||
|
81.12.40.250:8080
|
||||||
|
177.234.221.27:999
|
||||||
|
182.253.39.206:8080
|
||||||
|
45.93.17.108:3133
|
||||||
|
34.154.161.152:80
|
||||||
|
185.49.170.20:43626
|
||||||
|
162.252.151.113:8282
|
||||||
|
32.142.206.26:9081
|
||||||
|
67.43.227.227:25323
|
||||||
|
103.146.170.252:83
|
||||||
|
195.178.56.35:8080
|
||||||
|
72.10.160.170:1899
|
||||||
|
146.190.35.141:8000
|
||||||
|
117.160.250.163:9999
|
||||||
|
82.97.215.240:80
|
||||||
|
103.41.90.52:83
|
||||||
|
85.117.60.131:8080
|
||||||
|
38.7.1.113:999
|
||||||
|
41.59.112.250:3030
|
||||||
|
117.160.250.163:81
|
||||||
|
34.175.101.255:80
|
||||||
|
72.10.164.178:12197
|
||||||
|
190.202.111.202:8080
|
||||||
|
207.230.8.75:999
|
||||||
|
185.139.228.188:80
|
||||||
|
188.132.221.135:8080
|
||||||
|
138.68.235.51:80
|
||||||
|
51.91.109.83:80
|
||||||
|
45.90.218.210:4444
|
||||||
|
138.197.102.119:80
|
||||||
|
45.174.57.34:999
|
||||||
|
83.219.145.106:3128
|
||||||
|
182.160.29.120:3128
|
||||||
|
183.230.162.122:9091
|
||||||
|
45.191.46.210:999
|
||||||
|
43.243.172.2:82
|
||||||
|
45.71.202.148:1993
|
||||||
|
58.246.58.150:9002
|
||||||
|
200.125.168.221:999
|
||||||
|
42.61.48.219:8000
|
||||||
|
46.17.104.163:4444
|
||||||
|
72.10.164.178:20149
|
||||||
|
178.128.113.118:23128
|
||||||
|
183.215.23.242:9091
|
||||||
|
45.144.65.14:4444
|
||||||
|
190.217.69.203:999
|
||||||
|
201.91.82.155:3128
|
||||||
|
45.144.65.175:4444
|
||||||
|
41.33.203.233:1975
|
||||||
|
45.90.218.209:4444
|
||||||
|
107.173.148.173:3128
|
||||||
|
129.151.228.63:80
|
||||||
|
64.159.159.122:3129
|
||||||
|
74.48.78.52:80
|
||||||
|
191.102.254.27:8085
|
||||||
|
72.10.160.170:5671
|
||||||
|
154.236.179.229:1976
|
||||||
|
45.224.23.251:999
|
||||||
|
72.10.160.173:13615
|
||||||
|
61.29.96.146:80
|
||||||
|
45.144.65.17:4444
|
||||||
|
94.154.152.4:8079
|
||||||
|
223.112.53.2:1025
|
||||||
|
46.17.104.192:4444
|
||||||
|
103.174.236.52:8080
|
||||||
|
64.159.159.123:3129
|
||||||
|
67.43.236.21:1847
|
||||||
|
117.160.250.132:8899
|
||||||
|
190.90.233.25:8080
|
||||||
|
113.125.82.11:3128
|
||||||
|
129.151.228.63:8079
|
||||||
|
103.124.139.184:8080
|
||||||
|
102.132.201.202:80
|
||||||
|
181.205.243.147:999
|
||||||
|
199.223.255.109:3128
|
||||||
|
12.176.231.147:80
|
||||||
|
82.65.220.152:80
|
||||||
|
38.10.69.104:9090
|
||||||
|
38.51.243.145:999
|
||||||
|
197.211.8.166:8080
|
||||||
|
202.137.8.151:8080
|
||||||
|
5.75.200.38:80
|
||||||
|
94.153.163.226:81
|
||||||
|
45.95.203.165:4444
|
||||||
|
216.176.187.99:39837
|
||||||
|
41.65.0.206:1981
|
||||||
|
183.100.14.134:8000
|
||||||
|
102.68.128.217:8080
|
||||||
|
204.199.120.62:999
|
||||||
|
190.61.84.166:9812
|
||||||
|
72.10.160.172:8019
|
||||||
|
72.10.164.178:28787
|
||||||
|
51.159.66.158:3128
|
||||||
|
181.209.111.148:999
|
||||||
|
14.103.26.198:8000
|
||||||
|
111.225.153.75:8089
|
||||||
|
119.18.149.110:5020
|
||||||
|
45.95.203.213:4444
|
||||||
|
45.124.184.13:80
|
||||||
|
102.219.85.118:3128
|
||||||
|
152.230.215.123:80
|
||||||
|
27.64.123.82:8080
|
||||||
|
67.43.227.230:24153
|
||||||
|
193.38.224.169:8081
|
||||||
|
183.234.215.11:8443
|
||||||
|
34.135.166.24:80
|
||||||
|
218.6.120.111:7777
|
||||||
|
103.197.71.7:80
|
||||||
|
67.43.236.20:1777
|
||||||
|
46.250.240.209:3128
|
||||||
|
67.43.236.20:5189
|
||||||
|
185.104.252.10:9090
|
||||||
|
180.250.143.189:497
|
||||||
|
45.95.203.85:4444
|
||||||
|
43.255.113.232:86
|
||||||
|
72.167.132.66:3128
|
||||||
|
89.145.162.81:3128
|
||||||
|
91.151.90.239:80
|
||||||
|
67.43.236.20:2273
|
||||||
|
45.11.95.166:6001
|
||||||
|
190.94.212.76:999
|
||||||
|
20.193.154.130:8888
|
||||||
|
149.129.51.152:443
|
||||||
|
181.88.151.38:8080
|
||||||
|
218.75.69.50:57903
|
||||||
|
23.137.248.197:80
|
||||||
|
101.255.151.69:3125
|
||||||
|
93.123.22.151:80
|
||||||
|
103.154.230.58:8080
|
||||||
|
182.253.181.10:8080
|
||||||
|
103.118.46.12:32650
|
||||||
|
72.10.164.178:2289
|
||||||
|
38.7.24.17:8080
|
||||||
|
12.186.205.122:80
|
||||||
|
185.199.53.73:80
|
||||||
|
117.160.250.133:8899
|
||||||
|
61.173.116.207:8888
|
||||||
|
72.10.160.90:24843
|
||||||
|
159.65.221.25:80
|
||||||
|
72.10.160.90:1051
|
||||||
|
147.12.46.62:3128
|
||||||
|
103.204.82.34:3212
|
||||||
|
124.104.149.53:8081
|
||||||
|
201.20.67.70:8080
|
||||||
|
111.225.153.62:8089
|
||||||
|
103.184.19.73:8080
|
||||||
|
131.100.48.73:999
|
||||||
|
193.138.178.246:8282
|
||||||
|
190.119.68.141:999
|
||||||
|
202.70.145.26:4995
|
||||||
|
62.72.56.132:80
|
||||||
|
144.91.77.153:3128
|
||||||
|
187.73.225.96:777
|
||||||
|
41.40.81.208:8080
|
||||||
|
188.234.147.54:8019
|
||||||
|
181.78.107.95:999
|
||||||
|
45.117.179.209:80
|
||||||
|
23.225.133.80:41698
|
||||||
|
67.43.227.227:31743
|
||||||
|
137.59.48.20:8080
|
||||||
|
167.249.29.220:999
|
||||||
|
196.219.202.74:8080
|
||||||
|
46.161.194.91:8085
|
||||||
|
72.10.160.90:32373
|
||||||
|
117.160.250.134:8899
|
||||||
|
72.10.164.178:32313
|
||||||
|
123.126.158.50:80
|
||||||
|
36.64.162.194:8080
|
||||||
|
103.133.25.18:8181
|
||||||
|
103.217.224.53:3127
|
||||||
|
187.102.216.217:999
|
||||||
|
36.91.20.5:8080
|
||||||
|
177.93.40.54:999
|
||||||
|
194.182.187.78:3128
|
||||||
|
177.19.167.242:80
|
||||||
|
202.154.189.189:8080
|
||||||
|
182.160.110.154:9898
|
||||||
|
51.15.242.202:8888
|
||||||
|
43.247.38.57:8080
|
||||||
|
170.239.207.229:999
|
||||||
|
114.129.2.82:8081
|
||||||
|
91.196.77.225:8085
|
||||||
|
179.1.192.58:999
|
||||||
|
65.18.114.254:55443
|
||||||
|
72.10.164.178:23361
|
||||||
|
103.217.224.139:8040
|
||||||
|
173.213.71.7:80
|
||||||
|
3.127.203.145:8080
|
||||||
|
45.11.95.165:5206
|
||||||
|
41.65.236.57:1976
|
||||||
|
117.160.250.138:8899
|
||||||
|
103.36.10.21:3125
|
||||||
|
103.193.144.90:8080
|
||||||
|
103.161.30.65:83
|
||||||
|
45.6.224.254:999
|
||||||
|
62.3.30.70:8080
|
||||||
|
103.131.232.126:8080
|
||||||
|
103.155.62.158:8080
|
||||||
|
190.120.249.180:999
|
||||||
|
216.137.184.253:80
|
||||||
|
94.154.152.109:8079
|
||||||
|
5.252.23.249:3128
|
||||||
|
201.217.246.212:8080
|
||||||
|
45.95.203.139:4444
|
||||||
|
123.182.58.40:8089
|
||||||
|
213.133.98.201:1369
|
||||||
|
190.128.195.58:999
|
||||||
|
41.174.132.58:8080
|
||||||
|
41.65.236.37:1976
|
||||||
|
41.65.0.206:1976
|
||||||
|
103.146.185.139:1111
|
||||||
|
38.156.73.54:8080
|
||||||
|
133.18.234.13:80
|
||||||
|
38.252.209.32:999
|
||||||
|
193.106.138.52:3128
|
||||||
|
202.152.51.44:8080
|
||||||
|
47.114.101.57:8888
|
||||||
|
67.43.228.253:30473
|
||||||
|
185.189.199.77:8080
|
||||||
|
152.231.25.58:8080
|
||||||
|
191.102.254.26:8085
|
||||||
|
170.238.104.213:8080
|
||||||
|
103.103.88.100:8090
|
||||||
|
72.10.164.178:6091
|
||||||
|
188.163.170.130:41209
|
||||||
|
103.53.78.26:8080
|
||||||
|
23.162.160.1:16099
|
||||||
|
103.114.97.98:8999
|
||||||
|
1.32.59.217:47045
|
||||||
|
45.174.57.22:999
|
||||||
|
45.95.203.109:4444
|
||||||
|
45.5.136.6:8080
|
||||||
|
223.113.80.158:9091
|
||||||
|
190.128.225.117:999
|
||||||
|
185.139.56.133:6961
|
||||||
|
103.213.116.5:8080
|
||||||
|
72.169.67.241:87
|
||||||
|
116.212.140.118:8080
|
||||||
|
103.250.70.214:8080
|
||||||
|
45.95.203.198:4444
|
||||||
|
72.10.160.94:8123
|
||||||
|
45.240.182.120:1976
|
||||||
|
88.198.199.53:80
|
||||||
|
147.139.140.74:80
|
||||||
|
103.162.50.13:8080
|
||||||
|
67.43.236.20:1789
|
||||||
|
186.96.95.205:999
|
||||||
|
175.100.98.190:8080
|
||||||
|
47.107.61.215:8000
|
||||||
|
202.12.80.14:83
|
||||||
|
45.229.10.98:8402
|
||||||
|
111.225.153.180:8089
|
||||||
|
45.95.203.129:4444
|
||||||
|
181.78.19.242:999
|
||||||
|
72.10.160.170:32221
|
||||||
|
23.132.48.1:999
|
||||||
|
185.74.6.248:8080
|
||||||
|
70.63.90.245:8080
|
||||||
|
103.84.177.246:8083
|
||||||
|
41.254.56.34:1981
|
||||||
|
93.123.16.188:3128
|
||||||
|
147.78.169.80:8443
|
||||||
|
188.119.99.210:80
|
||||||
|
188.132.222.5:8080
|
||||||
|
67.43.227.228:28203
|
||||||
|
45.95.203.176:4444
|
||||||
|
190.128.241.102:80
|
||||||
|
185.128.240.77:8080
|
||||||
|
45.95.203.150:4444
|
||||||
|
103.146.197.43:4995
|
||||||
|
45.144.65.12:4444
|
||||||
|
67.43.227.227:24863
|
||||||
|
108.170.12.11:80
|
||||||
|
67.43.227.228:22521
|
||||||
|
188.132.222.35:8080
|
||||||
|
103.139.188.41:7077
|
||||||
|
203.128.75.195:8080
|
||||||
|
47.243.92.199:3128
|
||||||
|
62.33.207.201:80
|
||||||
|
103.167.151.232:3128
|
||||||
|
129.213.150.205:80
|
||||||
|
45.90.218.215:4444
|
||||||
|
45.95.203.200:4444
|
||||||
|
67.43.228.250:16519
|
||||||
|
103.94.52.70:3128
|
||||||
|
81.145.54.212:80
|
||||||
|
190.90.39.78:999
|
||||||
|
60.188.102.225:18080
|
||||||
|
45.144.65.45:4444
|
||||||
|
103.172.196.139:8080
|
||||||
|
104.129.192.165:11267
|
||||||
|
139.255.10.237:8080
|
||||||
|
111.206.0.99:8181
|
||||||
|
67.43.228.253:22859
|
||||||
|
45.90.218.85:4444
|
||||||
|
181.209.89.66:999
|
||||||
|
219.65.42.161:80
|
||||||
|
84.204.40.155:8080
|
||||||
|
45.90.219.39:4444
|
||||||
|
194.182.163.117:3128
|
||||||
|
38.145.211.247:8899
|
||||||
|
80.240.130.161:8888
|
||||||
|
195.189.60.103:80
|
||||||
|
80.78.237.2:55443
|
||||||
|
103.145.160.3:8080
|
||||||
|
72.10.160.91:5177
|
||||||
|
103.160.184.222:8080
|
||||||
|
157.100.60.144:999
|
||||||
|
14.170.154.193:19132
|
||||||
|
45.144.65.21:4444
|
||||||
|
83.171.90.83:8080
|
||||||
|
111.225.153.175:8089
|
||||||
|
117.160.250.163:9990
|
||||||
|
103.158.220.90:84
|
||||||
|
202.51.212.146:8080
|
||||||
|
142.93.14.238:8888
|
||||||
|
72.10.160.90:17663
|
||||||
|
67.43.236.20:1581
|
||||||
|
167.172.96.213:80
|
||||||
|
115.96.208.124:8080
|
||||||
|
80.241.251.54:8080
|
||||||
|
185.247.18.200:8888
|
||||||
|
5.253.18.188:80
|
||||||
|
92.119.59.161:80
|
||||||
|
154.16.146.43:80
|
||||||
|
45.11.95.165:5035
|
||||||
|
103.10.231.189:8080
|
||||||
|
221.6.139.190:9002
|
||||||
|
103.105.76.249:8080
|
||||||
|
185.103.102.128:80
|
||||||
|
65.109.199.184:80
|
||||||
|
66.225.246.238:8123
|
||||||
|
72.10.160.90:21163
|
||||||
|
201.71.2.103:999
|
||||||
|
45.95.203.209:4444
|
||||||
|
108.170.12.14:80
|
||||||
|
135.181.154.225:80
|
||||||
|
124.105.24.80:8082
|
||||||
|
218.57.210.186:9002
|
||||||
|
160.72.98.165:3128
|
||||||
|
1.85.33.94:6666
|
||||||
|
93.188.161.84:80
|
||||||
|
188.166.56.246:80
|
||||||
|
103.86.109.38:80
|
||||||
|
51.145.176.250:8080
|
||||||
|
72.10.164.178:21313
|
||||||
|
136.243.89.93:8888
|
||||||
|
45.95.203.149:4444
|
||||||
|
219.65.42.160:80
|
||||||
|
202.38.181.129:8080
|
||||||
|
103.151.20.131:80
|
||||||
|
45.230.171.41:999
|
||||||
|
20.219.118.36:80
|
||||||
|
159.89.238.24:8000
|
||||||
|
154.19.84.127:8080
|
||||||
|
45.90.216.44:4444
|
||||||
|
154.16.146.47:80
|
||||||
|
36.93.130.219:66
|
||||||
|
67.43.236.20:18363
|
||||||
|
154.118.228.212:80
|
||||||
|
20.127.221.223:80
|
||||||
|
194.182.178.90:3128
|
||||||
|
72.10.160.170:1885
|
||||||
|
72.10.160.172:2955
|
||||||
|
120.37.121.209:9091
|
||||||
|
67.43.236.20:5497
|
||||||
|
191.36.212.250:9010
|
||||||
|
154.65.39.7:80
|
||||||
|
67.43.227.227:22933
|
||||||
|
77.119.237.96:55654
|
||||||
|
103.154.113.90:8080
|
||||||
|
197.98.201.97:10268
|
||||||
|
62.183.112.172:443
|
||||||
|
103.28.112.126:8080
|
||||||
|
192.151.255.25:41698
|
||||||
|
58.147.186.31:3125
|
||||||
|
192.151.255.22:41698
|
||||||
|
114.232.109.91:8089
|
||||||
|
202.154.19.218:8081
|
||||||
|
117.54.114.101:80
|
||||||
|
117.54.114.99:80
|
||||||
|
123.30.154.171:7777
|
||||||
|
117.54.114.35:80
|
||||||
|
117.54.114.96:80
|
||||||
|
117.54.114.100:80
|
||||||
|
97.64.69.57:16099
|
||||||
|
38.156.73.60:8080
|
||||||
|
143.208.59.2:999
|
||||||
|
114.232.110.145:8089
|
||||||
|
103.83.232.122:80
|
||||||
|
38.54.71.67:80
|
||||||
|
103.111.136.110:8080
|
||||||
|
103.111.118.65:1080
|
||||||
|
43.255.113.232:8083
|
||||||
|
117.54.114.98:80
|
||||||
|
188.136.162.3:7060
|
||||||
|
69.160.223.225:8181
|
||||||
|
103.49.202.252:80
|
||||||
|
43.255.113.232:84
|
||||||
|
114.231.41.219:8089
|
||||||
|
182.72.203.255:80
|
||||||
|
117.54.114.97:80
|
||||||
|
62.112.10.26:3128
|
||||||
|
114.231.82.175:8089
|
||||||
|
114.232.109.171:8089
|
||||||
|
117.54.114.102:80
|
||||||
|
41.65.236.56:1981
|
||||||
|
41.65.236.57:1981
|
||||||
|
36.6.144.194:8089
|
||||||
|
165.225.72.155:11164
|
||||||
|
114.231.45.176:8089
|
||||||
|
36.6.144.34:8089
|
||||||
|
114.231.41.224:8089
|
||||||
|
36.6.145.54:8089
|
||||||
|
183.164.243.135:8089
|
||||||
|
36.6.144.2:8089
|
||||||
|
36.6.145.236:8089
|
||||||
|
103.99.22.27:8080
|
||||||
|
190.114.245.122:999
|
||||||
|
103.139.144.128:8080
|
||||||
|
43.255.113.232:8084
|
||||||
|
178.46.163.102:3128
|
||||||
|
27.254.46.194:80
|
||||||
|
202.148.16.150:8080
|
||||||
|
177.54.229.0:9292
|
||||||
|
114.231.8.132:8089
|
||||||
|
41.204.63.118:80
|
||||||
|
178.115.253.35:8080
|
||||||
|
178.115.243.26:8080
|
||||||
|
185.123.101.160:80
|
||||||
|
183.81.156.98:8080
|
||||||
|
217.26.191.75:999
|
||||||
|
114.231.41.211:8089
|
||||||
|
197.98.201.97:10271
|
||||||
|
197.98.201.97:11001
|
||||||
|
197.98.201.97:21002
|
||||||
|
197.98.201.97:10884
|
||||||
|
197.98.201.97:11020
|
||||||
|
197.98.201.97:33333
|
||||||
|
197.98.201.97:12009
|
||||||
|
197.98.201.97:10015
|
||||||
|
114.231.45.147:8089
|
||||||
|
114.231.45.154:8089
|
||||||
|
114.231.82.195:8089
|
||||||
|
114.232.110.225:8089
|
||||||
|
114.231.46.235:8089
|
||||||
|
114.232.109.7:8089
|
||||||
|
43.252.238.86:8080
|
||||||
|
122.160.30.99:80
|
||||||
|
189.240.60.166:9090
|
||||||
|
195.35.32.249:80
|
||||||
|
41.231.37.76:3128
|
||||||
|
132.145.169.90:3128
|
||||||
|
41.223.136.162:80
|
||||||
|
94.182.146.250:8080
|
||||||
|
150.136.109.246:3128
|
||||||
|
196.61.74.41:8080
|
||||||
|
103.31.235.82:8080
|
||||||
|
14.160.32.23:8080
|
||||||
|
95.130.173.195:3128
|
||||||
|
190.95.195.105:999
|
||||||
|
185.89.156.2:44224
|
||||||
|
114.231.42.135:8089
|
||||||
|
114.232.109.2:8089
|
||||||
|
150.136.111.210:3128
|
||||||
@@ -0,0 +1,543 @@
|
|||||||
|
import os
|
||||||
|
import signal
|
||||||
|
import sys
|
||||||
|
import argparse
|
||||||
|
import json
|
||||||
|
import time
|
||||||
|
import pprint
|
||||||
|
import random
|
||||||
|
import requests
|
||||||
|
import datetime
|
||||||
|
import glob
|
||||||
|
import threading
|
||||||
|
# import keyboard
|
||||||
|
from pynput import keyboard
|
||||||
|
from threading import Thread, Semaphore
|
||||||
|
from streamlink import Streamlink
|
||||||
|
from fake_useragent import UserAgent
|
||||||
|
from rich.console import Console
|
||||||
|
from rich.live import Live
|
||||||
|
from rich.prompt import Prompt
|
||||||
|
from rich.spinner import Spinner
|
||||||
|
from rich.table import Table
|
||||||
|
from rich.text import Text
|
||||||
|
import subprocess
|
||||||
|
import pty
|
||||||
|
|
||||||
|
console = Console()
|
||||||
|
|
||||||
|
def hprint(color, texte):
|
||||||
|
timestamp = datetime.datetime.now().strftime("%Hh %Mm %Ss")
|
||||||
|
console.print("[bold "+color+"] ["+timestamp+"] "+texte+" [/bold "+color+"]")
|
||||||
|
|
||||||
|
def del_file(dossier, file):
|
||||||
|
motif = os.path.join(dossier, file)
|
||||||
|
for file in glob.glob(motif):
|
||||||
|
os.remove(file)
|
||||||
|
hprint("",f"file deleted : {file}")
|
||||||
|
|
||||||
|
def get_value_json(var_name, config):
|
||||||
|
return config.get(var_name)
|
||||||
|
|
||||||
|
def get_value_json_list(index, key, json_data):
|
||||||
|
try:
|
||||||
|
return json_data[index][key]
|
||||||
|
except (IndexError, KeyError, TypeError):
|
||||||
|
return None
|
||||||
|
|
||||||
|
# Fonction pour obtenir l'heure actuelle sous forme de chaîne
|
||||||
|
def get_current_time():
|
||||||
|
current_time = time.time()
|
||||||
|
return time.strftime('%H:%M:%S', time.localtime(current_time))
|
||||||
|
# now = datetime.now()
|
||||||
|
# return now.strftime("%H:%M")
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
################### RecordTwitch ########################
|
||||||
|
|
||||||
|
class RecordTwitch:
|
||||||
|
def __init__(self, channel_name, recordtime):
|
||||||
|
|
||||||
|
self.channel_name = channel_name
|
||||||
|
self.all_proxies = []
|
||||||
|
self.channel_url = "https://www.twitch.tv/" + self.channel_name
|
||||||
|
self.record_time = recordtime
|
||||||
|
self.dir_twitchrecord = "twitch-recordAudio"
|
||||||
|
self.process = None # Pour stocker le sous-processus en cours
|
||||||
|
|
||||||
|
|
||||||
|
if (self.record_time == -1):
|
||||||
|
self.record_time = 9999
|
||||||
|
|
||||||
|
def stop(self):
|
||||||
|
"""Arrête le processus d'enregistrement s'il est en cours."""
|
||||||
|
if self.process and self.process.poll() is None: # Vérifie si le processus est actif
|
||||||
|
hprint("yellow",f"Arrêt de l'enregistrement...")
|
||||||
|
self.process.terminate() # Envoie un signal de terminaison
|
||||||
|
try:
|
||||||
|
self.process.wait(timeout=5) # Attend la fin avec un délai de 5 secondes
|
||||||
|
except subprocess.TimeoutExpired:
|
||||||
|
hprint("RED",f"Le processus ne répond pas, forçage de l'arrêt.")
|
||||||
|
self.process.kill() # Forcer l'arrêt si le processus ne termine pas
|
||||||
|
hprint("yellow",f"Enregistrement arrêté.")
|
||||||
|
else:
|
||||||
|
hprint("green",f"Aucun enregistrement en cours.")
|
||||||
|
|
||||||
|
def hprint(self,color, texte):
|
||||||
|
timestamp = datetime.datetime.now().strftime("%Hh %Mm %Ss")
|
||||||
|
console.print("[bold "+color+"] ["+timestamp+"] "+texte+" [/bold "+color+"]")
|
||||||
|
|
||||||
|
|
||||||
|
# Fonction pour convertir l'heure en secondes
|
||||||
|
def time_to_seconds(time_str):
|
||||||
|
h, m, s = map(int, time_str.split(':'))
|
||||||
|
return h * 3600 + m * 60 + s
|
||||||
|
|
||||||
|
|
||||||
|
# Fonction pour rechercher dans le dictionnaire
|
||||||
|
def search_dict(d, key):
|
||||||
|
return d.get(key, "Key not found")
|
||||||
|
|
||||||
|
|
||||||
|
def main_record_twitch(self):
|
||||||
|
# Utiliser Popen à la place de run pour pouvoir arrêter le processus
|
||||||
|
try:
|
||||||
|
print(f"Lancement de l'enregistrement pour {self.channel_name} pendant {self.record_time} secondes.")
|
||||||
|
record_twitch = ['python', self.dir_twitchrecord+'/twitch_record_unlimited.py', '-twitchname', self.channel_name,'-recordtime',str(self.record_time)]
|
||||||
|
self.process = subprocess.Popen(record_twitch)
|
||||||
|
self.process.communicate() # Attend que le sous-processus termine
|
||||||
|
except Exception as e:
|
||||||
|
print(f"Erreur pendant l'enregistrement: {e}")
|
||||||
|
|
||||||
|
def start_recording(self):
|
||||||
|
"""Lance main_record_twitch dans un thread pour ne pas bloquer le code principal."""
|
||||||
|
self.thread = threading.Thread(target=self.main_record_twitch)
|
||||||
|
self.thread.start() # Démarre l'enregistrement dans un thread séparé
|
||||||
|
|
||||||
|
|
||||||
|
################### RecordTwitch FIN ########################
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
################### Subtitle ########################
|
||||||
|
|
||||||
|
|
||||||
|
class Subtitle_translation:
|
||||||
|
def __init__(self, pathjson):
|
||||||
|
self.pathjson = pathjson
|
||||||
|
self.reload_json()
|
||||||
|
self.dir_whisperX = "whisperX"
|
||||||
|
self.subtitle = {}
|
||||||
|
self.all_subtitle = ""
|
||||||
|
self.is_running = True
|
||||||
|
self.loop_timer = 30
|
||||||
|
self.language = get_value_json("language", self.config)
|
||||||
|
self.dir_record = "record"
|
||||||
|
|
||||||
|
def stop(self):
|
||||||
|
hprint("yellow",f"Arrêt loop subtitle")
|
||||||
|
self.is_running = False
|
||||||
|
if self.loop_thread.is_alive():
|
||||||
|
# self.loop_thread.join() # Attend la fin du thread pour un arrêt propre
|
||||||
|
hprint("red", "Boucle de traitement arrêtée.")
|
||||||
|
else :
|
||||||
|
hprint("yellow",f"loop subtitle déja arreté")
|
||||||
|
|
||||||
|
def reload_json(self):
|
||||||
|
with open(self.pathjson, 'r') as file:
|
||||||
|
self.config = json.load(file)
|
||||||
|
|
||||||
|
|
||||||
|
def verif_file_transcribe(self):
|
||||||
|
for file in os.listdir(self.dir_record):
|
||||||
|
file_path = os.path.join(self.dir_record, file)
|
||||||
|
if os.path.isfile(file_path):
|
||||||
|
hprint("blue",f"File find -> transcribe.")
|
||||||
|
# Exécuter une fonction sur le fichier
|
||||||
|
self.auto_create_subtitle(file)
|
||||||
|
|
||||||
|
# Supprimer le fichier après le traitement
|
||||||
|
os.remove(file_path)
|
||||||
|
print(f"Fichier {file_path} supprimé.")
|
||||||
|
|
||||||
|
|
||||||
|
def remove_repetitions(self, message):
|
||||||
|
"""
|
||||||
|
Supprime les répétitions dans un message en conservant uniquement le premier
|
||||||
|
exemple d'une phrase répétée.
|
||||||
|
|
||||||
|
:param message: Le message sous forme de chaîne de caractères
|
||||||
|
:return: Le message sans répétitions
|
||||||
|
"""
|
||||||
|
hprint("yellow", "remove_repetitions start for: \n" +message)
|
||||||
|
|
||||||
|
words = message.split() # Découpe le texte en mots
|
||||||
|
seen = set() # Pour suivre les mots déjà rencontrés
|
||||||
|
result = [] # Stocke les mots sans répétition
|
||||||
|
|
||||||
|
|
||||||
|
for word in words:
|
||||||
|
if word not in seen:
|
||||||
|
result.append(word)
|
||||||
|
seen.add(word)
|
||||||
|
|
||||||
|
hprint("green", "remove_repetitions cleaned text : \n" +" ".join(result))
|
||||||
|
return " ".join(result)## str this switch
|
||||||
|
|
||||||
|
def print_allsubtitle(self):
|
||||||
|
os.system('clear')
|
||||||
|
hprint("yellow", "\n\n All subtitle Print\n ")
|
||||||
|
for key, text in self.subtitle.items():
|
||||||
|
hprint("yellow", " time "+ str(key)+" = "+ text+" \n\n")
|
||||||
|
|
||||||
|
def get_lasttext(self):
|
||||||
|
# Vérifie que le dictionnaire n'est pas vide
|
||||||
|
if not self.subtitle:
|
||||||
|
hprint("red", "Aucun sous-titre disponible.")
|
||||||
|
return ""
|
||||||
|
|
||||||
|
# Récupère la dernière clé et valeur
|
||||||
|
last_time, last_text = list(self.subtitle.items())[-1]
|
||||||
|
hprint("magenta", f"Dernier sous-titre à {last_time} = {last_text}")
|
||||||
|
return last_text
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
def auto_create_subtitle(self,file):
|
||||||
|
hprint("green",f"start auto_create_subtitle")
|
||||||
|
del_file("","*.txt")
|
||||||
|
del_file("","*.srt")
|
||||||
|
del_file("","*.vtt")
|
||||||
|
del_file("","*.tsv")
|
||||||
|
del_file("","*.json")
|
||||||
|
|
||||||
|
# subtitle_directory = "subtitle"
|
||||||
|
# os.makedirs(subtitle_directory, exist_ok=True)
|
||||||
|
# os.chdir(subtitle_directory)
|
||||||
|
spead_find = ""
|
||||||
|
hprint("green", "translation : "+file+" ")
|
||||||
|
|
||||||
|
# whisperx --language fr --compute_type float32 ../record/final_output_audio.mp3
|
||||||
|
# record_twitch = ['whisperx', '--language',self.language, '--compute_type','float32', '../'+self.dir_record+"/"+file] #ancienne version
|
||||||
|
# record_twitch = ['whisper', '--language',self.language, '../'+self.dir_record+"/"+file,"--device","cuda"]
|
||||||
|
record_twitch = ['whisper', '--language',self.language, './'+self.dir_record+"/"+file,"--device","cuda", "--model","large-v3"]
|
||||||
|
|
||||||
|
console.print("[bold yellow] command : "+str(record_twitch)+" [/bold yellow]")
|
||||||
|
subprocess.run(record_twitch)
|
||||||
|
|
||||||
|
file_noext = file.rsplit('.', 1)[0]
|
||||||
|
with open(file_noext+".txt", "r") as thisfile:
|
||||||
|
spead_find += thisfile.read().replace("'", "").replace('"', "").replace("\n", " ").replace(",", "")
|
||||||
|
|
||||||
|
# parties = file_noext.split('_') # Sépare la base du nom et le numéro + extension
|
||||||
|
# num_ext = parties[-1] # Prend la dernière partie qui contient "007.mp3"
|
||||||
|
spead_find = self.remove_repetitions(spead_find)
|
||||||
|
self.all_subtitle += spead_find+"\n"
|
||||||
|
num_ext = get_current_time()
|
||||||
|
self.subtitle[str(num_ext)] = spead_find
|
||||||
|
hprint("yellow", "parole du streamer : \n" +spead_find)
|
||||||
|
|
||||||
|
# attention a No active speech found in audio
|
||||||
|
# os.chdir("../")
|
||||||
|
console.print("[bold PURPLE] finish create_subtitle [/bold PURPLE]")
|
||||||
|
|
||||||
|
def main_loop(self):
|
||||||
|
time.sleep(45)
|
||||||
|
hprint("green", "start main boucle_traitement record")
|
||||||
|
try:
|
||||||
|
while self.is_running:
|
||||||
|
hprint("blue",f"wait {self.loop_timer}s loop main translation.")
|
||||||
|
# Attend 'intervalle' secondes avant la prochaine itération
|
||||||
|
self.verif_file_transcribe()
|
||||||
|
time.sleep(self.loop_timer)
|
||||||
|
except KeyboardInterrupt:
|
||||||
|
print("Arrêt du script.")
|
||||||
|
|
||||||
|
# #console.print("[bold green]Enregistrement terminé, le programme va se terminer.[/bold green]")
|
||||||
|
|
||||||
|
def start_main_loop(self):
|
||||||
|
"""Lance dans un thread pour ne pas bloquer le code principal."""
|
||||||
|
self.loop_thread = threading.Thread(target=self.main_loop)
|
||||||
|
self.loop_thread.start() # Démarre dans un thread séparé
|
||||||
|
|
||||||
|
|
||||||
|
################### Subtitle FIN ########################
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
################### IA_GENERATOR TEXT ########################
|
||||||
|
|
||||||
|
|
||||||
|
class IA_generator:
|
||||||
|
def __init__(self,pathjson):
|
||||||
|
self.pathjson = pathjson
|
||||||
|
self.reload_json()
|
||||||
|
self.subtitle = {}
|
||||||
|
self.all_subtitle = ""
|
||||||
|
self.is_running = True
|
||||||
|
self.loop_timer = 60
|
||||||
|
self.streamer_word = ""
|
||||||
|
self.index_prompt = 0
|
||||||
|
self.response_generation = {}
|
||||||
|
self.list_prompt = get_value_json("list_prompt", self.config)
|
||||||
|
self.bad_answer = get_value_json("bad_answer", self.config)
|
||||||
|
|
||||||
|
def stop(self):
|
||||||
|
hprint("yellow",f"Arrêt loop subtitle")
|
||||||
|
self.is_running = False
|
||||||
|
if self.loop_thread.is_alive():
|
||||||
|
# self.loop_thread.join() # Attend la fin du thread pour un arrêt propre
|
||||||
|
hprint("red", "Boucle de traitement arrêtée.")
|
||||||
|
else :
|
||||||
|
hprint("yellow",f"loop subtitle déja arreté")
|
||||||
|
|
||||||
|
|
||||||
|
def change_prompt(self):
|
||||||
|
if self.index_prompt == len(self.list_prompt):
|
||||||
|
self.index_prompt = 0
|
||||||
|
else :
|
||||||
|
self.index_prompt += 1
|
||||||
|
|
||||||
|
|
||||||
|
def reload_json(self):
|
||||||
|
with open(self.pathjson, 'r') as file:
|
||||||
|
self.config = json.load(file)
|
||||||
|
|
||||||
|
|
||||||
|
def get_last_values(self, n):
|
||||||
|
values = list(self.subtitle.values())
|
||||||
|
return ''.join(values[-n:])
|
||||||
|
|
||||||
|
def print_allgeneration(self):
|
||||||
|
os.system('clear')
|
||||||
|
hprint("yellow", "\n\n Print All response_generation \n ")
|
||||||
|
for key, text in self.response_generation.items():
|
||||||
|
hprint("yellow", " key = "+ str(key)+" = "+ text+" \n\n")
|
||||||
|
|
||||||
|
def getlast_generation(self):
|
||||||
|
# return self.response_generation
|
||||||
|
if not self.response_generation:
|
||||||
|
hprint("red", "Aucun response_generation disponible.")
|
||||||
|
return ""
|
||||||
|
# Récupère la dernière clé et valeur
|
||||||
|
key, last_generation = list(self.response_generation.items())[-1]
|
||||||
|
hprint("magenta", f"Dernier response_generation key : {key} = {last_generation}")
|
||||||
|
return last_generation
|
||||||
|
|
||||||
|
def clear_response(self, text):
|
||||||
|
# Vérifie si ":" est dans la chaîne de caractères
|
||||||
|
if ":" in text:
|
||||||
|
# Sépare la chaîne et récupère la deuxième partie
|
||||||
|
return text.split(":", 1)[1].strip()
|
||||||
|
else:
|
||||||
|
# Retourne la chaîne telle quelle si ":" n'est pas présent
|
||||||
|
return text
|
||||||
|
|
||||||
|
def imagine_response(self):
|
||||||
|
hprint("green",f"start imagine_response\n")
|
||||||
|
# hprint("magenta",f"streamer_word : \n"+str(self.streamer_word))
|
||||||
|
# hprint("magenta",f"streamer_word : \n"+str(len(self.streamer_word[0])))
|
||||||
|
if str(self.streamer_word) == "":
|
||||||
|
hprint("magenta",f"pas encore de sosu titre on quitte génération")
|
||||||
|
return
|
||||||
|
|
||||||
|
prompt_gpt = ['tgpt','-q','-w', '"'+self.list_prompt[self.index_prompt]+' "'+ str(self.streamer_word)+'"']
|
||||||
|
|
||||||
|
hprint("DARKCYAN","index preprompt : "+str(self.index_prompt)+"\n")
|
||||||
|
hprint("DARKCYAN","\nPrompt demandé : "+str(prompt_gpt)+"\n")
|
||||||
|
process = subprocess.run(prompt_gpt, capture_output=True, text=True, check=False)
|
||||||
|
text_generation = process.stdout.replace("'", "").replace('"', "").replace("\n", "")
|
||||||
|
# hprint("CYAN","réponse imaginé sans formatage : \n"+text_generation+"\n\n") #debug
|
||||||
|
textfinal = self.clear_response(text_generation)
|
||||||
|
|
||||||
|
# nombre_de_mots = len(textfinal.split())
|
||||||
|
# nombre_de_caracteres = len(textfinal)
|
||||||
|
hprint("CYAN","réponse imaginé : \n"+textfinal+"\n\n")
|
||||||
|
self.change_prompt()
|
||||||
|
|
||||||
|
key = get_current_time()
|
||||||
|
self.response_generation[str(key)] = textfinal
|
||||||
|
|
||||||
|
def setnew_streamer_word_text(self, streamer_word_text):
|
||||||
|
self.streamer_word = streamer_word_text
|
||||||
|
|
||||||
|
def get_last_values(self, n):
|
||||||
|
values = list(self.subtitle.values())
|
||||||
|
return ''.join(values[-n:])
|
||||||
|
|
||||||
|
def main_ask(self, streamer_word_text):
|
||||||
|
hprint("blue", "imagine_response start")
|
||||||
|
self.streamer_word = streamer_word_text
|
||||||
|
imagine_response_thread = Thread(target=self.imagine_response)
|
||||||
|
imagine_response_thread.start()
|
||||||
|
|
||||||
|
def main_loop(self):
|
||||||
|
hprint("blue", "main_loop imagine_response start")
|
||||||
|
time.sleep(100)
|
||||||
|
try:
|
||||||
|
while self.is_running:
|
||||||
|
hprint("blue",f"wait {self.loop_timer}s loop main imagine_response.")
|
||||||
|
self.imagine_response()
|
||||||
|
time.sleep(self.loop_timer)
|
||||||
|
except KeyboardInterrupt:
|
||||||
|
print("Arrêt du script.")
|
||||||
|
|
||||||
|
def start_main_loop(self):
|
||||||
|
"""Lance dans un thread pour ne pas bloquer le code principal."""
|
||||||
|
self.loop_thread = threading.Thread(target=self.main_loop)
|
||||||
|
self.loop_thread.start() # Démarre dans un thread séparé
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
################### IA_GENERATOR TEXT FIN ########################
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
################### sendmessageTwitch ########################
|
||||||
|
|
||||||
|
class messageTwitch:
|
||||||
|
def __init__(self, channel_name):
|
||||||
|
|
||||||
|
self.channel_name = channel_name
|
||||||
|
self.indexuser = 0
|
||||||
|
|
||||||
|
|
||||||
|
with open("../config/user.json", 'r') as file:
|
||||||
|
self.userjson = json.load(file)
|
||||||
|
self.totaluser = len(self.userjson)
|
||||||
|
|
||||||
|
self.tw_acc_pseudo = get_value_json_list(self.indexuser, "tw_acc_pseudo", self.userjson)
|
||||||
|
self.tw_acc_token = get_value_json_list(self.indexuser, "tw_acc_token", self.userjson)
|
||||||
|
self.charactere = get_value_json_list(self.indexuser, "charactere", self.userjson)
|
||||||
|
|
||||||
|
def set_user(self,index_user):
|
||||||
|
self.indexuser = index_user
|
||||||
|
self.tw_acc_pseudo = get_value_json_list(self.indexuser, "tw_acc_pseudo", self.userjson)
|
||||||
|
self.tw_acc_token = get_value_json_list(self.indexuser, "tw_acc_token", self.userjson)
|
||||||
|
self.charactere = get_value_json_list(self.indexuser, "charactere", self.userjson)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
def change_user(self):
|
||||||
|
|
||||||
|
#commented for pausing
|
||||||
|
#if (self.totaluser != 1): # si la liste ne fait que 1 de taille
|
||||||
|
# if(self.totaluser+1 > self.indexuser): # si la taille de liste est plus grande que lindex
|
||||||
|
# self.indexuser = self.indexuser + 1
|
||||||
|
#else :
|
||||||
|
# self.indexuser = 0
|
||||||
|
|
||||||
|
self.tw_acc_pseudo = get_value_json_list(self.indexuser, "tw_acc_pseudo", self.userjson)
|
||||||
|
self.tw_acc_token = get_value_json_list(self.indexuser, "tw_acc_token", self.userjson)
|
||||||
|
self.charactere = get_value_json_list(self.indexuser, "charactere", self.userjson)
|
||||||
|
|
||||||
|
|
||||||
|
def send_message(self, Message_text):
|
||||||
|
hprint("green","start send_message")
|
||||||
|
|
||||||
|
command = '-pseudo "'+self.tw_acc_pseudo+'" -token "'+self.tw_acc_token+'" -twitchname "'+self.channel_name+'" -message " '+self.charactere+' '+Message_text+'"'
|
||||||
|
message_tosend = 'python send_message.py '+command
|
||||||
|
hprint("yellow",f"send message = "+str(message_tosend))
|
||||||
|
subprocess.run(message_tosend, shell=True)
|
||||||
|
hprint("yellow",f"Finnish send message")
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
################### sendmessageTwitch FIN ########################
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -0,0 +1,96 @@
|
|||||||
|
import os
|
||||||
|
import signal
|
||||||
|
import sys
|
||||||
|
import argparse
|
||||||
|
import json
|
||||||
|
import time
|
||||||
|
import pprint
|
||||||
|
import random
|
||||||
|
import requests
|
||||||
|
import datetime
|
||||||
|
import glob
|
||||||
|
import threading
|
||||||
|
# import keyboard
|
||||||
|
from pynput import keyboard
|
||||||
|
from threading import Thread, Semaphore
|
||||||
|
from streamlink import Streamlink
|
||||||
|
from fake_useragent import UserAgent
|
||||||
|
from rich.console import Console
|
||||||
|
from rich.live import Live
|
||||||
|
from rich.prompt import Prompt
|
||||||
|
from rich.spinner import Spinner
|
||||||
|
from rich.table import Table
|
||||||
|
from rich.text import Text
|
||||||
|
import subprocess
|
||||||
|
import pty
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
def signal_handler(sig, frame):
|
||||||
|
os.system('killall python')
|
||||||
|
sys.exit(0)
|
||||||
|
|
||||||
|
signal.signal(signal.SIGINT, signal_handler)
|
||||||
|
console = Console()
|
||||||
|
|
||||||
|
|
||||||
|
def hprint(color, texte):
|
||||||
|
timestamp = datetime.datetime.now().strftime("%Hh %Mm %Ss")
|
||||||
|
console.print("[bold "+color+"] ["+timestamp+"] "+texte+" [/bold "+color+"]")
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
def get_value_json(var_name, config):
|
||||||
|
return config.get(var_name)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
def send_message(tw_acc_pseudo, tw_acc_token, channel_name, Message_text):
|
||||||
|
hprint("green","start send_message")
|
||||||
|
|
||||||
|
command = '-pseudo "'+tw_acc_pseudo+'" -token "'+tw_acc_token+'" -twitchname "'+channel_name+'" -message " Kappa '+Message_text+'"'
|
||||||
|
message_tosend = 'python send_message.py '+command
|
||||||
|
hprint("yellow",f"send message = "+str(message_tosend))
|
||||||
|
subprocess.run(message_tosend, shell=True)
|
||||||
|
hprint("yellow",f"Finnish send message")
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
def clear_screen():
|
||||||
|
os.system('clear')
|
||||||
|
|
||||||
|
def afficher_type(variable):
|
||||||
|
"""Affiche le type d'une variable."""
|
||||||
|
print(f"Le type de la variable est : {type(variable).__name__}")
|
||||||
|
|
||||||
|
def stop_all():
|
||||||
|
hprint("blue", "Arrêt d'enregistrement twitch.")
|
||||||
|
recordTw.stop()
|
||||||
|
sb_translation.stop()
|
||||||
|
|
||||||
|
|
||||||
|
def generation_responce():
|
||||||
|
text_streamer = sb_translation.get_lasttext()
|
||||||
|
hprint("blue", "start IA_generator")
|
||||||
|
ask_text.main_ask(text_streamer)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Binary file not shown.
@@ -0,0 +1,203 @@
|
|||||||
|
import os
|
||||||
|
import signal
|
||||||
|
import sys
|
||||||
|
import argparse
|
||||||
|
import json
|
||||||
|
import time
|
||||||
|
import pprint
|
||||||
|
import random
|
||||||
|
import requests
|
||||||
|
import datetime
|
||||||
|
import glob
|
||||||
|
import threading
|
||||||
|
# import keyboard
|
||||||
|
from pynput import keyboard
|
||||||
|
from threading import Thread, Semaphore
|
||||||
|
from streamlink import Streamlink
|
||||||
|
from fake_useragent import UserAgent
|
||||||
|
from rich.console import Console
|
||||||
|
from rich.live import Live
|
||||||
|
from rich.prompt import Prompt
|
||||||
|
from rich.spinner import Spinner
|
||||||
|
from rich.table import Table
|
||||||
|
from rich.text import Text
|
||||||
|
import subprocess
|
||||||
|
import pty
|
||||||
|
|
||||||
|
|
||||||
|
#import from local file 4 main class
|
||||||
|
from fonction.first_class import RecordTwitch
|
||||||
|
from fonction.first_class import Subtitle_translation
|
||||||
|
from fonction.first_class import IA_generator
|
||||||
|
from fonction.first_class import messageTwitch
|
||||||
|
|
||||||
|
#import from local file secondary fonction
|
||||||
|
from fonction.second_fonction import *
|
||||||
|
|
||||||
|
|
||||||
|
def signal_handler(sig, frame):
|
||||||
|
os.system('killall python')
|
||||||
|
sys.exit(0)
|
||||||
|
|
||||||
|
signal.signal(signal.SIGINT, signal_handler)
|
||||||
|
console = Console()
|
||||||
|
|
||||||
|
|
||||||
|
def send_message(tw_acc_pseudo, tw_acc_token, channel_name, Message_text):
|
||||||
|
hprint("green","start send_message")
|
||||||
|
|
||||||
|
command = '-pseudo "'+tw_acc_pseudo+'" -token "'+tw_acc_token+'" -twitchname "'+channel_name+'" -message " Kappa '+Message_text+'"'
|
||||||
|
message_tosend = 'python send_message.py '+command
|
||||||
|
hprint("yellow",f"send message = "+str(message_tosend))
|
||||||
|
#subprocess.run(message_tosend, shell=True)
|
||||||
|
hprint("yellow",f"Finnish send message")
|
||||||
|
|
||||||
|
|
||||||
|
def stop_all():
|
||||||
|
hprint("blue", "Arrêt d'enregistrement twitch.")
|
||||||
|
recordTw.stop()
|
||||||
|
sb_translation.stop()
|
||||||
|
|
||||||
|
def print_help():
|
||||||
|
hprint("PURPLE", "Touche h : pour afficher les commandes")
|
||||||
|
hprint("PURPLE", "Touche q : pour quitter le sript")
|
||||||
|
hprint("PURPLE", "Touche c : Clear le terminal")
|
||||||
|
hprint("PURPLE", "Touche s : envoie un message dans le tchat twitch avec la derniere génération")
|
||||||
|
|
||||||
|
hprint("PURPLE", "Touche u : pour stopper lenregistrement twitch")
|
||||||
|
# hprint("PURPLE", "Touche j : pour start lenregistrement twitch") # pas set
|
||||||
|
|
||||||
|
# hprint("PURPLE", "Touche i : pour start la traduction en text du record") # pas set
|
||||||
|
hprint("PURPLE", "Touche p : pour stopper la traduction en text du record")
|
||||||
|
hprint("PURPLE", "Touche o : liste tout les sous titre créé")
|
||||||
|
|
||||||
|
hprint("PURPLE", "Touche k : lancer une generation de reponse avec ia depuis les traduction")
|
||||||
|
hprint("PURPLE", "Touche l : liste toute les génération")
|
||||||
|
hprint("PURPLE", "Touche m : change le prompt a donner a l'ia")
|
||||||
|
|
||||||
|
def on_press(key):
|
||||||
|
try:
|
||||||
|
if key.char == 'h':
|
||||||
|
hprint("cyan", "Touche 'h' détectée. Help")
|
||||||
|
print_help()
|
||||||
|
elif key.char == 'q': # Si la touche 'q' est pressée, arrête l'écoute
|
||||||
|
hprint("cyan", "Touche 'q' détectée. Fin du programme.")
|
||||||
|
main_loop = False
|
||||||
|
stop_all()
|
||||||
|
return False # Cela arrêtera l'écouteur
|
||||||
|
elif key.char == 'c':
|
||||||
|
hprint("cyan", "Touche 'c' clear terminal")
|
||||||
|
clear_screen()
|
||||||
|
elif key.char == 'u':
|
||||||
|
hprint("cyan", "Touche 'u' détectée. Arrêt de l'enregistrement.")
|
||||||
|
recordTw.stop() # Arrêter l'enregistrement
|
||||||
|
elif key.char == 'p':
|
||||||
|
hprint("cyan", "Touche 'p' détectée. Arrêt de la traduction en text.")
|
||||||
|
sb_translation.stop() # Arrêter l'enregistrement
|
||||||
|
elif key.char == 'k':
|
||||||
|
hprint("cyan", "Touche 'k' imagination réponse")
|
||||||
|
generation_responce()
|
||||||
|
elif key.char == 's':
|
||||||
|
hprint("cyan", "Touche 's' Envoie du message")
|
||||||
|
Message_text = ask_text.getlast_generation()
|
||||||
|
#send_message(tw_acc_pseudo, tw_acc_token, args.twitchname, Message_text)
|
||||||
|
elif key.char == 'o':
|
||||||
|
hprint("cyan", "Touche 'o'liste sous titre")
|
||||||
|
sb_translation.print_allsubtitle()
|
||||||
|
elif key.char == 'l':
|
||||||
|
hprint("cyan", "Touche 'l' liste génération")
|
||||||
|
ask_text.print_allgeneration()
|
||||||
|
elif key.char == 'x':
|
||||||
|
hprint("cyan", "Touche 'x' reload json")
|
||||||
|
ask_text.reload_json()
|
||||||
|
sb_translation.reload_json()
|
||||||
|
elif key.char == 'm':
|
||||||
|
hprint("cyan", "Touche 'm' change prompt ia")
|
||||||
|
ask_text.change_prompt()
|
||||||
|
except AttributeError:
|
||||||
|
pass
|
||||||
|
|
||||||
|
|
||||||
|
def generation_responce():
|
||||||
|
text_streamer = sb_translation.get_lasttext()
|
||||||
|
hprint("blue", "start IA_generator")
|
||||||
|
ask_text.main_ask(text_streamer)
|
||||||
|
|
||||||
|
def start_keyboard_listener():
|
||||||
|
with keyboard.Listener(on_press=on_press) as listener:
|
||||||
|
listener.join()
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
#----------------------------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
if __name__ == '__main__':
|
||||||
|
main_loop = True
|
||||||
|
|
||||||
|
work_directory = "working_bot"
|
||||||
|
os.chdir(work_directory)
|
||||||
|
|
||||||
|
with open("../config/config.json", 'r') as file:
|
||||||
|
config = json.load(file)
|
||||||
|
tw_acc_pseudo = get_value_json("tw_acc_pseudo", config)
|
||||||
|
tw_acc_token = get_value_json("tw_acc_token", config)
|
||||||
|
|
||||||
|
parser = argparse.ArgumentParser()
|
||||||
|
parser.add_argument('-threads', type=int, default=10, help='Number of threads')
|
||||||
|
parser.add_argument('-recordtime', type=int, default=60, help='Time to record')
|
||||||
|
parser.add_argument('-twitchname', type=str, required=True, help='Twitch channel name')
|
||||||
|
args = parser.parse_args()
|
||||||
|
|
||||||
|
hprint("blue", "start loop RecordTwitch")
|
||||||
|
recordTw = RecordTwitch(channel_name=args.twitchname, recordtime=args.recordtime)
|
||||||
|
recordTw.start_recording()
|
||||||
|
|
||||||
|
hprint("blue", "start loop Subtitle_translation")
|
||||||
|
sb_translation = Subtitle_translation("../config/config.json")
|
||||||
|
sb_translation.start_main_loop()
|
||||||
|
|
||||||
|
ask_text = IA_generator("../config/config.json")
|
||||||
|
ask_text.start_main_loop()
|
||||||
|
|
||||||
|
controluser = messageTwitch(args.twitchname)
|
||||||
|
|
||||||
|
print_help()
|
||||||
|
listener_thread = threading.Thread(target=start_keyboard_listener)
|
||||||
|
listener_thread.start() # mise en thread de l'écoute des appuye touche
|
||||||
|
|
||||||
|
|
||||||
|
time.sleep(25)
|
||||||
|
last_generaton = ""
|
||||||
|
while main_loop:
|
||||||
|
hprint("blue", "start main_loop main script")
|
||||||
|
text_streamer = sb_translation.get_lasttext()
|
||||||
|
ask_text.setnew_streamer_word_text(text_streamer)
|
||||||
|
new_genration = ask_text.getlast_generation()
|
||||||
|
|
||||||
|
if new_genration != "" and new_genration != last_generaton:
|
||||||
|
hprint("blue", "Send message -> "+new_genration)
|
||||||
|
# send_message(tw_acc_pseudo, tw_acc_token, args.twitchname, new_genration)
|
||||||
|
controluser.send_message(new_genration)
|
||||||
|
controluser.change_user()
|
||||||
|
last_generaton = new_genration
|
||||||
|
|
||||||
|
time.sleep(25)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
torch>=2
|
||||||
|
torchaudio>=2
|
||||||
|
faster-whisper==1.0.0
|
||||||
|
transformers
|
||||||
|
pandas
|
||||||
|
setuptools>=65
|
||||||
|
nltk
|
||||||
|
customtkinter
|
||||||
|
requests
|
||||||
|
streamlink
|
||||||
|
fake_useragent
|
||||||
|
rich
|
||||||
|
pydub
|
||||||
|
ffmpeg
|
||||||
|
whisperx
|
||||||
|
pytmi
|
||||||
|
keyboard
|
||||||
|
pynput
|
||||||
@@ -0,0 +1,19 @@
|
|||||||
|
[
|
||||||
|
{
|
||||||
|
"tw_acc_pseudo": "foufure13",
|
||||||
|
"tw_acc_token": "oauth:nmpw9bypx9emht7hn5z3vlgbwitaz5",
|
||||||
|
"character":["amicale","philosophique"]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"tw_acc_pseudo": "foufure13",
|
||||||
|
"tw_acc_token": "oauth:nmpw9bypx9emht7hn5z3vlgbwitaz5",
|
||||||
|
"character":["blageur","direct","sournois"]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"tw_acc_pseudo": "foufure13",
|
||||||
|
"tw_acc_token": "oauth:nmpw9bypx9emht7hn5z3vlgbwitaz5",
|
||||||
|
"character":["blageur","direct","sournois"]
|
||||||
|
}
|
||||||
|
|
||||||
|
]
|
||||||
|
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
{"text": " Le Swain n'a plus de ult, il n'a plus de flash, je le fais tout claquer l\u00e0. Bon le Swain maintenant il ne pourra plus jamais me 1v1, je suis niveau 11, sa game elle est finie. Il est l\u00e0, par contre \u00e7a d\u00e9cale sur toi je pense. Ok, il faut juste que je slam juste cette wave. Ah mais je pensais que la botlane allait d\u00e9caler moi, na\u00efvement. Je pensais qu'ils allaient d\u00e9clencher mais \u00e0 pas moment. Bah my bad.", "segments": [{"id": 0, "seek": 0, "start": 0.72, "end": 3.4, "text": " Le Swain n'a plus de ult, il n'a plus de flash, je le fais tout claquer l\u00e0.", "tokens": [50401, 1456, 3926, 491, 297, 6, 64, 1804, 368, 3725, 11, 1930, 297, 6, 64, 1804, 368, 7319, 11, 1506, 476, 12153, 3486, 3583, 8035, 3684, 13, 50535], "temperature": 0.0, "avg_logprob": -0.29959945021004514, "compression_ratio": 1.3435114503816794, "no_speech_prob": 0.271548867225647}, {"id": 1, "seek": 0, "start": 19.400000000000002, "end": 24.1, "text": " Bon le Swain maintenant il ne pourra plus jamais me 1v1, je suis niveau 11, sa game elle est finie.", "tokens": [51335, 7368, 476, 3926, 491, 14817, 1930, 408, 37753, 1804, 14540, 385, 502, 85, 16, 11, 1506, 7624, 19144, 2975, 11, 601, 1216, 8404, 871, 962, 414, 13, 51570], "temperature": 0.0, "avg_logprob": -0.29959945021004514, "compression_ratio": 1.3435114503816794, "no_speech_prob": 0.271548867225647}, {"id": 2, "seek": 3000, "start": 30.0, "end": 36.0, "text": " Il est l\u00e0, par contre \u00e7a d\u00e9cale sur toi je pense.", "tokens": [50365, 4416, 871, 3684, 11, 971, 14927, 2788, 9198, 1220, 1022, 15648, 1506, 11209, 13, 50665], "temperature": 0.0, "avg_logprob": -0.3605501957428761, "compression_ratio": 1.4166666666666667, "no_speech_prob": 0.007284470833837986}, {"id": 3, "seek": 3000, "start": 36.0, "end": 39.0, "text": " Ok, il faut juste que je slam juste cette wave.", "tokens": [50665, 3477, 11, 1930, 8487, 13016, 631, 1506, 25617, 13016, 5550, 5772, 13, 50815], "temperature": 0.0, "avg_logprob": -0.3605501957428761, "compression_ratio": 1.4166666666666667, "no_speech_prob": 0.007284470833837986}, {"id": 4, "seek": 3000, "start": 52.0, "end": 55.0, "text": " Ah mais je pensais que la botlane allait d\u00e9caler moi, na\u00efvement.", "tokens": [51465, 2438, 2420, 1506, 6099, 1527, 631, 635, 10592, 46121, 439, 1001, 9198, 17148, 7748, 11, 1667, 15487, 303, 518, 13, 51615], "temperature": 0.0, "avg_logprob": -0.3605501957428761, "compression_ratio": 1.4166666666666667, "no_speech_prob": 0.007284470833837986}, {"id": 5, "seek": 3000, "start": 55.0, "end": 58.0, "text": " Je pensais qu'ils allaient d\u00e9clencher mais \u00e0 pas moment.", "tokens": [51615, 2588, 6099, 1527, 421, 6, 4174, 11591, 1196, 2795, 3474, 268, 6759, 2420, 1531, 1736, 1623, 13, 51765], "temperature": 0.0, "avg_logprob": -0.3605501957428761, "compression_ratio": 1.4166666666666667, "no_speech_prob": 0.007284470833837986}, {"id": 6, "seek": 3000, "start": 58.0, "end": 59.0, "text": " Bah my bad.", "tokens": [51765, 14782, 452, 1578, 13, 51815], "temperature": 0.0, "avg_logprob": -0.3605501957428761, "compression_ratio": 1.4166666666666667, "no_speech_prob": 0.007284470833837986}], "language": "fr"}
|
||||||
@@ -0,0 +1,28 @@
|
|||||||
|
1
|
||||||
|
00:00:00,720 --> 00:00:03,400
|
||||||
|
Le Swain n'a plus de ult, il n'a plus de flash, je le fais tout claquer là.
|
||||||
|
|
||||||
|
2
|
||||||
|
00:00:19,400 --> 00:00:24,100
|
||||||
|
Bon le Swain maintenant il ne pourra plus jamais me 1v1, je suis niveau 11, sa game elle est finie.
|
||||||
|
|
||||||
|
3
|
||||||
|
00:00:30,000 --> 00:00:36,000
|
||||||
|
Il est là, par contre ça décale sur toi je pense.
|
||||||
|
|
||||||
|
4
|
||||||
|
00:00:36,000 --> 00:00:39,000
|
||||||
|
Ok, il faut juste que je slam juste cette wave.
|
||||||
|
|
||||||
|
5
|
||||||
|
00:00:52,000 --> 00:00:55,000
|
||||||
|
Ah mais je pensais que la botlane allait décaler moi, naïvement.
|
||||||
|
|
||||||
|
6
|
||||||
|
00:00:55,000 --> 00:00:58,000
|
||||||
|
Je pensais qu'ils allaient déclencher mais à pas moment.
|
||||||
|
|
||||||
|
7
|
||||||
|
00:00:58,000 --> 00:00:59,000
|
||||||
|
Bah my bad.
|
||||||
|
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
start end text
|
||||||
|
720 3400 Le Swain n'a plus de ult, il n'a plus de flash, je le fais tout claquer là.
|
||||||
|
19400 24100 Bon le Swain maintenant il ne pourra plus jamais me 1v1, je suis niveau 11, sa game elle est finie.
|
||||||
|
30000 36000 Il est là, par contre ça décale sur toi je pense.
|
||||||
|
36000 39000 Ok, il faut juste que je slam juste cette wave.
|
||||||
|
52000 55000 Ah mais je pensais que la botlane allait décaler moi, naïvement.
|
||||||
|
55000 58000 Je pensais qu'ils allaient déclencher mais à pas moment.
|
||||||
|
58000 59000 Bah my bad.
|
||||||
|
@@ -0,0 +1,7 @@
|
|||||||
|
Le Swain n'a plus de ult, il n'a plus de flash, je le fais tout claquer là.
|
||||||
|
Bon le Swain maintenant il ne pourra plus jamais me 1v1, je suis niveau 11, sa game elle est finie.
|
||||||
|
Il est là, par contre ça décale sur toi je pense.
|
||||||
|
Ok, il faut juste que je slam juste cette wave.
|
||||||
|
Ah mais je pensais que la botlane allait décaler moi, naïvement.
|
||||||
|
Je pensais qu'ils allaient déclencher mais à pas moment.
|
||||||
|
Bah my bad.
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
WEBVTT
|
||||||
|
|
||||||
|
00:00.720 --> 00:03.400
|
||||||
|
Le Swain n'a plus de ult, il n'a plus de flash, je le fais tout claquer là.
|
||||||
|
|
||||||
|
00:19.400 --> 00:24.100
|
||||||
|
Bon le Swain maintenant il ne pourra plus jamais me 1v1, je suis niveau 11, sa game elle est finie.
|
||||||
|
|
||||||
|
00:30.000 --> 00:36.000
|
||||||
|
Il est là, par contre ça décale sur toi je pense.
|
||||||
|
|
||||||
|
00:36.000 --> 00:39.000
|
||||||
|
Ok, il faut juste que je slam juste cette wave.
|
||||||
|
|
||||||
|
00:52.000 --> 00:55.000
|
||||||
|
Ah mais je pensais que la botlane allait décaler moi, naïvement.
|
||||||
|
|
||||||
|
00:55.000 --> 00:58.000
|
||||||
|
Je pensais qu'ils allaient déclencher mais à pas moment.
|
||||||
|
|
||||||
|
00:58.000 --> 00:59.000
|
||||||
|
Bah my bad.
|
||||||
|
|
||||||
@@ -0,0 +1,635 @@
|
|||||||
|
72.10.160.92:8853
|
||||||
|
158.255.77.169:80
|
||||||
|
66.29.154.103:3128
|
||||||
|
72.10.164.178:1411
|
||||||
|
5.56.133.24:80
|
||||||
|
47.251.73.54:3128
|
||||||
|
185.76.10.135:8082
|
||||||
|
72.10.164.178:20921
|
||||||
|
109.61.42.223:80
|
||||||
|
47.247.78.134:80
|
||||||
|
61.160.212.99:181
|
||||||
|
185.217.5.3:80
|
||||||
|
85.215.64.49:80
|
||||||
|
221.231.13.198:1080
|
||||||
|
72.10.160.94:8853
|
||||||
|
198.44.255.3:80
|
||||||
|
103.86.109.38:80
|
||||||
|
176.9.239.181:80
|
||||||
|
123.154.118.169:8085
|
||||||
|
198.199.86.11:3128
|
||||||
|
72.10.160.90:7305
|
||||||
|
101.66.199.194:8085
|
||||||
|
67.43.228.253:20493
|
||||||
|
38.54.71.67:80
|
||||||
|
72.10.160.170:8337
|
||||||
|
182.66.207.139:1888
|
||||||
|
103.49.202.252:80
|
||||||
|
220.248.70.237:9002
|
||||||
|
47.251.73.54:9080
|
||||||
|
67.43.236.20:27089
|
||||||
|
67.43.236.18:15891
|
||||||
|
47.56.110.204:8989
|
||||||
|
67.43.227.226:6725
|
||||||
|
74.241.245.225:3128
|
||||||
|
111.59.4.88:9002
|
||||||
|
45.76.123.210:80
|
||||||
|
103.127.1.130:80
|
||||||
|
198.199.86.11:8080
|
||||||
|
72.10.160.91:19933
|
||||||
|
94.72.152.254:80
|
||||||
|
47.238.130.212:8080
|
||||||
|
158.255.77.168:80
|
||||||
|
72.10.164.178:29593
|
||||||
|
72.10.160.91:24081
|
||||||
|
111.97.81.200:80
|
||||||
|
190.103.177.131:80
|
||||||
|
72.10.160.171:11985
|
||||||
|
141.145.214.176:80
|
||||||
|
72.10.164.178:31239
|
||||||
|
49.7.11.187:80
|
||||||
|
103.190.179.27:80
|
||||||
|
72.10.160.170:25629
|
||||||
|
67.43.236.20:24553
|
||||||
|
67.43.227.227:26173
|
||||||
|
200.174.198.86:8888
|
||||||
|
45.92.177.60:8080
|
||||||
|
116.125.141.115:80
|
||||||
|
47.247.78.132:80
|
||||||
|
106.75.90.108:3128
|
||||||
|
67.43.228.252:21469
|
||||||
|
67.43.236.20:11551
|
||||||
|
78.80.228.150:80
|
||||||
|
72.10.160.90:23969
|
||||||
|
160.86.242.23:8080
|
||||||
|
87.98.148.98:80
|
||||||
|
72.10.164.178:13075
|
||||||
|
67.43.228.250:21823
|
||||||
|
165.22.77.86:8080
|
||||||
|
58.246.58.150:9002
|
||||||
|
45.177.179.65:999
|
||||||
|
103.133.61.179:8080
|
||||||
|
50.220.168.152:80
|
||||||
|
101.66.199.60:8085
|
||||||
|
67.43.227.226:12699
|
||||||
|
67.43.227.229:8467
|
||||||
|
141.95.1.186:3128
|
||||||
|
38.156.72.196:8080
|
||||||
|
47.247.78.131:80
|
||||||
|
38.52.212.10:999
|
||||||
|
78.138.152.142:3128
|
||||||
|
192.145.206.160:8080
|
||||||
|
72.10.160.172:16817
|
||||||
|
72.10.164.178:12637
|
||||||
|
43.129.238.55:8085
|
||||||
|
198.49.68.80:80
|
||||||
|
58.147.171.110:8085
|
||||||
|
67.43.236.20:31349
|
||||||
|
72.10.160.90:31515
|
||||||
|
60.242.169.2:80
|
||||||
|
5.188.3.199:8443
|
||||||
|
95.170.219.13:8085
|
||||||
|
149.129.226.9:4145
|
||||||
|
176.37.139.137:41890
|
||||||
|
181.129.74.58:40667
|
||||||
|
180.191.23.66:8082
|
||||||
|
67.43.236.20:9637
|
||||||
|
72.10.160.90:30769
|
||||||
|
67.43.227.226:25741
|
||||||
|
103.76.109.104:8080
|
||||||
|
47.250.11.111:8081
|
||||||
|
222.252.194.29:8080
|
||||||
|
8.211.51.115:8008
|
||||||
|
157.20.244.189:1111
|
||||||
|
64.147.212.78:8080
|
||||||
|
67.43.236.20:4079
|
||||||
|
119.188.93.251:81
|
||||||
|
72.10.160.90:25525
|
||||||
|
46.161.196.139:8080
|
||||||
|
181.198.64.114:999
|
||||||
|
103.166.159.183:8090
|
||||||
|
103.247.14.103:1111
|
||||||
|
161.35.70.249:3128
|
||||||
|
72.10.160.91:21575
|
||||||
|
79.106.170.34:8989
|
||||||
|
67.43.227.228:20443
|
||||||
|
189.43.42.101:80
|
||||||
|
49.13.173.87:80
|
||||||
|
106.42.30.243:82
|
||||||
|
110.78.85.161:8080
|
||||||
|
45.230.48.131:999
|
||||||
|
3.71.80.214:8090
|
||||||
|
103.75.53.93:7878
|
||||||
|
50.220.168.149:80
|
||||||
|
8.219.229.53:8443
|
||||||
|
202.189.11.149:8123
|
||||||
|
154.236.177.100:1977
|
||||||
|
103.99.27.78:8085
|
||||||
|
182.253.181.10:8080
|
||||||
|
66.29.154.105:3128
|
||||||
|
103.78.215.253:8080
|
||||||
|
110.72.102.77:8085
|
||||||
|
45.76.122.178:80
|
||||||
|
190.14.10.19:999
|
||||||
|
103.157.117.61:8080
|
||||||
|
111.1.61.49:3128
|
||||||
|
5.9.238.29:80
|
||||||
|
47.247.78.133:80
|
||||||
|
222.243.174.132:81
|
||||||
|
103.156.75.41:8181
|
||||||
|
103.172.42.47:1111
|
||||||
|
67.43.227.228:13963
|
||||||
|
139.162.78.109:8080
|
||||||
|
111.26.177.28:9091
|
||||||
|
67.43.227.227:8431
|
||||||
|
195.114.209.50:80
|
||||||
|
45.227.195.121:8082
|
||||||
|
165.232.129.150:80
|
||||||
|
103.137.67.134:8080
|
||||||
|
41.59.90.174:80
|
||||||
|
65.109.220.163:80
|
||||||
|
175.139.233.78:80
|
||||||
|
49.13.173.87:8081
|
||||||
|
75.25.159.161:3128
|
||||||
|
67.43.236.18:27993
|
||||||
|
67.43.227.230:13123
|
||||||
|
72.10.164.178:22257
|
||||||
|
177.93.16.66:8080
|
||||||
|
200.61.16.80:8080
|
||||||
|
209.97.150.167:8080
|
||||||
|
41.204.53.29:80
|
||||||
|
45.5.117.168:999
|
||||||
|
72.10.160.172:13913
|
||||||
|
67.43.236.18:30131
|
||||||
|
67.43.228.252:22331
|
||||||
|
49.48.96.64:8080
|
||||||
|
4.155.2.13:80
|
||||||
|
31.41.216.122:3128
|
||||||
|
67.43.228.253:6585
|
||||||
|
5.161.115.29:50546
|
||||||
|
72.10.160.170:31203
|
||||||
|
188.132.221.189:8080
|
||||||
|
87.242.9.167:53281
|
||||||
|
51.254.78.223:80
|
||||||
|
202.93.244.54:8085
|
||||||
|
103.28.114.140:8090
|
||||||
|
67.43.236.19:17303
|
||||||
|
186.232.59.146:54443
|
||||||
|
128.199.202.122:8080
|
||||||
|
67.43.228.253:8955
|
||||||
|
181.204.83.115:41890
|
||||||
|
202.152.24.50:8080
|
||||||
|
177.75.1.33:8080
|
||||||
|
67.43.236.20:2525
|
||||||
|
51.210.54.186:80
|
||||||
|
67.43.227.227:4415
|
||||||
|
36.67.208.60:80
|
||||||
|
103.48.69.73:83
|
||||||
|
103.220.206.138:59417
|
||||||
|
47.91.120.190:8443
|
||||||
|
67.43.228.253:3355
|
||||||
|
200.92.201.126:999
|
||||||
|
103.143.8.126:8089
|
||||||
|
172.191.74.198:8080
|
||||||
|
47.89.184.18:3128
|
||||||
|
8.212.165.164:8020
|
||||||
|
43.153.207.93:3128
|
||||||
|
47.250.155.254:8004
|
||||||
|
182.253.115.130:8080
|
||||||
|
103.162.63.101:8080
|
||||||
|
103.191.165.4:7777
|
||||||
|
222.127.220.113:8085
|
||||||
|
195.159.124.57:85
|
||||||
|
103.242.105.26:8080
|
||||||
|
34.66.64.198:3128
|
||||||
|
67.43.227.228:17213
|
||||||
|
94.70.195.145:8080
|
||||||
|
41.204.53.20:80
|
||||||
|
89.135.59.65:8090
|
||||||
|
213.233.177.134:80
|
||||||
|
67.43.236.20:23003
|
||||||
|
47.88.17.170:8118
|
||||||
|
67.43.236.20:5865
|
||||||
|
167.71.214.49:8888
|
||||||
|
103.153.62.155:8080
|
||||||
|
80.249.112.163:80
|
||||||
|
181.198.64.115:999
|
||||||
|
77.235.31.24:8080
|
||||||
|
51.79.170.92:80
|
||||||
|
67.43.236.18:22439
|
||||||
|
72.10.164.178:14303
|
||||||
|
120.28.216.126:8082
|
||||||
|
41.128.148.70:1976
|
||||||
|
181.78.95.49:999
|
||||||
|
45.173.6.194:999
|
||||||
|
47.91.120.190:80
|
||||||
|
47.74.46.81:1000
|
||||||
|
103.139.126.230:8083
|
||||||
|
47.90.167.27:1000
|
||||||
|
103.115.31.45:8181
|
||||||
|
103.1.50.172:3125
|
||||||
|
72.10.164.178:10243
|
||||||
|
67.43.236.20:2431
|
||||||
|
190.94.212.43:999
|
||||||
|
181.78.95.50:999
|
||||||
|
67.43.227.227:13791
|
||||||
|
8.212.165.164:8080
|
||||||
|
103.153.154.6:80
|
||||||
|
23.247.136.245:80
|
||||||
|
47.91.104.88:3128
|
||||||
|
103.203.232.101:1080
|
||||||
|
67.43.227.226:30785
|
||||||
|
67.43.236.20:20527
|
||||||
|
36.134.91.82:8888
|
||||||
|
47.91.109.17:9098
|
||||||
|
67.43.236.20:28481
|
||||||
|
103.179.182.61:8181
|
||||||
|
103.162.62.250:8181
|
||||||
|
67.43.236.20:9591
|
||||||
|
183.215.23.242:9091
|
||||||
|
67.43.236.22:32455
|
||||||
|
72.10.160.170:6879
|
||||||
|
102.0.14.72:8080
|
||||||
|
27.147.169.66:888
|
||||||
|
113.201.243.8:8088
|
||||||
|
212.174.79.169:8080
|
||||||
|
143.110.226.180:8888
|
||||||
|
72.10.164.178:19315
|
||||||
|
196.251.195.146:8084
|
||||||
|
72.10.160.174:27285
|
||||||
|
103.169.131.62:8080
|
||||||
|
72.10.160.94:29589
|
||||||
|
72.10.160.90:7033
|
||||||
|
201.222.46.250:999
|
||||||
|
165.22.77.86:80
|
||||||
|
172.105.247.219:3128
|
||||||
|
80.71.217.138:8080
|
||||||
|
188.132.222.46:8080
|
||||||
|
67.43.228.253:2781
|
||||||
|
1.179.217.11:8080
|
||||||
|
47.251.87.74:8443
|
||||||
|
43.153.50.150:3128
|
||||||
|
27.147.195.170:58080
|
||||||
|
58.240.211.251:7890
|
||||||
|
88.255.106.27:8080
|
||||||
|
139.59.1.14:3128
|
||||||
|
72.10.160.94:27419
|
||||||
|
196.251.195.254:8084
|
||||||
|
162.223.90.130:80
|
||||||
|
113.192.30.89:8088
|
||||||
|
109.110.53.170:45810
|
||||||
|
42.119.164.44:80
|
||||||
|
67.43.236.19:17065
|
||||||
|
2.59.181.248:33100
|
||||||
|
67.43.236.20:28363
|
||||||
|
41.65.160.173:1976
|
||||||
|
45.185.162.194:999
|
||||||
|
72.10.164.178:24683
|
||||||
|
133.18.234.13:80
|
||||||
|
47.91.109.17:8008
|
||||||
|
103.120.165.54:8885
|
||||||
|
67.43.228.250:26791
|
||||||
|
114.236.93.208:59074
|
||||||
|
118.69.123.180:80
|
||||||
|
177.234.193.180:999
|
||||||
|
72.10.160.90:7833
|
||||||
|
161.34.40.115:3128
|
||||||
|
103.180.123.93:8080
|
||||||
|
72.10.164.178:19335
|
||||||
|
72.10.160.90:15095
|
||||||
|
72.10.164.178:28805
|
||||||
|
101.255.148.22:3127
|
||||||
|
46.10.209.230:8080
|
||||||
|
101.66.195.207:8085
|
||||||
|
72.10.164.178:20019
|
||||||
|
72.10.160.90:3945
|
||||||
|
72.10.164.178:22999
|
||||||
|
67.43.227.230:10349
|
||||||
|
161.49.176.169:10101
|
||||||
|
8.219.97.248:80
|
||||||
|
160.248.80.91:587
|
||||||
|
72.10.164.178:32827
|
||||||
|
67.43.228.252:5287
|
||||||
|
221.6.139.190:9002
|
||||||
|
135.181.154.225:80
|
||||||
|
72.10.164.178:27267
|
||||||
|
119.15.86.30:8080
|
||||||
|
186.207.191.213:8080
|
||||||
|
72.10.160.173:9879
|
||||||
|
103.159.194.249:8080
|
||||||
|
67.43.227.227:5191
|
||||||
|
121.101.134.214:1111
|
||||||
|
122.185.180.190:32650
|
||||||
|
195.20.236.50:3128
|
||||||
|
201.71.2.249:999
|
||||||
|
148.72.168.81:30119
|
||||||
|
177.234.223.30:999
|
||||||
|
103.159.195.29:8080
|
||||||
|
60.242.169.3:80
|
||||||
|
113.108.13.120:8083
|
||||||
|
50.62.183.223:80
|
||||||
|
114.9.27.190:3125
|
||||||
|
72.10.160.93:30769
|
||||||
|
67.43.228.250:20833
|
||||||
|
143.42.66.91:80
|
||||||
|
54.37.207.54:3128
|
||||||
|
31.7.70.215:3128
|
||||||
|
183.234.215.11:8443
|
||||||
|
107.189.8.240:8080
|
||||||
|
172.232.172.64:8080
|
||||||
|
189.43.42.105:80
|
||||||
|
149.14.76.99:8080
|
||||||
|
72.10.160.173:6677
|
||||||
|
109.236.83.153:8888
|
||||||
|
162.19.107.209:3128
|
||||||
|
62.169.26.156:8082
|
||||||
|
153.101.67.170:9002
|
||||||
|
41.204.53.22:80
|
||||||
|
67.43.228.252:28393
|
||||||
|
182.253.140.250:8080
|
||||||
|
41.254.48.54:19333
|
||||||
|
154.12.242.82:8889
|
||||||
|
67.43.227.226:19815
|
||||||
|
161.34.40.33:3128
|
||||||
|
67.43.236.18:3639
|
||||||
|
67.43.227.227:8467
|
||||||
|
103.228.243.229:3125
|
||||||
|
202.148.16.147:8080
|
||||||
|
31.43.52.216:41890
|
||||||
|
41.204.53.26:80
|
||||||
|
72.10.160.91:2113
|
||||||
|
194.182.187.78:3128
|
||||||
|
103.152.100.221:8080
|
||||||
|
77.238.224.28:8080
|
||||||
|
218.252.242.29:80
|
||||||
|
58.147.186.214:3125
|
||||||
|
41.204.53.21:80
|
||||||
|
116.197.134.13:8080
|
||||||
|
77.221.136.168:8000
|
||||||
|
36.95.82.69:8080
|
||||||
|
171.97.235.209:8080
|
||||||
|
80.194.38.106:3333
|
||||||
|
72.10.164.178:1491
|
||||||
|
179.49.162.133:999
|
||||||
|
27.112.70.155:8083
|
||||||
|
109.104.153.241:8898
|
||||||
|
191.242.224.185:3100
|
||||||
|
101.255.166.58:3030
|
||||||
|
8.213.156.191:1080
|
||||||
|
61.14.233.227:1003
|
||||||
|
190.2.215.93:999
|
||||||
|
72.10.160.90:12519
|
||||||
|
115.178.49.111:8080
|
||||||
|
38.52.222.243:999
|
||||||
|
116.203.67.104:3128
|
||||||
|
194.124.36.180:8080
|
||||||
|
72.10.160.171:14497
|
||||||
|
72.10.160.94:24081
|
||||||
|
183.162.197.197:8060
|
||||||
|
139.59.1.14:8080
|
||||||
|
118.97.164.19:8080
|
||||||
|
72.10.160.171:24163
|
||||||
|
67.43.228.253:29377
|
||||||
|
178.48.68.61:18080
|
||||||
|
190.94.212.197:999
|
||||||
|
67.43.227.230:2595
|
||||||
|
5.252.22.45:80
|
||||||
|
8.209.255.13:3128
|
||||||
|
72.10.164.178:32801
|
||||||
|
103.26.108.118:84
|
||||||
|
67.43.227.227:3497
|
||||||
|
160.119.42.77:8088
|
||||||
|
103.48.71.142:83
|
||||||
|
67.43.227.226:26173
|
||||||
|
61.129.2.212:8080
|
||||||
|
148.72.168.80:30127
|
||||||
|
212.107.28.120:80
|
||||||
|
47.252.18.37:80
|
||||||
|
185.172.172.95:3128
|
||||||
|
77.221.139.76:8000
|
||||||
|
203.128.80.178:8099
|
||||||
|
67.43.227.227:17131
|
||||||
|
47.91.115.179:9080
|
||||||
|
139.196.191.172:443
|
||||||
|
189.201.153.91:999
|
||||||
|
103.247.21.44:1111
|
||||||
|
43.153.237.252:3128
|
||||||
|
82.180.146.116:3128
|
||||||
|
191.243.46.30:43241
|
||||||
|
188.125.169.100:8080
|
||||||
|
72.10.160.90:11717
|
||||||
|
186.125.218.170:999
|
||||||
|
114.216.205.216:8089
|
||||||
|
41.34.3.143:8080
|
||||||
|
123.126.158.50:80
|
||||||
|
91.229.28.110:3128
|
||||||
|
72.10.164.178:27109
|
||||||
|
201.62.125.142:8080
|
||||||
|
67.43.228.250:15181
|
||||||
|
158.178.203.159:3128
|
||||||
|
72.10.160.170:29217
|
||||||
|
36.64.132.91:3127
|
||||||
|
222.74.73.202:42055
|
||||||
|
23.247.137.142:80
|
||||||
|
80.78.65.230:8080
|
||||||
|
51.89.255.67:80
|
||||||
|
129.226.193.16:3128
|
||||||
|
72.10.160.170:14399
|
||||||
|
103.189.249.207:8090
|
||||||
|
154.205.128.153:8888
|
||||||
|
103.137.67.177:8080
|
||||||
|
72.10.160.90:11173
|
||||||
|
178.128.113.118:23128
|
||||||
|
138.68.60.8:3128
|
||||||
|
190.43.232.60:999
|
||||||
|
67.43.227.227:31681
|
||||||
|
185.250.148.59:8989
|
||||||
|
72.10.160.172:14235
|
||||||
|
72.10.160.171:11855
|
||||||
|
67.43.236.20:23983
|
||||||
|
45.77.113.142:8082
|
||||||
|
190.95.209.180:999
|
||||||
|
57.128.169.167:3128
|
||||||
|
67.43.228.250:1405
|
||||||
|
58.20.248.139:9002
|
||||||
|
182.253.6.236:8080
|
||||||
|
103.157.59.75:8080
|
||||||
|
188.72.6.178:8083
|
||||||
|
190.83.15.21:999
|
||||||
|
131.196.42.95:667
|
||||||
|
176.9.238.155:16379
|
||||||
|
5.161.115.29:51111
|
||||||
|
38.159.229.98:999
|
||||||
|
103.76.151.52:8181
|
||||||
|
38.222.45.212:8080
|
||||||
|
24.150.141.252:8080
|
||||||
|
144.24.122.46:80
|
||||||
|
43.134.68.153:3128
|
||||||
|
72.10.164.178:32927
|
||||||
|
8.213.151.128:3128
|
||||||
|
67.43.236.22:31349
|
||||||
|
120.28.213.45:8080
|
||||||
|
181.78.108.225:999
|
||||||
|
72.10.164.178:20705
|
||||||
|
67.43.227.230:25493
|
||||||
|
192.145.173.101:8080
|
||||||
|
23.122.184.9:8888
|
||||||
|
190.2.57.97:3128
|
||||||
|
190.239.221.47:999
|
||||||
|
103.165.128.171:8080
|
||||||
|
67.43.236.20:28903
|
||||||
|
89.114.185.185:8080
|
||||||
|
72.10.164.178:11611
|
||||||
|
49.0.34.194:8080
|
||||||
|
27.147.175.115:8080
|
||||||
|
103.126.219.37:8080
|
||||||
|
114.236.93.208:19353
|
||||||
|
198.145.118.84:8080
|
||||||
|
196.251.193.116:8082
|
||||||
|
181.78.82.214:999
|
||||||
|
195.158.26.246:8080
|
||||||
|
190.61.106.97:8080
|
||||||
|
103.156.15.96:1111
|
||||||
|
181.10.123.156:999
|
||||||
|
14.143.75.250:80
|
||||||
|
125.124.225.211:3128
|
||||||
|
58.47.50.115:8118
|
||||||
|
103.42.242.45:3125
|
||||||
|
45.117.29.153:58080
|
||||||
|
72.10.164.178:23305
|
||||||
|
103.142.165.193:58080
|
||||||
|
186.215.87.194:6011
|
||||||
|
103.242.105.193:8181
|
||||||
|
49.13.1.139:8080
|
||||||
|
116.0.53.34:8080
|
||||||
|
103.165.155.60:8080
|
||||||
|
148.251.111.63:80
|
||||||
|
72.10.160.170:14349
|
||||||
|
201.220.112.98:999
|
||||||
|
103.105.53.110:7777
|
||||||
|
67.43.227.226:8245
|
||||||
|
103.177.199.47:1111
|
||||||
|
103.168.254.62:8080
|
||||||
|
103.48.68.138:83
|
||||||
|
103.175.238.174:8080
|
||||||
|
189.43.42.100:80
|
||||||
|
67.43.236.19:2525
|
||||||
|
24.152.50.130:8080
|
||||||
|
67.43.236.20:30351
|
||||||
|
3.70.236.147:8090
|
||||||
|
103.141.180.254:8080
|
||||||
|
50.220.168.146:80
|
||||||
|
67.43.236.18:4685
|
||||||
|
46.17.249.210:35782
|
||||||
|
38.54.101.254:8080
|
||||||
|
45.70.203.117:999
|
||||||
|
83.219.145.106:3128
|
||||||
|
103.69.20.28:58080
|
||||||
|
62.169.26.156:8081
|
||||||
|
38.54.101.254:7071
|
||||||
|
67.43.236.20:21477
|
||||||
|
67.43.227.229:13633
|
||||||
|
47.247.78.129:80
|
||||||
|
185.76.10.135:8081
|
||||||
|
177.234.250.58:999
|
||||||
|
188.125.167.67:8080
|
||||||
|
61.160.212.169:181
|
||||||
|
67.43.236.18:11165
|
||||||
|
60.242.169.0:80
|
||||||
|
72.10.164.178:27171
|
||||||
|
67.43.228.253:4787
|
||||||
|
72.10.164.178:10033
|
||||||
|
67.43.228.251:18543
|
||||||
|
50.220.168.144:80
|
||||||
|
77.228.182.122:8080
|
||||||
|
103.126.148.24:8080
|
||||||
|
189.43.42.96:80
|
||||||
|
72.10.160.171:31337
|
||||||
|
179.32.62.127:999
|
||||||
|
148.72.169.225:10539
|
||||||
|
72.10.164.178:21861
|
||||||
|
72.10.160.171:30791
|
||||||
|
72.10.160.94:8777
|
||||||
|
67.43.227.227:14673
|
||||||
|
121.37.109.196:8118
|
||||||
|
103.119.67.95:8080
|
||||||
|
103.112.54.21:58080
|
||||||
|
103.122.1.26:8080
|
||||||
|
63.151.59.218:8080
|
||||||
|
67.43.227.228:30889
|
||||||
|
177.93.48.43:999
|
||||||
|
67.43.228.253:29153
|
||||||
|
67.43.227.227:29381
|
||||||
|
103.123.120.49:8080
|
||||||
|
101.255.209.242:8080
|
||||||
|
103.124.173.209:82
|
||||||
|
191.97.68.42:8080
|
||||||
|
38.156.73.61:8080
|
||||||
|
102.214.104.56:8080
|
||||||
|
103.48.68.124:83
|
||||||
|
188.240.120.15:8080
|
||||||
|
200.94.102.12:999
|
||||||
|
222.252.194.204:8080
|
||||||
|
148.72.168.81:30118
|
||||||
|
191.102.248.9:8085
|
||||||
|
41.193.81.7:80
|
||||||
|
41.216.186.183:8181
|
||||||
|
165.225.216.157:10111
|
||||||
|
103.118.175.154:8080
|
||||||
|
103.29.185.59:3125
|
||||||
|
103.189.197.113:8181
|
||||||
|
190.95.132.190:999
|
||||||
|
167.103.20.104:8800
|
||||||
|
95.214.123.132:8080
|
||||||
|
203.190.44.251:8080
|
||||||
|
58.220.95.63:10878
|
||||||
|
187.86.159.54:3128
|
||||||
|
103.217.217.190:8080
|
||||||
|
38.82.21.192:999
|
||||||
|
124.83.73.240:8082
|
||||||
|
103.80.230.26:8090
|
||||||
|
119.2.52.152:8282
|
||||||
|
147.161.132.252:10035
|
||||||
|
116.105.76.194:28006
|
||||||
|
167.103.3.22:11011
|
||||||
|
103.41.35.153:58080
|
||||||
|
117.54.114.101:80
|
||||||
|
185.118.153.110:8080
|
||||||
|
14.241.80.61:8080
|
||||||
|
190.95.202.210:999
|
||||||
|
117.54.114.96:80
|
||||||
|
103.166.158.33:8080
|
||||||
|
117.54.114.99:80
|
||||||
|
103.39.51.73:8080
|
||||||
|
103.153.142.18:8080
|
||||||
|
103.123.120.121:8080
|
||||||
|
185.49.170.20:43626
|
||||||
|
103.28.114.157:66
|
||||||
|
218.91.79.36:8888
|
||||||
|
165.225.214.117:9400
|
||||||
|
103.76.149.67:8080
|
||||||
|
201.91.82.155:3128
|
||||||
|
136.226.233.89:9400
|
||||||
|
197.255.125.12:80
|
||||||
|
103.59.163.130:32650
|
||||||
|
186.3.97.45:999
|
||||||
|
136.226.232.203:10063
|
||||||
|
136.226.252.85:9401
|
||||||
|
202.180.54.211:8080
|
||||||
|
165.225.216.156:9443
|
||||||
|
176.121.1.163:8989
|
||||||
|
103.152.116.82:8080
|
||||||
|
103.63.26.226:1111
|
||||||
|
112.78.40.210:8080
|
||||||
|
178.115.253.35:8080
|
||||||
|
185.65.254.161:8081
|
||||||
|
147.45.71.77:8080
|
||||||
|
154.73.28.253:8080
|
||||||
|
91.103.253.144:3128
|
||||||
|
103.171.244.44:8088
|
||||||
|
103.155.20.61:8082
|
||||||
|
154.73.28.161:8080
|
||||||
|
117.54.114.97:80
|
||||||
|
185.242.84.22:3128
|
||||||
|
103.124.139.212:1080
|
||||||
|
103.127.97.187:3128
|
||||||
@@ -0,0 +1,41 @@
|
|||||||
|
import asyncio
|
||||||
|
import argparse
|
||||||
|
from urllib.parse import urlparse
|
||||||
|
from pytmi import Client # Assurez-vous que c'est le nom correct de votre module et qu'il est correctement installé.
|
||||||
|
|
||||||
|
async def send_message_to_twitch_stream(nick, token, stream_url, message):
|
||||||
|
parsed_url = urlparse(stream_url)
|
||||||
|
channel = parsed_url.path.lstrip('/')
|
||||||
|
|
||||||
|
async with Client() as client:
|
||||||
|
try:
|
||||||
|
print("Tentative de login")
|
||||||
|
await client.login_oauth(token, nick)
|
||||||
|
print("Tentative de join")
|
||||||
|
await client.join(channel)
|
||||||
|
print("Tentative d'envoi de message")
|
||||||
|
await client.send_message(message)
|
||||||
|
print("Message envoyé avec succès.")
|
||||||
|
# await client.part(channel)
|
||||||
|
# print("disconnect.")
|
||||||
|
except Exception as e:
|
||||||
|
print(f"Erreur lors de l'interaction avec Twitch: {type(e).__name__}, {e}")
|
||||||
|
|
||||||
|
async def main():
|
||||||
|
# nick = "foufure13" # Remplacez par votre pseudo Twitch
|
||||||
|
# token = "oauth:7mexqe9zcxrqpz1s0fji4oolr4mxn6" # Remplacez par votre token OAuth
|
||||||
|
# stream_url = "https://www.twitch.tv/shambiess" # Remplacez par l'URL du stream Twitch
|
||||||
|
# message = "yoo" # Message à envoyer
|
||||||
|
|
||||||
|
parser = argparse.ArgumentParser()
|
||||||
|
parser.add_argument('-pseudo', type=str, required=True, help='Pseudo name account')
|
||||||
|
parser.add_argument('-token', type=str, required=True, help='Token oauth')
|
||||||
|
parser.add_argument('-message', type=str, required=True, help='Message to send')
|
||||||
|
parser.add_argument('-twitchname', type=str, required=True, help='Twitch channel name')
|
||||||
|
args = parser.parse_args()
|
||||||
|
|
||||||
|
stream_url = "https://www.twitch.tv/"+args.twitchname
|
||||||
|
await send_message_to_twitch_stream(nick=args.pseudo, token=args.token, stream_url=stream_url, message=args.message)
|
||||||
|
|
||||||
|
if __name__ == "__main__":
|
||||||
|
asyncio.run(main())
|
||||||
Submodule
+1
Submodule working_bot/twitch-recordAudio added at 7d4c48796e
Reference in New Issue
Block a user