chatgpt.com
o1
20241217
use meta prompt
https://platform.openai.com/docs/guides/prompt-generation/meta-prompts#meta-prompts
chatgpt.com
o1
20241217
use meta prompt
https://platform.openai.com/docs/guides/prompt-generation/meta-prompts#meta-prompts
(function() { | |
var css = ` | |
body { | |
background: white; | |
} | |
html { | |
filter: invert(100%) hue-rotate(180deg); | |
} | |
img { | |
filter: invert(100%) hue-rotate(180deg); |
/// x.com.js | |
function twitter_demetricator() { | |
// inspired by | |
// https://chrome.google.com/webstore/detail/abcocamcgfjfdcpfopgpadihhbjbdcem | |
console.log("starting twitter demetricator ..."); | |
const spans = document.querySelectorAll('span[data-testid="app-text-transition-container"]'); | |
spans.forEach(span => { | |
const firstChildSpan = span.querySelector('span'); | |
if (firstChildSpan) { | |
const grandsonSpan = firstChildSpan.querySelector('span'); |
# some alternatives to get date or datetime | |
# in order to get epoch seconds of the beginning of the choosen date | |
# -------------------------------------------------------------------------------- | |
# alternative 1 | |
# -------------------------------------------------------------------------------- | |
from datetime import datetime | |
from zoneinfo import ZoneInfo | |
datetime.now(tz=ZoneInfo('localtime')) | |
# requires an extra std package `zoneinfo` |
import urllib.request | |
import json | |
def get_public_ip(url): | |
try: | |
req = urllib.request.Request( | |
url, | |
headers={'User-Agent': 'curl/7.74.0'} | |
) | |
with urllib.request.urlopen(req) as response: |
#!/bin/bash | |
# Replace with the actual directory path to search in | |
search_dir=$(git rev-parse --show-toplevel 2>/dev/null || git rev-parse --git-dir 2>/dev/null | sed 's/\.git$//') | |
# Replace with your list of strings | |
search_strings=("< pattern 1 >" "< pattern 2 >" "< pattern 3 >") | |
# Create a pattern by joining the search strings with a pipe (|) as the separator | |
pattern=$(printf "%s\\|" "${search_strings[@]}") |
start=$(date +%s%N) | |
# any command | |
end=$(date +%s%N) | |
elapsed_nanosec=$((end - start)) | |
formatted_elapsed_nanosec=$(printf "%'d" "$elapsed_nanosec" | sed 's/,/_/g') | |
echo "Elapsed time: $formatted_elapsed_nanosec nanoseconds" |
{ | |
test1: repository(owner: "robfig", name: "cron") { | |
...RepoFragment | |
} | |
} | |
fragment RepoFragment on Repository { | |
name | |
defaultBranchRef { |
# -------------------------------------------------------------------------------- | |
# option 1: using numpy.array(< list >, dtype=object).flat) | |
# -------------------------------------------------------------------------------- | |
import tracemalloc | |
import functools | |
import operator | |
import itertools | |
import numpy |
{ | |
"backmatter": "", | |
"bulletListMarker": "-", | |
"codeBlockStyle": "fenced", | |
"contextMenus": true, | |
"disallowedChars": "[]#^", | |
"downloadImages": false, | |
"downloadMode": "downloadsApi", | |
"emDelimiter": "_", | |
"fence": "```", |