agentnova 0.2.6__tar.gz → 0.3.1__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 (127) hide show
  1. agentnova-0.3.1/PKG-INFO +305 -0
  2. agentnova-0.3.1/README.md +271 -0
  3. agentnova-0.3.1/agentnova/__init__.py +145 -0
  4. agentnova-0.3.1/agentnova/__main__.py +12 -0
  5. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/acp_plugin.py +56 -348
  6. agentnova-0.3.1/agentnova/agent.py +981 -0
  7. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/agent_mode.py +19 -4
  8. agentnova-0.3.1/agentnova/backends/__init__.py +90 -0
  9. agentnova-0.3.1/agentnova/backends/base.py +182 -0
  10. agentnova-0.3.1/agentnova/backends/bitnet.py +233 -0
  11. agentnova-0.3.1/agentnova/backends/ollama.py +632 -0
  12. agentnova-0.3.1/agentnova/cli.py +1494 -0
  13. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/config.py +116 -27
  14. agentnova-0.3.1/agentnova/core/__init__.py +95 -0
  15. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/core/args_normal.py +20 -15
  16. agentnova-0.3.1/agentnova/core/helpers.py +809 -0
  17. agentnova-0.3.1/agentnova/core/memory.py +164 -0
  18. agentnova-0.3.1/agentnova/core/model_config.py +241 -0
  19. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/core/model_family_config.py +55 -129
  20. agentnova-0.3.1/agentnova/core/models.py +114 -0
  21. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/core/prompts.py +213 -5
  22. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/core/tool_parse.py +331 -16
  23. agentnova-0.3.1/agentnova/core/types.py +65 -0
  24. agentnova-0.3.1/agentnova/examples/00_basic_agent.py +72 -0
  25. agentnova-0.3.1/agentnova/examples/01_quick_diagnostic.py +193 -0
  26. agentnova-0.3.1/agentnova/examples/02_tool_test.py +283 -0
  27. agentnova-0.3.1/agentnova/examples/03_reasoning_test.py +277 -0
  28. agentnova-0.3.1/agentnova/examples/04_gsm8k_benchmark.py +229 -0
  29. agentnova-0.3.1/agentnova/examples/05_common_sense.py +385 -0
  30. agentnova-0.3.1/agentnova/examples/06_causal_reasoning.py +366 -0
  31. agentnova-0.3.1/agentnova/examples/07_logical_deduction.py +357 -0
  32. agentnova-0.3.1/agentnova/examples/08_reading_comprehension.py +418 -0
  33. agentnova-0.3.1/agentnova/examples/09_general_knowledge.py +377 -0
  34. agentnova-0.3.1/agentnova/examples/10_implicit_reasoning.py +356 -0
  35. agentnova-0.3.1/agentnova/examples/11_analogical_reasoning.py +363 -0
  36. agentnova-0.3.1/agentnova/examples/__init__.py +21 -0
  37. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/model_discovery.py +98 -106
  38. agentnova-0.3.1/agentnova/orchestrator.py +205 -0
  39. {agentnova-0.2.6/agentnova/core → agentnova-0.3.1/agentnova}/orchestrator_enhanced.py +54 -54
  40. agentnova-0.3.1/agentnova/py.typed +2 -0
  41. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/shared_args.py +24 -2
  42. agentnova-0.3.1/agentnova/skills/web-search/SKILL.md +74 -0
  43. agentnova-0.3.1/agentnova/soul/___init___.py +97 -0
  44. agentnova-0.3.1/agentnova/soul/__init__.py +97 -0
  45. agentnova-0.3.1/agentnova/soul/loader.py +492 -0
  46. agentnova-0.3.1/agentnova/soul/types.py +262 -0
  47. agentnova-0.3.1/agentnova/souls/nova-helper/IDENTITY.md +33 -0
  48. agentnova-0.3.1/agentnova/souls/nova-helper/SOUL.md +62 -0
  49. agentnova-0.3.1/agentnova/souls/nova-helper/STYLE.md +75 -0
  50. agentnova-0.3.1/agentnova/souls/nova-helper/soul.json +30 -0
  51. agentnova-0.3.1/agentnova/tools/__init__.py +23 -0
  52. agentnova-0.3.1/agentnova/tools/builtins.py +412 -0
  53. agentnova-0.3.1/agentnova/tools/registry.py +183 -0
  54. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/tools/sandboxed_repl.py +68 -68
  55. agentnova-0.3.1/agentnova.egg-info/PKG-INFO +305 -0
  56. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova.egg-info/SOURCES.txt +35 -26
  57. agentnova-0.3.1/agentnova.egg-info/entry_points.txt +7 -0
  58. agentnova-0.3.1/localclaw/__init__.py +51 -0
  59. agentnova-0.3.1/localclaw-redirect/localclaw/__init__.py +76 -0
  60. {agentnova-0.2.6 → agentnova-0.3.1}/pyproject.toml +15 -15
  61. {agentnova-0.2.6 → agentnova-0.3.1}/tests/test_acp_integration.py +24 -18
  62. {agentnova-0.2.6 → agentnova-0.3.1}/tests/test_acp_subagents.py +16 -30
  63. agentnova-0.3.1/tests/test_agent.py +272 -0
  64. agentnova-0.2.6/PKG-INFO +0 -360
  65. agentnova-0.2.6/README.md +0 -324
  66. agentnova-0.2.6/agentnova/__init__.py +0 -212
  67. agentnova-0.2.6/agentnova/__main__.py +0 -27
  68. agentnova-0.2.6/agentnova/bitnet_client.py +0 -151
  69. agentnova-0.2.6/agentnova/bitnet_setup.py +0 -30
  70. agentnova-0.2.6/agentnova/cli.py +0 -2702
  71. agentnova-0.2.6/agentnova/core/agent.py +0 -1342
  72. agentnova-0.2.6/agentnova/core/helpers.py +0 -337
  73. agentnova-0.2.6/agentnova/core/memory.py +0 -191
  74. agentnova-0.2.6/agentnova/core/models.py +0 -47
  75. agentnova-0.2.6/agentnova/core/ollama_client.py +0 -553
  76. agentnova-0.2.6/agentnova/core/orchestrator.py +0 -191
  77. agentnova-0.2.6/agentnova/core/tools.py +0 -304
  78. agentnova-0.2.6/agentnova/core/types.py +0 -11
  79. agentnova-0.2.6/agentnova/examples/00_backend_demo.py +0 -211
  80. agentnova-0.2.6/agentnova/examples/01_basic_agent.py +0 -182
  81. agentnova-0.2.6/agentnova/examples/02_tool_agent.py +0 -276
  82. agentnova-0.2.6/agentnova/examples/03_orchestrator.py +0 -209
  83. agentnova-0.2.6/agentnova/examples/04_comprehensive_test.py +0 -267
  84. agentnova-0.2.6/agentnova/examples/05_tool_tests.py +0 -494
  85. agentnova-0.2.6/agentnova/examples/06_interactive_chat.py +0 -216
  86. agentnova-0.2.6/agentnova/examples/07_model_comparison.py +0 -534
  87. agentnova-0.2.6/agentnova/examples/08_robust_comparison.py +0 -531
  88. agentnova-0.2.6/agentnova/examples/09_expanded_benchmark.py +0 -412
  89. agentnova-0.2.6/agentnova/examples/10_skills_demo.py +0 -366
  90. agentnova-0.2.6/agentnova/examples/11_skill_creator_test.py +0 -525
  91. agentnova-0.2.6/agentnova/examples/12_batch_operations.py +0 -214
  92. agentnova-0.2.6/agentnova/examples/13_shutdown_demo.py +0 -191
  93. agentnova-0.2.6/agentnova/examples/14_gsm8k_benchmark.py +0 -428
  94. agentnova-0.2.6/agentnova/examples/15_quick_diagnostic.py +0 -296
  95. agentnova-0.2.6/agentnova/examples/16_agent_mode_test.py +0 -582
  96. agentnova-0.2.6/agentnova/skills/web_search/SKILL.md +0 -138
  97. agentnova-0.2.6/agentnova/tools/builtins.py +0 -713
  98. agentnova-0.2.6/agentnova.egg-info/PKG-INFO +0 -360
  99. agentnova-0.2.6/agentnova.egg-info/entry_points.txt +0 -6
  100. agentnova-0.2.6/localclaw/__init__.py +0 -115
  101. agentnova-0.2.6/localclaw/__main__.py +0 -23
  102. agentnova-0.2.6/tests/test_agent.py +0 -266
  103. {agentnova-0.2.6 → agentnova-0.3.1}/LICENSE +0 -0
  104. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/core/math_prompts.py +0 -0
  105. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/__init__.py +0 -0
  106. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/acp/SKILL.md +0 -0
  107. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/datetime/SKILL.md +0 -0
  108. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/loader.py +0 -0
  109. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/skill-creator/SKILL.md +0 -0
  110. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/skill-creator/scripts/__init__.py +0 -0
  111. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/skill-creator/scripts/aggregate_benchmark.py +0 -0
  112. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/skill-creator/scripts/generate_report.py +0 -0
  113. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/skill-creator/scripts/improve_description.py +0 -0
  114. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/skill-creator/scripts/init_skill.py +0 -0
  115. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/skill-creator/scripts/package_skill.py +0 -0
  116. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/skill-creator/scripts/quick_validate.py +0 -0
  117. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/skill-creator/scripts/run_eval.py +0 -0
  118. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/skill-creator/scripts/run_loop.py +0 -0
  119. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/skill-creator/scripts/security_scan.py +0 -0
  120. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/skill-creator/scripts/test_package_skill.py +0 -0
  121. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/skill-creator/scripts/test_quick_validate.py +0 -0
  122. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/skill-creator/scripts/utils.py +0 -0
  123. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova/skills/skill-creator/scripts/validate.py +0 -0
  124. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova.egg-info/dependency_links.txt +0 -0
  125. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova.egg-info/requires.txt +0 -0
  126. {agentnova-0.2.6 → agentnova-0.3.1}/agentnova.egg-info/top_level.txt +0 -0
  127. {agentnova-0.2.6 → agentnova-0.3.1}/setup.cfg +0 -0
@@ -0,0 +1,305 @@
1
+ Metadata-Version: 2.4
2
+ Name: agentnova
3
+ Version: 0.3.1
4
+ Summary: ⚛️ AgentNova - A minimal, hackable agentic framework for local LLM inference
5
+ Author-email: VTSTech <veritas@vts-tech.org>
6
+ Maintainer-email: VTSTech <veritas@vts-tech.org>
7
+ License: MIT
8
+ Project-URL: Homepage, https://www.vts-tech.org
9
+ Project-URL: Documentation, https://github.com/VTSTech/AgentNova#readme
10
+ Project-URL: Repository, https://github.com/VTSTech/AgentNova
11
+ Project-URL: Issues, https://github.com/VTSTech/AgentNova/issues
12
+ Keywords: llm,agent,ollama,bitnet,local-inference,tool-calling,react,autonomous,agentic,ai-agent
13
+ Classifier: Development Status :: 3 - Alpha
14
+ Classifier: Environment :: Console
15
+ Classifier: Intended Audience :: Developers
16
+ Classifier: Intended Audience :: Science/Research
17
+ Classifier: License :: OSI Approved :: MIT License
18
+ Classifier: Operating System :: OS Independent
19
+ Classifier: Programming Language :: Python :: 3
20
+ Classifier: Programming Language :: Python :: 3.9
21
+ Classifier: Programming Language :: Python :: 3.10
22
+ Classifier: Programming Language :: Python :: 3.11
23
+ Classifier: Programming Language :: Python :: 3.12
24
+ Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
25
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
26
+ Requires-Python: >=3.9
27
+ Description-Content-Type: text/markdown
28
+ License-File: LICENSE
29
+ Provides-Extra: dev
30
+ Requires-Dist: pytest>=7.0; extra == "dev"
31
+ Requires-Dist: black>=23.0; extra == "dev"
32
+ Requires-Dist: ruff>=0.1.0; extra == "dev"
33
+ Dynamic: license-file
34
+
35
+ # ⚛️ AgentNova R03.1
36
+
37
+ **Status: Alpha**
38
+
39
+ A minimal, hackable agentic framework engineered to run **entirely locally** with [Ollama](https://ollama.com) or [BitNet](https://github.com/microsoft/BitNet).
40
+
41
+ Inspired by the architecture of OpenClaw, rebuilt from scratch for local-first operation.
42
+
43
+ **Written by [VTSTech](https://www.vts-tech.org)** · [GitHub](https://github.com/VTSTech/AgentNova)
44
+
45
+ [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/VTSTech/AgentNova/blob/main/AgentNova.ipynb)
46
+ [![GitHub commits](https://badgen.net/github/commits/VTSTech/AgentNova)](https://GitHub.com/VTSTech/AgentNova/commit/) [![GitHub latest commit](https://badgen.net/github/last-commit/VTSTech/AgentNova)](https://GitHub.com/VTSTech/AgentNova/commit/)
47
+
48
+ [![pip - agentnova](https://img.shields.io/badge/pip-agentnova-2ea44f?logo=PyPi)](https://pypi.org/project/agentnova/) [![PyPI version fury.io](https://badge.fury.io/py/agentnova.svg)](https://pypi.org/project/agentnova/) [![PyPI download month](https://img.shields.io/pypi/dm/agentnova.svg)](https://pypi.org/project/agentnova/) [![PyPI download day](https://img.shields.io/pypi/dd/agentnova.svg)](https://pypi.org/project/agentnova/)
49
+
50
+ [![License](https://img.shields.io/badge/License-MIT-blue)](#license) [![Go to Python website](https://img.shields.io/badge/dynamic/toml?url=https%3A%2F%2Fraw.githubusercontent.com%2FVTSTech%2FAgentNova%2Frefs%2Fheads%2Fmain%2Fpyproject.toml&query=project.requires-python&label=python&logo=python&logoColor=white)](https://python.org)
51
+
52
+ <img width="801" height="603" alt="image" src="https://github.com/user-attachments/assets/457acc38-231f-4d75-aec6-fa4897fbbb88" />
53
+
54
+ ---
55
+
56
+ ## 📚 Documentation
57
+
58
+ | Document | Description |
59
+ |----------|-------------|
60
+ | [Architecture.md](https://github.com/VTSTech/AgentNova/blob/main/Architecture.md) | Technical documentation for developers (directory structure, core design, orchestrator modes) |
61
+ | [CHANGELOG.md](https://github.com/VTSTech/AgentNova/blob/main/CHANGELOG.md) | Version history and release notes (includes LocalClaw history) |
62
+ | [TESTS.md](https://github.com/VTSTech/AgentNova/blob/main/TESTS.md) | Benchmark results, model recommendations, and testing guide |
63
+
64
+ ## Features
65
+
66
+ - **Zero dependencies** — Uses Python stdlib only (urllib for HTTP)
67
+ - **Ollama + BitNet backends** — Switch with `--backend` flag
68
+ - **Three-tier tool support** — Native, ReAct, or none (auto-detected)
69
+ - **Small model optimized** — Fuzzy matching, argument normalization
70
+ - **Built-in security** — Path validation, command blocklist, SSRF protection
71
+ - **Multi-agent orchestration** — Router, pipeline, and parallel modes
72
+
73
+ ## Installation
74
+
75
+ ```bash
76
+ # From source
77
+ git clone https://github.com/VTSTech/AgentNova.git
78
+ cd AgentNova
79
+ pip install -e .
80
+
81
+ # Or from PyPI (when published)
82
+ pip install agentnova
83
+ ```
84
+
85
+ ## Quick Start
86
+
87
+ ### CLI Usage
88
+
89
+ ```bash
90
+ # Run a single prompt
91
+ agentnova run "What is 15 * 8?" --tools calculator
92
+
93
+ # Interactive chat
94
+ agentnova chat -m qwen2.5:0.5b --tools calculator,shell
95
+
96
+ # Autonomous agent mode
97
+ agentnova agent -m qwen2.5:7b --tools calculator,shell,write_file
98
+
99
+ # List available models
100
+ agentnova models
101
+
102
+ # List available tools
103
+ agentnova tools
104
+ ```
105
+
106
+ ### Python API
107
+
108
+ ```python
109
+ from agentnova import Agent
110
+ from agentnova.tools import make_builtin_registry
111
+
112
+ # Create tools
113
+ tools = make_builtin_registry().subset(["calculator", "shell"])
114
+
115
+ # Create agent
116
+ agent = Agent(
117
+ model="qwen2.5:0.5b",
118
+ tools=tools,
119
+ backend="ollama",
120
+ )
121
+
122
+ # Run
123
+ result = agent.run("What is 15 * 8?")
124
+ print(result.final_answer)
125
+ print(f"Completed in {result.total_ms:.0f}ms")
126
+ ```
127
+
128
+ ### Multi-Agent Orchestration
129
+
130
+ ```python
131
+ from agentnova import Agent, Orchestrator, AgentCard
132
+
133
+ orchestrator = Orchestrator(mode="router")
134
+
135
+ # Register specialized agents
136
+ orchestrator.register(AgentCard(
137
+ name="math_agent",
138
+ description="Handles mathematical calculations",
139
+ capabilities=["calculate", "math", "compute"],
140
+ tools=["calculator"],
141
+ ))
142
+
143
+ orchestrator.register(AgentCard(
144
+ name="file_agent",
145
+ description="Handles file operations",
146
+ capabilities=["read", "write", "file"],
147
+ tools=["read_file", "write_file"],
148
+ ))
149
+
150
+ # Route tasks to appropriate agent
151
+ result = orchestrator.run("Calculate 15 * 8 and save to file")
152
+ ```
153
+
154
+ ## Tool Support Levels
155
+
156
+ AgentNova supports three levels of tool use:
157
+
158
+ 1. **Native** — Models with built-in function calling (qwen2.5, llama3.1+, mistral, granite, functiongemma)
159
+ 2. **ReAct** — Text-based tool use via reasoning prompts (qwen2.5-coder, qwen3)
160
+ 3. **None** — Pure reasoning without tools
161
+
162
+ Tool support is auto-detected by running `agentnova models --tool-support`. Results are cached in `~/.cache/agentnova/tool_support.json`.
163
+
164
+ ```bash
165
+ # Test and cache tool support for all models
166
+ agentnova models --tool-support
167
+
168
+ # Re-test (ignore cache)
169
+ agentnova models --tool-support --no-cache
170
+ ```
171
+
172
+ You can also force ReAct mode:
173
+
174
+ ```python
175
+ agent = Agent(model="qwen2.5:0.5b", force_react=True)
176
+ ```
177
+
178
+ ## Model Families
179
+
180
+ Configured model families with optimized prompts:
181
+
182
+ - **qwen2.5** — Native tool support, excellent performance
183
+ - **llama3.1/3.2/3.3** — Native tool support
184
+ - **mistral/mixtral** — Native tool support
185
+ - **gemma2/gemma3** — ReAct mode, special prompting
186
+ - **granite/granitemoe** — Native tool support
187
+ - **phi3** — Native tool support
188
+ - **deepseek** — Native with `<think/>` tag handling
189
+
190
+ ## Security Features
191
+
192
+ Built-in security for safe operation:
193
+
194
+ - **Command blocklist** — Blocks dangerous shell commands (rm, sudo, etc.)
195
+ - **Path validation** — Prevents access to sensitive directories
196
+ - **SSRF protection** — Blocks requests to local/internal URLs
197
+ - **Injection detection** — Detects shell injection patterns
198
+
199
+ ## Configuration
200
+
201
+ Environment variables:
202
+
203
+ ```bash
204
+ # Backend URLs
205
+ OLLAMA_BASE_URL=https://your-ollama-server.com # Default: http://localhost:11434
206
+ BITNET_BASE_URL=http://localhost:8765 # BitNet server URL
207
+ BITNET_TUNNEL=https://your-tunnel.com # Alternative BitNet URL
208
+ ACP_BASE_URL=http://localhost:8766 # ACP server URL
209
+
210
+ # Agent settings
211
+ AGENTNOVA_BACKEND=ollama # Default backend: ollama or bitnet
212
+ AGENTNOVA_MODEL=qwen2.5:0.5b # Default model
213
+ AGENTNOVA_MAX_STEPS=10 # Maximum reasoning steps
214
+ AGENTNOVA_DEBUG=false # Enable debug output
215
+ ```
216
+
217
+ Check current configuration:
218
+ ```bash
219
+ agentnova config
220
+ agentnova config --urls # Show only URLs
221
+ ```
222
+
223
+ ## LocalClaw Redirect
224
+
225
+ The `localclaw` command is provided for backward compatibility:
226
+
227
+ ```bash
228
+ # Both work identically
229
+ localclaw run "What is 2+2?"
230
+ agentnova run "What is 2+2?"
231
+ ```
232
+
233
+ ## Tests & Examples
234
+
235
+ AgentNova includes a suite of tests for validating agent capabilities:
236
+
237
+ ```bash
238
+ # Basic agent test (no tools)
239
+ python -m agentnova.examples.00_basic_agent
240
+
241
+ # Quick 5-question diagnostic
242
+ python -m agentnova.examples.01_quick_diagnostic
243
+
244
+ # Tool usage tests (calculator, shell, datetime)
245
+ python -m agentnova.examples.02_tool_test
246
+
247
+ # Logic and reasoning tests (BBH-style)
248
+ python -m agentnova.examples.03_reasoning_test
249
+
250
+ # GSM8K math benchmark (50 questions)
251
+ python -m agentnova.examples.04_gsm8k_benchmark
252
+ ```
253
+
254
+ ### Test Categories
255
+
256
+ | Test | Questions | Focus |
257
+ |------|-----------|-------|
258
+ | Quick Diagnostic | 5 | Calculator tool, multi-step reasoning |
259
+ | Tool Test | 10 | Calculator, shell, datetime tools |
260
+ | Reasoning Test | 13 | Logic, deduction, patterns, spatial |
261
+ | GSM8K Benchmark | 50 | Math word problems |
262
+
263
+ ### Benchmark Results (Quick Diagnostic)
264
+
265
+ | Model | Score | Time | Tool Support |
266
+ |-------|-------|------|-------------|
267
+ | functiongemma:270m | 5/5 (100%) | ~20s | native |
268
+ | granite4:350m | 5/5 (100%) | ~50s | native |
269
+ | qwen2.5:0.5b | 5/5 (100%) | 38s | native |
270
+ | qwen2.5-coder:0.5b | 5/5 (100%) | 93s | react |
271
+ | qwen3:0.6b | 5/5 (100%) | 70s | react |
272
+
273
+ All tested models achieve 100% on the Quick Diagnostic. Native models are ~2x faster than ReAct models due to direct API tool calling.
274
+
275
+ ## Development
276
+
277
+ ```bash
278
+ # Install dev dependencies
279
+ pip install -e ".[dev]"
280
+
281
+ # Run unit tests
282
+ pytest
283
+
284
+ # Format code
285
+ black agentnova
286
+ ruff check agentnova
287
+ ```
288
+
289
+ ## License
290
+
291
+ MIT License - See LICENSE file for details.
292
+
293
+ ## Author
294
+
295
+ **VTSTech** — [https://www.vts-tech.org](https://www.vts-tech.org)
296
+
297
+ ## Contributing
298
+
299
+ Contributions welcome! Please read the contributing guidelines first.
300
+
301
+ ## Acknowledgments
302
+
303
+ - Built for local inference with [Ollama](https://ollama.ai)
304
+ - Optimized for small, efficient models
305
+ - Inspired by ReAct and other agentic frameworks
@@ -0,0 +1,271 @@
1
+ # ⚛️ AgentNova R03.1
2
+
3
+ **Status: Alpha**
4
+
5
+ A minimal, hackable agentic framework engineered to run **entirely locally** with [Ollama](https://ollama.com) or [BitNet](https://github.com/microsoft/BitNet).
6
+
7
+ Inspired by the architecture of OpenClaw, rebuilt from scratch for local-first operation.
8
+
9
+ **Written by [VTSTech](https://www.vts-tech.org)** · [GitHub](https://github.com/VTSTech/AgentNova)
10
+
11
+ [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/VTSTech/AgentNova/blob/main/AgentNova.ipynb)
12
+ [![GitHub commits](https://badgen.net/github/commits/VTSTech/AgentNova)](https://GitHub.com/VTSTech/AgentNova/commit/) [![GitHub latest commit](https://badgen.net/github/last-commit/VTSTech/AgentNova)](https://GitHub.com/VTSTech/AgentNova/commit/)
13
+
14
+ [![pip - agentnova](https://img.shields.io/badge/pip-agentnova-2ea44f?logo=PyPi)](https://pypi.org/project/agentnova/) [![PyPI version fury.io](https://badge.fury.io/py/agentnova.svg)](https://pypi.org/project/agentnova/) [![PyPI download month](https://img.shields.io/pypi/dm/agentnova.svg)](https://pypi.org/project/agentnova/) [![PyPI download day](https://img.shields.io/pypi/dd/agentnova.svg)](https://pypi.org/project/agentnova/)
15
+
16
+ [![License](https://img.shields.io/badge/License-MIT-blue)](#license) [![Go to Python website](https://img.shields.io/badge/dynamic/toml?url=https%3A%2F%2Fraw.githubusercontent.com%2FVTSTech%2FAgentNova%2Frefs%2Fheads%2Fmain%2Fpyproject.toml&query=project.requires-python&label=python&logo=python&logoColor=white)](https://python.org)
17
+
18
+ <img width="801" height="603" alt="image" src="https://github.com/user-attachments/assets/457acc38-231f-4d75-aec6-fa4897fbbb88" />
19
+
20
+ ---
21
+
22
+ ## 📚 Documentation
23
+
24
+ | Document | Description |
25
+ |----------|-------------|
26
+ | [Architecture.md](https://github.com/VTSTech/AgentNova/blob/main/Architecture.md) | Technical documentation for developers (directory structure, core design, orchestrator modes) |
27
+ | [CHANGELOG.md](https://github.com/VTSTech/AgentNova/blob/main/CHANGELOG.md) | Version history and release notes (includes LocalClaw history) |
28
+ | [TESTS.md](https://github.com/VTSTech/AgentNova/blob/main/TESTS.md) | Benchmark results, model recommendations, and testing guide |
29
+
30
+ ## Features
31
+
32
+ - **Zero dependencies** — Uses Python stdlib only (urllib for HTTP)
33
+ - **Ollama + BitNet backends** — Switch with `--backend` flag
34
+ - **Three-tier tool support** — Native, ReAct, or none (auto-detected)
35
+ - **Small model optimized** — Fuzzy matching, argument normalization
36
+ - **Built-in security** — Path validation, command blocklist, SSRF protection
37
+ - **Multi-agent orchestration** — Router, pipeline, and parallel modes
38
+
39
+ ## Installation
40
+
41
+ ```bash
42
+ # From source
43
+ git clone https://github.com/VTSTech/AgentNova.git
44
+ cd AgentNova
45
+ pip install -e .
46
+
47
+ # Or from PyPI (when published)
48
+ pip install agentnova
49
+ ```
50
+
51
+ ## Quick Start
52
+
53
+ ### CLI Usage
54
+
55
+ ```bash
56
+ # Run a single prompt
57
+ agentnova run "What is 15 * 8?" --tools calculator
58
+
59
+ # Interactive chat
60
+ agentnova chat -m qwen2.5:0.5b --tools calculator,shell
61
+
62
+ # Autonomous agent mode
63
+ agentnova agent -m qwen2.5:7b --tools calculator,shell,write_file
64
+
65
+ # List available models
66
+ agentnova models
67
+
68
+ # List available tools
69
+ agentnova tools
70
+ ```
71
+
72
+ ### Python API
73
+
74
+ ```python
75
+ from agentnova import Agent
76
+ from agentnova.tools import make_builtin_registry
77
+
78
+ # Create tools
79
+ tools = make_builtin_registry().subset(["calculator", "shell"])
80
+
81
+ # Create agent
82
+ agent = Agent(
83
+ model="qwen2.5:0.5b",
84
+ tools=tools,
85
+ backend="ollama",
86
+ )
87
+
88
+ # Run
89
+ result = agent.run("What is 15 * 8?")
90
+ print(result.final_answer)
91
+ print(f"Completed in {result.total_ms:.0f}ms")
92
+ ```
93
+
94
+ ### Multi-Agent Orchestration
95
+
96
+ ```python
97
+ from agentnova import Agent, Orchestrator, AgentCard
98
+
99
+ orchestrator = Orchestrator(mode="router")
100
+
101
+ # Register specialized agents
102
+ orchestrator.register(AgentCard(
103
+ name="math_agent",
104
+ description="Handles mathematical calculations",
105
+ capabilities=["calculate", "math", "compute"],
106
+ tools=["calculator"],
107
+ ))
108
+
109
+ orchestrator.register(AgentCard(
110
+ name="file_agent",
111
+ description="Handles file operations",
112
+ capabilities=["read", "write", "file"],
113
+ tools=["read_file", "write_file"],
114
+ ))
115
+
116
+ # Route tasks to appropriate agent
117
+ result = orchestrator.run("Calculate 15 * 8 and save to file")
118
+ ```
119
+
120
+ ## Tool Support Levels
121
+
122
+ AgentNova supports three levels of tool use:
123
+
124
+ 1. **Native** — Models with built-in function calling (qwen2.5, llama3.1+, mistral, granite, functiongemma)
125
+ 2. **ReAct** — Text-based tool use via reasoning prompts (qwen2.5-coder, qwen3)
126
+ 3. **None** — Pure reasoning without tools
127
+
128
+ Tool support is auto-detected by running `agentnova models --tool-support`. Results are cached in `~/.cache/agentnova/tool_support.json`.
129
+
130
+ ```bash
131
+ # Test and cache tool support for all models
132
+ agentnova models --tool-support
133
+
134
+ # Re-test (ignore cache)
135
+ agentnova models --tool-support --no-cache
136
+ ```
137
+
138
+ You can also force ReAct mode:
139
+
140
+ ```python
141
+ agent = Agent(model="qwen2.5:0.5b", force_react=True)
142
+ ```
143
+
144
+ ## Model Families
145
+
146
+ Configured model families with optimized prompts:
147
+
148
+ - **qwen2.5** — Native tool support, excellent performance
149
+ - **llama3.1/3.2/3.3** — Native tool support
150
+ - **mistral/mixtral** — Native tool support
151
+ - **gemma2/gemma3** — ReAct mode, special prompting
152
+ - **granite/granitemoe** — Native tool support
153
+ - **phi3** — Native tool support
154
+ - **deepseek** — Native with `<think/>` tag handling
155
+
156
+ ## Security Features
157
+
158
+ Built-in security for safe operation:
159
+
160
+ - **Command blocklist** — Blocks dangerous shell commands (rm, sudo, etc.)
161
+ - **Path validation** — Prevents access to sensitive directories
162
+ - **SSRF protection** — Blocks requests to local/internal URLs
163
+ - **Injection detection** — Detects shell injection patterns
164
+
165
+ ## Configuration
166
+
167
+ Environment variables:
168
+
169
+ ```bash
170
+ # Backend URLs
171
+ OLLAMA_BASE_URL=https://your-ollama-server.com # Default: http://localhost:11434
172
+ BITNET_BASE_URL=http://localhost:8765 # BitNet server URL
173
+ BITNET_TUNNEL=https://your-tunnel.com # Alternative BitNet URL
174
+ ACP_BASE_URL=http://localhost:8766 # ACP server URL
175
+
176
+ # Agent settings
177
+ AGENTNOVA_BACKEND=ollama # Default backend: ollama or bitnet
178
+ AGENTNOVA_MODEL=qwen2.5:0.5b # Default model
179
+ AGENTNOVA_MAX_STEPS=10 # Maximum reasoning steps
180
+ AGENTNOVA_DEBUG=false # Enable debug output
181
+ ```
182
+
183
+ Check current configuration:
184
+ ```bash
185
+ agentnova config
186
+ agentnova config --urls # Show only URLs
187
+ ```
188
+
189
+ ## LocalClaw Redirect
190
+
191
+ The `localclaw` command is provided for backward compatibility:
192
+
193
+ ```bash
194
+ # Both work identically
195
+ localclaw run "What is 2+2?"
196
+ agentnova run "What is 2+2?"
197
+ ```
198
+
199
+ ## Tests & Examples
200
+
201
+ AgentNova includes a suite of tests for validating agent capabilities:
202
+
203
+ ```bash
204
+ # Basic agent test (no tools)
205
+ python -m agentnova.examples.00_basic_agent
206
+
207
+ # Quick 5-question diagnostic
208
+ python -m agentnova.examples.01_quick_diagnostic
209
+
210
+ # Tool usage tests (calculator, shell, datetime)
211
+ python -m agentnova.examples.02_tool_test
212
+
213
+ # Logic and reasoning tests (BBH-style)
214
+ python -m agentnova.examples.03_reasoning_test
215
+
216
+ # GSM8K math benchmark (50 questions)
217
+ python -m agentnova.examples.04_gsm8k_benchmark
218
+ ```
219
+
220
+ ### Test Categories
221
+
222
+ | Test | Questions | Focus |
223
+ |------|-----------|-------|
224
+ | Quick Diagnostic | 5 | Calculator tool, multi-step reasoning |
225
+ | Tool Test | 10 | Calculator, shell, datetime tools |
226
+ | Reasoning Test | 13 | Logic, deduction, patterns, spatial |
227
+ | GSM8K Benchmark | 50 | Math word problems |
228
+
229
+ ### Benchmark Results (Quick Diagnostic)
230
+
231
+ | Model | Score | Time | Tool Support |
232
+ |-------|-------|------|-------------|
233
+ | functiongemma:270m | 5/5 (100%) | ~20s | native |
234
+ | granite4:350m | 5/5 (100%) | ~50s | native |
235
+ | qwen2.5:0.5b | 5/5 (100%) | 38s | native |
236
+ | qwen2.5-coder:0.5b | 5/5 (100%) | 93s | react |
237
+ | qwen3:0.6b | 5/5 (100%) | 70s | react |
238
+
239
+ All tested models achieve 100% on the Quick Diagnostic. Native models are ~2x faster than ReAct models due to direct API tool calling.
240
+
241
+ ## Development
242
+
243
+ ```bash
244
+ # Install dev dependencies
245
+ pip install -e ".[dev]"
246
+
247
+ # Run unit tests
248
+ pytest
249
+
250
+ # Format code
251
+ black agentnova
252
+ ruff check agentnova
253
+ ```
254
+
255
+ ## License
256
+
257
+ MIT License - See LICENSE file for details.
258
+
259
+ ## Author
260
+
261
+ **VTSTech** — [https://www.vts-tech.org](https://www.vts-tech.org)
262
+
263
+ ## Contributing
264
+
265
+ Contributions welcome! Please read the contributing guidelines first.
266
+
267
+ ## Acknowledgments
268
+
269
+ - Built for local inference with [Ollama](https://ollama.ai)
270
+ - Optimized for small, efficient models
271
+ - Inspired by ReAct and other agentic frameworks