Skip to content

micro-fix :added database initialization and statement management tools#3475

Open
IBOCATA wants to merge 8 commits intoadenhq:mainfrom
IBOCATA:patch-10
Open

micro-fix :added database initialization and statement management tools#3475
IBOCATA wants to merge 8 commits intoadenhq:mainfrom
IBOCATA:patch-10

Conversation

@IBOCATA
Copy link

@IBOCATA IBOCATA commented Feb 4, 2026

Added database initialization and statement management tools.

Description

This PR introduces a comprehensive enhancement for the Hive AI Agent, enabling the creation and management of a dedicated String Database. This feature automates the initiation, training, and validation of business statements, providing a structured workflow for LLM-assisted human judgment.

Type of Change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

Related Issues

Fixes #3393

Changes Made

  • ✨ Key Features
    String DB Orchestration: Implements a managed layer for storing and indexing raw business statements imported into the system.
    Lifecycle Management: Automates the transition of statements through five distinct phases: Initiation, Training, Testing, Validation, and Final Judgment.
    Human-in-the-loop (HITL) Interface: Optimized outputs specifically designed for human auditors to review LLM "judgments" on business logic.
    Integrated Search Cache: Utilizes the previously implemented TTL cache to verify business statements against real-world data without redundant API costs.

Implementation

  1. Database Initiation & Schema
    We use the Zod validation layer to ensure every imported business statement is "clean" before it hits the String DB.
  2. The Training & Testing Pipeline
    The agent uses a "Reasoning Loop" to train on the business context and test the logic of the statements.
    Initiation: Raw CSV/JSON import of business statements.
    Training: LLM creates embeddings and associations within the String DB.
    Testing: Automated edge-case generation to stress-test statement logic.
    Validation: Comparing statement outcomes against cached web search results.

Testing

​🚦 Testing & Validation
​[x] Import Integrity: Verified that malformed business statements are rejected by the Zod gateway.
​[x] State Persistence: Confirmed that statements maintain their "Training" or "Testing" status across agent restarts.
​[x] Human Judgment Export: Verified the "Human-readable" summary format for final validation.

Checklist

  • My code follows the project's style guidelines
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

📋 Assignee Checklist (SQLite/Vector Implementation)
Initialization: Ensure init_db() is called on server startup so the .db file is created locally.
Persistence Check: Verify that even if the MCP server restarts, the "Training" status of statements is preserved in SQLite.
Human Judgement Flow: The get_training_batch tool should be used to feed data to the LLM for initial "Human-like" evaluation

Added database initialization and statement management tools.
Added TensorFlow and Keras imports, and implemented functions to build ANN and CNN models for business data classification and sequence analysis.
Added a new function to build a CNN model for text analysis.
database initialization.
Added a comment for database initialization.
Added robotics modules for vision and control functionalities.
doc/docs :Integrate robotics vision and control modules
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: MCP server crashes on startup when required environment variables are missing

1 participant