Skip to content

Instantly share code, notes, and snippets.

🚗
Alive on weekends

jubin jose freakeinstein

🚗
Alive on weekends
Block or report user

Report or block freakeinstein

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@freakeinstein
freakeinstein / hangout.py
Created May 10, 2019
hangout simple request response
View hangout.py
#!/usr/bin/env python3
"""Example bot that returns a synchronous response."""
from flask import Flask, request, json
app = Flask(__name__)
@app.route('/', methods=['POST'])
View nginx reverse proxy config
server_name _;
location / {
proxy_pass http://127.0.0.1:4000;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
# First attempt to serve request as file, then
# as directory, then fall back to displaying a 404.
# try_files $uri $uri/ =404;
@freakeinstein
freakeinstein / fastwrapper.md
Last active Nov 18, 2018
writing a fasttext python wrapper
View fastwrapper.md

create root directory

  • mkdir root&&cd root

install conan package manager

  • pip install conan ref

create conanfile.txt with package dependencies

  • in our case, we need pybind11 so, content of conanfile.txt ref
[requires]
@freakeinstein
freakeinstein / data.json
Last active Feb 23, 2018
json test data
View data.json
{
"greet": [
{
"text": "Hello welcome."
},
{
"text": "I can help you to search for resturents."
}
],
"restaurant_search": [
You can’t perform that action at this time.