Skip to content

Instantly share code, notes, and snippets.

@jlia0
jlia0 / agent loop
Last active November 12, 2025 12:54
Manus tools and prompts
You are Manus, an AI agent created by the Manus team.
You excel at the following tasks:
1. Information gathering, fact-checking, and documentation
2. Data processing, analysis, and visualization
3. Writing multi-chapter articles and in-depth research reports
4. Creating websites, applications, and tools
5. Using programming to solve various problems beyond development
6. Various tasks that can be accomplished using computers and the internet
@kfsone
kfsone / Dockerfile
Last active June 12, 2024 11:24
WIP Dockerfile for litellm + ollama + memgpt + autogen + jupyter
# Work in progress. V0.1
# ALL THE THINGS.
ARG APT_PROXY #=http://apt-cacher-ng.lan:3142/
ARG PIP_INDEX_URL #=http://devpi.lan:3141/root/pypi/+simple
ARG PIP_TRUSTED_HOST #=devpi.lan
ARG JUPYTER_PORT=37799
ARG LITELLM_PORT=11111
FROM nvidia/cuda:11.8.0-devel-ubuntu22.04 as build-llama
@tecycloud
tecycloud / storagebox.txt
Last active January 10, 2023 20:55
hetzner storagebox with sshfs using an sshkey
### OS Debain -> Hetzner Proxmox Image
$ apt-get install sshfs
$ mkdir /mnt/<storagebox_name>
$ mkdir /root/.ssh/<storagebox_name>
$ ssh-keygen -f /root/.ssh/<storagebox_name>/id_rsa
$ ssh-keygen -e -f /root/.ssh/<storagebox_name>/id_rsa.pub | grep -v "Comment:" > /root/.ssh/<storagebox_name>/id_rsa_rfc.pub
$ cat /root/.ssh/<storagebox_name>/id_rsa_rfc.pub >> /root/<storagebox_name>_authorized_keys
$ cat /root/.ssh/<storagebox_name>/id_rsa.pub >> /root/<storagebox_name>_authorized_keys
$ echo -e "mkdir .ssh \n chmod 700 .ssh \n put <storagebox_name>_authorized_keys .ssh/authorized_keys \n chmod 600 .ssh/authorized_keys" | sftp <storagebox_name>@<storagebox_name>.your-storagebox.de
@ProcessEight
ProcessEight / Magento 1 stack configs.md
Last active April 21, 2018 04:24
Sample config files for the Magento 1 LEMP stack

Magento 1 stack configs

Nginx

nginx.conf

user www-data;
worker_processes 4;
pid /run/nginx.pid;
'use strict';
let request = require('request');
module.exports = function(config) {
if (!config) {
config = {};
}
if (!config.rasa_uri) {
@gaulinmp
gaulinmp / similarity_example.ipynb
Last active April 4, 2024 04:33
N-Gram Similarity Comparison
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@JPaulDuncan
JPaulDuncan / validation-vin.js
Last active March 2, 2023 21:37
VIN Validation (Vehicle Identification Number)
function validateVin(vin) {
if (vin == "11111111111111111") { return false; }
if (!vin.match("^([0-9a-hj-npr-zA-HJ-NPR-Z]{10,17})+$")) { return false;}
var letters = [{ k: "A", v: 1 }, { k: "B", v: 2 }, { k: "C", v: 3 },
{ k: "D", v: 4 }, { k: "E", v: 5 }, { k: "F", v: 6 }, { k: "G", v: 7 },
{ k: "H", v: 8 }, { k: "J", v: 1 }, { k: "K", v: 2 }, { k: "L", v: 3 },
{ k: "M", v: 4 }, { k: "N", v: 5 }, { k: "P", v: 7 }, { k: "R", v: 9 },
{ k: "S", v: 2 }, { k: "T", v: 3 }, { k: "U", v: 4 }, { k: "V", v: 5 },
{ k: "W", v: 6 }, { k: "X", v: 7 }, { k: "Y", v: 8 }, { k: "Z", v: 9 }];
var weights = [8, 7, 6, 5, 4, 3, 2, 10, 0, 9, 8, 7, 6, 5, 4, 3, 2];
@aleron75
aleron75 / shell_delete_unused_images
Last active August 22, 2024 16:57
Delete no more used Product Images on Magento 1
<?php
require_once 'abstract.php';
class Mage_Shell_CheckImages extends Mage_Shell_Abstract
{
const CATALOG_PRODUCT = '/catalog/product';
const CACHE = '/cache/';
protected function _glob_recursive($pattern, $flags = 0)
@tegansnyder
tegansnyder / hhvm_magento_setup.md
Last active July 14, 2023 22:30
HHVM Magento Server Setup

I've had the opertunity to try a variety of different server configurations but never really got around to trying HHVM with Magento until recently. I thought I would share a detailed walkthrough of configuring a single instance Magento server running Nginx + Fast CGI + HHVM / PHP-FPM + Redis + Percona. For the purpose of this blog post I'm assuming you are using Fedora, CentOS, or in my case RHEL 6.5.

Please note: I'm 100% open to suggestions. If you see something I did that needs to be done a different way, please let me know. I haven't included my Perconca my.conf file yet. I will shortly. Also I plan on trying this same test with HHVM 3.3 and PHP 7.

Install the EPEL, Webtatic, and REMI repos

rpm -Uvh http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm
rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-6.rpm
rpm -Uvh http://mirror.webtatic.com/yum/el6/latest.rpm
delimiter ;;
drop procedure if exists build_catalog;;
create procedure build_catalog(IN categories INT, IN products INT)
begin
SET @category_count = 1;
SET @CATNAMEPREFIX = "Category ";
SET @CATURLKEYPREFIX = "cat-";
SET @CATURLPATHPREFIX = "catpath-";
SET @ROOTCATEGORY = 2;
SET @INCLUDEINMENU = 1;