Skip to content

Instantly share code, notes, and snippets.

View PriNova's full-sized avatar

PriNova | Tino Wening PriNova

View GitHub Profile
@PriNova
PriNova / README.md
Created June 19, 2026 18:30
Codex banked reset status + manual consume helper

codex-consume-reset

Public helper script for OpenAI Codex banked manual reset credits.

Features:

  • Read-only status: --status
  • Full GET response dump: --show-responses
  • Manual consume flow with confirmation
  • Supports Pi auth file default: ~/.pi/agent/auth.json
import type { ExtensionAPI } from "@mariozechner/pi-coding-agent";
const SENTINEL = "BEGIN_OPENAI_GPT_PROMPT_GUIDANCE";
// Source: https://developers.openai.com/api/docs/guides/prompt-guidance
// (Prompt guidance for GPT-5.4; extracted + lightly adapted for a coding/terminal agent harness.)
const OPENAI_GPT_PROMPT_GUIDANCE = String.raw`
${SENTINEL}
[OpenAI GPT prompt guidance — coding/agent harness]
@PriNova
PriNova / android-env-safe.sh
Created March 29, 2026 20:32
Rollback-safe Android build environment installer for Termux on Android
#!/data/data/com.termux/files/usr/bin/bash
set -Eeuo pipefail
SCRIPT_NAME="android-env-safe"
SCRIPT_VERSION="1.0.1"
PREFIX="${PREFIX:-/data/data/com.termux/files/usr}"
HOME_DIR="$HOME"
SHELL_RC="$HOME_DIR/.bashrc"
GRADLE_DIR="$HOME_DIR/.gradle"
GRADLE_PROPERTIES="$GRADLE_DIR/gradle.properties"
@PriNova
PriNova / pi-tool-call-filter.md
Created February 3, 2026 10:41
pi tool call filter
/**
 * Tool Call Filter Extension
 *
 * Filters out invalid tool calls before they're sent back to the provider.
 * This addresses issues where some models construct malformed tool call blocks.
 *
 * Install: Place in ~/.pi/extensions/tool-call-filter.ts or project .pi/extensions/
 */
@PriNova
PriNova / bypass_drag_n_drop_vscode.md
Created January 21, 2026 18:40
Add image via Drag and Drop into VS Code bypassing limitations

Drag & Drop Images from Outside VS Code (No SHIFT Required)

This pattern bypasses the VS Code webview’s default drag handling by:

  • Capturing drag events at the window level
  • Calling preventDefault() (and often stopImmediatePropagation())
  • Showing a container-specific overlay
  • Reading files from dataTransfer.items / dataTransfer.files

@PriNova
PriNova / perf_analysis.md
Created June 26, 2025 07:01
Performance Analysis

How to Perform Critical Performance Analysis Using Sub-Agents

Overview

This workflow provides comprehensive performance analysis for code changes with the rigor expected in game engines, graphics engines, and critical systems where speed, space efficiency, reliability, and robustness are paramount. The approach systematically evaluates algorithmic complexity, data structures, memory patterns, and system-level optimizations through specialized sub-agents with deep performance expertise.

Complete Critical Performance Analysis Workflow Prompt

I need to perform critical performance analysis for [CODE CHANGE DESCRIPTION] in [REPOSITORY/BRANCH]. This analysis must meet the standards of game engines, graphics engines, and critical systems where performance is paramount. Follow this comprehensive performance analysis workflow with nested sub-agent delegation:

How to Perform Thorough Code Reviews Using Sub-Agents

Overview

This workflow provides comprehensive code review coverage by deploying specialized sub-agents across multiple review domains. The approach ensures systematic evaluation of security, performance, architecture, testing, and functionality through parallel domain analysis and structured integration.

Complete Code Review Workflow Prompt

I need to perform a thorough code review for [CODE CHANGE DESCRIPTION] in [REPOSITORY/BRANCH]. Follow this comprehensive code review workflow with specialized sub-agent delegation:
@PriNova
PriNova / bug_fix.md
Last active June 26, 2025 07:05
Bug fixing Amp

How to Fix Bugs in Unfamiliar Codebases Using Sub-Agents

Overview

This adaptive workflow systematically diagnoses and fixes bugs in unknown codebases by using strategic sub-agent delegation and evidence-based investigation strategies.

Complete Bug Fixing Workflow Prompt

I need to fix [BUG DESCRIPTION] in this unfamiliar codebase. Follow this adaptive bug fixing workflow with strategic sub-agent delegation:
@PriNova
PriNova / feature_impl.md
Last active June 26, 2025 07:06
Amp feature implementation prompt.

How to Implement Features in Unfamiliar Codebases Using Sub-Agents

Overview

This workflow maximizes efficiency and reliability when implementing new features in unknown codebases by using strategic sub-agent delegation and systematic discovery phases.

Complete Workflow Prompt

I need to implement [FEATURE DESCRIPTION] in this unfamiliar codebase. Follow this optimized workflow with strategic sub-agent delegation:
@PriNova
PriNova / proxy.py
Created December 17, 2024 10:54
A simple proxy server
import http.server
import socketserver
import logging
import requests
import json
from urllib.parse import urlparse
PORT = 8000
class ProxyHandler(http.server.SimpleHTTPRequestHandler):