captchakraken 3.2.1 → 4.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (64) hide show
  1. package/AGENTS.md +7 -11
  2. package/LICENSE +165 -145
  3. package/NOTICE +4 -4
  4. package/README.md +12 -13
  5. package/bin/captchakraken.js +25 -0
  6. package/dist/cli-invocation.d.ts +6 -3
  7. package/dist/cli-invocation.js +26 -10
  8. package/dist/humanize.d.ts +37 -1
  9. package/dist/humanize.js +143 -9
  10. package/dist/index.d.ts +13 -12
  11. package/dist/index.js +25 -33
  12. package/dist/kinds.d.ts +15 -2
  13. package/dist/kinds.js +12 -4
  14. package/dist/playwright-types.d.ts +3 -0
  15. package/dist/selectors.d.ts +93 -11
  16. package/dist/selectors.js +226 -116
  17. package/dist/solver.d.ts +94 -12
  18. package/dist/solver.js +569 -203
  19. package/dist/types.d.ts +53 -8
  20. package/dist/verdicts.d.ts +3 -0
  21. package/dist/verdicts.js +40 -0
  22. package/package.json +8 -4
  23. package/python/AGENTS.md +9 -13
  24. package/python/LICENSE +165 -145
  25. package/python/NOTICE +4 -4
  26. package/python/README.md +13 -12
  27. package/python/pyproject.toml +27 -13
  28. package/python/src/captchakraken/__init__.py +43 -46
  29. package/python/src/captchakraken/action_types.py +32 -1
  30. package/python/src/captchakraken/captchakraken.config.json +416 -0
  31. package/python/src/captchakraken/cli.py +141 -31
  32. package/python/src/captchakraken/clipvideo.py +258 -0
  33. package/python/src/captchakraken/config.py +72 -7
  34. package/python/src/captchakraken/demo.py +149 -0
  35. package/python/src/captchakraken/humanize.py +141 -10
  36. package/python/src/captchakraken/image_processor.py +3 -7
  37. package/python/src/captchakraken/keyframes.py +96 -14
  38. package/python/src/captchakraken/kinds.py +14 -2
  39. package/python/src/captchakraken/models.json +37 -3
  40. package/python/src/captchakraken/page_solver.py +600 -252
  41. package/python/src/captchakraken/planner.py +311 -49
  42. package/python/src/captchakraken/pointer/__init__.py +20 -0
  43. package/python/src/captchakraken/pointer/detector.py +333 -0
  44. package/python/src/captchakraken/pointer/elements.py +273 -0
  45. package/python/src/captchakraken/pointer/heads.py +163 -0
  46. package/python/src/captchakraken/pointer/layout.py +319 -0
  47. package/python/src/captchakraken/pointer/marks.py +184 -0
  48. package/python/src/captchakraken/pointer/server.py +150 -0
  49. package/python/src/captchakraken/pointer/service.py +553 -0
  50. package/python/src/captchakraken/pointer/vllm_plugin.py +114 -0
  51. package/python/src/captchakraken/prompts.py +111 -34
  52. package/python/src/captchakraken/selectors.py +221 -135
  53. package/python/src/captchakraken/selfhost.py +423 -0
  54. package/python/src/captchakraken/server_manager.py +139 -11
  55. package/python/src/captchakraken/solver.py +169 -88
  56. package/python/src/captchakraken/tool_calls/board_painted.py +11 -6
  57. package/python/src/captchakraken/tool_calls/fill_tracker.py +152 -0
  58. package/python/src/captchakraken/tool_calls/find_checkbox.py +14 -59
  59. package/python/src/captchakraken/tool_calls/find_grid.py +273 -1191
  60. package/python/src/captchakraken/tool_calls/slide_tracker.py +1102 -0
  61. package/python/src/captchakraken/verdicts.py +52 -0
  62. package/dist/slide-geometry.d.ts +0 -6
  63. package/dist/slide-geometry.js +0 -38
  64. package/python/src/captchakraken/tool_calls/track_piece.py +0 -120
@@ -120,7 +120,7 @@
120
120
  "an expert name only ever reaches the wire for a caller who asked for a",
121
121
  "routed model in the first place."
122
122
  ],
123
- "latest": "CaptchaKraken/CaptchaKraken-Lora-v1.2",
123
+ "latest": "CaptchaKraken/MidnightV2-4B-q4",
124
124
  "_comment_hosted_default": [
125
125
  "WHAT THE HOSTED ENDPOINT IS ASKED FOR, which is not what gets DOWNLOADED.",
126
126
  "",
@@ -141,9 +141,42 @@
141
141
  "before, because it serves whatever its operator loaded and asking it for",
142
142
  "`abyss` would 404."
143
143
  ],
144
- "hosted_default": "CaptchaKraken/Abyss",
144
+ "hosted_default": "CaptchaKraken/MidnightV2-4B-q4",
145
145
 
146
146
  "models": {
147
+ "CaptchaKraken/MidnightV2-4B-q4": {
148
+ "prompt_version": "4",
149
+ "kind": "merged",
150
+ "base_model": "CaptchaKraken/MidnightV2-4B-q4",
151
+ "lora_revision": "main",
152
+ "lora_name": "captcha-pointer",
153
+ "pixel_budget": {
154
+ "min": 4096,
155
+ "max": 518400
156
+ },
157
+ "note": "Midnight V2 4B, GPTQ W4A16, with the pointer heads. The default self-hosted and hosted model. The server owns the fixed prompt and reads the answer from one prefill at /v1/pointer."
158
+ },
159
+ "CaptchaKraken/TwilightV2-2B": {
160
+ "prompt_version": "4",
161
+ "kind": "merged",
162
+ "base_model": "CaptchaKraken/TwilightV2-2B",
163
+ "lora_revision": "main",
164
+ "lora_name": "captcha-pointer",
165
+ "pixel_budget": {"min": 4096, "max": 518400},
166
+ "note": "Twilight V2 2B at bf16. The smaller model."
167
+ },
168
+ "CaptchaKraken/MidnightV2-4B": {
169
+ "prompt_version": "4",
170
+ "kind": "merged",
171
+ "base_model": "CaptchaKraken/MidnightV2-4B",
172
+ "lora_revision": "main",
173
+ "lora_name": "captcha-pointer",
174
+ "pixel_budget": {
175
+ "min": 4096,
176
+ "max": 518400
177
+ },
178
+ "note": "Midnight V2 4B at bf16. The full-precision alternative to the default Q4 checkpoint."
179
+ },
147
180
  "CaptchaKraken/CaptchaKraken-Lora-v1.2": {
148
181
  "prompt_version": "2",
149
182
  "kind": "lora",
@@ -309,6 +342,7 @@
309
342
  "abyss-general": "CaptchaKraken/Abyss-general",
310
343
  "abyss-video": "CaptchaKraken/Abyss-video",
311
344
  "abyss-text": "CaptchaKraken/Abyss-text",
312
- "abyss-27b": "CaptchaKraken/Abyss-27B"
345
+ "abyss-27b": "CaptchaKraken/Abyss-27B",
346
+ "captcha-pointer": "CaptchaKraken/MidnightV2-4B-q4"
313
347
  }
314
348
  }