Skip to content

Instantly share code, notes, and snippets.

View nelsonic's full-sized avatar
💭
Let's Build a Better World Together!☀️

Nelson nelsonic

💭
Let's Build a Better World Together!☀️
View GitHub Profile
This file has been truncated, but you can view the full file.
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.155 Safari/537.36
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_4) AppleWebKit/600.7.12 (KHTML, like Gecko) Version/8.0.7 Safari/600.7.12
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.135 Safari/537.36
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_5) AppleWebKit/600.8.9 (KHTML, like Gecko) Version/8.0.8 Safari/600.8.9
Mozilla/5.0 (iPhone; CPU iPhone OS 8_2 like Mac OS X) AppleWebKit/600.1.4 (KHTML, like Gecko) CriOS/44.0.2403.67 Mobile/12D508 Safari/600.1.4
Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/44.0.2403.155 Safari/537.36
Mozilla/5.0 (Windows NT 6.1; rv:38.0) Gecko/20100101 Firefox/38.0
Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2049.0 Safari/537.36
Mozilla/5.0 (Windows NT 10.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.135 Safari/537.36 Edge/12.10240
Mozilla/5.0
@nelsonic
nelsonic / llama-7b-m1.md
Created May 22, 2023 17:32 — forked from cedrickchee/llama-7b-m1.md
4 Steps in Running LLaMA-7B on a M1 MacBook with `llama.cpp`

4 Steps in Running LLaMA-7B on a M1 MacBook

The large language models usability

The problem with large language models is that you can’t run these locally on your laptop. Thanks to Georgi Gerganov and his llama.cpp project, it is now possible to run Meta’s LLaMA on a single computer without a dedicated GPU.

Running LLaMA

There are multiple steps involved in running LLaMA locally on a M1 Mac after downloading the model weights.

@nelsonic
nelsonic / recursiveGet.js
Last active April 26, 2021 17:19 — forked from deepanprabhu/gist:fbb406c3432c19eafe78a4b44e6a4b23
Concise Recursive DynamoDB Scan - Large Table - Using ExclusiveStartKey and LastEvaluatedKey - NodeJS
// Load the AWS SDK for JS
const AWS = require("aws-sdk");
// Set a region to interact with (make sure it's the same as the region of your table)
AWS.config.update({region: 'eu-west-2'});
// Set a table name that we can use later on
const tableName = "people"
// Create the Service interface for DynamoDB
@nelsonic
nelsonic / gist:cb4143e3b5be7bfd9a5cf73dfa74a6ac
Created October 15, 2020 11:29 — forked from vargeorge/gist:8b20488b7d7b6c101b4b
Show full path on OS X terminal / iTerm before the $ prompt
1. Edit ~/.bash_profile and add the following line to show full path before the $ prompt.
For example, as user@hostname:path/to/directory$
# show path before the $ prompt
export PS1='\u@\H:\w$ '
2. Save file and restart terminal or run source command
$ source ~/.bash_profile
@nelsonic
nelsonic / softwareengineering
Created September 30, 2019 11:52 — forked from scottashipp/softwareengineering
Software Engineering Quotes for fortune
%
Simple things should be simple, complex things should be possible.
The Wiki Way: Quick Collaboration on the Web, Bo Leuf, Ward
Cunningham
%
Simplicity is the soul of efficiency.
Austin Freeman
%
I have yet to see any problem, however complicated, which, when you
looked at it in the right way, did not become still more complicated.
@nelsonic
nelsonic / softwareengineering
Created September 30, 2019 11:52 — forked from scottashipp/softwareengineering
Software Engineering Quotes for fortune
%
Simple things should be simple, complex things should be possible.
The Wiki Way: Quick Collaboration on the Web, Bo Leuf, Ward
Cunningham
%
Simplicity is the soul of efficiency.
Austin Freeman
%
I have yet to see any problem, however complicated, which, when you
looked at it in the right way, did not become still more complicated.
@nelsonic
nelsonic / travis-deploy-ssh.md
Created May 25, 2018 19:56 — forked from m3t/travis-deploy-ssh.md
Continuous deployment over SSH with Tavis CI, e.g. gh-pages

On Mar 28, 2013 Dan Allen explained how to deploy to github-pages automatically. Many other GitHub users like Steve Klabnik and Domenic Denicola followed with the same approach:

Use an OAuth token with public_repo or repo permission to access the Github account over HTTPS inside a virtual build environment.

The same applies to Travis CI's built-in abilities, and there are more restrictions as deploying GitHub Releases works only for tags, not for branches.

Security concerns

The token grants write access for all of your (public) repositories and

@nelsonic
nelsonic / facebook-contact-info-summary.rb
Created March 23, 2018 15:46 — forked from dylanmckay/facebook-contact-info-summary.rb
A Ruby script for collecting phone record statistics from a Facebook user data dump
#! /usr/bin/env ruby
# This script can be used to parse and dump the information from
# the 'html/contact_info.htm' file in a Facebook user data ZIP download.
#
# It prints all cell phone call + SMS message + MMS records, plus a summary of each.
#
# It also dumps all of the records into CSV files inside a 'CSV' folder, that is created
# in whatever the working directory of the program is when executed.
#
@nelsonic
nelsonic / introrx.md
Created February 1, 2018 20:21 — forked from staltz/introrx.md
The introduction to Reactive Programming you've been missing
@nelsonic
nelsonic / Main.elm
Created January 3, 2018 17:15 — forked from chrisbuttery/Main.elm
Elm 0.17. A simple Mouse.moves example
import Html exposing (Html, text, div)
import Html.App as Html
import Mouse exposing (..)
main =
Html.program
{ init = init
, view = view
, update = update
, subscriptions = subscriptions