This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # zsh | |
| sudo apt install -y zsh zsh-antigen zsh-syntax-highlighting | |
| sudo chsh -s /bin/zsh laugustyniak | |
| sudo chsh -s /bin/zsh root | |
| git clone https://github.com/tarjoilija/zgen.git "${HOME}/.zgen" | |
| git clone git://github.com/wting/autojump.git | |
| cd autojump |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # zsh | |
| sudo yum install -y zsh autojump-zsh | |
| sudo chsh -s /bin/zsh aci-user | |
| sudo chsh -s /bin/zsh laugustyniak | |
| sudo chsh -s /bin/zsh root | |
| # oh-my-zsh | |
| sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| pip install rasa_nlu[spacy] | |
| python -m spacy download en_core_web_md | |
| python -m spacy link en_core_web_md en |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| cd /usr/lib/slack/resources/app.asar.unpacked/src/static | |
| mv slack-taskbar-highlight.png slack-taskbar-highlight-backup.png | |
| mv slack-taskbar-unread.png slack-taskbar-unread-backup.png | |
| cp slack-taskbar-rest.png slack-taskbar-highlight.png | |
| cp slack-taskbar-rest.png slack-taskbar-unread.png |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| curl -XGET 'http://127.0.0.1:9200/_all/_settings?pretty=1' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| RUN apt-get update && apt-get install -y sudo && rm -rf /var/lib/apt/lists/* |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| nlp = spacy.load('en_vectors_web_lg') | |
| def most_similar(word): | |
| queries = [w for w in word.vocab if w.is_lower == word.is_lower and w.prob >= -15] | |
| by_similarity = sorted(queries, key=lambda w: word.similarity(w), reverse=True) | |
| return by_similarity[:10] | |
| word_to_lookup = ['insurance', 'extended', 'phone', 'coverage', 'device'] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import unicodedata | |
| data = u'ïnvéntìvé' | |
| normal = unicodedata.normalize\ | |
| ('NFKD', data).\ | |
| encode('ASCII', 'ignore') | |
| print(normal) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import sys | |
| reload(sys) | |
| sys.setdefaultencoding('utf-8') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import operator | |
| sorted(d.items(), key=operator.itemgetter(1), reverse=True) |
NewerOlder