Skip to content

Instantly share code, notes, and snippets.

View jarkko-hautakorpi's full-sized avatar

Jarkko jarkko-hautakorpi

View GitHub Profile
git clone https://github.com/cpacker/MemGPT.git
conda create -n memgpt python=3.10
conda activate memgpt
cd memgpt
pip install -r requirements.txt
export OPENAI_API_KEY="YOUR_API_KEY"
# download .txt docs from: https://huggingface.co/datasets/MemGPT/example-sec-filings/tree/main
# place in "memgpt/personas/examples/preload_archival/*.txt"
python3 main.py --archival_storage_files_compute_embeddings="memgpt/personas/examples/preload_archival/*.txt" --persona=memgpt_doc --human=basic
REM This is to fix teams issue: MS Teams keeps randomly crashing
REM https://answers.microsoft.com/en-us/msoffice/forum/all/ms-teams-keeps-randomly-crashing/d4b3fd90-c77e-468a-82a7-8190db44f73f
taskkill /F /IM teams.exe
del /f /s /q %appdata%\Microsoft\teams\application cache\cache\*
del /f /s /q %appdata%\Microsoft\teams\blob_storage\*
del /f /s /q %appdata%\Microsoft\teams\databases\*
del /f /s /q %appdata%\Microsoft\teams\GPUcache\*
del /f /s /q %appdata%\Microsoft\teams\IndexedDB\*
del /f /s /q "%appdata%\Microsoft\teams\Local Storage\*"
@Staars
Staars / mj_ht_v1.ino
Created February 1, 2020 08:49
Xiaomi test (from cbm80amiga) with the OLED-part removed
// Reading Xiaomi Mi BLE Temperature & Humidity Monitor
// Code for the video: https://youtu.be/pyhpXnFzNhU
// (C)2019 Pawel A. Hernik
// BLE code based on Dmitry Grinberg and Florian Echtler work
/* PINOUT
nRF24L01 from pin side/top:
-------------
|1 3 5 7 |
|2 4 6 8 |
@micw
micw / w132.ino
Last active January 4, 2022 16:58
Ventus W132 decoder sketch
/**
* Ein ESP8622 NodeMCU Develompent Board, welches Sensorwerte via MQTT verschickt
* http://frightanic.com/iot/comparison-of-esp8266-nodemcu-development-boards/
*
* Umbau eines W132 Windsensors von ELV
*
* - Abtrennen des 433 MHZ-Senders, welcher mit 3 Leitungen (Schwarz, Rot, Blau) an der Logik-Platine angeschlossen ist
* - Anschließen des ESP-8266
* - Schwarz -> GND
* - Rot -> 3.3V
@DKrepsky
DKrepsky / Kicad project relative path
Created July 13, 2017 14:12
Add project relative path into kicad
To add paths relative to the project folder use the environment variable ${KIPRJMOD}.
Example: ${KIPRJMOD}/3d/resistor_model.wrl
// Copyright 2015-2016 Espressif Systems (Shanghai) PTE LTD
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
@Evilcry
Evilcry / scada_password_recovery_list.csv
Last active March 21, 2024 14:59
SCADA Password Recovery List
We can make this file beautiful and searchable if this error is corrected: It looks like row 8 should actually have 1 column, instead of 8. in line 7.
Yokogawa;CENTUM CS 3000 DCS;CENTUM:CENTUM
Yokogawa;EJX910A Multivariable Transmitter HART Communication Type;YOKOGAWA. (to release the Write Protect mode)
Yokogawa;WT 3000 Driver;anonymous:blank (Ethernet access)
Yokogawa;DX1000/DX1000N/DX2000 Advanced;Administrator 1:Admin1 etc./ User 1:User01 etc.
Yokogawa;YFGW410 gateway;admin:!admin
Wonderware;System Platform/Archestra;administrator:blank
Wonderware;Intouch;Administrator:Wonderware
Wonderware;Historian;SQL Server Login: aadbo:pwddbo, wwdbo:pwddbo, aaAdmin:pwAdmin, wwAdmin:wwAdmin, aaPower:pwPower, wwPower:wwPower, aaUser:pwUser, wwUser:wwUser
Westermo;TDW 33;no password, just return, Hardcoded password: n3Y9kA6otYZu8, (?? TD-36)
Westermo;MRD-305-DIN/MRD-310/MRD-315/MRD-330/MRD-355/MRD-350/MRD-455;admin:westermo
@fntlnz
fntlnz / self-signed-certificate-with-custom-ca.md
Last active July 15, 2024 09:31
Self Signed Certificate with Custom Root CA

Create Root CA (Done once)

Create Root Key

Attention: this is the key used to sign the certificate requests, anyone holding this can sign certificates on your behalf. So keep it in a safe place!

openssl genrsa -des3 -out rootCA.key 4096
#!/usr/bin/env ruby
require 'open-uri'
require 'pathname'
require 'json'
def strip_hash(f)
ext = f.extname
if ext.include?("?")
@tleish
tleish / mysql_backup.sh
Last active May 28, 2024 04:55
Bash Script to backup all MySQL databases
#!/bin/bash
#==============================================================================
#TITLE: mysql_backup.sh
#DESCRIPTION: script for automating the daily mysql backups on development computer
#AUTHOR: tleish
#DATE: 2013-12-20
#VERSION: 0.4
#USAGE: ./mysql_backup.sh
#CRON:
# example cron for daily db backup @ 9:15 am