hanzo 0.3.18__tar.gz → 0.3.34__tar.gz

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 (68) hide show
  1. hanzo-0.3.34/.gitignore +63 -0
  2. hanzo-0.3.34/PKG-INFO +312 -0
  3. hanzo-0.3.34/README.md +223 -0
  4. {hanzo-0.3.18 → hanzo-0.3.34}/pyproject.toml +29 -2
  5. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/__init__.py +2 -2
  6. hanzo-0.3.34/src/hanzo/base_agent.py +526 -0
  7. hanzo-0.3.34/src/hanzo/batch_orchestrator.py +1027 -0
  8. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/cli.py +22 -10
  9. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/commands/__init__.py +3 -0
  10. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/commands/agent.py +21 -9
  11. hanzo-0.3.34/src/hanzo/commands/auth.py +256 -0
  12. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/commands/chat.py +65 -16
  13. hanzo-0.3.34/src/hanzo/commands/infra.py +494 -0
  14. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/commands/mcp.py +1 -3
  15. hanzo-0.3.34/src/hanzo/commands/network.py +859 -0
  16. hanzo-0.3.18/src/hanzo/commands/cluster.py → hanzo-0.3.34/src/hanzo/commands/node.py +127 -127
  17. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/commands/repl.py +5 -2
  18. hanzo-0.3.34/src/hanzo/commands/router.py +168 -0
  19. hanzo-0.3.34/src/hanzo/cryptography/__init__.py +36 -0
  20. hanzo-0.3.34/src/hanzo/cryptography/ml_dsa.py +331 -0
  21. hanzo-0.3.34/src/hanzo/cryptography/precompiles.py +190 -0
  22. hanzo-0.3.34/src/hanzo/cryptography/slh_dsa.py +262 -0
  23. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/dev.py +685 -280
  24. hanzo-0.3.34/src/hanzo/fallback_handler.py +303 -0
  25. hanzo-0.3.34/src/hanzo/infra/__init__.py +408 -0
  26. hanzo-0.3.34/src/hanzo/infra/cron.py +631 -0
  27. hanzo-0.3.34/src/hanzo/infra/documentdb.py +565 -0
  28. hanzo-0.3.34/src/hanzo/infra/functions.py +539 -0
  29. hanzo-0.3.34/src/hanzo/infra/kv.py +525 -0
  30. hanzo-0.3.34/src/hanzo/infra/pubsub.py +534 -0
  31. hanzo-0.3.34/src/hanzo/infra/queues.py +637 -0
  32. hanzo-0.3.34/src/hanzo/infra/search.py +510 -0
  33. hanzo-0.3.34/src/hanzo/infra/storage.py +535 -0
  34. hanzo-0.3.34/src/hanzo/infra/tasks.py +518 -0
  35. hanzo-0.3.34/src/hanzo/infra/vector.py +350 -0
  36. hanzo-0.3.34/src/hanzo/interactive/dashboard.py +202 -0
  37. hanzo-0.3.34/src/hanzo/interactive/enhanced_repl.py +1069 -0
  38. hanzo-0.3.34/src/hanzo/interactive/model_selector.py +159 -0
  39. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/interactive/repl.py +83 -34
  40. hanzo-0.3.34/src/hanzo/interactive/todo_manager.py +456 -0
  41. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/mcp_server.py +8 -3
  42. hanzo-0.3.34/src/hanzo/memory_manager.py +448 -0
  43. hanzo-0.3.34/src/hanzo/model_registry.py +423 -0
  44. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/orchestrator_config.py +85 -13
  45. hanzo-0.3.34/src/hanzo/rate_limiter.py +317 -0
  46. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/router/__init__.py +1 -1
  47. hanzo-0.3.34/src/hanzo/streaming.py +292 -0
  48. hanzo-0.3.34/src/hanzo/tools/__init__.py +5 -0
  49. hanzo-0.3.34/src/hanzo/tools/detector.py +481 -0
  50. hanzo-0.3.34/src/hanzo/ui/__init__.py +8 -0
  51. hanzo-0.3.34/src/hanzo/ui/inline_startup.py +134 -0
  52. hanzo-0.3.34/src/hanzo/ui/startup.py +443 -0
  53. hanzo-0.3.18/.gitignore +0 -16
  54. hanzo-0.3.18/PKG-INFO +0 -137
  55. hanzo-0.3.18/README.md +0 -84
  56. hanzo-0.3.18/src/hanzo/commands/auth.py +0 -328
  57. hanzo-0.3.18/src/hanzo/commands/network.py +0 -342
  58. hanzo-0.3.18/src/hanzo/interactive/dashboard.py +0 -115
  59. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/__main__.py +0 -0
  60. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/commands/config.py +0 -0
  61. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/commands/miner.py +0 -0
  62. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/commands/tools.py +0 -0
  63. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/interactive/__init__.py +0 -0
  64. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/repl.py +0 -0
  65. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/utils/__init__.py +0 -0
  66. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/utils/config.py +0 -0
  67. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/utils/net_check.py +0 -0
  68. {hanzo-0.3.18 → hanzo-0.3.34}/src/hanzo/utils/output.py +0 -0
@@ -0,0 +1,63 @@
1
+ # IDE and editor
2
+ .vscode
3
+ .idea
4
+
5
+ # Python
6
+ *.egg-info
7
+ __pycache__
8
+ .mypy_cache
9
+ .pytest_cache
10
+ *.pyc
11
+ .venv
12
+
13
+ # Build
14
+ dist
15
+ _dev
16
+
17
+ # Environment
18
+ .env
19
+ .envrc
20
+
21
+ # Logs
22
+ .prism.log
23
+ codegen.log
24
+ *.log
25
+
26
+ # Package manager
27
+ Brewfile.lock.json
28
+
29
+ # Agent config files (symlinked from user home)
30
+ LLM.md
31
+ AGENTS.md
32
+ CLAUDE.md
33
+ GEMINI.md
34
+ GROK.md
35
+ QWEN.md
36
+
37
+ # Local databases and state
38
+ .hanzo/
39
+ .grok/
40
+
41
+ # Documentation build
42
+ docs/.next/
43
+ docs/out/
44
+ docs/node_modules/
45
+
46
+ # Training data and scripts (DO NOT COMMIT)
47
+ training_dataset.jsonl
48
+ scripts/full_extractor.py
49
+ scripts/mega_extractor.py
50
+ scripts/mega_full_extractor.py
51
+ scripts/streaming_extractor.py
52
+ scripts/supplement_extractor.py
53
+
54
+ # Test files at root (experimental)
55
+ test_post_quantum_*.py
56
+
57
+ # Analysis documents (internal)
58
+ HANZO_INNOVATION_OPPORTUNITIES.md
59
+ POST_QUANTUM_CRYPTOGRAPHY_IMPLEMENTATION.md
60
+
61
+ # Experimental cryptography (WIP)
62
+ pkg/hanzo/src/hanzo/cryptography/
63
+ site/
hanzo-0.3.34/PKG-INFO ADDED
@@ -0,0 +1,312 @@
1
+ Metadata-Version: 2.4
2
+ Name: hanzo
3
+ Version: 0.3.34
4
+ Summary: Hanzo AI - Complete AI Infrastructure Platform with CLI, Router, MCP, and Agent Runtime
5
+ Project-URL: Homepage, https://hanzo.ai
6
+ Project-URL: Repository, https://github.com/hanzoai/python-sdk
7
+ Project-URL: Documentation, https://docs.hanzo.ai/cli
8
+ Project-URL: Bug Tracker, https://github.com/hanzoai/python-sdk/issues
9
+ Author-email: Hanzo AI <dev@hanzo.ai>
10
+ Keywords: agents,ai,cli,hanzo,llm,local-ai,mcp,private-ai
11
+ Classifier: Development Status :: 4 - Beta
12
+ Classifier: Environment :: Console
13
+ Classifier: Intended Audience :: Developers
14
+ Classifier: License :: OSI Approved :: Apache Software License
15
+ Classifier: Operating System :: OS Independent
16
+ Classifier: Programming Language :: Python :: 3
17
+ Classifier: Programming Language :: Python :: 3.10
18
+ Classifier: Programming Language :: Python :: 3.11
19
+ Classifier: Programming Language :: Python :: 3.12
20
+ Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
21
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
22
+ Requires-Python: >=3.10
23
+ Requires-Dist: anthropic>=0.25.0
24
+ Requires-Dist: click>=8.1.0
25
+ Requires-Dist: httpx>=0.23.0
26
+ Requires-Dist: openai>=1.0.0
27
+ Requires-Dist: prompt-toolkit>=3.0.0
28
+ Requires-Dist: pydantic>=2.0.0
29
+ Requires-Dist: pyyaml>=6.0
30
+ Requires-Dist: qrcode>=7.4.2
31
+ Requires-Dist: rich>=13.0.0
32
+ Requires-Dist: typer>=0.9.0
33
+ Provides-Extra: agents
34
+ Requires-Dist: hanzo-agents>=0.1.0; extra == 'agents'
35
+ Requires-Dist: hanzo-network>=0.1.3; extra == 'agents'
36
+ Provides-Extra: ai
37
+ Requires-Dist: hanzoai>=1.0.0; extra == 'ai'
38
+ Provides-Extra: all
39
+ Requires-Dist: hanzo-aci>=0.2.8; extra == 'all'
40
+ Requires-Dist: hanzo-agents>=0.1.0; extra == 'all'
41
+ Requires-Dist: hanzo-mcp>=0.7.0; extra == 'all'
42
+ Requires-Dist: hanzo-memory>=1.0.0; extra == 'all'
43
+ Requires-Dist: hanzo-network>=0.1.3; extra == 'all'
44
+ Requires-Dist: hanzo-repl>=0.1.0; extra == 'all'
45
+ Requires-Dist: hanzoai>=1.0.0; extra == 'all'
46
+ Provides-Extra: cron
47
+ Requires-Dist: croniter>=2.0.0; extra == 'cron'
48
+ Requires-Dist: redis>=5.0.0; extra == 'cron'
49
+ Provides-Extra: dev
50
+ Requires-Dist: hanzo-aci>=0.2.8; extra == 'dev'
51
+ Provides-Extra: documentdb
52
+ Requires-Dist: motor>=3.3.0; extra == 'documentdb'
53
+ Requires-Dist: pymongo>=4.6.0; extra == 'documentdb'
54
+ Provides-Extra: functions
55
+ Requires-Dist: httpx>=0.23.0; extra == 'functions'
56
+ Provides-Extra: infra
57
+ Requires-Dist: aiobotocore>=2.9.0; extra == 'infra'
58
+ Requires-Dist: botocore>=1.34.0; extra == 'infra'
59
+ Requires-Dist: croniter>=2.0.0; extra == 'infra'
60
+ Requires-Dist: httpx>=0.23.0; extra == 'infra'
61
+ Requires-Dist: meilisearch-python-sdk>=3.0.0; extra == 'infra'
62
+ Requires-Dist: motor>=3.3.0; extra == 'infra'
63
+ Requires-Dist: nats-py>=2.6.0; extra == 'infra'
64
+ Requires-Dist: pymongo>=4.6.0; extra == 'infra'
65
+ Requires-Dist: qdrant-client>=1.7.0; extra == 'infra'
66
+ Requires-Dist: redis>=5.0.0; extra == 'infra'
67
+ Requires-Dist: temporalio>=1.4.0; extra == 'infra'
68
+ Provides-Extra: kv
69
+ Requires-Dist: redis>=5.0.0; extra == 'kv'
70
+ Provides-Extra: mcp
71
+ Requires-Dist: hanzo-mcp>=0.7.0; extra == 'mcp'
72
+ Provides-Extra: pubsub
73
+ Requires-Dist: nats-py>=2.6.0; extra == 'pubsub'
74
+ Provides-Extra: queues
75
+ Requires-Dist: redis>=5.0.0; extra == 'queues'
76
+ Provides-Extra: repl
77
+ Requires-Dist: hanzo-repl>=0.1.0; extra == 'repl'
78
+ Provides-Extra: router
79
+ Provides-Extra: search
80
+ Requires-Dist: meilisearch-python-sdk>=3.0.0; extra == 'search'
81
+ Provides-Extra: storage
82
+ Requires-Dist: aiobotocore>=2.9.0; extra == 'storage'
83
+ Requires-Dist: botocore>=1.34.0; extra == 'storage'
84
+ Provides-Extra: tasks
85
+ Requires-Dist: temporalio>=1.4.0; extra == 'tasks'
86
+ Provides-Extra: vector
87
+ Requires-Dist: qdrant-client>=1.7.0; extra == 'vector'
88
+ Description-Content-Type: text/markdown
89
+
90
+ # Hanzo CLI and Orchestration Tools
91
+
92
+ [![PyPI](https://img.shields.io/pypi/v/hanzo.svg)](https://pypi.org/project/hanzo/)
93
+ [![Python Version](https://img.shields.io/pypi/pyversions/hanzo.svg)](https://pypi.org/project/hanzo/)
94
+
95
+ Core CLI and orchestration tools for the Hanzo AI platform.
96
+
97
+ ## Installation
98
+
99
+ ```bash
100
+ pip install hanzo
101
+ ```
102
+
103
+ ## Features
104
+
105
+ - **Interactive Chat**: Chat with AI models through CLI
106
+ - **Node Management**: Run local AI inference nodes
107
+ - **Router Control**: Manage LLM proxy router
108
+ - **REPL Interface**: Interactive Python REPL with AI
109
+ - **Batch Orchestration**: Orchestrate multiple AI tasks
110
+ - **Memory Management**: Persistent conversation memory
111
+
112
+ ## Usage
113
+
114
+ ### CLI Commands
115
+
116
+ ```bash
117
+ # Interactive chat
118
+ hanzo chat
119
+
120
+ # Use specific model
121
+ hanzo chat --model gpt-4
122
+
123
+ # Use router (local proxy)
124
+ hanzo chat --router
125
+
126
+ # Use cloud API
127
+ hanzo chat --cloud
128
+ ```
129
+
130
+ ### Node Management
131
+
132
+ ```bash
133
+ # Start local node
134
+ hanzo node start
135
+
136
+ # Check status
137
+ hanzo node status
138
+
139
+ # List available models
140
+ hanzo node models
141
+
142
+ # Load specific model
143
+ hanzo node load llama2:7b
144
+
145
+ # Stop node
146
+ hanzo node stop
147
+ ```
148
+
149
+ ### Router Management
150
+
151
+ ```bash
152
+ # Start router proxy
153
+ hanzo router start
154
+
155
+ # Check router status
156
+ hanzo router status
157
+
158
+ # List available models
159
+ hanzo router models
160
+
161
+ # View configuration
162
+ hanzo router config
163
+
164
+ # Stop router
165
+ hanzo router stop
166
+ ```
167
+
168
+ ### Interactive REPL
169
+
170
+ ```bash
171
+ # Start REPL
172
+ hanzo repl
173
+
174
+ # In REPL:
175
+ > /help # Show help
176
+ > /models # List models
177
+ > /model gpt-4 # Switch model
178
+ > /clear # Clear context
179
+ > What is Python? # Ask questions
180
+ ```
181
+
182
+ ## Python API
183
+
184
+ ### Batch Orchestration
185
+
186
+ ```python
187
+ from hanzo.batch_orchestrator import BatchOrchestrator
188
+
189
+ orchestrator = BatchOrchestrator()
190
+ results = await orchestrator.run_batch([
191
+ "Summarize quantum computing",
192
+ "Explain machine learning",
193
+ "Define artificial intelligence"
194
+ ])
195
+ ```
196
+
197
+ ### Memory Management
198
+
199
+ ```python
200
+ from hanzo.memory_manager import MemoryManager
201
+
202
+ memory = MemoryManager()
203
+ memory.add_to_context("user", "What is Python?")
204
+ memory.add_to_context("assistant", "Python is...")
205
+ context = memory.get_context()
206
+ ```
207
+
208
+ ### Fallback Handling
209
+
210
+ ```python
211
+ from hanzo.fallback_handler import FallbackHandler
212
+
213
+ handler = FallbackHandler()
214
+ result = await handler.handle_with_fallback(
215
+ primary_fn=api_call,
216
+ fallback_fn=local_inference
217
+ )
218
+ ```
219
+
220
+ ## Configuration
221
+
222
+ ### Environment Variables
223
+
224
+ ```bash
225
+ # API settings
226
+ HANZO_API_KEY=your-api-key
227
+ HANZO_BASE_URL=https://api.hanzo.ai
228
+
229
+ # Router settings
230
+ HANZO_ROUTER_URL=http://localhost:4000/v1
231
+
232
+ # Node settings
233
+ HANZO_NODE_URL=http://localhost:8000/v1
234
+ HANZO_NODE_WORKERS=4
235
+
236
+ # Model preferences
237
+ HANZO_DEFAULT_MODEL=gpt-4
238
+ HANZO_FALLBACK_MODEL=llama2:7b
239
+ ```
240
+
241
+ ### Configuration File
242
+
243
+ Create `~/.hanzo/config.yaml`:
244
+
245
+ ```yaml
246
+ api:
247
+ key: your-api-key
248
+ base_url: https://api.hanzo.ai
249
+
250
+ router:
251
+ url: http://localhost:4000/v1
252
+ auto_start: true
253
+
254
+ node:
255
+ url: http://localhost:8000/v1
256
+ workers: 4
257
+ models:
258
+ - llama2:7b
259
+ - mistral:7b
260
+
261
+ models:
262
+ default: gpt-4
263
+ fallback: llama2:7b
264
+ ```
265
+
266
+ ## Architecture
267
+
268
+ ### Components
269
+
270
+ - **CLI**: Command-line interface (`cli.py`)
271
+ - **Chat**: Interactive chat interface (`commands/chat.py`)
272
+ - **Node**: Local AI node management (`commands/node.py`)
273
+ - **Router**: LLM proxy management (`commands/router.py`)
274
+ - **REPL**: Interactive Python REPL (`interactive/repl.py`)
275
+ - **Orchestrator**: Batch task orchestration (`batch_orchestrator.py`)
276
+ - **Memory**: Conversation memory (`memory_manager.py`)
277
+ - **Fallback**: Resilient API handling (`fallback_handler.py`)
278
+
279
+ ### Port Allocation
280
+
281
+ - **4000**: Router (LLM proxy)
282
+ - **8000**: Node (local AI)
283
+ - **9550-9553**: Desktop app integration
284
+
285
+ ## Development
286
+
287
+ ### Setup
288
+
289
+ ```bash
290
+ cd pkg/hanzo
291
+ uv sync --all-extras
292
+ ```
293
+
294
+ ### Testing
295
+
296
+ ```bash
297
+ # Run tests
298
+ pytest tests/
299
+
300
+ # With coverage
301
+ pytest tests/ --cov=hanzo
302
+ ```
303
+
304
+ ### Building
305
+
306
+ ```bash
307
+ uv build
308
+ ```
309
+
310
+ ## License
311
+
312
+ Apache License 2.0
hanzo-0.3.34/README.md ADDED
@@ -0,0 +1,223 @@
1
+ # Hanzo CLI and Orchestration Tools
2
+
3
+ [![PyPI](https://img.shields.io/pypi/v/hanzo.svg)](https://pypi.org/project/hanzo/)
4
+ [![Python Version](https://img.shields.io/pypi/pyversions/hanzo.svg)](https://pypi.org/project/hanzo/)
5
+
6
+ Core CLI and orchestration tools for the Hanzo AI platform.
7
+
8
+ ## Installation
9
+
10
+ ```bash
11
+ pip install hanzo
12
+ ```
13
+
14
+ ## Features
15
+
16
+ - **Interactive Chat**: Chat with AI models through CLI
17
+ - **Node Management**: Run local AI inference nodes
18
+ - **Router Control**: Manage LLM proxy router
19
+ - **REPL Interface**: Interactive Python REPL with AI
20
+ - **Batch Orchestration**: Orchestrate multiple AI tasks
21
+ - **Memory Management**: Persistent conversation memory
22
+
23
+ ## Usage
24
+
25
+ ### CLI Commands
26
+
27
+ ```bash
28
+ # Interactive chat
29
+ hanzo chat
30
+
31
+ # Use specific model
32
+ hanzo chat --model gpt-4
33
+
34
+ # Use router (local proxy)
35
+ hanzo chat --router
36
+
37
+ # Use cloud API
38
+ hanzo chat --cloud
39
+ ```
40
+
41
+ ### Node Management
42
+
43
+ ```bash
44
+ # Start local node
45
+ hanzo node start
46
+
47
+ # Check status
48
+ hanzo node status
49
+
50
+ # List available models
51
+ hanzo node models
52
+
53
+ # Load specific model
54
+ hanzo node load llama2:7b
55
+
56
+ # Stop node
57
+ hanzo node stop
58
+ ```
59
+
60
+ ### Router Management
61
+
62
+ ```bash
63
+ # Start router proxy
64
+ hanzo router start
65
+
66
+ # Check router status
67
+ hanzo router status
68
+
69
+ # List available models
70
+ hanzo router models
71
+
72
+ # View configuration
73
+ hanzo router config
74
+
75
+ # Stop router
76
+ hanzo router stop
77
+ ```
78
+
79
+ ### Interactive REPL
80
+
81
+ ```bash
82
+ # Start REPL
83
+ hanzo repl
84
+
85
+ # In REPL:
86
+ > /help # Show help
87
+ > /models # List models
88
+ > /model gpt-4 # Switch model
89
+ > /clear # Clear context
90
+ > What is Python? # Ask questions
91
+ ```
92
+
93
+ ## Python API
94
+
95
+ ### Batch Orchestration
96
+
97
+ ```python
98
+ from hanzo.batch_orchestrator import BatchOrchestrator
99
+
100
+ orchestrator = BatchOrchestrator()
101
+ results = await orchestrator.run_batch([
102
+ "Summarize quantum computing",
103
+ "Explain machine learning",
104
+ "Define artificial intelligence"
105
+ ])
106
+ ```
107
+
108
+ ### Memory Management
109
+
110
+ ```python
111
+ from hanzo.memory_manager import MemoryManager
112
+
113
+ memory = MemoryManager()
114
+ memory.add_to_context("user", "What is Python?")
115
+ memory.add_to_context("assistant", "Python is...")
116
+ context = memory.get_context()
117
+ ```
118
+
119
+ ### Fallback Handling
120
+
121
+ ```python
122
+ from hanzo.fallback_handler import FallbackHandler
123
+
124
+ handler = FallbackHandler()
125
+ result = await handler.handle_with_fallback(
126
+ primary_fn=api_call,
127
+ fallback_fn=local_inference
128
+ )
129
+ ```
130
+
131
+ ## Configuration
132
+
133
+ ### Environment Variables
134
+
135
+ ```bash
136
+ # API settings
137
+ HANZO_API_KEY=your-api-key
138
+ HANZO_BASE_URL=https://api.hanzo.ai
139
+
140
+ # Router settings
141
+ HANZO_ROUTER_URL=http://localhost:4000/v1
142
+
143
+ # Node settings
144
+ HANZO_NODE_URL=http://localhost:8000/v1
145
+ HANZO_NODE_WORKERS=4
146
+
147
+ # Model preferences
148
+ HANZO_DEFAULT_MODEL=gpt-4
149
+ HANZO_FALLBACK_MODEL=llama2:7b
150
+ ```
151
+
152
+ ### Configuration File
153
+
154
+ Create `~/.hanzo/config.yaml`:
155
+
156
+ ```yaml
157
+ api:
158
+ key: your-api-key
159
+ base_url: https://api.hanzo.ai
160
+
161
+ router:
162
+ url: http://localhost:4000/v1
163
+ auto_start: true
164
+
165
+ node:
166
+ url: http://localhost:8000/v1
167
+ workers: 4
168
+ models:
169
+ - llama2:7b
170
+ - mistral:7b
171
+
172
+ models:
173
+ default: gpt-4
174
+ fallback: llama2:7b
175
+ ```
176
+
177
+ ## Architecture
178
+
179
+ ### Components
180
+
181
+ - **CLI**: Command-line interface (`cli.py`)
182
+ - **Chat**: Interactive chat interface (`commands/chat.py`)
183
+ - **Node**: Local AI node management (`commands/node.py`)
184
+ - **Router**: LLM proxy management (`commands/router.py`)
185
+ - **REPL**: Interactive Python REPL (`interactive/repl.py`)
186
+ - **Orchestrator**: Batch task orchestration (`batch_orchestrator.py`)
187
+ - **Memory**: Conversation memory (`memory_manager.py`)
188
+ - **Fallback**: Resilient API handling (`fallback_handler.py`)
189
+
190
+ ### Port Allocation
191
+
192
+ - **4000**: Router (LLM proxy)
193
+ - **8000**: Node (local AI)
194
+ - **9550-9553**: Desktop app integration
195
+
196
+ ## Development
197
+
198
+ ### Setup
199
+
200
+ ```bash
201
+ cd pkg/hanzo
202
+ uv sync --all-extras
203
+ ```
204
+
205
+ ### Testing
206
+
207
+ ```bash
208
+ # Run tests
209
+ pytest tests/
210
+
211
+ # With coverage
212
+ pytest tests/ --cov=hanzo
213
+ ```
214
+
215
+ ### Building
216
+
217
+ ```bash
218
+ uv build
219
+ ```
220
+
221
+ ## License
222
+
223
+ Apache License 2.0
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "hanzo"
3
- version = "0.3.18"
3
+ version = "0.3.34"
4
4
  description = "Hanzo AI - Complete AI Infrastructure Platform with CLI, Router, MCP, and Agent Runtime"
5
5
  authors = [
6
6
  {name = "Hanzo AI", email = "dev@hanzo.ai"},
@@ -15,6 +15,7 @@ dependencies = [
15
15
  "pyyaml>=6.0",
16
16
  "openai>=1.0.0",
17
17
  "anthropic>=0.25.0",
18
+ "qrcode>=7.4.2",
18
19
  ]
19
20
  readme = "README.md"
20
21
  requires-python = ">= 3.10"
@@ -72,6 +73,32 @@ repl = [
72
73
  # "hanzo-router>=1.74.3", # TODO: For AI chat functionality - publish to PyPI
73
74
  ]
74
75
 
76
+ # Infrastructure extras - simple names
77
+ vector = ["qdrant-client>=1.7.0"]
78
+ kv = ["redis>=5.0.0"]
79
+ documentdb = ["motor>=3.3.0", "pymongo>=4.6.0"]
80
+ storage = ["aiobotocore>=2.9.0", "botocore>=1.34.0"]
81
+ search = ["meilisearch-python-sdk>=3.0.0"]
82
+ pubsub = ["nats-py>=2.6.0"]
83
+ tasks = ["temporalio>=1.4.0"]
84
+ queues = ["redis>=5.0.0"]
85
+ cron = ["redis>=5.0.0", "croniter>=2.0.0"]
86
+ functions = ["httpx>=0.23.0"]
87
+ # All infrastructure
88
+ infra = [
89
+ "qdrant-client>=1.7.0",
90
+ "redis>=5.0.0",
91
+ "motor>=3.3.0",
92
+ "pymongo>=4.6.0",
93
+ "aiobotocore>=2.9.0",
94
+ "botocore>=1.34.0",
95
+ "meilisearch-python-sdk>=3.0.0",
96
+ "nats-py>=2.6.0",
97
+ "temporalio>=1.4.0",
98
+ "croniter>=2.0.0",
99
+ "httpx>=0.23.0",
100
+ ]
101
+
75
102
  [project.urls]
76
103
  Homepage = "https://hanzo.ai"
77
104
  Repository = "https://github.com/hanzoai/python-sdk"
@@ -88,4 +115,4 @@ include = [
88
115
  ]
89
116
 
90
117
  [tool.hatch.build.targets.wheel]
91
- packages = ["src/hanzo"]
118
+ packages = ["src/hanzo"]
@@ -1,6 +1,6 @@
1
1
  """Hanzo - Complete AI Infrastructure Platform with CLI, Router, MCP, and Agent Runtime."""
2
2
 
3
- __version__ = "0.3.2"
4
- __all__ = ["main", "cli"]
3
+ __version__ = "0.3.34"
4
+ __all__ = ["main", "cli", "__version__"]
5
5
 
6
6
  from .cli import cli, main