Skip to content

Instantly share code, notes, and snippets.

View vkryukov's full-sized avatar

Victor vkryukov

  • Sunnyvale, CA
  • 18:49 (UTC -08:00)
View GitHub Profile
@vkryukov
vkryukov / digits.py
Last active October 13, 2019 18:37
Arithmetic puzzle solver
"""
Arithmetic puzzle solver. You are given a sequence of four digits, say 1,2,3,4,
and your job is to combine them with ordinary arithmetic operations (+, -, ×, and ÷)
in any order to make a target number. E.g. 24 = 1 * 2 * 3 * 4 or 24 = (1 + 2 + 3) * 4.
Some 'hard' problems from https://blog.plover.com/math/17-puzzle.html:
1. Given 6, 6, 5, 2, get 17.
2. Given 3, 3, 8, 8, get 24.
"""
@vkryukov
vkryukov / codex_beam_bootstrap.sh
Last active September 18, 2025 08:49
Installing Elixir/Erlang on Codex
#!/usr/bin/env bash
###############################################################################
# codex_beam_bootstrap.sh ─ OTP 27 + Elixir 1.18 behind Codex MITM proxy
###############################################################################
go install github.com/asdf-vm/asdf/cmd/[email protected]
asdf plugin add erlang https://github.com/michallepicki/asdf-erlang-prebuilt-ubuntu-24.04.git || true
asdf plugin add elixir
asdf install erlang 27.3.4
asdf set -u erlang 27.3.4
@vkryukov
vkryukov / claude code - opus 4.1
Last active August 26, 2025 00:40
OpenAI.Response 0.7.0 improvement ideas using various CLI tools (Claude Code, Codex, Gemini)
Based on my analysis of your library, here are comprehensive improvement suggestions organized by priority and impact:
🎯 High Priority Improvements
1. Enhanced Error Handling & Resilience
- Add automatic retry with exponential backoff for transient failures (429, 500, 503 errors)
- Implement circuit breaker pattern to prevent cascading failures
- Add configurable timeout strategies per operation type
- Provide better error context with request details in errors
@vkryukov
vkryukov / 20251020-17-16-s0ix-output.log
Created October 20, 2025 17:44
S0ix Selftest Result
---Check S2idle path S0ix Residency---:
The system OS Kernel version is:
Linux localhost-live 6.14.0-63.fc42.x86_64 #1 SMP PREEMPT_DYNAMIC Mon Mar 24 19:53:37 UTC 2025 x86_64 GNU/Linux
---Check whether your system supports S0ix or not---:
The acpidump tool is needed to check whether low idle S0
capability is enabled on the test platform, please install acpica-tools
or check if the acpidump command execution failed.