Skip to content

Instantly share code, notes, and snippets.

View soltrinox's full-sized avatar
🤖
Building Cybernetic Systems

Mr. Rosario soltrinox

🤖
Building Cybernetic Systems
View GitHub Profile

Secure AI Communication

The application of this innovative technology for secure artificial intelligence communication is profound and far-reaching. Imagine a scenario where one can interact with an AI system, altering its programming directly through the AI interface, yet the AI remains incapable of compromising or altering its own core programming. This level of security is achieved by replacing traditional zero-knowledge proofs with a novel encryption method that leverages random noise and advanced quantum mechanical principles.

At the heart of this technology is the use of random noise to create a secure encryption channel between humans and machines. By utilizing perfectly random entropy sources, the system generates cryptographic keys and primes that are inherently unpredictable, even to the most advanced super quantum computers. This unpredictability stems from the fundamental limitations of physical space-time, making it computationally infeasible for any entity to crack the encryption through b

@soltrinox
soltrinox / ContentView.swift
Created March 5, 2024 05:30 — forked from otmb/ContentView.swift
WKWebView can read a wasm from a localfile with XMLHttpRequest, but returns an error with fetch
import SwiftUI
import WebKit
enum WebViewError: Error {
case contentConversion(String)
case emptyFileName
case inivalidFilePath
var message: String {
switch self {
@soltrinox
soltrinox / readfile.contents.md
Last active February 21, 2024 12:02
BASH: Read file contents
# Example using xxd to read a byte at a specific offset from a binary file
xxd -p -l1 -s 100 file.bin  # Read one byte (-l1) at offset 100 (-s) from file.bin

# Using xxd to handle hex offsets and output in decimal format
echo $((16#$(xxd -p -l1 -s $((16#FC)) file.bin)))  # Convert the output of xxd from hex to decimal

# Example using dd to dump raw data
dd if=file.bin seek=$((16#FC)) bs=1 count=5 status=none  # Dump 5 bytes from file.bin starting at hex offset FC
@soltrinox
soltrinox / nginx.google.conf
Created January 5, 2024 03:37 — forked from liweitianux/nginx.google.conf
Nginx Proxy to Google
#
# Nginx reverse proxy to Google Search (with images and webcache))
#
# Credit:
# * Nginx rewrite append a parameter at the end of an URL
# https://serverfault.com/a/311660/387898
# * https://github.com/tracycool/Reverse-Proxy-for-Google
# * https://github.com/caiguanhao/nginx-bypass-gfw/blob/master/google.conf
#
# References:
@soltrinox
soltrinox / RecordAudio.swift
Created December 24, 2023 18:51 — forked from leonid-s-usov/RecordAudio.swift
Swift Audio Recording class. Reads buffers of input samples from the microphone using the iOS RemoteIO Audio Unit API
//
// RecordAudio.swift
//
// This is a Swift class (updated for Swift 5)
// that uses the iOS RemoteIO Audio Unit
// to record audio input samples,
// (should be instantiated as a singleton object.)
//
// Created by Ronald Nicholson on 10/21/16.
// Copyright © 2017,2019 HotPaw Productions. All rights reserved.

Polynomial Ring and Ideal Lattice in JavaScript

Given the mathematical concepts of Polynomial Ring and Ideal Lattice, we can implement them in JavaScript.

Definitions:

  1. Polynomial Ring: A polynomial ring is a set of polynomials in one or more indeterminates with coefficients in another ring,
  2. often a field. The polynomial ring, $$( K[X] )$$, in ( X ) over a field ( K ) can be defined as the set of expressions,
  3. called polynomials in ( X ), of the form: $$[ p = p_m X^m + p_{m-1} X^{m-1} + ... + p_1 X + p_0 ]$$
# Make sure you have Anaconda installed
# This tutorial assumes you have an Nvidia GPU, but you can find the non-GPU version on the Textgen WebUI github
# More information found here: https://github.com/oobabooga/text-generation-webui
conda create -n textgen python=3.10.9
conda activate textgen
pip3 install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu117
git clone https://github.com/oobabooga/text-generation-webui
cd text-generation-webui
python -m pip install -r requirements.txt
# this tutorial assumes conda and git are both installed on your computer
conda create -n tg python=3.10.9
conda activate tg
pip3 install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu117
git clone https://github.com/oobabooga/text-generation-webui.git
cd text-generation-webui
pip install -r requirements.txt
# GPU only:
@soltrinox
soltrinox / verbs.activity.classifiers.csv
Created September 3, 2023 14:09
ACTIVITY CLASSIFIERS - ML
accept Indicates that that the actor has accepted the object. For instance a person accepting an award or accepting an assignment.
access Indicates that the actor has accessed the object. For instance a person accessing a room or accessing a file.
acknowledge Indicates that the actor has acknowledged the object. This effectively signals that the actor is aware of the objects existence.
add Indicates that the actor has added the object to the target. For instance adding a photo to an album.
agree Indicates that the actor agrees with the object. For example a person agreeing with an argument or expressing agreement with a particular issue.
append Indicates that the actor has appended the object to the target. For instance a person appending a new record to a database.
approve Indicates that the actor has approved the object. For instance a manager might approve a travel request.
archive Indicates that the actor has archived the object.