ops/kaggle_kernel: ready-to-push submission bundle
Browse files
ops/kaggle_kernel/kernel-metadata.json
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"id": "tchbcb/qwenjev-submission",
|
| 3 |
+
"title": "qwenjev-submission",
|
| 4 |
+
"code_file": "submission.ipynb",
|
| 5 |
+
"language": "python",
|
| 6 |
+
"kernel_type": "notebook",
|
| 7 |
+
"is_private": "false",
|
| 8 |
+
"enable_gpu": "true",
|
| 9 |
+
"enable_internet": "false",
|
| 10 |
+
"dataset_sources": [],
|
| 11 |
+
"competition_sources": [
|
| 12 |
+
"arc-prize-2026-arc-agi-3"
|
| 13 |
+
],
|
| 14 |
+
"kernel_sources": []
|
| 15 |
+
}
|
ops/kaggle_kernel/submission.ipynb
ADDED
|
@@ -0,0 +1,43 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"cells": [
|
| 3 |
+
{
|
| 4 |
+
"cell_type": "markdown",
|
| 5 |
+
"metadata": {},
|
| 6 |
+
"source": "# QwenJev hybrid agent - ARC Prize 2026 (ARC-AGI-3)\n\nSystem-1: Qwen3-VL-2B + QLoRA adapters (vision tower intact, T4-trained) \nSystem-2: Qwen3.5-9B multimodal controller (frozen, selective wake-up)\n\nArtifacts (attach as Kaggle Datasets):\n * qwenjev-code -> this repo (qwenjev/ package tree)\n * qwenjev-weights -> t4_assets_v2/checkpoints/* (qwenjev_s1.pt,\n hf_lora/, stage_a_lora/) + Qwen3-VL-2B base\n * qwenjev-wheels -> t4_assets/wheels/*.whl (57 pinned wheels)\n"
|
| 7 |
+
},
|
| 8 |
+
{
|
| 9 |
+
"cell_type": "code",
|
| 10 |
+
"execution_count": null,
|
| 11 |
+
"metadata": {},
|
| 12 |
+
"outputs": [],
|
| 13 |
+
"source": "# 1. offline deps: our pinned wheels first, then the competition bundle\nimport glob, subprocess, sys\nours = sorted(glob.glob('/kaggle/input/qwenjev-wheels/*.whl'))\nif ours:\n subprocess.run([sys.executable, '-m', 'pip', 'install', '--no-index',\n '--find-links', ours[0].rsplit('/', 1)[0],\n 'transformers==5.16.1', 'peft==0.20.0',\n 'accelerate==1.14.0', 'bitsandbytes==0.50.2'],\n check=False)\ncomp = sorted(glob.glob('/kaggle/input/*/arc_agi_3_wheels/*.whl'))\nif comp:\n subprocess.run([sys.executable, '-m', 'pip', 'install', '--no-index',\n '--find-links', comp[0].rsplit('/', 1)[0], 'arc-agi'],\n check=False)\n"
|
| 14 |
+
},
|
| 15 |
+
{
|
| 16 |
+
"cell_type": "code",
|
| 17 |
+
"execution_count": null,
|
| 18 |
+
"metadata": {},
|
| 19 |
+
"outputs": [],
|
| 20 |
+
"source": "# 2. offline model paths (everything pre-attached, no internet)\nimport os\nW = '/kaggle/input/qwenjev-weights'\nos.environ['HF_HUB_OFFLINE'] = '1'\nos.environ.setdefault('QWEN3VL2B_BASE', W + '/Qwen3-VL-2B-Instruct') # base\nos.environ.setdefault('S1_CHECKPOINT', W + '/checkpoints') # qwenjev_s1.pt + hf_lora/\nos.environ.setdefault('S2_ENDPOINT', '') # in-process transformers path\n"
|
| 21 |
+
},
|
| 22 |
+
{
|
| 23 |
+
"cell_type": "code",
|
| 24 |
+
"execution_count": null,
|
| 25 |
+
"metadata": {},
|
| 26 |
+
"outputs": [],
|
| 27 |
+
"source": "# 3. build System-1 exactly as the T4 eval did (merged adapters)\nimport sys, torch\nsys.path.insert(0, '/kaggle/input/qwenjev-code') # this repo as a Dataset\nfrom qwenjev.system1 import System1, System1Config\nfrom qwenjev.hf_compat import resume_adapters\n\nckpt = os.environ['S1_CHECKPOINT']\ncfg = System1Config(backend='hf', hf_model=os.environ['QWEN3VL2B_BASE'],\n hf_quant4=False, max_leaf_tokens=512, score_levels=10,\n leaf_batch_size=8) # inference chunk\ns1 = System1(cfg) # device auto-resolved\ns1.load_heads(ckpt + '/qwenjev_s1.pt')\nresume_adapters(s1._backbone, ckpt + '/hf_lora', merge=True) # fold LoRA\n\n# 4. run the hybrid agent over the hidden games; the official\n# sample-submission driver (competition Code tab) owns the game\n# loop - plug this System-1 into QwenJevAgent as shown there.\n# from agent.qwenjev_agent import QwenJevAgent\n# AGENT = QwenJevAgent(system1=s1)\n"
|
| 28 |
+
}
|
| 29 |
+
],
|
| 30 |
+
"metadata": {
|
| 31 |
+
"kernelspec": {
|
| 32 |
+
"display_name": "Python 3",
|
| 33 |
+
"language": "python",
|
| 34 |
+
"name": "python3"
|
| 35 |
+
},
|
| 36 |
+
"language_info": {
|
| 37 |
+
"name": "python",
|
| 38 |
+
"version": "3.12"
|
| 39 |
+
}
|
| 40 |
+
},
|
| 41 |
+
"nbformat": 4,
|
| 42 |
+
"nbformat_minor": 5
|
| 43 |
+
}
|