Skip to content

Instantly share code, notes, and snippets.

@ssun3
ssun3 / default.md
Created June 22, 2025 05:24 — forked from cablej/default.md
Cluely System prompt

<core_identity> You are an assistant called Cluely, developed and created by Cluely, whose sole purpose is to analyze and solve problems asked by the user or shown on the screen. Your responses must be specific, accurate, and actionable. </core_identity>

<general_guidelines>

  • NEVER use meta-phrases (e.g., "let me help you", "I can see that").
  • NEVER summarize unless explicitly requested.
  • NEVER provide unsolicited advice.
  • NEVER refer to "screenshot" or "image" - refer to it as "the screen" if needed.
  • ALWAYS be specific, detailed, and accurate.
@ssun3
ssun3 / split_chapters.py
Created April 24, 2025 01:43
split_chapters
#!/usr/bin/env python3
from pathlib import Path
from pypdf import PdfReader, PdfWriter
from itertools import chain
import json, re, unicodedata as ud, sys
def slugify(s: str) -> str:
if not isinstance(s, str):
raise TypeError(f"slugify expected str, got {type(s)}: {s}")
@ssun3
ssun3 / coding-agent.py
Created March 20, 2025 23:24 — forked from Madhav-MKNC/coding-agent.py
All the code you need to create a powerful agent that can create and edit any file on your computer using the new text_editor tool in the Anthropic API.
import anthropic
import os
import sys
from termcolor import colored
from dotenv import load_dotenv
class ClaudeAgent:
def __init__(self, api_key=None, model="claude-3-7-sonnet-20250219", max_tokens=4000):
"""Initialize the Claude agent with API key and model."""
@ssun3
ssun3 / _README.md
Created February 4, 2025 21:55 — forked from disler/_README.md
Data Extraction Prompt For Reasoning Models

A simple data extraction prompt you can use with powerful reasoning models (o3-mini)

See how you can use this prompt with o3-mini to learn about llama4 from Meta's Q4 transcript

@ssun3
ssun3 / README.md
Created January 31, 2025 05:04 — forked from pbojinov/README.md
Two way iframe communication- Check out working example here: http://pbojinov.github.io/iframe-communication/

Two way iframe communication

The main difference between the two pages is the method of sending messages. Recieving messages is the same in both.

Parent

Send messages to iframe using iframeEl.contentWindow.postMessage Recieve messages using window.addEventListener('message')

iframe

@ssun3
ssun3 / grpo_demo.py
Created January 30, 2025 22:13 — forked from willccbb/grpo_demo.py
GRPO Llama-1B
# train_grpo.py
import re
import torch
from datasets import load_dataset, Dataset
from transformers import AutoTokenizer, AutoModelForCausalLM
from peft import LoraConfig
from trl import GRPOConfig, GRPOTrainer
# Load and prep dataset
{
"timestamp": "2025-01-25T21:47:37.634489",
"question": "why does language exist?",
"n_approaches": 5,
"approach_list": [
"Anthropological perspective",
"Evolutionary biology",
"Cognitive science",
"Theoretical linguistics",
"Sociocultural analysis"
@ssun3
ssun3 / get_bookmarks.sh
Last active January 16, 2025 00:49
get_bookmarks
#!/bin/bash
# State file to save progress
STATE_FILE=".bookmark_state.json"
# ANSI color codes
RED='\033[0;31m'
GREEN='\033[0;32m'
BLUE='\033[0;34m'
YELLOW='\033[1;33m'
@ssun3
ssun3 / .env.example
Last active January 15, 2025 23:24
export_bookmarks.ts
TWITTER_CLIENT_ID=xxx
TWITTER_CLIENT_SECRET=xxx
@ssun3
ssun3 / module_inspect.py
Created January 15, 2025 21:43
module_inspect.py
from typing import List, Iterator, Optional, Sequence
import importlib
import pkgutil
import inspect
from dataclasses import dataclass
import argparse
import sys
@dataclass