pwn 0.5.618 → 0.5.620

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 (82) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +2 -2
  3. data/README.md +14 -6
  4. data/bin/pwn_gqrx_scanner +25 -5
  5. data/documentation/Agent-Tool-Registry.md +3 -3
  6. data/documentation/Diagrams.md +6 -2
  7. data/documentation/Extrospection.md +30 -11
  8. data/documentation/Home.md +5 -4
  9. data/documentation/How-PWN-Works.md +7 -4
  10. data/documentation/Mistakes.md +96 -0
  11. data/documentation/Persistence.md +3 -1
  12. data/documentation/SDR.md +23 -5
  13. data/documentation/Skills-Memory-Learning.md +15 -5
  14. data/documentation/diagrams/agent-tool-registry.svg +94 -92
  15. data/documentation/diagrams/dot/agent-tool-registry.dot +2 -2
  16. data/documentation/diagrams/dot/extrospection-world-awareness.dot +9 -7
  17. data/documentation/diagrams/dot/memory-skills-detailed.dot +12 -5
  18. data/documentation/diagrams/dot/mistakes-negative-feedback.dot +93 -0
  19. data/documentation/diagrams/dot/overall-pwn-architecture.dot +7 -5
  20. data/documentation/diagrams/dot/persistence-filesystem.dot +3 -2
  21. data/documentation/diagrams/dot/pwn-ai-feedback-learning-loop.dot +19 -7
  22. data/documentation/diagrams/dot/sdr-radio-flow.dot +13 -11
  23. data/documentation/diagrams/extrospection-world-awareness.svg +111 -93
  24. data/documentation/diagrams/memory-skills-detailed.svg +146 -97
  25. data/documentation/diagrams/mistakes-negative-feedback.svg +266 -0
  26. data/documentation/diagrams/overall-pwn-architecture.svg +184 -173
  27. data/documentation/diagrams/persistence-filesystem.svg +77 -62
  28. data/documentation/diagrams/pwn-ai-feedback-learning-loop.svg +217 -149
  29. data/documentation/diagrams/sdr-radio-flow.svg +76 -56
  30. data/documentation/pwn-ai-Agent.md +28 -15
  31. data/lib/pwn/ai/agent/extrospection.rb +65 -6
  32. data/lib/pwn/ai/agent/learning.rb +67 -7
  33. data/lib/pwn/ai/agent/loop.rb +72 -6
  34. data/lib/pwn/ai/agent/mistakes.rb +369 -0
  35. data/lib/pwn/ai/agent/prompt_builder.rb +10 -1
  36. data/lib/pwn/ai/agent/tools/extrospection.rb +2 -2
  37. data/lib/pwn/ai/agent/tools/mistakes.rb +132 -0
  38. data/lib/pwn/ai/agent.rb +1 -0
  39. data/lib/pwn/plugins/jira_data_center.rb +2 -2
  40. data/lib/pwn/sdr/decoder/adsb.rb +101 -0
  41. data/lib/pwn/sdr/decoder/apt.rb +75 -0
  42. data/lib/pwn/sdr/decoder/bluetooth.rb +78 -0
  43. data/lib/pwn/sdr/decoder/dect.rb +84 -0
  44. data/lib/pwn/sdr/decoder/gps.rb +83 -0
  45. data/lib/pwn/sdr/decoder/gsm.rb +50 -29
  46. data/lib/pwn/sdr/decoder/iridium.rb +81 -0
  47. data/lib/pwn/sdr/decoder/lora.rb +87 -0
  48. data/lib/pwn/sdr/decoder/lte.rb +88 -0
  49. data/lib/pwn/sdr/decoder/morse.rb +64 -0
  50. data/lib/pwn/sdr/decoder/p25.rb +71 -0
  51. data/lib/pwn/sdr/decoder/pager.rb +77 -0
  52. data/lib/pwn/sdr/decoder/pocsag.rb +26 -11
  53. data/lib/pwn/sdr/decoder/rfid.rb +88 -0
  54. data/lib/pwn/sdr/decoder/rtl433.rb +95 -0
  55. data/lib/pwn/sdr/decoder/rtty.rb +66 -0
  56. data/lib/pwn/sdr/decoder/wifi.rb +98 -0
  57. data/lib/pwn/sdr/decoder/zigbee.rb +96 -0
  58. data/lib/pwn/sdr/decoder.rb +67 -7
  59. data/lib/pwn/sdr/frequency_allocation.rb +82 -41
  60. data/lib/pwn/sdr/gqrx.rb +186 -95
  61. data/lib/pwn/version.rb +1 -1
  62. data/spec/lib/pwn/ai/agent/mistakes_spec.rb +36 -0
  63. data/spec/lib/pwn/ai/agent/tools/mistakes_spec.rb +12 -0
  64. data/spec/lib/pwn/sdr/decoder/adsb_spec.rb +15 -0
  65. data/spec/lib/pwn/sdr/decoder/apt_spec.rb +15 -0
  66. data/spec/lib/pwn/sdr/decoder/bluetooth_spec.rb +15 -0
  67. data/spec/lib/pwn/sdr/decoder/dect_spec.rb +15 -0
  68. data/spec/lib/pwn/sdr/decoder/gps_spec.rb +15 -0
  69. data/spec/lib/pwn/sdr/decoder/iridium_spec.rb +15 -0
  70. data/spec/lib/pwn/sdr/decoder/lora_spec.rb +15 -0
  71. data/spec/lib/pwn/sdr/decoder/lte_spec.rb +15 -0
  72. data/spec/lib/pwn/sdr/decoder/morse_spec.rb +15 -0
  73. data/spec/lib/pwn/sdr/decoder/p25_spec.rb +15 -0
  74. data/spec/lib/pwn/sdr/decoder/pager_spec.rb +15 -0
  75. data/spec/lib/pwn/sdr/decoder/rfid_spec.rb +15 -0
  76. data/spec/lib/pwn/sdr/decoder/rtl433_spec.rb +15 -0
  77. data/spec/lib/pwn/sdr/decoder/rtty_spec.rb +15 -0
  78. data/spec/lib/pwn/sdr/decoder/wifi_spec.rb +15 -0
  79. data/spec/lib/pwn/sdr/decoder/zigbee_spec.rb +15 -0
  80. data/third_party/pwn_rdoc.jsonl +92 -3
  81. metadata +44 -6
  82. data/README.md.bak +0 -200
@@ -0,0 +1,266 @@
1
+ <?xml version="1.0" encoding="UTF-8" standalone="no"?>
2
+ <!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
3
+ "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
4
+ <!-- Generated by graphviz version 14.1.2 (0)
5
+ -->
6
+ <!-- Title: PWN_Mistakes_Negative_Feedback Pages: 1 -->
7
+ <svg width="959pt" height="895pt"
8
+ viewBox="0.00 0.00 959.00 895.00" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
9
+ <g id="graph0" class="graph" transform="scale(1 1) rotate(0) translate(43.2 852.14)">
10
+ <title>PWN_Mistakes_Negative_Feedback</title>
11
+ <polygon fill="#0f172a" stroke="none" points="-43.2,43.2 -43.2,-852.14 916.2,-852.14 916.2,43.2 -43.2,43.2"/>
12
+ <text xml:space="preserve" text-anchor="start" x="179.62" y="-786.94" font-family="sans-Serif" font-weight="bold" font-size="20.00" fill="#e2e8f0">PWN::AI::Agent::Mistakes — Negative&#45;Feedback Loop</text>
13
+ <text xml:space="preserve" text-anchor="start" x="260.25" y="-775.49" font-family="sans-Serif" font-size="11.00" fill="#94a3b8">learn from mistakes · do NOT repeat them · cross&#45;session · self&#45;correcting</text>
14
+ <g id="clust1" class="cluster">
15
+ <title>cluster_in</title>
16
+ <path fill="#450a0a" stroke="#b91c1c" stroke-dasharray="5,2" d="M20,-678.69C20,-678.69 737,-678.69 737,-678.69 743,-678.69 749,-684.69 749,-690.69 749,-690.69 749,-749.94 749,-749.94 749,-755.94 743,-761.94 737,-761.94 737,-761.94 20,-761.94 20,-761.94 14,-761.94 8,-755.94 8,-749.94 8,-749.94 8,-690.69 8,-690.69 8,-684.69 14,-678.69 20,-678.69"/>
17
+ <text xml:space="preserve" text-anchor="middle" x="378.5" y="-738.94" font-family="sans-Serif" font-size="20.00" fill="#fecaca">Four ingest paths</text>
18
+ </g>
19
+ <g id="clust3" class="cluster">
20
+ <title>cluster_fp</title>
21
+ <path fill="#022c22" stroke="#047857" stroke-width="2" d="M170,-536.44C170,-536.44 590,-536.44 590,-536.44 596,-536.44 602,-542.44 602,-548.44 602,-548.44 602,-620.19 602,-620.19 602,-626.19 596,-632.19 590,-632.19 590,-632.19 170,-632.19 170,-632.19 164,-632.19 158,-626.19 158,-620.19 158,-620.19 158,-548.44 158,-548.44 158,-542.44 164,-536.44 170,-536.44"/>
22
+ <text xml:space="preserve" text-anchor="middle" x="380" y="-609.19" font-family="sans-Serif" font-size="20.00" fill="#a7f3d0">Fingerprint &#160;(stable across sessions)</text>
23
+ </g>
24
+ <g id="clust5" class="cluster">
25
+ <title>cluster_react</title>
26
+ <path fill="#2e1065" stroke="#6d28d9" stroke-width="2" d="M295,-230.75C295,-230.75 853,-230.75 853,-230.75 859,-230.75 865,-236.75 865,-242.75 865,-242.75 865,-328 865,-328 865,-334 859,-340 853,-340 853,-340 295,-340 295,-340 289,-340 283,-334 283,-328 283,-328 283,-242.75 283,-242.75 283,-236.75 289,-230.75 295,-230.75"/>
27
+ <text xml:space="preserve" text-anchor="middle" x="574" y="-317" font-family="sans-Serif" font-size="20.00" fill="#ddd6fe">Reactions inside Loop.run</text>
28
+ </g>
29
+ <g id="clust7" class="cluster">
30
+ <title>cluster_out</title>
31
+ <path fill="#422006" stroke="#a16207" stroke-width="2" d="M162,-110.5C162,-110.5 653,-110.5 653,-110.5 659,-110.5 665,-116.5 665,-122.5 665,-122.5 665,-181.75 665,-181.75 665,-187.75 659,-193.75 653,-193.75 653,-193.75 162,-193.75 162,-193.75 156,-193.75 150,-187.75 150,-181.75 150,-181.75 150,-122.5 150,-122.5 150,-116.5 156,-110.5 162,-110.5"/>
32
+ <text xml:space="preserve" text-anchor="middle" x="407.5" y="-170.75" font-family="sans-Serif" font-size="20.00" fill="#fde68a">Injected into every future prompt</text>
33
+ </g>
34
+ <!-- ToolFail -->
35
+ <g id="node1" class="node">
36
+ <title>ToolFail</title>
37
+ <path fill="#fda4af" stroke="#334155" stroke-width="1.4" d="M143.5,-722.69C143.5,-722.69 28.5,-722.69 28.5,-722.69 22.5,-722.69 16.5,-716.69 16.5,-710.69 16.5,-710.69 16.5,-698.69 16.5,-698.69 16.5,-692.69 22.5,-686.69 28.5,-686.69 28.5,-686.69 143.5,-686.69 143.5,-686.69 149.5,-686.69 155.5,-692.69 155.5,-698.69 155.5,-698.69 155.5,-710.69 155.5,-710.69 155.5,-716.69 149.5,-722.69 143.5,-722.69"/>
38
+ <text xml:space="preserve" text-anchor="middle" x="86" y="-707.74" font-family="sans-Serif" font-size="11.00" fill="#0f172a">:tool</text>
39
+ <text xml:space="preserve" text-anchor="middle" x="86" y="-694.24" font-family="sans-Serif" font-size="11.00" fill="#0f172a">Dispatch → success:false</text>
40
+ </g>
41
+ <!-- Norm -->
42
+ <g id="node5" class="node">
43
+ <title>Norm</title>
44
+ <path fill="#6ee7b7" stroke="#334155" stroke-width="1.4" d="M332,-592.94C332,-592.94 178,-592.94 178,-592.94 172,-592.94 166,-586.94 166,-580.94 166,-580.94 166,-556.44 166,-556.44 166,-550.44 172,-544.44 178,-544.44 178,-544.44 332,-544.44 332,-544.44 338,-544.44 344,-550.44 344,-556.44 344,-556.44 344,-580.94 344,-580.94 344,-586.94 338,-592.94 332,-592.94"/>
45
+ <text xml:space="preserve" text-anchor="middle" x="255" y="-578.49" font-family="sans-Serif" font-size="11.00" fill="#0f172a">normalize_error()</text>
46
+ <text xml:space="preserve" text-anchor="middle" x="255" y="-564.99" font-family="sans-Serif" font-size="11.00" fill="#0f172a">strip paths · :LINE · 0xADDR</text>
47
+ <text xml:space="preserve" text-anchor="middle" x="255" y="-551.49" font-family="sans-Serif" font-size="11.00" fill="#0f172a">port N · TIMESTAMP · UUID · pid</text>
48
+ </g>
49
+ <!-- ToolFail&#45;&gt;Norm -->
50
+ <g id="edge1" class="edge">
51
+ <title>ToolFail&#45;&gt;Norm</title>
52
+ <path fill="none" stroke="#fb7185" stroke-width="1.3" d="M108.09,-686.17C135.76,-664.23 183.59,-626.31 217.14,-599.71"/>
53
+ <polygon fill="#fb7185" stroke="#fb7185" stroke-width="1.3" points="218.84,-601.93 223.37,-594.77 215.36,-597.54 218.84,-601.93"/>
54
+ <text xml:space="preserve" text-anchor="middle" x="181.56" y="-642.14" font-family="sans-Serif" font-size="9.00" fill="#cbd5e1">record()</text>
55
+ </g>
56
+ <!-- LoopFail -->
57
+ <g id="node2" class="node">
58
+ <title>LoopFail</title>
59
+ <path fill="#fda4af" stroke="#334155" stroke-width="1.4" d="M329.38,-722.69C329.38,-722.69 210.62,-722.69 210.62,-722.69 204.62,-722.69 198.62,-716.69 198.62,-710.69 198.62,-710.69 198.62,-698.69 198.62,-698.69 198.62,-692.69 204.62,-686.69 210.62,-686.69 210.62,-686.69 329.38,-686.69 329.38,-686.69 335.38,-686.69 341.38,-692.69 341.38,-698.69 341.38,-698.69 341.38,-710.69 341.38,-710.69 341.38,-716.69 335.38,-722.69 329.38,-722.69"/>
60
+ <text xml:space="preserve" text-anchor="middle" x="270" y="-707.74" font-family="sans-Serif" font-size="11.00" fill="#0f172a">:loop</text>
61
+ <text xml:space="preserve" text-anchor="middle" x="270" y="-694.24" font-family="sans-Serif" font-size="11.00" fill="#0f172a">iteration budget exhausted</text>
62
+ </g>
63
+ <!-- LoopFail&#45;&gt;Norm -->
64
+ <g id="edge2" class="edge">
65
+ <title>LoopFail&#45;&gt;Norm</title>
66
+ <path fill="none" stroke="#fb7185" stroke-width="1.3" d="M268.04,-686.17C265.69,-665.16 261.69,-629.48 258.74,-603.13"/>
67
+ <polygon fill="#fb7185" stroke="#fb7185" stroke-width="1.3" points="261.56,-603.14 257.89,-595.5 256,-603.76 261.56,-603.14"/>
68
+ </g>
69
+ <!-- UserCorr -->
70
+ <g id="node3" class="node">
71
+ <title>UserCorr</title>
72
+ <path fill="#fda4af" stroke="#334155" stroke-width="1.4" d="M537.25,-722.69C537.25,-722.69 396.75,-722.69 396.75,-722.69 390.75,-722.69 384.75,-716.69 384.75,-710.69 384.75,-710.69 384.75,-698.69 384.75,-698.69 384.75,-692.69 390.75,-686.69 396.75,-686.69 396.75,-686.69 537.25,-686.69 537.25,-686.69 543.25,-686.69 549.25,-692.69 549.25,-698.69 549.25,-698.69 549.25,-710.69 549.25,-710.69 549.25,-716.69 543.25,-722.69 537.25,-722.69"/>
73
+ <text xml:space="preserve" text-anchor="middle" x="467" y="-707.74" font-family="sans-Serif" font-size="11.00" fill="#0f172a">:user_correction</text>
74
+ <text xml:space="preserve" text-anchor="middle" x="467" y="-694.24" font-family="sans-Serif" font-size="11.00" fill="#0f172a">&quot;no that&#39;s wrong&quot; / &quot;still broken&quot;</text>
75
+ </g>
76
+ <!-- Sig -->
77
+ <g id="node6" class="node">
78
+ <title>Sig</title>
79
+ <path fill="#6ee7b7" stroke="#334155" stroke-width="2" d="M582.25,-586.69C582.25,-586.69 441.75,-586.69 441.75,-586.69 435.75,-586.69 429.75,-580.69 429.75,-574.69 429.75,-574.69 429.75,-562.69 429.75,-562.69 429.75,-556.69 435.75,-550.69 441.75,-550.69 441.75,-550.69 582.25,-550.69 582.25,-550.69 588.25,-550.69 594.25,-556.69 594.25,-562.69 594.25,-562.69 594.25,-574.69 594.25,-574.69 594.25,-580.69 588.25,-586.69 582.25,-586.69"/>
80
+ <text xml:space="preserve" text-anchor="middle" x="512" y="-571.74" font-family="sans-Serif" font-size="11.00" fill="#0f172a">signature = sha12(tool + norm)</text>
81
+ <text xml:space="preserve" text-anchor="middle" x="512" y="-558.24" font-family="sans-Serif" font-size="11.00" fill="#0f172a">count++ &#160;(cross&#45;session)</text>
82
+ </g>
83
+ <!-- UserCorr&#45;&gt;Sig -->
84
+ <g id="edge3" class="edge">
85
+ <title>UserCorr&#45;&gt;Sig</title>
86
+ <path fill="none" stroke="#fb7185" stroke-width="1.3" d="M472.88,-686.17C480.52,-663.42 493.93,-623.49 502.89,-596.81"/>
87
+ <polygon fill="#fb7185" stroke="#fb7185" stroke-width="1.3" points="505.45,-597.98 505.35,-589.5 500.14,-596.2 505.45,-597.98"/>
88
+ <text xml:space="preserve" text-anchor="middle" x="527.9" y="-642.14" font-family="sans-Serif" font-size="9.00" fill="#cbd5e1">+ flip_last_outcome</text>
89
+ </g>
90
+ <!-- ModelRec -->
91
+ <g id="node4" class="node">
92
+ <title>ModelRec</title>
93
+ <path fill="#fda4af" stroke="#334155" stroke-width="1.4" d="M729.38,-722.69C729.38,-722.69 604.62,-722.69 604.62,-722.69 598.62,-722.69 592.62,-716.69 592.62,-710.69 592.62,-710.69 592.62,-698.69 592.62,-698.69 592.62,-692.69 598.62,-686.69 604.62,-686.69 604.62,-686.69 729.38,-686.69 729.38,-686.69 735.38,-686.69 741.38,-692.69 741.38,-698.69 741.38,-698.69 741.38,-710.69 741.38,-710.69 741.38,-716.69 735.38,-722.69 729.38,-722.69"/>
94
+ <text xml:space="preserve" text-anchor="middle" x="667" y="-707.74" font-family="sans-Serif" font-size="11.00" fill="#0f172a">:model</text>
95
+ <text xml:space="preserve" text-anchor="middle" x="667" y="-694.24" font-family="sans-Serif" font-size="11.00" fill="#0f172a">mistakes_record(tool, error)</text>
96
+ </g>
97
+ <!-- ModelRec&#45;&gt;Sig -->
98
+ <g id="edge4" class="edge">
99
+ <title>ModelRec&#45;&gt;Sig</title>
100
+ <path fill="none" stroke="#fb7185" stroke-width="1.3" d="M646.74,-686.17C619.5,-662.63 570.96,-620.66 540.18,-594.05"/>
101
+ <polygon fill="#fb7185" stroke="#fb7185" stroke-width="1.3" points="542.13,-592.04 534.25,-588.92 538.47,-596.27 542.13,-592.04"/>
102
+ </g>
103
+ <!-- Norm&#45;&gt;Sig -->
104
+ <g id="edge5" class="edge">
105
+ <title>Norm&#45;&gt;Sig</title>
106
+ <path fill="none" stroke="#34d399" stroke-width="1.3" d="M344.6,-568.69C369.42,-568.69 394.24,-568.69 419.07,-568.69"/>
107
+ <polygon fill="#34d399" stroke="#34d399" stroke-width="1.3" points="418.99,-571.49 426.99,-568.69 418.99,-565.89 418.99,-571.49"/>
108
+ </g>
109
+ <!-- Store -->
110
+ <g id="node7" class="node">
111
+ <title>Store</title>
112
+ <path fill="#fcd34d" stroke="#334155" stroke-width="2" d="M591.25,-455.88C591.25,-459.22 555.73,-461.94 512,-461.94 468.27,-461.94 432.75,-459.22 432.75,-455.88 432.75,-455.88 432.75,-401.31 432.75,-401.31 432.75,-397.97 468.27,-395.25 512,-395.25 555.73,-395.25 591.25,-397.97 591.25,-401.31 591.25,-401.31 591.25,-455.88 591.25,-455.88"/>
113
+ <path fill="none" stroke="#334155" stroke-width="2" d="M591.25,-455.88C591.25,-452.53 555.73,-449.81 512,-449.81 468.27,-449.81 432.75,-452.53 432.75,-455.88"/>
114
+ <text xml:space="preserve" text-anchor="middle" x="512" y="-438.39" font-family="sans-Serif" font-size="11.00" fill="#0f172a">~/.pwn/mistakes.json</text>
115
+ <text xml:space="preserve" text-anchor="middle" x="512" y="-424.89" font-family="sans-Serif" font-size="11.00" fill="#0f172a">{sig → tool·error·count·fix</text>
116
+ <text xml:space="preserve" text-anchor="middle" x="512" y="-411.39" font-family="sans-Serif" font-size="11.00" fill="#0f172a"> resolved·regressed·sessions}</text>
117
+ </g>
118
+ <!-- Sig&#45;&gt;Store -->
119
+ <g id="edge6" class="edge">
120
+ <title>Sig&#45;&gt;Store</title>
121
+ <path fill="none" stroke="#f59e0b" stroke-width="2" d="M512,-549.92C512,-530.73 512,-499.44 512,-473.58"/>
122
+ <polygon fill="#f59e0b" stroke="#f59e0b" stroke-width="2" points="514.8,-473.91 512,-465.91 509.2,-473.91 514.8,-473.91"/>
123
+ <text xml:space="preserve" text-anchor="middle" x="525.5" y="-499.89" font-family="sans-Serif" font-size="9.00" fill="#cbd5e1">persist</text>
124
+ </g>
125
+ <!-- Guard -->
126
+ <g id="node8" class="node">
127
+ <title>Guard</title>
128
+ <path fill="#c4b5fd" stroke="#334155" stroke-width="1.4" d="M845.12,-300.75C845.12,-300.75 682.88,-300.75 682.88,-300.75 676.88,-300.75 670.88,-294.75 670.88,-288.75 670.88,-288.75 670.88,-250.75 670.88,-250.75 670.88,-244.75 676.88,-238.75 682.88,-238.75 682.88,-238.75 845.12,-238.75 845.12,-238.75 851.12,-238.75 857.12,-244.75 857.12,-250.75 857.12,-250.75 857.12,-288.75 857.12,-288.75 857.12,-294.75 851.12,-300.75 845.12,-300.75"/>
129
+ <text xml:space="preserve" text-anchor="middle" x="764" y="-286.3" font-family="sans-Serif" font-size="11.00" fill="#0f172a">guard_repeated_failure</text>
130
+ <text xml:space="preserve" text-anchor="middle" x="764" y="-272.8" font-family="sans-Serif" font-size="11.00" fill="#0f172a">max(turn, PERSISTENT count) ≥ 3</text>
131
+ <text xml:space="preserve" text-anchor="middle" x="764" y="-259.3" font-family="sans-Serif" font-size="11.00" fill="#0f172a">→ trips on 1st recurrence</text>
132
+ <text xml:space="preserve" text-anchor="middle" x="764" y="-245.8" font-family="sans-Serif" font-size="11.00" fill="#0f172a">in a new session</text>
133
+ </g>
134
+ <!-- Store&#45;&gt;Guard -->
135
+ <g id="edge7" class="edge">
136
+ <title>Store&#45;&gt;Guard</title>
137
+ <path fill="none" stroke="#a78bfa" stroke-width="1.3" d="M564.21,-395.1C605.71,-369.27 663.68,-333.19 706.5,-306.54"/>
138
+ <polygon fill="#a78bfa" stroke="#a78bfa" stroke-width="1.3" points="707.87,-308.99 713.18,-302.38 704.91,-304.23 707.87,-308.99"/>
139
+ <text xml:space="preserve" text-anchor="middle" x="649.25" y="-350.32" font-family="sans-Serif" font-size="9.00" fill="#cbd5e1">count</text>
140
+ </g>
141
+ <!-- Hint -->
142
+ <g id="node9" class="node">
143
+ <title>Hint</title>
144
+ <path fill="#c4b5fd" stroke="#334155" stroke-width="1.4" d="M467.25,-300.75C467.25,-300.75 302.75,-300.75 302.75,-300.75 296.75,-300.75 290.75,-294.75 290.75,-288.75 290.75,-288.75 290.75,-250.75 290.75,-250.75 290.75,-244.75 296.75,-238.75 302.75,-238.75 302.75,-238.75 467.25,-238.75 467.25,-238.75 473.25,-238.75 479.25,-244.75 479.25,-250.75 479.25,-250.75 479.25,-288.75 479.25,-288.75 479.25,-294.75 473.25,-300.75 467.25,-300.75"/>
145
+ <text xml:space="preserve" text-anchor="middle" x="385" y="-286.3" font-family="sans-Serif" font-size="11.00" fill="#0f172a">correction_hint</text>
146
+ <text xml:space="preserve" text-anchor="middle" x="385" y="-272.8" font-family="sans-Serif" font-size="11.00" fill="#0f172a">append to failed result:</text>
147
+ <text xml:space="preserve" text-anchor="middle" x="385" y="-259.3" font-family="sans-Serif" font-size="11.00" fill="#0f172a">&quot;seen N×, sig=…, KNOWN FIX: …&quot;</text>
148
+ <text xml:space="preserve" text-anchor="middle" x="385" y="-245.8" font-family="sans-Serif" font-size="11.00" fill="#0f172a">→ self&#45;correct NEXT iter</text>
149
+ </g>
150
+ <!-- Store&#45;&gt;Hint -->
151
+ <g id="edge8" class="edge">
152
+ <title>Store&#45;&gt;Hint</title>
153
+ <path fill="none" stroke="#a78bfa" stroke-width="1.3" d="M485.07,-394.33C464.79,-369.29 436.96,-334.92 415.8,-308.79"/>
154
+ <polygon fill="#a78bfa" stroke="#a78bfa" stroke-width="1.3" points="418.19,-307.29 410.98,-302.83 413.84,-310.81 418.19,-307.29"/>
155
+ <text xml:space="preserve" text-anchor="middle" x="463.23" y="-350.32" font-family="sans-Serif" font-size="9.00" fill="#cbd5e1">fix?</text>
156
+ </g>
157
+ <!-- Regr -->
158
+ <g id="node10" class="node">
159
+ <title>Regr</title>
160
+ <path fill="#c4b5fd" stroke="#334155" stroke-width="1.4" d="M616,-294C616,-294 534,-294 534,-294 528,-294 522,-288 522,-282 522,-282 522,-257.5 522,-257.5 522,-251.5 528,-245.5 534,-245.5 534,-245.5 616,-245.5 616,-245.5 622,-245.5 628,-251.5 628,-257.5 628,-257.5 628,-282 628,-282 628,-288 622,-294 616,-294"/>
161
+ <text xml:space="preserve" text-anchor="middle" x="575" y="-279.55" font-family="sans-Serif" font-size="11.00" fill="#0f172a">[REGRESSED]</text>
162
+ <text xml:space="preserve" text-anchor="middle" x="575" y="-266.05" font-family="sans-Serif" font-size="11.00" fill="#0f172a">resolved sig recurs</text>
163
+ <text xml:space="preserve" text-anchor="middle" x="575" y="-252.55" font-family="sans-Serif" font-size="11.00" fill="#0f172a">→ reopen + tag</text>
164
+ </g>
165
+ <!-- Store&#45;&gt;Regr -->
166
+ <g id="edge9" class="edge">
167
+ <title>Store&#45;&gt;Regr</title>
168
+ <path fill="none" stroke="#a78bfa" stroke-width="1.3" d="M525.36,-394.33C536.15,-367.46 551.25,-329.87 561.96,-303.22"/>
169
+ <polygon fill="#a78bfa" stroke="#a78bfa" stroke-width="1.3" points="564.43,-304.58 564.81,-296.11 559.23,-302.49 564.43,-304.58"/>
170
+ <text xml:space="preserve" text-anchor="middle" x="576.12" y="-350.7" font-family="sans-Serif" font-size="9.00" fill="#cbd5e1">resolved∧recur</text>
171
+ </g>
172
+ <!-- KMist -->
173
+ <g id="node11" class="node">
174
+ <title>KMist</title>
175
+ <path fill="#fcd34d" stroke="#334155" stroke-width="1.4" d="M644.5,-154.5C644.5,-154.5 499.5,-154.5 499.5,-154.5 493.5,-154.5 487.5,-148.5 487.5,-142.5 487.5,-142.5 487.5,-130.5 487.5,-130.5 487.5,-124.5 493.5,-118.5 499.5,-118.5 499.5,-118.5 644.5,-118.5 644.5,-118.5 650.5,-118.5 656.5,-124.5 656.5,-130.5 656.5,-130.5 656.5,-142.5 656.5,-142.5 656.5,-148.5 650.5,-154.5 644.5,-154.5"/>
176
+ <text xml:space="preserve" text-anchor="middle" x="572" y="-139.55" font-family="sans-Serif" font-size="11.00" fill="#0f172a">KNOWN MISTAKES</text>
177
+ <text xml:space="preserve" text-anchor="middle" x="572" y="-126.05" font-family="sans-Serif" font-size="11.00" fill="#0f172a">✗ [sig] tool ×N [REPEATING]…</text>
178
+ </g>
179
+ <!-- Guard&#45;&gt;KMist -->
180
+ <g id="edge10" class="edge">
181
+ <title>Guard&#45;&gt;KMist</title>
182
+ <path fill="none" stroke="#f59e0b" stroke-width="1.3" d="M719.47,-238.31C684.79,-214.6 637.39,-182.2 605.79,-160.6"/>
183
+ <polygon fill="#f59e0b" stroke="#f59e0b" stroke-width="1.3" points="607.53,-158.4 599.34,-156.19 604.37,-163.02 607.53,-158.4"/>
184
+ </g>
185
+ <!-- KFix -->
186
+ <g id="node12" class="node">
187
+ <title>KFix</title>
188
+ <path fill="#fcd34d" stroke="#334155" stroke-width="1.4" d="M432.75,-154.5C432.75,-154.5 337.25,-154.5 337.25,-154.5 331.25,-154.5 325.25,-148.5 325.25,-142.5 325.25,-142.5 325.25,-130.5 325.25,-130.5 325.25,-124.5 331.25,-118.5 337.25,-118.5 337.25,-118.5 432.75,-118.5 432.75,-118.5 438.75,-118.5 444.75,-124.5 444.75,-130.5 444.75,-130.5 444.75,-142.5 444.75,-142.5 444.75,-148.5 438.75,-154.5 432.75,-154.5"/>
189
+ <text xml:space="preserve" text-anchor="middle" x="385" y="-139.55" font-family="sans-Serif" font-size="11.00" fill="#0f172a">KNOWN FIXES</text>
190
+ <text xml:space="preserve" text-anchor="middle" x="385" y="-126.05" font-family="sans-Serif" font-size="11.00" fill="#0f172a">✓ [sig] tool — FIX: …</text>
191
+ </g>
192
+ <!-- Hint&#45;&gt;KFix -->
193
+ <!-- Regr&#45;&gt;KMist -->
194
+ <g id="edge12" class="edge">
195
+ <title>Regr&#45;&gt;KMist</title>
196
+ <path fill="none" stroke="#f59e0b" stroke-width="1.3" d="M574.46,-244.98C573.94,-222.33 573.16,-188.26 572.62,-164.57"/>
197
+ <polygon fill="#f59e0b" stroke="#f59e0b" stroke-width="1.3" points="575.42,-164.71 572.44,-156.78 569.82,-164.84 575.42,-164.71"/>
198
+ </g>
199
+ <!-- Prompt -->
200
+ <g id="node14" class="node">
201
+ <title>Prompt</title>
202
+ <path fill="#7dd3fc" stroke="#334155" stroke-width="2" d="M416.25,-36C416.25,-36 353.75,-36 353.75,-36 347.75,-36 341.75,-30 341.75,-24 341.75,-24 341.75,-12 341.75,-12 341.75,-6 347.75,0 353.75,0 353.75,0 416.25,0 416.25,0 422.25,0 428.25,-6 428.25,-12 428.25,-12 428.25,-24 428.25,-24 428.25,-30 422.25,-36 416.25,-36"/>
203
+ <text xml:space="preserve" text-anchor="middle" x="385" y="-21.05" font-family="sans-Serif" font-size="11.00" fill="#0f172a">PromptBuilder</text>
204
+ <text xml:space="preserve" text-anchor="middle" x="385" y="-7.55" font-family="sans-Serif" font-size="11.00" fill="#0f172a">system prompt</text>
205
+ </g>
206
+ <!-- KMist&#45;&gt;Prompt -->
207
+ <g id="edge16" class="edge">
208
+ <title>KMist&#45;&gt;Prompt</title>
209
+ <path fill="none" stroke="#fb7185" stroke-width="2" stroke-dasharray="5,2" d="M503.87,-117.86C491.34,-115.07 478.32,-112.46 466,-110.5 429.11,-104.64 156.29,-109.99 131,-82.5 102.58,-51.61 247.4,-32.24 330.26,-23.84"/>
210
+ <polygon fill="#fb7185" stroke="#fb7185" stroke-width="2" points="330.33,-26.65 338.02,-23.08 329.78,-21.08 330.33,-26.65"/>
211
+ <text xml:space="preserve" text-anchor="middle" x="161" y="-73.95" font-family="sans-Serif" font-size="9.00" fill="#cbd5e1">do NOT repeat</text>
212
+ </g>
213
+ <!-- KMist&#45;&gt;Prompt -->
214
+ <!-- KFix&#45;&gt;Prompt -->
215
+ <g id="edge17" class="edge">
216
+ <title>KFix&#45;&gt;Prompt</title>
217
+ <path fill="none" stroke="#fbbf24" stroke-width="2" stroke-dasharray="5,2" d="M324.56,-119.66C297.76,-109.32 274.88,-93.67 287.75,-72 297.43,-55.69 314.09,-44.08 330.92,-35.97"/>
218
+ <polygon fill="#fbbf24" stroke="#fbbf24" stroke-width="2" points="331.84,-38.62 338.02,-32.82 329.57,-33.51 331.84,-38.62"/>
219
+ <text xml:space="preserve" text-anchor="middle" x="320.38" y="-73.95" font-family="sans-Serif" font-size="9.00" fill="#cbd5e1">do THIS instead</text>
220
+ </g>
221
+ <!-- KFix&#45;&gt;Prompt -->
222
+ <!-- Mem -->
223
+ <g id="node13" class="node">
224
+ <title>Mem</title>
225
+ <path fill="#fcd34d" stroke="#334155" stroke-width="1.4" d="M270,-154.5C270,-154.5 170,-154.5 170,-154.5 164,-154.5 158,-148.5 158,-142.5 158,-142.5 158,-130.5 158,-130.5 158,-124.5 164,-118.5 170,-118.5 170,-118.5 270,-118.5 270,-118.5 276,-118.5 282,-124.5 282,-130.5 282,-130.5 282,-142.5 282,-142.5 282,-148.5 276,-154.5 270,-154.5"/>
226
+ <text xml:space="preserve" text-anchor="middle" x="220" y="-139.55" font-family="sans-Serif" font-size="11.00" fill="#0f172a">PWN::Memory :lesson</text>
227
+ <text xml:space="preserve" text-anchor="middle" x="220" y="-126.05" font-family="sans-Serif" font-size="11.00" fill="#0f172a">&quot;AVOID X — FIX: Y&quot;</text>
228
+ </g>
229
+ <!-- Mem&#45;&gt;Prompt -->
230
+ <g id="edge18" class="edge">
231
+ <title>Mem&#45;&gt;Prompt</title>
232
+ <path fill="none" stroke="#fbbf24" stroke-width="1.3" stroke-dasharray="5,2" d="M274.34,-117.85C311.92,-105.23 356.33,-89.31 363,-82.5 372.53,-72.76 377.94,-58.7 381.01,-46.27"/>
233
+ <polygon fill="#fbbf24" stroke="#fbbf24" stroke-width="1.3" points="383.7,-47.11 382.6,-38.71 378.22,-45.96 383.7,-47.11"/>
234
+ <text xml:space="preserve" text-anchor="middle" x="402.91" y="-73.95" font-family="sans-Serif" font-size="9.00" fill="#cbd5e1">MEMORY block</text>
235
+ </g>
236
+ <!-- Mem&#45;&gt;Prompt -->
237
+ <!-- Resolve -->
238
+ <g id="node15" class="node">
239
+ <title>Resolve</title>
240
+ <path fill="#6ee7b7" stroke="#334155" stroke-width="2" d="M263.25,-446.59C263.25,-446.59 188.75,-446.59 188.75,-446.59 182.75,-446.59 176.75,-440.59 176.75,-434.59 176.75,-434.59 176.75,-422.59 176.75,-422.59 176.75,-416.59 182.75,-410.59 188.75,-410.59 188.75,-410.59 263.25,-410.59 263.25,-410.59 269.25,-410.59 275.25,-416.59 275.25,-422.59 275.25,-422.59 275.25,-434.59 275.25,-434.59 275.25,-440.59 269.25,-446.59 263.25,-446.59"/>
241
+ <text xml:space="preserve" text-anchor="middle" x="226" y="-431.64" font-family="sans-Serif" font-size="11.00" fill="#0f172a">mistakes_resolve</text>
242
+ <text xml:space="preserve" text-anchor="middle" x="226" y="-418.14" font-family="sans-Serif" font-size="11.00" fill="#0f172a">(signature, fix)</text>
243
+ </g>
244
+ <!-- Resolve&#45;&gt;Store -->
245
+ <g id="edge13" class="edge">
246
+ <title>Resolve&#45;&gt;Store</title>
247
+ <path fill="none" stroke="#34d399" stroke-width="2" d="M276.14,-428.59C316.05,-428.59 372.95,-428.59 420.87,-428.59"/>
248
+ <polygon fill="#34d399" stroke="#34d399" stroke-width="2" points="420.86,-431.39 428.86,-428.59 420.86,-425.79 420.86,-431.39"/>
249
+ <text xml:space="preserve" text-anchor="middle" x="354" y="-444.04" font-family="sans-Serif" font-size="9.00" fill="#cbd5e1">resolved:true</text>
250
+ <text xml:space="preserve" text-anchor="middle" x="354" y="-433.54" font-family="sans-Serif" font-size="9.00" fill="#cbd5e1">fix:…</text>
251
+ </g>
252
+ <!-- Resolve&#45;&gt;KFix -->
253
+ <g id="edge14" class="edge">
254
+ <title>Resolve&#45;&gt;KFix</title>
255
+ <path fill="none" stroke="#f59e0b" stroke-width="1.3" d="M226.55,-409.87C228.43,-373.56 236.69,-289.26 273,-230.75 291.16,-201.49 321.67,-176.98 346.27,-160.45"/>
256
+ <polygon fill="#f59e0b" stroke="#f59e0b" stroke-width="1.3" points="347.55,-162.95 352.71,-156.23 344.48,-158.27 347.55,-162.95"/>
257
+ </g>
258
+ <!-- Resolve&#45;&gt;Mem -->
259
+ <g id="edge15" class="edge">
260
+ <title>Resolve&#45;&gt;Mem</title>
261
+ <path fill="none" stroke="#f59e0b" stroke-width="1.3" d="M207.1,-409.87C191.14,-393.5 169.46,-367.6 160.25,-340 144.89,-293.94 146.6,-277.35 160.25,-230.75 167.7,-205.31 184.46,-180.22 198.34,-162.49"/>
262
+ <polygon fill="#f59e0b" stroke="#f59e0b" stroke-width="1.3" points="200.39,-164.4 203.23,-156.41 196.03,-160.89 200.39,-164.4"/>
263
+ <text xml:space="preserve" text-anchor="middle" x="177.12" y="-266.45" font-family="sans-Serif" font-size="9.00" fill="#cbd5e1">promote</text>
264
+ </g>
265
+ </g>
266
+ </svg>