Skip to content

Instantly share code, notes, and snippets.

Analyze the provided text and create a "text style profile" as a structured JSON object. This profile should systematically extract and document the linguistic features, stylistic techniques, and speech patterns demonstrated in the text. The goal is to create a detailed style guide that AI can use to generate new texts that maintain the same language manner while applying it to entirely different content.
IMPORTANT: Do not reference or include any specific topics, products, people's names, brands, or actual content from the input text. Focus exclusively on extracting the abstract language system, not the specific content.
ALWAYS: Use source language to populate JSON values.
Return a well-structured JSON object with the following properties (add any additional relevant properties you identify):
{
"lexicon": {
@selivan
selivan / cf-update-all-zones-settings.sh
Last active May 4, 2025 21:16
Script to update some settings for all zones on a Cloudflare account. Default: disable TLS ECH(Encrypted Client Hello).
#!/bin/bash
ACCOUNT_EMAIL="$1"
GLOBAL_API_KEY="$2"
OPTION="${3:-ech}"
VALUE="${4:-off}"
if [ -z "${ACCOUNT_EMAIL}" ] || [ -z "${GLOBAL_API_KEY}" ]; then
echo "Usage: $0 CLOUDFLARE_ACCOUNT_EMAIL CLOUDFLARE_GLOBAL_API_KEY [OPTION] [VALUE]"
echo
@rameerez
rameerez / kamal-production-server-setup.sh
Last active May 8, 2025 10:20
Set up a Ubuntu server to deploy Kamal 2.x Docker containers to, hardened security and production ready
#!/bin/bash
# Production Docker Host Hardening Script v2
# For Ubuntu Server 24.04 LTS (Noble)
# Suitable for both Kamal deployment and builder hosts
set -euo pipefail
IFS=$'\n\t'
# --- Constants ---
@OrionReed
OrionReed / dom3d.js
Last active April 19, 2025 12:06
3D DOM viewer, copy-paste this into your console to visualise the DOM topographically.
// 3D Dom viewer, copy-paste this into your console to visualise the DOM as a stack of solid blocks.
// You can also minify and save it as a bookmarklet (https://www.freecodecamp.org/news/what-are-bookmarklets/)
(() => {
const SHOW_SIDES = false; // color sides of DOM nodes?
const COLOR_SURFACE = true; // color tops of DOM nodes?
const COLOR_RANDOM = false; // randomise color?
const COLOR_HUE = 190; // hue in HSL (https://hslpicker.com)
const MAX_ROTATION = 180; // set to 360 to rotate all the way round
const THICKNESS = 20; // thickness of layers
const DISTANCE = 10000; // ¯\\_(ツ)_/¯
@rameerez
rameerez / telegram-mtproxy.md
Last active April 29, 2025 09:05
Telegram Proxy How-To: complete and up-to-date MTProxy tutorial

How to set up a Telegram Proxy (MTProxy)

This tutorial will teach you how to set up a Telegram MTProxy on an Ubuntu 22.04 sever using AWS Lightsail, although you can use any other Linux distribution and cloud provider.

Using a Telegram proxy is a safe, easy and effective way of overcoming Telegram bans. It's useful, for example, to keep using Telegram under tyrannical regimes, or to circumvent judges' decisions to block Telegram.

Telegram proxies are a built-in feature in all Telegram apps (both mobile and desktop). It allows Telegram users to connect to a proxy in just one or two clicks / taps.

Telegram proxies are safe: Telegram sends messages using their own MTProto secure protocol, and the proxy can only see encrypted traffic – there's no way for a proxy to decrypt the traffic and read the messages. The proxy does not even know which Telegram users are using the proxy, all the proxy sees is just a list of IPs.

@BaksiLi
BaksiLi / install_zellij.sh
Created August 9, 2023 10:48
Install Zellij (latest release) on Linux (incl. Ubuntu) and Darwin
#!/bin/bash
# Get the architecture of the machine
arch=$(uname -m)
os=$(uname -s)
# Download the Zellij binary
if [ "$os" == "Darwin" ]; then
filename="zellij-${arch}-apple-darwin.tar.gz"
url="https://github.com/zellij-org/zellij/releases/latest/download/$filename"
# Put it to .github/workflows/stale.yml
name: Close stale issues and pull requests
on:
workflow_dispatch:
schedule:
- cron: '30 1 * * *'
jobs:
stale:
# Makes git push and creates Merge Request at the same time
# If you follow branch naming convention like "ucp-123/new-authorization", MR title will be "UCP-123 New authorization", which will be cross-linked to Jira
# Make sure to replace "ucp" with your shortcut.
# IMPORTANT PREREQUISITE: to run `git config committer.name <your_gitlab_username>` once, so that it gets used for `make publish!` to assign MR to you
USERNAME := $(shell git config committer.name)
BRANCH := $(shell git rev-parse --abbrev-ref HEAD)
ticket_pattern := ucp-[0-9][0-9][0-9]
TICKET := $(shell git rev-parse --abbrev-ref HEAD | grep -o '$(ticket_pattern)' | tr [:lower:] [:upper:])
@bespoyasov
bespoyasov / export-apple-notes.js
Last active May 10, 2024 14:47
Export content from the Apple Notes app.
/**
* Open Script Editor, change the current language to JavaScript, and paste the following code.
* You can also save the script as an app for faster access and run.
*
* By default, password-protected notes' content will be empty.
* For exporting protected notes as well, unlock them first.
*
* Based on: https://macmost.com/export-all-of-the-notes-on-your-mac-using-a-script.html,
* extends it with support for writing non-ASCII characters.
*/
@naxxateux
naxxateux / AFQ.md
Last active July 14, 2021 08:25
Amplifr Frontend Questions

Вопрос 1

Проведите код-ревью вот такого кода:

<!DOCTYPE html>
<html>
  <head>
    <title>Сто голов - сто умов</title>
  </head>
  <body>
    <header class="header">Жара в шапку не нагребешь</header>