agent99 0.0.3 → 0.0.5

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 (103) hide show
  1. checksums.yaml +4 -4
  2. data/A2A_SPEC-dev.md +1829 -0
  3. data/CHANGELOG.md +38 -0
  4. data/COMMITS.md +196 -0
  5. data/DOCS.md +96 -0
  6. data/README.md +212 -84
  7. data/Rakefile +62 -0
  8. data/docs/AI/htm.md +215 -0
  9. data/docs/AI/htm.rb +141 -0
  10. data/docs/AI/htm_demo.db +0 -0
  11. data/docs/AI/notes_on_htm_implementation.md +1319 -0
  12. data/docs/AI/some_code.rb +692 -0
  13. data/docs/advanced-topics/a2a-protocol.md +13 -0
  14. data/docs/{advanced_features.md → advanced-topics/advanced-features.md} +9 -4
  15. data/docs/{control_actions.md → advanced-topics/control-actions.md} +2 -0
  16. data/docs/advanced-topics/model-context-protocol.md +4 -0
  17. data/docs/advanced-topics/multi-agent-processing.md +674 -0
  18. data/docs/agent-development/request-response-handling.md +512 -0
  19. data/docs/agent99_framework/central_registry.md +94 -0
  20. data/docs/agent99_framework/message_client.md +120 -0
  21. data/docs/agent99_framework/registry_client.md +119 -0
  22. data/docs/api-reference/agent99-base.md +463 -0
  23. data/docs/api-reference/message-clients.md +495 -0
  24. data/docs/{api_reference.md → api-reference/overview.md} +14 -4
  25. data/docs/api-reference/registry-client.md +470 -0
  26. data/docs/api-reference/schemas.md +518 -0
  27. data/docs/assets/css/custom.css +27 -0
  28. data/docs/assets/images/agent-lifecycle.svg +73 -0
  29. data/docs/assets/images/agent-registry-process.svg +86 -0
  30. data/docs/assets/images/agent-registry-processes.svg +114 -0
  31. data/docs/assets/images/agent-types-overview.svg +51 -0
  32. data/docs/assets/images/agent99-architecture.svg +85 -0
  33. data/docs/assets/images/agent99_logo.png +0 -0
  34. data/docs/assets/images/control-actions-state.svg +83 -0
  35. data/docs/assets/images/knowledge-graph.svg +77 -0
  36. data/docs/assets/images/message-processing-flow.svg +148 -0
  37. data/docs/assets/images/multi-agent-system.svg +66 -0
  38. data/docs/assets/images/proxy-pattern-sequence.svg +48 -0
  39. data/docs/assets/images/request-flow.svg +97 -0
  40. data/docs/assets/images/request-processing-lifecycle.svg +50 -0
  41. data/docs/assets/images/request-response-sequence.svg +39 -0
  42. data/docs/{agent_lifecycle.md → core-concepts/agent-lifecycle.md} +2 -0
  43. data/docs/core-concepts/agent-types.md +255 -0
  44. data/docs/{architecture.md → core-concepts/architecture.md} +5 -5
  45. data/docs/core-concepts/what-is-an-agent.md +293 -0
  46. data/docs/diagrams/message-flow-sequence.svg +198 -0
  47. data/docs/diagrams/p2p-network-topology.svg +181 -0
  48. data/docs/diagrams/smart-transport-routing.svg +165 -0
  49. data/docs/diagrams/three-layer-architecture.svg +77 -0
  50. data/docs/diagrams/transport-extension-api.svg +309 -0
  51. data/docs/diagrams/transport-extension-architecture.svg +234 -0
  52. data/docs/diagrams/transport-selection-flowchart.svg +264 -0
  53. data/docs/examples/advanced-examples.md +951 -0
  54. data/docs/examples/basic-examples.md +268 -0
  55. data/docs/{agent_discovery.md → framework-components/agent-discovery.md} +9 -5
  56. data/docs/{agent_registry_processes.md → framework-components/agent-registry.md} +9 -3
  57. data/docs/{message_processing.md → framework-components/message-processing.md} +3 -1
  58. data/docs/getting-started/basic-example.md +306 -0
  59. data/docs/getting-started/installation.md +160 -0
  60. data/docs/getting-started/overview.md +64 -0
  61. data/docs/getting-started/quick-start.md +179 -0
  62. data/docs/index.md +97 -0
  63. data/docs/operations/breaking-changes.md +26 -0
  64. data/examples/DEMO.md +148 -0
  65. data/examples/README.md +50 -0
  66. data/examples/agent_watcher.rb +5 -1
  67. data/examples/bad_agent.rb +32 -0
  68. data/examples/chief_agent.rb +17 -6
  69. data/examples/control.rb +16 -7
  70. data/examples/example_agent.rb +16 -3
  71. data/examples/maxwell_agent86.rb +15 -26
  72. data/examples/registry.rb +10 -9
  73. data/examples/run_demo.rb +433 -0
  74. data/lib/agent99/agent_discovery.rb +4 -0
  75. data/lib/agent99/agent_lifecycle.rb +34 -10
  76. data/lib/agent99/amqp_message_client.rb +2 -2
  77. data/lib/agent99/base.rb +6 -2
  78. data/lib/agent99/message_processing.rb +6 -10
  79. data/lib/agent99/registry_client.rb +15 -11
  80. data/lib/agent99/tcp_message_client.rb +183 -0
  81. data/lib/agent99/version.rb +1 -1
  82. data/lib/agent99.rb +1 -1
  83. data/mkdocs.yml +195 -0
  84. data/p2p_plan.md +533 -0
  85. data/p2p_roadmap.md +299 -0
  86. data/registry_plan.md +1818 -0
  87. metadata +93 -30
  88. data/docs/README.md +0 -57
  89. data/docs/diagrams/agent_registry_processes.dot +0 -42
  90. data/docs/diagrams/agent_registry_processes.png +0 -0
  91. data/docs/diagrams/high_level_architecture.dot +0 -26
  92. data/docs/diagrams/high_level_architecture.png +0 -0
  93. data/docs/diagrams/request_flow.dot +0 -42
  94. data/docs/diagrams/request_flow.png +0 -0
  95. /data/docs/{extending_the_framework.md → advanced-topics/extending-the-framework.md} +0 -0
  96. /data/docs/{custom_agent_implementation.md → agent-development/custom-agent-implementation.md} +0 -0
  97. /data/docs/{error_handling_and_logging.md → agent-development/error-handling-and-logging.md} +0 -0
  98. /data/docs/{schema_definition.md → agent-development/schema-definition.md} +0 -0
  99. /data/docs/{messaging_system.md → framework-components/messaging-system.md} +0 -0
  100. /data/docs/{configuration.md → operations/configuration.md} +0 -0
  101. /data/docs/{preformance_considerations.md → operations/performance-considerations.md} +0 -0
  102. /data/docs/{security.md → operations/security.md} +0 -0
  103. /data/docs/{troubleshooting.md → operations/troubleshooting.md} +0 -0
@@ -0,0 +1,264 @@
1
+ <svg width="1000" height="800" xmlns="http://www.w3.org/2000/svg">
2
+ <!-- Background transparent -->
3
+
4
+ <!-- Title -->
5
+ <text x="500" y="30" text-anchor="middle" fill="#f7fafc"
6
+ font-family="Arial, sans-serif" font-size="20" font-weight="bold">
7
+ Agent99 Smart Transport Selection Flow
8
+ </text>
9
+
10
+ <!-- Start -->
11
+ <ellipse cx="500" cy="80" rx="80" ry="30"
12
+ fill="#2d3748" stroke="#4a5568" stroke-width="2"/>
13
+ <text x="500" y="88" text-anchor="middle" fill="#e2e8f0"
14
+ font-family="Arial, sans-serif" font-size="12" font-weight="bold">
15
+ Agent Message
16
+ </text>
17
+ <text x="500" y="100" text-anchor="middle" fill="#cbd5e0"
18
+ font-family="Arial, sans-serif" font-size="10">
19
+ to Target Agent
20
+ </text>
21
+
22
+ <!-- First Decision: Same Process? -->
23
+ <polygon points="500,150 580,180 500,210 420,180"
24
+ fill="#553c9a" stroke="#7c3aed" stroke-width="2"/>
25
+ <text x="500" y="175" text-anchor="middle" fill="#e9d5ff"
26
+ font-family="Arial, sans-serif" font-size="11" font-weight="bold">
27
+ Same
28
+ </text>
29
+ <text x="500" y="190" text-anchor="middle" fill="#e9d5ff"
30
+ font-family="Arial, sans-serif" font-size="11" font-weight="bold">
31
+ Process?
32
+ </text>
33
+
34
+ <!-- Memory Transport -->
35
+ <rect x="200" y="150" width="120" height="60"
36
+ fill="#2f855a" stroke="#48bb78" stroke-width="2" rx="8"/>
37
+ <text x="260" y="175" text-anchor="middle" fill="#f0fff4"
38
+ font-family="Arial, sans-serif" font-size="12" font-weight="bold">
39
+ Memory
40
+ </text>
41
+ <text x="260" y="190" text-anchor="middle" fill="#c6f6d5"
42
+ font-family="Arial, sans-serif" font-size="10">
43
+ Transport
44
+ </text>
45
+ <text x="260" y="202" text-anchor="middle" fill="#a7f3d0"
46
+ font-family="Arial, sans-serif" font-size="8">
47
+ Instant delivery
48
+ </text>
49
+
50
+ <!-- Second Decision: Same Machine? -->
51
+ <polygon points="500,280 580,310 500,340 420,310"
52
+ fill="#553c9a" stroke="#7c3aed" stroke-width="2"/>
53
+ <text x="500" y="305" text-anchor="middle" fill="#e9d5ff"
54
+ font-family="Arial, sans-serif" font-size="11" font-weight="bold">
55
+ Same
56
+ </text>
57
+ <text x="500" y="320" text-anchor="middle" fill="#e9d5ff"
58
+ font-family="Arial, sans-serif" font-size="11" font-weight="bold">
59
+ Machine?
60
+ </text>
61
+
62
+ <!-- Redis Transport -->
63
+ <rect x="200" y="280" width="120" height="60"
64
+ fill="#d69e2e" stroke="#ed8936" stroke-width="2" rx="8"/>
65
+ <text x="260" y="305" text-anchor="middle" fill="#fffbeb"
66
+ font-family="Arial, sans-serif" font-size="12" font-weight="bold">
67
+ Redis
68
+ </text>
69
+ <text x="260" y="320" text-anchor="middle" fill="#fde68a"
70
+ font-family="Arial, sans-serif" font-size="10">
71
+ Transport
72
+ </text>
73
+ <text x="260" y="332" text-anchor="middle" fill="#fcd34d"
74
+ font-family="Arial, sans-serif" font-size="8">
75
+ Local pub/sub
76
+ </text>
77
+
78
+ <!-- Third Decision: Same LAN? -->
79
+ <polygon points="500,410 580,440 500,470 420,440"
80
+ fill="#553c9a" stroke="#7c3aed" stroke-width="2"/>
81
+ <text x="500" y="435" text-anchor="middle" fill="#e9d5ff"
82
+ font-family="Arial, sans-serif" font-size="11" font-weight="bold">
83
+ Same
84
+ </text>
85
+ <text x="500" y="450" text-anchor="middle" fill="#e9d5ff"
86
+ font-family="Arial, sans-serif" font-size="11" font-weight="bold">
87
+ LAN?
88
+ </text>
89
+
90
+ <!-- Lanet Transport -->
91
+ <rect x="200" y="410" width="120" height="60"
92
+ fill="#065f46" stroke="#10b981" stroke-width="2" rx="8"/>
93
+ <text x="260" y="435" text-anchor="middle" fill="#d1fae5"
94
+ font-family="Arial, sans-serif" font-size="12" font-weight="bold">
95
+ Lanet
96
+ </text>
97
+ <text x="260" y="450" text-anchor="middle" fill="#a7f3d0"
98
+ font-family="Arial, sans-serif" font-size="10">
99
+ Transport
100
+ </text>
101
+ <text x="260" y="462" text-anchor="middle" fill="#6ee7b7"
102
+ font-family="Arial, sans-serif" font-size="8">
103
+ P2P encrypted
104
+ </text>
105
+
106
+ <!-- Fourth Decision: Reliable Required? -->
107
+ <polygon points="500,540 580,570 500,600 420,570"
108
+ fill="#553c9a" stroke="#7c3aed" stroke-width="2"/>
109
+ <text x="500" y="565" text-anchor="middle" fill="#e9d5ff"
110
+ font-family="Arial, sans-serif" font-size="11" font-weight="bold">
111
+ Reliable
112
+ </text>
113
+ <text x="500" y="580" text-anchor="middle" fill="#e9d5ff"
114
+ font-family="Arial, sans-serif" font-size="11" font-weight="bold">
115
+ Required?
116
+ </text>
117
+
118
+ <!-- AMQP Transport -->
119
+ <rect x="650" y="540" width="120" height="60"
120
+ fill="#7c2d12" stroke="#dc2626" stroke-width="2" rx="8"/>
121
+ <text x="710" y="565" text-anchor="middle" fill="#fef2f2"
122
+ font-family="Arial, sans-serif" font-size="12" font-weight="bold">
123
+ AMQP
124
+ </text>
125
+ <text x="710" y="580" text-anchor="middle" fill="#fecaca"
126
+ font-family="Arial, sans-serif" font-size="10">
127
+ Transport
128
+ </text>
129
+ <text x="710" y="592" text-anchor="middle" fill="#fca5a5"
130
+ font-family="Arial, sans-serif" font-size="8">
131
+ Guaranteed delivery
132
+ </text>
133
+
134
+ <!-- NATS Transport -->
135
+ <rect x="650" y="650" width="120" height="60"
136
+ fill="#1e40af" stroke="#3b82f6" stroke-width="2" rx="8"/>
137
+ <text x="710" y="675" text-anchor="middle" fill="#dbeafe"
138
+ font-family="Arial, sans-serif" font-size="12" font-weight="bold">
139
+ NATS
140
+ </text>
141
+ <text x="710" y="690" text-anchor="middle" fill="#bfdbfe"
142
+ font-family="Arial, sans-serif" font-size="10">
143
+ Transport
144
+ </text>
145
+ <text x="710" y="702" text-anchor="middle" fill="#93c5fd"
146
+ font-family="Arial, sans-serif" font-size="8">
147
+ High performance
148
+ </text>
149
+
150
+ <!-- Arrow definitions -->
151
+ <defs>
152
+ <marker id="greenarrow" markerWidth="10" markerHeight="7"
153
+ refX="9" refY="3.5" orient="auto">
154
+ <polygon points="0 0, 10 3.5, 0 7" fill="#10b981"/>
155
+ </marker>
156
+ <marker id="redarrow" markerWidth="10" markerHeight="7"
157
+ refX="9" refY="3.5" orient="auto">
158
+ <polygon points="0 0, 10 3.5, 0 7" fill="#dc2626"/>
159
+ </marker>
160
+ <marker id="bluearrow" markerWidth="10" markerHeight="7"
161
+ refX="9" refY="3.5" orient="auto">
162
+ <polygon points="0 0, 10 3.5, 0 7" fill="#3b82f6"/>
163
+ </marker>
164
+ <marker id="purplearrow" markerWidth="10" markerHeight="7"
165
+ refX="9" refY="3.5" orient="auto">
166
+ <polygon points="0 0, 10 3.5, 0 7" fill="#7c3aed"/>
167
+ </marker>
168
+ </defs>
169
+
170
+ <!-- Flow arrows -->
171
+ <line x1="500" y1="110" x2="500" y2="145"
172
+ stroke="#7c3aed" stroke-width="2" marker-end="url(#purplearrow)"/>
173
+
174
+ <!-- Yes paths -->
175
+ <line x1="420" y1="180" x2="330" y2="180"
176
+ stroke="#10b981" stroke-width="2" marker-end="url(#greenarrow)"/>
177
+ <text x="375" y="175" text-anchor="middle" fill="#10b981"
178
+ font-family="Arial, sans-serif" font-size="10" font-weight="bold">
179
+ YES
180
+ </text>
181
+
182
+ <line x1="420" y1="310" x2="330" y2="310"
183
+ stroke="#10b981" stroke-width="2" marker-end="url(#greenarrow)"/>
184
+ <text x="375" y="305" text-anchor="middle" fill="#10b981"
185
+ font-family="Arial, sans-serif" font-size="10" font-weight="bold">
186
+ YES
187
+ </text>
188
+
189
+ <line x1="420" y1="440" x2="330" y2="440"
190
+ stroke="#10b981" stroke-width="2" marker-end="url(#greenarrow)"/>
191
+ <text x="375" y="435" text-anchor="middle" fill="#10b981"
192
+ font-family="Arial, sans-serif" font-size="10" font-weight="bold">
193
+ YES
194
+ </text>
195
+
196
+ <line x1="580" y1="570" x2="640" y2="570"
197
+ stroke="#dc2626" stroke-width="2" marker-end="url(#redarrow)"/>
198
+ <text x="610" y="565" text-anchor="middle" fill="#dc2626"
199
+ font-family="Arial, sans-serif" font-size="10" font-weight="bold">
200
+ YES
201
+ </text>
202
+
203
+ <!-- No paths -->
204
+ <line x1="500" y1="210" x2="500" y2="275"
205
+ stroke="#7c3aed" stroke-width="2" marker-end="url(#purplearrow)"/>
206
+ <text x="515" y="240" fill="#7c3aed"
207
+ font-family="Arial, sans-serif" font-size="10" font-weight="bold">
208
+ NO
209
+ </text>
210
+
211
+ <line x1="500" y1="340" x2="500" y2="405"
212
+ stroke="#7c3aed" stroke-width="2" marker-end="url(#purplearrow)"/>
213
+ <text x="515" y="370" fill="#7c3aed"
214
+ font-family="Arial, sans-serif" font-size="10" font-weight="bold">
215
+ NO
216
+ </text>
217
+
218
+ <line x1="500" y1="470" x2="500" y2="535"
219
+ stroke="#7c3aed" stroke-width="2" marker-end="url(#purplearrow)"/>
220
+ <text x="515" y="500" fill="#7c3aed"
221
+ font-family="Arial, sans-serif" font-size="10" font-weight="bold">
222
+ NO
223
+ </text>
224
+
225
+ <line x1="500" y1="600" x2="650" y2="680"
226
+ stroke="#3b82f6" stroke-width="2" marker-end="url(#bluearrow)"/>
227
+ <text x="575" y="635" text-anchor="middle" fill="#3b82f6"
228
+ font-family="Arial, sans-serif" font-size="10" font-weight="bold">
229
+ NO
230
+ </text>
231
+
232
+ <!-- Performance characteristics -->
233
+ <rect x="50" y="730" width="900" height="50"
234
+ fill="#0f172a" stroke="#334155" stroke-width="1" rx="5" opacity="0.9"/>
235
+ <text x="70" y="750" fill="#f1f5f9"
236
+ font-family="Arial, sans-serif" font-size="12" font-weight="bold">
237
+ Performance Characteristics:
238
+ </text>
239
+ <text x="70" y="765" fill="#10b981"
240
+ font-family="Arial, sans-serif" font-size="10">
241
+ Memory: ~1μs •
242
+ </text>
243
+ <text x="170" y="765" fill="#ed8936"
244
+ font-family="Arial, sans-serif" font-size="10">
245
+ Redis: ~100μs •
246
+ </text>
247
+ <text x="280" y="765" fill="#10b981"
248
+ font-family="Arial, sans-serif" font-size="10">
249
+ Lanet: ~1ms •
250
+ </text>
251
+ <text x="370" y="765" fill="#dc2626"
252
+ font-family="Arial, sans-serif" font-size="10">
253
+ AMQP: ~5ms •
254
+ </text>
255
+ <text x="460" y="765" fill="#3b82f6"
256
+ font-family="Arial, sans-serif" font-size="10">
257
+ NATS: ~2ms
258
+ </text>
259
+
260
+ <text x="600" y="765" fill="#a0aec0"
261
+ font-family="Arial, sans-serif" font-size="10">
262
+ (Estimated latency, varies by network and load)
263
+ </text>
264
+ </svg>