How to simulate bot typing in Telegram chats?

yea, i’ve messed with this before. one thing u could try is adding some randomness to the typing time. like:

async def fake_type(chat_id, msg):
    time = len(msg) * 0.1 + random.uniform(1, 3)
    await bot.send_chat_action(chat_id, 'typing')
    await asyncio.sleep(time)
    await bot.send_message(chat_id, msg)

makes it feel more human-like. just my 2 cents!