Skip to content

Instantly share code, notes, and snippets.

View lambdaofgod's full-sized avatar
🤗
opensource

Jakub Bartczuk lambdaofgod

🤗
opensource
View GitHub Profile
@roycoding
roycoding / rss.md
Created May 21, 2020 20:10
It's 2020 and I made an RSS feed for my blog (with Python)

It's 2020 and I made an RSS feed for my blog (with Python)

Roy Keyes

21 May 2020 - This is a post on my blog. Grab the RSS feed here 😉

I was recently telling someone about all of the awesome blog posts I have sitting in my backlog, just waiting to actually be written. They asked if there was a way to subscribe or get notified when my next post was live. The answer was "watch my Twitter", which was admittedly unsatisfactory.

Coincidentally I have been seeing a number of recent articles on the desire for more independent blog content and a return to RSS-based syndication. I think this is all part of a broader push for a (return to a?) m

@AndyShiue
AndyShiue / CuTT.md
Last active October 30, 2024 20:12
Cubical type theory for dummies

I think I’ve figured out most parts of the cubical type theory papers; I’m going to take a shot to explain it informally in the format of Q&As. I prefer using syntax or terminologies that fit better rather than the more standard ones.

Q: What is cubical type theory?

A: It’s a type theory giving homotopy type theory its computational meaning.

Q: What is homotopy type theory then?

A: It’s traditional type theory (which refers to Martin-Löf type theory in this Q&A) augmented with higher inductive types and the univalence axiom.

@kumarbhrgv
kumarbhrgv / draft.md
Last active February 1, 2022 14:47
Diversity in Recommendation Systems

Improvising diversity of personalized recommendation systems

Recent Research papers:

  • Improving Aggregate Recommendation Diversity Using Ranking-Based Techniques:

    107 Citations : IEEE Transactions on Knowledge and Data Engineering
    we introduce and explore a number of item ranking techniques that can generate substantially more diverse recommendations across all users while maintaining comparable levels of recommendation accuracy. Comprehensive empirical evaluation consistently shows the diversity gains of the proposed techniques using several real-world rating data sets and different rating prediction algorithms

  • Recommendation Diversification Using Explanations: (Data Engineering, 2009. ICDE '09. IEEE 25th International Conference)

Traditionally, the problem is addressed through attribute-based diversification grouping items in the result set that share many common attributes (e.g., genre for movies) and selecting only a limited number of items from each group. It is, however,

@gbaman
gbaman / graphql_example.py
Created November 1, 2017 00:18
An example on using the Github GraphQL API with Python 3
# An example to get the remaining rate limit using the Github GraphQL API.
import requests
headers = {"Authorization": "Bearer YOUR API KEY"}
def run_query(query): # A simple function to use requests.post to make the API call. Note the json= section.
request = requests.post('https://api.github.com/graphql', json={'query': query}, headers=headers)
if request.status_code == 200:
@lorey
lorey / markdown_to_text.py
Last active July 18, 2024 05:53
Markdown to Plaintext in Python
from bs4 import BeautifulSoup
from markdown import markdown
import re
def markdown_to_text(markdown_string):
""" Converts a markdown string to plaintext """
# md -> html -> text since BeautifulSoup can extract text cleanly
html = markdown(markdown_string)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
# Taken from https://forums.aws.amazon.com/thread.jspa?messageID=332091
sudo su -
cd /usr/local/bin
mkdir ffmpeg
cd ffmpeg
wget http://ffmpeg.gusari.org/static/64bit/ffmpeg.static.64bit.latest.tar.gz
tar -xzf ffmpeg.static.64bit.latest.tar.gz
@aparrish
aparrish / spacy_intro.ipynb
Last active July 29, 2024 21:03
NLP Concepts with spaCy. Code examples released under CC0 https://creativecommons.org/choose/zero/, other text released under CC BY 4.0 https://creativecommons.org/licenses/by/4.0/
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
from vowpalwabbit import pyvw
def to_vw(clf, text, str_labels):
vw_example = str('{} |f {} '.format(str_labels, text))
return clf.example(vw_example)
clf = vw = pyvw.vw(
loss_function='logistic', oaa=2,
link='logistic', raw_predictions='output.txt'
)
@derhuerst
derhuerst / output.js
Created May 10, 2016 10:22
how fetch a GitHub user's stars
[
{
owner: 'bcoe',
repo: 'top-npm-users',
description: ':star: Generate a list of top npm users by based on monthly downloads.',
language: 'JavaScript',
isFork: false,
stargazers: 27,
watchers: 27
}