eixix / sili-telegram-bot Goto Github PK
View Code? Open in Web Editor NEWLicense: MIT License
License: MIT License
The punline is currently in section for meme constant "1" but describes a positive outcome. It should probably go in section "2".
This doesn't match with how the punlines are integrated into the message, as currently punlines are not supposed to be separate sentences.
Start of second sentence is not capitalized.
When the text tag being matched contains a link, the heuristic for getting the voiceline no longer works as the text is broken up by a link element.
sili-telegram-bot/src/models/voiceline.py
Line 58 in 0ee0acf
/voiceline Rubick: Oh. Shitty wizard!
(Link)
--> No voiceline will be found.
Use all text in the tag in question for matching. Slight performance penalty because we have to potentially do this for each voiceline tag of a hero, but necessary I think.
evtl in Abhängigkeit der Spielleistung
Bsp.: Omniknight: "hat die Gegner in den Boden gehämmert"
Lion: "mehr gefingert als im Puff"
Riki: "hat nochmal versucht, cloak and Dagger zu lernen"
"hat verschwindent impact gehabt"
"die Gegner haben ihren Tod nie kommen sehen"
The voiceline command attempts to send a message of the initiating user's telegram username in order to let others know who came up with the masterpiece of comedic timing in question while not polluting the chat with ugly commands.
Lines 139 to 141 in 3a06a4f
However the update.message.from_user.username
field may be empty when a user has no user name (or possibly is choosing to keep it private). In that case update.message.from_user.username
is None, and the operation fails, aborting the whole voiceline operation.
Have a hierarchy of fallback options for attributing the voiceline, so that if one is unavailable, we can still have the attribution.
I'd go with: username > first name (maybe last name, if available) > User ID > "Unknown User".
Obviously I don't know which of these are available when, so I need to double check the docs. If I did, this problem wouldn't exist.
In addition to hero voicelines, the dota wiki hosts plenty of other types of responses, such as announcers and personas. These should be retrievable as well.
The method for determining the hero response url fails if the hero name contains a preposition (e.g. Keeper of the Light, Queen of Pain). The problem is that the hero response URL is case sensitive, and with the current method the prepositions are captialized when they shouldn't be.
sili-telegram-bot/src/models/voiceline.py
Line 21 in 7afba75
update heroes.json to include Muerta
Für DoDos oder DOMiNas der einem coole meme strats vorschlägt. Die Captains schreibt ihm dann privat und er antwortet mit entsprechender Strategie oder halt öffentlich in der SiliGruppe. Der Bot müsste halt dann auch darauf achten kein hero doppelt zu vergeben oder die strat ein bisschen aufzuweichen
After entering a valid voiceline command, the command message is deleted, however the actual voiceline is not actually delivered. Other behaviour such as the help messages are not affected.
My theory is this has todo with the message deletion...
Bsp.:
Michi spielt oracle ---> "hat die Flexibilität einer Tomate bewiesen"
Cormo spielt Jakiro --> " - üüüüberraaaschung - " + Punchline
Cormo spielt Ogre ---> " ist doch auch nur nen Jakiro "
The DotA2 wiki has migrated to liquipedia (Official announcement).
Retrieving voicelines works by finding the appropriate voiceline on the wiki page of the hero in question, scanning the html of that page for the voiceline text, and then delivering a link to the corresponding audio file. With the new host and possibly changed html layout, changes will be necessary to continue this feature.
Hard-coded host:
sili-telegram-bot/src/models/voiceline.py
Line 15 in 65c2524
Indiviual hero url:
sili-telegram-bot/src/models/voiceline.py
Line 23 in 65c2524
CSS selector for finding voiceline text:
sili-telegram-bot/src/models/voiceline.py
Line 32 in 65c2524
einfach eine besondere Erwähnung bei einer Rampage!
Wie z.B.:
" hat das ganze gegnerische Team im alleingang in Grund und Boden gestampft! Warum ist er nur Crusader?"
" hat allein alle fünf Gegner zu Kleinholz verarbeitet!"
I feel for doing delicate little changes there should be a straightforward way to create debugging matches to use methods on...
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.