aelvoxim 1.0.0__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 (192) hide show
  1. aelvoxim-1.0.0/LICENSE +21 -0
  2. aelvoxim-1.0.0/PKG-INFO +254 -0
  3. aelvoxim-1.0.0/README.md +217 -0
  4. aelvoxim-1.0.0/pyproject.toml +51 -0
  5. aelvoxim-1.0.0/setup.cfg +4 -0
  6. aelvoxim-1.0.0/src/aelvoxim/__init__.py +11 -0
  7. aelvoxim-1.0.0/src/aelvoxim/__main__.py +84 -0
  8. aelvoxim-1.0.0/src/aelvoxim/admin.py +120 -0
  9. aelvoxim-1.0.0/src/aelvoxim/api/API.html +743 -0
  10. aelvoxim-1.0.0/src/aelvoxim/api/__init__.py +195 -0
  11. aelvoxim-1.0.0/src/aelvoxim/chimera/__init__.py +17 -0
  12. aelvoxim-1.0.0/src/aelvoxim/chimera/emotion_engine.py +265 -0
  13. aelvoxim-1.0.0/src/aelvoxim/chimera/intent_classifier.py +178 -0
  14. aelvoxim-1.0.0/src/aelvoxim/chimera/models.py +150 -0
  15. aelvoxim-1.0.0/src/aelvoxim/chimera/routes.py +400 -0
  16. aelvoxim-1.0.0/src/aelvoxim/chimera/serpent_client.py +118 -0
  17. aelvoxim-1.0.0/src/aelvoxim/client/security_gate.py +569 -0
  18. aelvoxim-1.0.0/src/aelvoxim/client/sentrikit.py +343 -0
  19. aelvoxim-1.0.0/src/aelvoxim/control/__init__.py +0 -0
  20. aelvoxim-1.0.0/src/aelvoxim/control/controller.py +126 -0
  21. aelvoxim-1.0.0/src/aelvoxim/control/metacog_check.py +241 -0
  22. aelvoxim-1.0.0/src/aelvoxim/control/retry_queue.py +133 -0
  23. aelvoxim-1.0.0/src/aelvoxim/core/__init__.py +4 -0
  24. aelvoxim-1.0.0/src/aelvoxim/core/belief.py +394 -0
  25. aelvoxim-1.0.0/src/aelvoxim/core/calibration.py +477 -0
  26. aelvoxim-1.0.0/src/aelvoxim/core/cognitive.py +118 -0
  27. aelvoxim-1.0.0/src/aelvoxim/core/content_filter.py +134 -0
  28. aelvoxim-1.0.0/src/aelvoxim/core/dgmh.py +297 -0
  29. aelvoxim-1.0.0/src/aelvoxim/core/health.py +234 -0
  30. aelvoxim-1.0.0/src/aelvoxim/core/judge.py +352 -0
  31. aelvoxim-1.0.0/src/aelvoxim/core/metacog.py +479 -0
  32. aelvoxim-1.0.0/src/aelvoxim/core/metacog_monitor.py +302 -0
  33. aelvoxim-1.0.0/src/aelvoxim/core/reasoner.py +153 -0
  34. aelvoxim-1.0.0/src/aelvoxim/core/self_review/__init__.py +58 -0
  35. aelvoxim-1.0.0/src/aelvoxim/core/self_review/self_review_system.py +221 -0
  36. aelvoxim-1.0.0/src/aelvoxim/core/self_review/test_self_review.py +27 -0
  37. aelvoxim-1.0.0/src/aelvoxim/core/selfmodel.py +812 -0
  38. aelvoxim-1.0.0/src/aelvoxim/cortex/__init__.py +230 -0
  39. aelvoxim-1.0.0/src/aelvoxim/cortex/router.py +78 -0
  40. aelvoxim-1.0.0/src/aelvoxim/cortex/scheduler.py +147 -0
  41. aelvoxim-1.0.0/src/aelvoxim/experts/__init__.py +69 -0
  42. aelvoxim-1.0.0/src/aelvoxim/experts/base.py +74 -0
  43. aelvoxim-1.0.0/src/aelvoxim/experts/code_review.py +419 -0
  44. aelvoxim-1.0.0/src/aelvoxim/experts/creative.py +289 -0
  45. aelvoxim-1.0.0/src/aelvoxim/experts/emotion.py +266 -0
  46. aelvoxim-1.0.0/src/aelvoxim/experts/ethics.py +158 -0
  47. aelvoxim-1.0.0/src/aelvoxim/experts/introspection.py +147 -0
  48. aelvoxim-1.0.0/src/aelvoxim/experts/logic.py +276 -0
  49. aelvoxim-1.0.0/src/aelvoxim/experts/memory.py +251 -0
  50. aelvoxim-1.0.0/src/aelvoxim/experts/orchestrator.py +582 -0
  51. aelvoxim-1.0.0/src/aelvoxim/experts/router.py +177 -0
  52. aelvoxim-1.0.0/src/aelvoxim/experts/safety.py +209 -0
  53. aelvoxim-1.0.0/src/aelvoxim/experts/sub_agent.py +303 -0
  54. aelvoxim-1.0.0/src/aelvoxim/hooks/__init__.py +75 -0
  55. aelvoxim-1.0.0/src/aelvoxim/hooks/analyzer.py +215 -0
  56. aelvoxim-1.0.0/src/aelvoxim/hooks/tracker.py +202 -0
  57. aelvoxim-1.0.0/src/aelvoxim/learn/__init__.py +18 -0
  58. aelvoxim-1.0.0/src/aelvoxim/learn/active_scan.py +224 -0
  59. aelvoxim-1.0.0/src/aelvoxim/learn/autotune.py +278 -0
  60. aelvoxim-1.0.0/src/aelvoxim/learn/cleanup.py +65 -0
  61. aelvoxim-1.0.0/src/aelvoxim/learn/curiosity.py +174 -0
  62. aelvoxim-1.0.0/src/aelvoxim/learn/decompose.py +295 -0
  63. aelvoxim-1.0.0/src/aelvoxim/learn/direction.py +254 -0
  64. aelvoxim-1.0.0/src/aelvoxim/learn/discover.py +296 -0
  65. aelvoxim-1.0.0/src/aelvoxim/learn/discovery.py +93 -0
  66. aelvoxim-1.0.0/src/aelvoxim/learn/execute.py +244 -0
  67. aelvoxim-1.0.0/src/aelvoxim/learn/extract.py +390 -0
  68. aelvoxim-1.0.0/src/aelvoxim/learn/gap_analysis.py +179 -0
  69. aelvoxim-1.0.0/src/aelvoxim/learn/goals.py +227 -0
  70. aelvoxim-1.0.0/src/aelvoxim/learn/hypothesis.py +337 -0
  71. aelvoxim-1.0.0/src/aelvoxim/learn/intent.py +162 -0
  72. aelvoxim-1.0.0/src/aelvoxim/learn/knowledge.py +1640 -0
  73. aelvoxim-1.0.0/src/aelvoxim/learn/learner.py +17 -0
  74. aelvoxim-1.0.0/src/aelvoxim/learn/llm.py +987 -0
  75. aelvoxim-1.0.0/src/aelvoxim/learn/loop.py +1120 -0
  76. aelvoxim-1.0.0/src/aelvoxim/learn/meta_cog.py +247 -0
  77. aelvoxim-1.0.0/src/aelvoxim/learn/meta_learner.py +292 -0
  78. aelvoxim-1.0.0/src/aelvoxim/learn/monitor.py +739 -0
  79. aelvoxim-1.0.0/src/aelvoxim/learn/patches/__init__.py +0 -0
  80. aelvoxim-1.0.0/src/aelvoxim/learn/patches/knowledge_cache.py +31 -0
  81. aelvoxim-1.0.0/src/aelvoxim/learn/patches/learner_cache.py +50 -0
  82. aelvoxim-1.0.0/src/aelvoxim/learn/patches/validate_safe.py +103 -0
  83. aelvoxim-1.0.0/src/aelvoxim/learn/post_validation.py +794 -0
  84. aelvoxim-1.0.0/src/aelvoxim/learn/presets.py +173 -0
  85. aelvoxim-1.0.0/src/aelvoxim/learn/report.py +93 -0
  86. aelvoxim-1.0.0/src/aelvoxim/learn/review.py +63 -0
  87. aelvoxim-1.0.0/src/aelvoxim/learn/review_scheduler.py +180 -0
  88. aelvoxim-1.0.0/src/aelvoxim/learn/scheduler.py +264 -0
  89. aelvoxim-1.0.0/src/aelvoxim/learn/search.py +431 -0
  90. aelvoxim-1.0.0/src/aelvoxim/learn/teach.py +206 -0
  91. aelvoxim-1.0.0/src/aelvoxim/learn/unknown_discovery.py +231 -0
  92. aelvoxim-1.0.0/src/aelvoxim/learn/validate.py +300 -0
  93. aelvoxim-1.0.0/src/aelvoxim/learn/validator.py +883 -0
  94. aelvoxim-1.0.0/src/aelvoxim/memory/__init__.py +972 -0
  95. aelvoxim-1.0.0/src/aelvoxim/memory/conf_matrix.py +243 -0
  96. aelvoxim-1.0.0/src/aelvoxim/memory/conflict.py +183 -0
  97. aelvoxim-1.0.0/src/aelvoxim/memory/consolidator.py +199 -0
  98. aelvoxim-1.0.0/src/aelvoxim/memory/decay.py +187 -0
  99. aelvoxim-1.0.0/src/aelvoxim/memory/entry.py +142 -0
  100. aelvoxim-1.0.0/src/aelvoxim/memory/forget.py +68 -0
  101. aelvoxim-1.0.0/src/aelvoxim/memory/fusion.py +304 -0
  102. aelvoxim-1.0.0/src/aelvoxim/memory/layers/__init__.py +8 -0
  103. aelvoxim-1.0.0/src/aelvoxim/memory/layers/base.py +37 -0
  104. aelvoxim-1.0.0/src/aelvoxim/memory/layers/episodic.py +35 -0
  105. aelvoxim-1.0.0/src/aelvoxim/memory/layers/procedural.py +51 -0
  106. aelvoxim-1.0.0/src/aelvoxim/memory/layers/semantic.py +43 -0
  107. aelvoxim-1.0.0/src/aelvoxim/memory/layers/working.py +35 -0
  108. aelvoxim-1.0.0/src/aelvoxim/memory/prevalidation.py +242 -0
  109. aelvoxim-1.0.0/src/aelvoxim/memory/relation_decay.py +155 -0
  110. aelvoxim-1.0.0/src/aelvoxim/memory/scorer.py +271 -0
  111. aelvoxim-1.0.0/src/aelvoxim/memory/semantic.py +128 -0
  112. aelvoxim-1.0.0/src/aelvoxim/orchestrator/__init__.py +96 -0
  113. aelvoxim-1.0.0/src/aelvoxim/planner.py +354 -0
  114. aelvoxim-1.0.0/src/aelvoxim/proactive/__init__.py +1 -0
  115. aelvoxim-1.0.0/src/aelvoxim/proactive/detector.py +52 -0
  116. aelvoxim-1.0.0/src/aelvoxim/proactive/dispatcher.py +77 -0
  117. aelvoxim-1.0.0/src/aelvoxim/proactive/engine.py +102 -0
  118. aelvoxim-1.0.0/src/aelvoxim/proactive/feedback.py +68 -0
  119. aelvoxim-1.0.0/src/aelvoxim/proactive/gate.py +77 -0
  120. aelvoxim-1.0.0/src/aelvoxim/proactive/predictor.py +48 -0
  121. aelvoxim-1.0.0/src/aelvoxim/proactive/selector.py +73 -0
  122. aelvoxim-1.0.0/src/aelvoxim/server/__init__.py +228 -0
  123. aelvoxim-1.0.0/src/aelvoxim/server/admin_panel.html +973 -0
  124. aelvoxim-1.0.0/src/aelvoxim/server/audit.py +73 -0
  125. aelvoxim-1.0.0/src/aelvoxim/server/auth.py +313 -0
  126. aelvoxim-1.0.0/src/aelvoxim/server/chat_monitor.py +454 -0
  127. aelvoxim-1.0.0/src/aelvoxim/server/console.html +2825 -0
  128. aelvoxim-1.0.0/src/aelvoxim/server/edition.py +90 -0
  129. aelvoxim-1.0.0/src/aelvoxim/server/email_verify.py +105 -0
  130. aelvoxim-1.0.0/src/aelvoxim/server/entity_extractor.py +452 -0
  131. aelvoxim-1.0.0/src/aelvoxim/server/knowledge_graph.py +273 -0
  132. aelvoxim-1.0.0/src/aelvoxim/server/license.py +228 -0
  133. aelvoxim-1.0.0/src/aelvoxim/server/portal.html +176 -0
  134. aelvoxim-1.0.0/src/aelvoxim/server/query_tracker.py +191 -0
  135. aelvoxim-1.0.0/src/aelvoxim/server/ratelimit.py +57 -0
  136. aelvoxim-1.0.0/src/aelvoxim/server/routes.py +180 -0
  137. aelvoxim-1.0.0/src/aelvoxim/server/routes_brain.py +91 -0
  138. aelvoxim-1.0.0/src/aelvoxim/server/routes_chat.py +454 -0
  139. aelvoxim-1.0.0/src/aelvoxim/server/routes_config.py +112 -0
  140. aelvoxim-1.0.0/src/aelvoxim/server/routes_memory.py +55 -0
  141. aelvoxim-1.0.0/src/aelvoxim/server/routes_system.py +800 -0
  142. aelvoxim-1.0.0/src/aelvoxim/server/routes_task.py +39 -0
  143. aelvoxim-1.0.0/src/aelvoxim/server/service_chat.py +1124 -0
  144. aelvoxim-1.0.0/src/aelvoxim/server/session_manager.py +335 -0
  145. aelvoxim-1.0.0/src/aelvoxim/server/tool_use.py +270 -0
  146. aelvoxim-1.0.0/src/aelvoxim/server/webhook.py +311 -0
  147. aelvoxim-1.0.0/src/aelvoxim/storage/db.py +557 -0
  148. aelvoxim-1.0.0/src/aelvoxim/storage/embedding.py +50 -0
  149. aelvoxim-1.0.0/src/aelvoxim/storage/migrate.py +366 -0
  150. aelvoxim-1.0.0/src/aelvoxim/storage/patches/db_pool.py +157 -0
  151. aelvoxim-1.0.0/src/aelvoxim/ui/dashboard.html +131 -0
  152. aelvoxim-1.0.0/src/aelvoxim/utils/__init__.py +96 -0
  153. aelvoxim-1.0.0/src/aelvoxim/utils/i18n.py +73 -0
  154. aelvoxim-1.0.0/src/aelvoxim/utils/path_registry.py +132 -0
  155. aelvoxim-1.0.0/src/aelvoxim.egg-info/PKG-INFO +254 -0
  156. aelvoxim-1.0.0/src/aelvoxim.egg-info/SOURCES.txt +190 -0
  157. aelvoxim-1.0.0/src/aelvoxim.egg-info/dependency_links.txt +1 -0
  158. aelvoxim-1.0.0/src/aelvoxim.egg-info/entry_points.txt +3 -0
  159. aelvoxim-1.0.0/src/aelvoxim.egg-info/requires.txt +18 -0
  160. aelvoxim-1.0.0/src/aelvoxim.egg-info/top_level.txt +2 -0
  161. aelvoxim-1.0.0/src/aelvoxim_orchestrator/__init__.py +7 -0
  162. aelvoxim-1.0.0/src/aelvoxim_orchestrator/__main__.py +23 -0
  163. aelvoxim-1.0.0/src/aelvoxim_orchestrator/app.py +558 -0
  164. aelvoxim-1.0.0/src/aelvoxim_orchestrator/router.py +78 -0
  165. aelvoxim-1.0.0/tests/test_auth.py +35 -0
  166. aelvoxim-1.0.0/tests/test_belief.py +47 -0
  167. aelvoxim-1.0.0/tests/test_calibration.py +48 -0
  168. aelvoxim-1.0.0/tests/test_core.py +17 -0
  169. aelvoxim-1.0.0/tests/test_core_extra.py +48 -0
  170. aelvoxim-1.0.0/tests/test_decompose.py +38 -0
  171. aelvoxim-1.0.0/tests/test_edition.py +65 -0
  172. aelvoxim-1.0.0/tests/test_entity_extractor.py +57 -0
  173. aelvoxim-1.0.0/tests/test_ethics.py +41 -0
  174. aelvoxim-1.0.0/tests/test_execute.py +36 -0
  175. aelvoxim-1.0.0/tests/test_fusion.py +158 -0
  176. aelvoxim-1.0.0/tests/test_intent.py +43 -0
  177. aelvoxim-1.0.0/tests/test_knowledge.py +85 -0
  178. aelvoxim-1.0.0/tests/test_learner.py +40 -0
  179. aelvoxim-1.0.0/tests/test_learner_extra.py +17 -0
  180. aelvoxim-1.0.0/tests/test_memory.py +66 -0
  181. aelvoxim-1.0.0/tests/test_memory_extra.py +33 -0
  182. aelvoxim-1.0.0/tests/test_memory_extra2.py +22 -0
  183. aelvoxim-1.0.0/tests/test_meta_learner.py +126 -0
  184. aelvoxim-1.0.0/tests/test_monitor.py +29 -0
  185. aelvoxim-1.0.0/tests/test_p2_modules.py +36 -0
  186. aelvoxim-1.0.0/tests/test_post_validation.py +156 -0
  187. aelvoxim-1.0.0/tests/test_router.py +129 -0
  188. aelvoxim-1.0.0/tests/test_routes.py +16 -0
  189. aelvoxim-1.0.0/tests/test_routes_chat.py +35 -0
  190. aelvoxim-1.0.0/tests/test_scorer.py +65 -0
  191. aelvoxim-1.0.0/tests/test_service_chat.py +69 -0
  192. aelvoxim-1.0.0/tests/test_sub_agent.py +94 -0
aelvoxim-1.0.0/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 gmxchz
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,254 @@
1
+ Metadata-Version: 2.4
2
+ Name: aelvoxim
3
+ Version: 1.0.0
4
+ Summary: Lightweight AI Cognitive Engine Framework — give your AI a memory
5
+ Author-email: macor24 <macor@gealss.com>
6
+ License: MIT
7
+ Project-URL: Homepage, https://github.com/macor24/aelvoxim
8
+ Project-URL: Repository, https://github.com/macor24/aelvoxim
9
+ Project-URL: Documentation, https://github.com/macor24/aelvoxim/tree/master/docs
10
+ Keywords: ai,agent,cognitive-engine,memory,self-learning,framework
11
+ Classifier: Development Status :: 3 - Alpha
12
+ Classifier: Intended Audience :: Developers
13
+ Classifier: License :: OSI Approved :: MIT License
14
+ Classifier: Programming Language :: Python :: 3
15
+ Classifier: Programming Language :: Python :: 3.10
16
+ Classifier: Programming Language :: Python :: 3.11
17
+ Classifier: Programming Language :: Python :: 3.12
18
+ Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
19
+ Classifier: Topic :: Software Development :: Libraries :: Application Frameworks
20
+ Description-Content-Type: text/markdown
21
+ License-File: LICENSE
22
+ Requires-Dist: bcrypt>=4.0.0
23
+ Requires-Dist: fastapi>=0.100.0
24
+ Requires-Dist: uvicorn[standard]>=0.20.0
25
+ Provides-Extra: pg
26
+ Requires-Dist: psycopg2-binary>=2.9.0; extra == "pg"
27
+ Provides-Extra: test
28
+ Requires-Dist: pytest>=7.0; extra == "test"
29
+ Requires-Dist: httpx>=0.27; extra == "test"
30
+ Provides-Extra: dev
31
+ Requires-Dist: aelvoxim[pg,test]; extra == "dev"
32
+ Requires-Dist: build>=1.0; extra == "dev"
33
+ Requires-Dist: twine>=4.0; extra == "dev"
34
+ Provides-Extra: full
35
+ Requires-Dist: aelvoxim[pg]; extra == "full"
36
+ Dynamic: license-file
37
+
38
+ # Aelvoxim
39
+
40
+ <p align="center">
41
+ <img src="docs/Aelvoxim2.jpg" alt="Aelvoxim" width="600">
42
+ </p>
43
+
44
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
45
+ [![Python 3.10+](https://img.shields.io/badge/python-3.10+-blue.svg)](https://www.python.org/downloads/)
46
+ [![PyPI](https://img.shields.io/pypi/v/aelvoxim)](https://pypi.org/project/aelvoxim/)
47
+ [![GitHub Repo](https://img.shields.io/badge/GitHub-macor24%2Faelvoxim-181717?logo=github)](https://github.com/macor24/aelvoxim)
48
+
49
+ **Aelvoxim — Lightweight AI Cognitive Engine Framework.**
50
+
51
+ Give your AI application a "memory" — it remembers, reasons, learns, and has meta-cognition.
52
+
53
+ ---
54
+
55
+ ## Quick Start
56
+
57
+ ```bash
58
+ # Install
59
+ pip install aelvoxim
60
+
61
+ # Start the server
62
+ aelvoxim server --port 9701
63
+
64
+ # Open in browser
65
+ open http://localhost:9701
66
+
67
+ # Or use the ChatAEL frontend (dedicated chat UI)
68
+ python serve_chatael.py
69
+ # Open http://localhost:9702
70
+ ```
71
+
72
+ ### From source
73
+
74
+ ```bash
75
+ git clone https://github.com/macor24/aelvoxim.git
76
+ cd aelvoxim
77
+ pip install -e .
78
+ python src/run_server.py 9701
79
+ ```
80
+
81
+ ---
82
+
83
+ ## Use Cases
84
+
85
+ Aelvoxim's layered memory, autonomous learning, and meta-cognition unlock scenarios that ordinary LLM wrappers and RAG pipelines cannot handle.
86
+
87
+ ### 🧑‍🤝‍🧑 Long-Living Virtual Character
88
+ Most AI agents lose everything on restart — Aelvoxim doesn't.
89
+
90
+ - Conversations are stored in **episodic memory** and **never reset**
91
+ - User preferences and speaking style are extracted into **semantic memory** (persist across sessions)
92
+ - The **forgetting curve** naturally prioritizes recent interactions while preserving core facts
93
+ - After weeks of use, the character grows to genuinely know the user, instead of starting from scratch every session
94
+
95
+ ### 📚 Living Code Documentation
96
+ Hook Aelvoxim into your Git workflow and let it maintain your project docs automatically.
97
+
98
+ - Connect via **GitHub/GitLab webhook** — every PR merge triggers re-learning
99
+ - Aelvoxim scans new code, extracts module APIs, and updates its knowledge base
100
+ - **Conflict detection** flags when an interface changed but docs weren't updated
101
+ - Team members ask "how does this function work?" and get answers grounded in actual code, not stale docs
102
+
103
+ ### 🔍 Continuous Compliance Monitoring (Medical / Legal)
104
+ Meta-cognition + auto-validation as a regulatory watchdog.
105
+
106
+ - Store regulations, guidelines, or protocols in the knowledge base
107
+ - **Curiosity-driven discovery** periodically searches for new versions or updates
108
+ - **Conflict detection** catches contradictions between new and old knowledge automatically
109
+ - Output validation ensures every answer stays within compliance boundaries
110
+ - No manual review cycles needed — the system watches itself
111
+
112
+ ### 🧠 Personal Learning Companion
113
+ Unlike ChatGPT where every conversation is isolated, Aelvoxim builds a persistent model of what you know.
114
+
115
+ - Tracks what you've learned and which concepts you find confusing
116
+ - **Forgetting curve** schedules review reminders at optimal intervals
117
+ - Extracts knowledge triples from your notes automatically (knowledge distillation)
118
+ - **Gap analysis** identifies blind spots and suggests what to study next
119
+ - Over time it becomes a second brain that knows your knowledge landscape
120
+
121
+ ### 📊 Automated Business Intelligence
122
+ Turn curiosity-driven learning into a competitive radar.
123
+
124
+ - Define interest directions (competitor moves, industry news, tech trends)
125
+ - **Curiosity engine** autonomously discovers and fetches relevant content
126
+ - Extracted insights are stored as structured knowledge
127
+ - **Conflict alerts** fire when new information contradicts existing beliefs (e.g. a competitor changed pricing)
128
+ - No manual keyword rules — the AI decides what's worth learning
129
+
130
+ ### ⚙️ Self-Tuning Service Bot
131
+ Deploy a support bot that tunes itself — no DevOps babysitting required.
132
+
133
+ - Out of the box it works with conservative defaults
134
+ - **Auto calibration** monitors real response quality and adjusts parameters (temperature, expert weights, memory thresholds) based on what actually works
135
+ - When traffic patterns shift (e.g. more technical questions at certain hours), the system adapts without a config push
136
+ - **Knowledge gap analysis** spots missing answers and automatically initiates learning
137
+ - Over weeks the bot silently improves — your only job is to keep it running
138
+
139
+ ---
140
+
141
+ ## Features
142
+
143
+ ### 🧠 Memory System
144
+ Your AI remembers like a human — with layers, decay, and doubt.
145
+
146
+ | Capability | Description |
147
+ |------------|-------------|
148
+ | **4-layer memory** | Working / Episodic / Semantic / Procedural |
149
+ | **MemoryFusion** | Inverted index + multi-layer retrieval |
150
+ | **Forgetting curve** | Knowledge decays naturally (Ebbinghaus) |
151
+ | **Conflict detection** | Finds contradictions, alerts the user |
152
+ | **Confidence Matrix** | 5-dimensional trust score on every response |
153
+
154
+ ### 🔧 Expert System
155
+ A team of specialized AI experts working together.
156
+
157
+ | Expert | Role | Community | Pro |
158
+ |--------|------|-----------|-----|
159
+ | LogicExpert | Rule reasoning, contradiction detection | ✅ | ✅ |
160
+ | MemoryExpert | Memory retrieval, fusion search | ✅ | ✅ |
161
+ | EthicsExpert | 15 ethical rules, transparent & auditable | ✅ | ✅ |
162
+ | SafetyExpert | Local keyword + regex safety checks | ✅ | ✅ |
163
+ | CodeReviewExpert | Code style, complexity, secret scanning | ✅ | ✅ |
164
+ | EmotionExpert | Sentiment analysis, empathetic response | ❌ | ✅ |
165
+ | CreativeExpert | Creative writing, content generation | ❌ | ✅ |
166
+ | IntrospectionExpert | Self-reflection, quality audit | ❌ | ✅ |
167
+ | HypothesisEngine | Root cause hypothesis & validation | ❌ | ✅ |
168
+
169
+ ### 📚 Learning System
170
+
171
+ | Capability | Community | Pro |
172
+ |------------|-----------|-----|
173
+ | Manual learning (API trigger) | ✅ | ✅ |
174
+ | 7×24 auto-learning loop | ❌ | ✅ |
175
+ | Curiosity-driven discovery | ❌ | ✅ |
176
+ | Auto parameter tuning | ❌ | ✅ |
177
+ | Knowledge gap analysis | ❌ | ✅ |
178
+ | Post-validation audit | ❌ | ✅ |
179
+
180
+ ### 🔌 API & Integration
181
+ - **RESTful API** — FastAPI, Swagger docs at `/docs`
182
+ - **SSE streaming** — Real-time token-by-token output
183
+ - **Multi-user auth** — Email/password registration + API Keys
184
+ - **Knowledge base CRUD** — Add, search, update, delete knowledge entries
185
+ - **Session management** — Persistent conversations with history
186
+
187
+ ---
188
+
189
+ ## Architecture
190
+
191
+ ```
192
+ aelvoxim/
193
+ ├── src/aelvoxim/
194
+ │ ├── core/ Cognitive engine (belief, metacog, reasoner, judge, DGM-H)
195
+ │ ├── learn/ Learning engine (learner, KB, validator, search, curiosity)
196
+ │ ├── memory/ Memory system (4 layers, fusion, decay, conflict, scoring)
197
+ │ ├── server/ API server (FastAPI, auth, chat pipeline, sessions)
198
+ │ ├── cortex/ Brain cortex (intent routing, scheduler)
199
+ │ ├── experts/ Expert system (orchestrator, 5+ experts, registry)
200
+ │ ├── storage/ Dual storage (SQLite local, PostgreSQL production)
201
+ │ ├── utils/ Helpers (i18n, paths, JSON)
202
+ │ └── edition.py Edition gating (community/pro config control)
203
+ ├── frontend/
204
+ │ └── chatael-v2/ ChatAEL — React + Tailwind chat UI
205
+ ├── tests/ 130+ test cases
206
+ ├── docs/
207
+ ├── CONTRIBUTING.md
208
+ ├── SECURITY.md
209
+ └── LICENSE (MIT)
210
+ ```
211
+
212
+ ---
213
+
214
+ ## Community vs Pro
215
+
216
+ | Dimension | Community (free, MIT) | Pro (license key) |
217
+ |-----------|----------------------|-------------------|
218
+ | Learning | Manual trigger | 7×24 auto loop |
219
+ | Discovery | User-specified | Curiosity-driven |
220
+ | Tuning | Static defaults | Dynamic auto-tune |
221
+ | Experts | 5 core | 12 total (incl. advanced) |
222
+ | Validation | None | Scheduled auto-scan |
223
+ | Security | Local rules | SentriKit deep engine |
224
+ | License | MIT | License key |
225
+
226
+ ---
227
+
228
+ ## External Dependencies
229
+
230
+ Only **3 external packages** — everything else is Python standard library.
231
+
232
+ | Package | Purpose |
233
+ |---------|---------|
234
+ | `bcrypt` | Password hashing |
235
+ | `fastapi` | API framework |
236
+ | `uvicorn` | ASGI server |
237
+
238
+ ---
239
+
240
+ ## Why Aelvoxim?
241
+
242
+ - **Lightweight** — 3 deps, 34k lines of Python, no Docker required
243
+ - **Self-contained** — SQLite for single-user, PostgreSQL for multi-user
244
+ - **Private by design** — Your data stays on your machine, no telemetry
245
+ - **Dual storage** — SQLite for dev, PostgreSQL for production, same code
246
+ - **Built-in safety** — Ethics rules, safety checks, meta-cognition monitoring
247
+
248
+ ---
249
+
250
+ ## License
251
+
252
+ MIT License — Copyright (c) 2026 macor24
253
+
254
+ See [LICENSE](./LICENSE) for details.
@@ -0,0 +1,217 @@
1
+ # Aelvoxim
2
+
3
+ <p align="center">
4
+ <img src="docs/Aelvoxim2.jpg" alt="Aelvoxim" width="600">
5
+ </p>
6
+
7
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
8
+ [![Python 3.10+](https://img.shields.io/badge/python-3.10+-blue.svg)](https://www.python.org/downloads/)
9
+ [![PyPI](https://img.shields.io/pypi/v/aelvoxim)](https://pypi.org/project/aelvoxim/)
10
+ [![GitHub Repo](https://img.shields.io/badge/GitHub-macor24%2Faelvoxim-181717?logo=github)](https://github.com/macor24/aelvoxim)
11
+
12
+ **Aelvoxim — Lightweight AI Cognitive Engine Framework.**
13
+
14
+ Give your AI application a "memory" — it remembers, reasons, learns, and has meta-cognition.
15
+
16
+ ---
17
+
18
+ ## Quick Start
19
+
20
+ ```bash
21
+ # Install
22
+ pip install aelvoxim
23
+
24
+ # Start the server
25
+ aelvoxim server --port 9701
26
+
27
+ # Open in browser
28
+ open http://localhost:9701
29
+
30
+ # Or use the ChatAEL frontend (dedicated chat UI)
31
+ python serve_chatael.py
32
+ # Open http://localhost:9702
33
+ ```
34
+
35
+ ### From source
36
+
37
+ ```bash
38
+ git clone https://github.com/macor24/aelvoxim.git
39
+ cd aelvoxim
40
+ pip install -e .
41
+ python src/run_server.py 9701
42
+ ```
43
+
44
+ ---
45
+
46
+ ## Use Cases
47
+
48
+ Aelvoxim's layered memory, autonomous learning, and meta-cognition unlock scenarios that ordinary LLM wrappers and RAG pipelines cannot handle.
49
+
50
+ ### 🧑‍🤝‍🧑 Long-Living Virtual Character
51
+ Most AI agents lose everything on restart — Aelvoxim doesn't.
52
+
53
+ - Conversations are stored in **episodic memory** and **never reset**
54
+ - User preferences and speaking style are extracted into **semantic memory** (persist across sessions)
55
+ - The **forgetting curve** naturally prioritizes recent interactions while preserving core facts
56
+ - After weeks of use, the character grows to genuinely know the user, instead of starting from scratch every session
57
+
58
+ ### 📚 Living Code Documentation
59
+ Hook Aelvoxim into your Git workflow and let it maintain your project docs automatically.
60
+
61
+ - Connect via **GitHub/GitLab webhook** — every PR merge triggers re-learning
62
+ - Aelvoxim scans new code, extracts module APIs, and updates its knowledge base
63
+ - **Conflict detection** flags when an interface changed but docs weren't updated
64
+ - Team members ask "how does this function work?" and get answers grounded in actual code, not stale docs
65
+
66
+ ### 🔍 Continuous Compliance Monitoring (Medical / Legal)
67
+ Meta-cognition + auto-validation as a regulatory watchdog.
68
+
69
+ - Store regulations, guidelines, or protocols in the knowledge base
70
+ - **Curiosity-driven discovery** periodically searches for new versions or updates
71
+ - **Conflict detection** catches contradictions between new and old knowledge automatically
72
+ - Output validation ensures every answer stays within compliance boundaries
73
+ - No manual review cycles needed — the system watches itself
74
+
75
+ ### 🧠 Personal Learning Companion
76
+ Unlike ChatGPT where every conversation is isolated, Aelvoxim builds a persistent model of what you know.
77
+
78
+ - Tracks what you've learned and which concepts you find confusing
79
+ - **Forgetting curve** schedules review reminders at optimal intervals
80
+ - Extracts knowledge triples from your notes automatically (knowledge distillation)
81
+ - **Gap analysis** identifies blind spots and suggests what to study next
82
+ - Over time it becomes a second brain that knows your knowledge landscape
83
+
84
+ ### 📊 Automated Business Intelligence
85
+ Turn curiosity-driven learning into a competitive radar.
86
+
87
+ - Define interest directions (competitor moves, industry news, tech trends)
88
+ - **Curiosity engine** autonomously discovers and fetches relevant content
89
+ - Extracted insights are stored as structured knowledge
90
+ - **Conflict alerts** fire when new information contradicts existing beliefs (e.g. a competitor changed pricing)
91
+ - No manual keyword rules — the AI decides what's worth learning
92
+
93
+ ### ⚙️ Self-Tuning Service Bot
94
+ Deploy a support bot that tunes itself — no DevOps babysitting required.
95
+
96
+ - Out of the box it works with conservative defaults
97
+ - **Auto calibration** monitors real response quality and adjusts parameters (temperature, expert weights, memory thresholds) based on what actually works
98
+ - When traffic patterns shift (e.g. more technical questions at certain hours), the system adapts without a config push
99
+ - **Knowledge gap analysis** spots missing answers and automatically initiates learning
100
+ - Over weeks the bot silently improves — your only job is to keep it running
101
+
102
+ ---
103
+
104
+ ## Features
105
+
106
+ ### 🧠 Memory System
107
+ Your AI remembers like a human — with layers, decay, and doubt.
108
+
109
+ | Capability | Description |
110
+ |------------|-------------|
111
+ | **4-layer memory** | Working / Episodic / Semantic / Procedural |
112
+ | **MemoryFusion** | Inverted index + multi-layer retrieval |
113
+ | **Forgetting curve** | Knowledge decays naturally (Ebbinghaus) |
114
+ | **Conflict detection** | Finds contradictions, alerts the user |
115
+ | **Confidence Matrix** | 5-dimensional trust score on every response |
116
+
117
+ ### 🔧 Expert System
118
+ A team of specialized AI experts working together.
119
+
120
+ | Expert | Role | Community | Pro |
121
+ |--------|------|-----------|-----|
122
+ | LogicExpert | Rule reasoning, contradiction detection | ✅ | ✅ |
123
+ | MemoryExpert | Memory retrieval, fusion search | ✅ | ✅ |
124
+ | EthicsExpert | 15 ethical rules, transparent & auditable | ✅ | ✅ |
125
+ | SafetyExpert | Local keyword + regex safety checks | ✅ | ✅ |
126
+ | CodeReviewExpert | Code style, complexity, secret scanning | ✅ | ✅ |
127
+ | EmotionExpert | Sentiment analysis, empathetic response | ❌ | ✅ |
128
+ | CreativeExpert | Creative writing, content generation | ❌ | ✅ |
129
+ | IntrospectionExpert | Self-reflection, quality audit | ❌ | ✅ |
130
+ | HypothesisEngine | Root cause hypothesis & validation | ❌ | ✅ |
131
+
132
+ ### 📚 Learning System
133
+
134
+ | Capability | Community | Pro |
135
+ |------------|-----------|-----|
136
+ | Manual learning (API trigger) | ✅ | ✅ |
137
+ | 7×24 auto-learning loop | ❌ | ✅ |
138
+ | Curiosity-driven discovery | ❌ | ✅ |
139
+ | Auto parameter tuning | ❌ | ✅ |
140
+ | Knowledge gap analysis | ❌ | ✅ |
141
+ | Post-validation audit | ❌ | ✅ |
142
+
143
+ ### 🔌 API & Integration
144
+ - **RESTful API** — FastAPI, Swagger docs at `/docs`
145
+ - **SSE streaming** — Real-time token-by-token output
146
+ - **Multi-user auth** — Email/password registration + API Keys
147
+ - **Knowledge base CRUD** — Add, search, update, delete knowledge entries
148
+ - **Session management** — Persistent conversations with history
149
+
150
+ ---
151
+
152
+ ## Architecture
153
+
154
+ ```
155
+ aelvoxim/
156
+ ├── src/aelvoxim/
157
+ │ ├── core/ Cognitive engine (belief, metacog, reasoner, judge, DGM-H)
158
+ │ ├── learn/ Learning engine (learner, KB, validator, search, curiosity)
159
+ │ ├── memory/ Memory system (4 layers, fusion, decay, conflict, scoring)
160
+ │ ├── server/ API server (FastAPI, auth, chat pipeline, sessions)
161
+ │ ├── cortex/ Brain cortex (intent routing, scheduler)
162
+ │ ├── experts/ Expert system (orchestrator, 5+ experts, registry)
163
+ │ ├── storage/ Dual storage (SQLite local, PostgreSQL production)
164
+ │ ├── utils/ Helpers (i18n, paths, JSON)
165
+ │ └── edition.py Edition gating (community/pro config control)
166
+ ├── frontend/
167
+ │ └── chatael-v2/ ChatAEL — React + Tailwind chat UI
168
+ ├── tests/ 130+ test cases
169
+ ├── docs/
170
+ ├── CONTRIBUTING.md
171
+ ├── SECURITY.md
172
+ └── LICENSE (MIT)
173
+ ```
174
+
175
+ ---
176
+
177
+ ## Community vs Pro
178
+
179
+ | Dimension | Community (free, MIT) | Pro (license key) |
180
+ |-----------|----------------------|-------------------|
181
+ | Learning | Manual trigger | 7×24 auto loop |
182
+ | Discovery | User-specified | Curiosity-driven |
183
+ | Tuning | Static defaults | Dynamic auto-tune |
184
+ | Experts | 5 core | 12 total (incl. advanced) |
185
+ | Validation | None | Scheduled auto-scan |
186
+ | Security | Local rules | SentriKit deep engine |
187
+ | License | MIT | License key |
188
+
189
+ ---
190
+
191
+ ## External Dependencies
192
+
193
+ Only **3 external packages** — everything else is Python standard library.
194
+
195
+ | Package | Purpose |
196
+ |---------|---------|
197
+ | `bcrypt` | Password hashing |
198
+ | `fastapi` | API framework |
199
+ | `uvicorn` | ASGI server |
200
+
201
+ ---
202
+
203
+ ## Why Aelvoxim?
204
+
205
+ - **Lightweight** — 3 deps, 34k lines of Python, no Docker required
206
+ - **Self-contained** — SQLite for single-user, PostgreSQL for multi-user
207
+ - **Private by design** — Your data stays on your machine, no telemetry
208
+ - **Dual storage** — SQLite for dev, PostgreSQL for production, same code
209
+ - **Built-in safety** — Ethics rules, safety checks, meta-cognition monitoring
210
+
211
+ ---
212
+
213
+ ## License
214
+
215
+ MIT License — Copyright (c) 2026 macor24
216
+
217
+ See [LICENSE](./LICENSE) for details.
@@ -0,0 +1,51 @@
1
+ [build-system]
2
+ requires = ["setuptools>=64.0"]
3
+ build-backend = "setuptools.build_meta"
4
+
5
+ [project]
6
+ name = "aelvoxim"
7
+ version = "1.0.0"
8
+ description = "Lightweight AI Cognitive Engine Framework — give your AI a memory"
9
+ readme = "README.md"
10
+ license = {text = "MIT"}
11
+ authors = [
12
+ {name = "macor24", email = "macor@gealss.com"},
13
+ ]
14
+ keywords = ["ai", "agent", "cognitive-engine", "memory", "self-learning", "framework"]
15
+ classifiers = [
16
+ "Development Status :: 3 - Alpha",
17
+ "Intended Audience :: Developers",
18
+ "License :: OSI Approved :: MIT License",
19
+ "Programming Language :: Python :: 3",
20
+ "Programming Language :: Python :: 3.10",
21
+ "Programming Language :: Python :: 3.11",
22
+ "Programming Language :: Python :: 3.12",
23
+ "Topic :: Scientific/Engineering :: Artificial Intelligence",
24
+ "Topic :: Software Development :: Libraries :: Application Frameworks",
25
+ ]
26
+ dependencies = [
27
+ "bcrypt>=4.0.0",
28
+ "fastapi>=0.100.0",
29
+ "uvicorn[standard]>=0.20.0",
30
+ ]
31
+
32
+ [project.optional-dependencies]
33
+ pg = ["psycopg2-binary>=2.9.0"]
34
+ test = ["pytest>=7.0", "httpx>=0.27"]
35
+ dev = ["aelvoxim[pg,test]", "build>=1.0", "twine>=4.0"]
36
+ full = ["aelvoxim[pg]"]
37
+
38
+ [project.urls]
39
+ Homepage = "https://github.com/macor24/aelvoxim"
40
+ Repository = "https://github.com/macor24/aelvoxim"
41
+ Documentation = "https://github.com/macor24/aelvoxim/tree/master/docs"
42
+
43
+ [tool.setuptools.packages.find]
44
+ where = ["src"]
45
+
46
+ [tool.setuptools.package-data]
47
+ aelvoxim = ["**/*.html"]
48
+
49
+ [project.scripts]
50
+ aelvoxim = "aelvoxim.__main__:main"
51
+ aelvoxim-admin = "aelvoxim.admin:main"
@@ -0,0 +1,4 @@
1
+ [egg_info]
2
+ tag_build =
3
+ tag_date = 0
4
+
@@ -0,0 +1,11 @@
1
+ """aelvoxim.init — Aelvoxim MetaCore
2
+
3
+ A zero-dependency, pure-stdlib, self-evolving AI Agent framework.
4
+ """
5
+
6
+ from __future__ import annotations
7
+
8
+ import os
9
+
10
+ _EDITION = os.environ.get("METACORE_EDITION", os.environ.get("AELVOXIM_EDITION", "enterprise"))
11
+ __version__ = "1.0.0"
@@ -0,0 +1,84 @@
1
+ """aelvoxim.__main__ — CLI entry point
2
+
3
+ Usage:
4
+ python -m metacore --lang en
5
+ python -m metacore learn add "Topic name"
6
+ python -m metacore status
7
+ """
8
+
9
+ import sys
10
+ import argparse
11
+
12
+ from .utils.i18n import set_lang, _
13
+
14
+
15
+ def main(argv=None):
16
+ parser = argparse.ArgumentParser(
17
+ description="MetaCore — Self-evolving AI Agent framework",
18
+ )
19
+ parser.add_argument("--lang", default="en", help="Interface language (en/zh)")
20
+ sub = parser.add_subparsers(dest="command")
21
+
22
+ # learn
23
+ learn_p = sub.add_parser("learn", help="Manage learning")
24
+ learn_sub = learn_p.add_subparsers(dest="learn_cmd")
25
+ add_p = learn_sub.add_parser("add", help="Add a learning direction")
26
+ add_p.add_argument("topic", help="Topic to learn")
27
+ learn_sub.add_parser("start", help="Start learning loop")
28
+ learn_sub.add_parser("stop", help="Stop learning loop")
29
+ learn_sub.add_parser("status", help="Show learning status")
30
+
31
+ # ui
32
+ ui_p = sub.add_parser("ui", help="Start read-only dashboard")
33
+ ui_p.add_argument("--port", type=int, default=9700, help="Dashboard port (default: 9700)")
34
+
35
+ # status
36
+ sub.add_parser("status", help="Show system status")
37
+
38
+ args = parser.parse_args(argv)
39
+ set_lang(args.lang)
40
+
41
+ if args.command == "ui":
42
+ print("Dashboard merged into 9701 at /v1/admin/panel")
43
+
44
+ if args.command == "learn":
45
+ cmd = getattr(args, "learn_cmd", None)
46
+ if cmd == "add":
47
+ from .learn.learner import get_learner
48
+ learner = get_learner()
49
+ added = learner.add_direction(args.topic)
50
+ print(f"Direction '{args.topic}' {'added' if added else 'already exists'}")
51
+ elif cmd == "start":
52
+ from .learn.learner import get_learner
53
+ get_learner().start()
54
+ print(_("started"))
55
+ elif cmd == "stop":
56
+ from .learn.learner import get_learner
57
+ get_learner().stop()
58
+ print(_("stopped"))
59
+ elif cmd == "status":
60
+ from .learn.learner import get_learner
61
+ st = get_learner().get_status()
62
+ print(json.dumps(st, indent=2, ensure_ascii=False))
63
+ # Cold-start suggestion
64
+ from .utils import LEARNER_CONFIG
65
+ try:
66
+ cfg = json.loads(LEARNER_CONFIG.read_text())
67
+ except Exception:
68
+ cfg = []
69
+ if not cfg:
70
+ print("---")
71
+ print("No learning directions yet. Try:")
72
+ print(' metacore learn add "FastAPI async optimization patterns"')
73
+ print(' metacore learn add "Python threading safety patterns"')
74
+ print(' metacore learn add "Database index optimization SQLite"')
75
+ elif args.command == "status":
76
+ from .learn.learner import get_learner
77
+ st = get_learner().get_status()
78
+ print(json.dumps(st, indent=2, ensure_ascii=False))
79
+ else:
80
+ parser.print_help()
81
+
82
+
83
+ if __name__ == "__main__":
84
+ main()