igel-qe-core 1.0.3 → 1.0.7
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.
- package/dist/cli/index.js +638 -54
- package/dist/cli/platform.js +115 -72
- package/dist/mcp/server.js +258 -17
- package/package.json +4 -4
- package/src/__pycache__/__init__.cpython-311.pyc +0 -0
- package/src/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/__pycache__/__init__.cpython-314.pyc +0 -0
- package/src/agents/__init__.py +3 -0
- package/src/agents/__pycache__/__init__.cpython-311.pyc +0 -0
- package/src/agents/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/agents/__pycache__/__init__.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/automation_design_agent.cpython-311.pyc +0 -0
- package/src/agents/__pycache__/automation_design_agent.cpython-313.pyc +0 -0
- package/src/agents/__pycache__/automation_design_agent.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/code_intelligence_agent.cpython-311.pyc +0 -0
- package/src/agents/__pycache__/code_intelligence_agent.cpython-313.pyc +0 -0
- package/src/agents/__pycache__/confidence_agent.cpython-311.pyc +0 -0
- package/src/agents/__pycache__/confidence_agent.cpython-313.pyc +0 -0
- package/src/agents/__pycache__/confidence_agent.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/execution_validation_agent.cpython-311.pyc +0 -0
- package/src/agents/__pycache__/execution_validation_agent.cpython-313.pyc +0 -0
- package/src/agents/__pycache__/execution_validation_agent.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/framework_analyzer_agent.cpython-311.pyc +0 -0
- package/src/agents/__pycache__/framework_analyzer_agent.cpython-313.pyc +0 -0
- package/src/agents/__pycache__/fusion_agent.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/graph.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/intent_agent.cpython-313.pyc +0 -0
- package/src/agents/__pycache__/intent_agent.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/kg_agent.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/memory_agent.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/reflection_agent.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/regression_agent.cpython-311.pyc +0 -0
- package/src/agents/__pycache__/regression_agent.cpython-313.pyc +0 -0
- package/src/agents/__pycache__/requirement_agent.cpython-311.pyc +0 -0
- package/src/agents/__pycache__/requirement_agent.cpython-313.pyc +0 -0
- package/src/agents/__pycache__/requirement_agent.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/retrieval_agent.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/scenario_agent.cpython-311.pyc +0 -0
- package/src/agents/__pycache__/scenario_agent.cpython-313.pyc +0 -0
- package/src/agents/__pycache__/scenario_agent.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/script_agent.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/script_generator_agent.cpython-311.pyc +0 -0
- package/src/agents/__pycache__/script_generator_agent.cpython-313.pyc +0 -0
- package/src/agents/__pycache__/script_generator_agent.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/state.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/temporal_agent.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/testcase_agent.cpython-311.pyc +0 -0
- package/src/agents/__pycache__/testcase_agent.cpython-313.pyc +0 -0
- package/src/agents/__pycache__/testcase_agent.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/validation_agent.cpython-311.pyc +0 -0
- package/src/agents/__pycache__/validation_agent.cpython-313.pyc +0 -0
- package/src/agents/__pycache__/validation_agent.cpython-314.pyc +0 -0
- package/src/agents/__pycache__/workflow_engine.cpython-311.pyc +0 -0
- package/src/agents/__pycache__/workflow_engine.cpython-313.pyc +0 -0
- package/src/agents/__pycache__/workflow_engine.cpython-314.pyc +0 -0
- package/{knowledge_base → src}/agents/automation_design_agent.py +14 -17
- package/{knowledge_base → src}/agents/code_intelligence_agent.py +2 -2
- package/src/agents/confidence_agent.py +114 -0
- package/{knowledge_base → src}/agents/execution_validation_agent.py +1 -1
- package/src/agents/feedback_agent.py +89 -0
- package/src/agents/framework_analyzer_agent.py +43 -0
- package/{knowledge_base → src}/agents/fusion_agent.py +3 -3
- package/{knowledge_base → src}/agents/graph.py +10 -10
- package/{knowledge_base → src}/agents/healing_agent.py +4 -4
- package/src/agents/intent_agent.py +30 -0
- package/src/agents/internal/__init__.py +3 -0
- package/src/agents/internal/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/agents/internal/__pycache__/approval_manager.cpython-313.pyc +0 -0
- package/src/agents/internal/__pycache__/question_engine.cpython-313.pyc +0 -0
- package/src/agents/internal/approval_manager.py +111 -0
- package/src/agents/internal/question_engine.py +111 -0
- package/src/agents/internal/workflow_engine.py +28 -0
- package/{knowledge_base → src}/agents/kg_agent.py +3 -3
- package/{knowledge_base → src}/agents/memory_agent.py +4 -4
- package/src/agents/orchestrator/__init__.py +3 -0
- package/src/agents/orchestrator/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/agents/orchestrator/__pycache__/orchestrator.cpython-313.pyc +0 -0
- package/src/agents/orchestrator/orchestrator.py +63 -0
- package/{knowledge_base → src}/agents/rca_agent.py +4 -4
- package/{knowledge_base → src}/agents/reflection_agent.py +1 -1
- package/{knowledge_base → src}/agents/regression_agent.py +2 -2
- package/src/agents/requirement_agent.py +97 -0
- package/{knowledge_base → src}/agents/retrieval_agent.py +2 -2
- package/{knowledge_base → src}/agents/scenario_agent.py +11 -17
- package/{knowledge_base → src}/agents/script_agent.py +6 -6
- package/{knowledge_base → src}/agents/script_generator_agent.py +12 -10
- package/{knowledge_base → src}/agents/temporal_agent.py +3 -3
- package/src/agents/testcase_agent.py +163 -0
- package/{knowledge_base → src}/agents/validation_agent.py +1 -1
- package/src/agents/workflow_engine.py +109 -0
- package/{knowledge_base → src}/alembic/README.md +4 -4
- package/{knowledge_base → src}/alembic/env.py +1 -1
- package/{knowledge_base → src}/alembic/script.py.mako +1 -1
- package/{knowledge_base → src}/api/middleware.py +3 -3
- package/{knowledge_base → src}/api/server.py +28 -28
- package/{knowledge_base → src}/chunking/chunker.py +3 -3
- package/src/cli/__pycache__/__init__.cpython-311.pyc +0 -0
- package/src/cli/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/cli/__pycache__/__init__.cpython-314.pyc +0 -0
- package/src/cli/__pycache__/workflow_cli.cpython-311.pyc +0 -0
- package/src/cli/__pycache__/workflow_cli.cpython-313.pyc +0 -0
- package/src/cli/__pycache__/workflow_cli.cpython-314.pyc +0 -0
- package/{knowledge_base → src}/cli/feedback_cli.py +10 -10
- package/{knowledge_base → src}/cli/generate.py +11 -11
- package/src/cli/index.ts +704 -0
- package/src/cli/platform.ts +147 -0
- package/src/cli/workflow_cli.py +930 -0
- package/{knowledge_base → src}/config/__init__.py +1 -1
- package/src/config/__pycache__/__init__.cpython-311.pyc +0 -0
- package/src/config/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/config/__pycache__/__init__.cpython-314.pyc +0 -0
- package/src/config/__pycache__/policy_config.cpython-311.pyc +0 -0
- package/src/config/__pycache__/policy_config.cpython-313.pyc +0 -0
- package/src/config/__pycache__/settings.cpython-311.pyc +0 -0
- package/src/config/__pycache__/settings.cpython-313.pyc +0 -0
- package/src/config/__pycache__/settings.cpython-314.pyc +0 -0
- package/src/config/policy_config.py +85 -0
- package/src/config/policy_rules.yaml +50 -0
- package/{knowledge_base → src}/config/settings.py +51 -6
- package/{knowledge_base → src}/connectors/__init__.py +1 -1
- package/src/connectors/__pycache__/__init__.cpython-311.pyc +0 -0
- package/src/connectors/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/connectors/__pycache__/__init__.cpython-314.pyc +0 -0
- package/src/connectors/__pycache__/base.cpython-311.pyc +0 -0
- package/src/connectors/__pycache__/base.cpython-313.pyc +0 -0
- package/src/connectors/__pycache__/base.cpython-314.pyc +0 -0
- package/src/connectors/__pycache__/jira_connector.cpython-311.pyc +0 -0
- package/src/connectors/__pycache__/jira_connector.cpython-313.pyc +0 -0
- package/src/connectors/__pycache__/jira_connector.cpython-314.pyc +0 -0
- package/src/connectors/__pycache__/query_bridge.cpython-313.pyc +0 -0
- package/src/connectors/__pycache__/query_bridge.cpython-314.pyc +0 -0
- package/src/connectors/bitbucket_connector.py +334 -0
- package/{knowledge_base → src}/connectors/community_connector.py +6 -6
- package/{knowledge_base → src}/connectors/confluence_connector.py +4 -4
- package/{knowledge_base → src}/connectors/jira_connector.py +7 -11
- package/{knowledge_base → src}/connectors/kb_igel_connector.py +6 -6
- package/{knowledge_base → src}/connectors/query_bridge.py +11 -11
- package/{knowledge_base → src}/connectors/search_backends.py +1 -1
- package/{knowledge_base → src}/connectors/serviceNow_connector.py +2 -2
- package/{knowledge_base → src}/connectors/sync_scheduler.py +12 -10
- package/{knowledge_base → src}/connectors/teamcity_connector.py +2 -2
- package/{knowledge_base → src}/connectors/testRail_connector.py +2 -2
- package/{knowledge_base → src}/connectors/web_fetcher.py +1 -1
- package/src/connectors/xray_connector.py +337 -0
- package/{knowledge_base → src}/core/__init__.py +1 -1
- package/src/core/__pycache__/__init__.cpython-311.pyc +0 -0
- package/src/core/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/core/__pycache__/__init__.cpython-314.pyc +0 -0
- package/src/core/__pycache__/circuit_breaker.cpython-313.pyc +0 -0
- package/src/core/__pycache__/circuit_breaker.cpython-314.pyc +0 -0
- package/src/core/__pycache__/confidence.cpython-311.pyc +0 -0
- package/src/core/__pycache__/confidence.cpython-313.pyc +0 -0
- package/src/core/__pycache__/confidence.cpython-314.pyc +0 -0
- package/src/core/__pycache__/context_engine.cpython-311.pyc +0 -0
- package/src/core/__pycache__/context_engine.cpython-313.pyc +0 -0
- package/src/core/__pycache__/evidence_resolver.cpython-311.pyc +0 -0
- package/src/core/__pycache__/evidence_resolver.cpython-313.pyc +0 -0
- package/src/core/__pycache__/guardrails.cpython-311.pyc +0 -0
- package/src/core/__pycache__/guardrails.cpython-313.pyc +0 -0
- package/src/core/__pycache__/hooks.cpython-311.pyc +0 -0
- package/src/core/__pycache__/hooks.cpython-313.pyc +0 -0
- package/src/core/__pycache__/intent_service.cpython-313.pyc +0 -0
- package/src/core/__pycache__/llm_executor.cpython-311.pyc +0 -0
- package/src/core/__pycache__/llm_executor.cpython-313.pyc +0 -0
- package/src/core/__pycache__/model_router.cpython-311.pyc +0 -0
- package/src/core/__pycache__/model_router.cpython-313.pyc +0 -0
- package/src/core/__pycache__/orchestration_contracts.cpython-311.pyc +0 -0
- package/src/core/__pycache__/orchestration_contracts.cpython-313.pyc +0 -0
- package/src/core/__pycache__/precedence.cpython-311.pyc +0 -0
- package/src/core/__pycache__/precedence.cpython-313.pyc +0 -0
- package/src/core/__pycache__/prompt_builder.cpython-311.pyc +0 -0
- package/src/core/__pycache__/prompt_builder.cpython-313.pyc +0 -0
- package/src/core/__pycache__/prompt_policy_engine.cpython-311.pyc +0 -0
- package/src/core/__pycache__/prompt_policy_engine.cpython-313.pyc +0 -0
- package/{knowledge_base → src}/core/cache.py +2 -2
- package/{knowledge_base → src}/core/confidence.py +2 -2
- package/src/core/context_engine.py +138 -0
- package/src/core/evidence_resolver.py +72 -0
- package/src/core/guardrails.py +22 -0
- package/src/core/hooks.py +57 -0
- package/src/core/intent_service.py +74 -0
- package/src/core/llm_executor.py +138 -0
- package/{knowledge_base → src}/core/logging_setup.py +1 -1
- package/src/core/model_router.py +246 -0
- package/src/core/orchestration_contracts.py +66 -0
- package/src/core/persistence_engine.py +159 -0
- package/src/core/prompt_builder.py +49 -0
- package/src/core/prompt_policy_engine.py +35 -0
- package/src/core/traceability_engine.py +56 -0
- package/src/db/__pycache__/__init__.cpython-311.pyc +0 -0
- package/src/db/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/db/__pycache__/__init__.cpython-314.pyc +0 -0
- package/src/db/__pycache__/client.cpython-311.pyc +0 -0
- package/src/db/__pycache__/client.cpython-313.pyc +0 -0
- package/src/db/__pycache__/client.cpython-314.pyc +0 -0
- package/src/db/__pycache__/igel_schema.cpython-311.pyc +0 -0
- package/src/db/__pycache__/igel_schema.cpython-313.pyc +0 -0
- package/src/db/__pycache__/igel_schema.cpython-314.pyc +0 -0
- package/src/db/__pycache__/kg_introspect.cpython-311.pyc +0 -0
- package/src/db/__pycache__/kg_introspect.cpython-313.pyc +0 -0
- package/{knowledge_base → src}/db/__pycache__/kg_introspect.cpython-314.pyc +0 -0
- package/{knowledge_base → src}/db/client.py +1 -1
- package/{knowledge_base → src}/db/connector_sync.py +1 -1
- package/{knowledge_base → src}/db/feedback_schema.py +2 -2
- package/{knowledge_base → src}/db/igel_schema.py +29 -4
- package/{knowledge_base → src}/db/kg_introspect.py +1 -1
- package/src/db/migrations.py +237 -0
- package/{knowledge_base → src}/db/schema.py +6 -6
- package/{knowledge_base → src}/deploy/Dockerfile +3 -3
- package/{knowledge_base → src}/deploy/feedback_automation.sh +3 -3
- package/{knowledge_base → src}/deploy/firecrawl-docker.sh +4 -4
- package/{knowledge_base → src}/deploy/igel-testgen.service +2 -2
- package/{knowledge_base → src}/deploy/install_reranker.sh +1 -1
- package/{knowledge_base → src}/deploy/requirements.txt +1 -2
- package/{knowledge_base → src}/deploy/run_server.sh +1 -1
- package/{knowledge_base → src}/docs/TEST_GENERATION_GUIDE.md +15 -15
- package/src/embeddings/__pycache__/__init__.cpython-311.pyc +0 -0
- package/src/embeddings/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/embeddings/__pycache__/__init__.cpython-314.pyc +0 -0
- package/src/embeddings/__pycache__/azure_embedder.cpython-311.pyc +0 -0
- package/src/embeddings/__pycache__/azure_embedder.cpython-313.pyc +0 -0
- package/{knowledge_base → src}/embeddings/__pycache__/azure_embedder.cpython-314.pyc +0 -0
- package/{knowledge_base → src}/embeddings/azure_embedder.py +10 -1
- package/{knowledge_base → src}/eval/__init__.py +3 -3
- package/{knowledge_base → src}/eval/__main__.py +7 -7
- package/src/eval/__pycache__/__init__.cpython-311.pyc +0 -0
- package/src/eval/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/eval/__pycache__/__init__.cpython-314.pyc +0 -0
- package/src/eval/__pycache__/baseline.cpython-311.pyc +0 -0
- package/src/eval/__pycache__/baseline.cpython-313.pyc +0 -0
- package/src/eval/__pycache__/baseline.cpython-314.pyc +0 -0
- package/src/eval/__pycache__/harness.cpython-311.pyc +0 -0
- package/src/eval/__pycache__/harness.cpython-313.pyc +0 -0
- package/src/eval/__pycache__/harness.cpython-314.pyc +0 -0
- package/src/eval/__pycache__/scorers.cpython-311.pyc +0 -0
- package/src/eval/__pycache__/scorers.cpython-313.pyc +0 -0
- package/src/eval/__pycache__/scorers.cpython-314.pyc +0 -0
- package/{knowledge_base → src}/eval/harness.py +6 -6
- package/{knowledge_base → src}/feedback/__init__.py +1 -1
- package/{knowledge_base → src}/feedback/analytics.py +1 -1
- package/{knowledge_base → src}/feedback/applier.py +4 -4
- package/{knowledge_base → src}/feedback/curator.py +2 -2
- package/{knowledge_base → src}/feedback/handler.py +1 -1
- package/src/generation/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/generation/__pycache__/__init__.cpython-314.pyc +0 -0
- package/src/generation/__pycache__/input_classifier.cpython-313.pyc +0 -0
- package/src/generation/__pycache__/manual_tc_parser.cpython-313.pyc +0 -0
- package/src/generation/__pycache__/prompts.cpython-313.pyc +0 -0
- package/src/generation/__pycache__/prompts.cpython-314.pyc +0 -0
- package/src/generation/__pycache__/test_generator.cpython-313.pyc +0 -0
- package/src/generation/__pycache__/test_generator.cpython-314.pyc +0 -0
- package/{knowledge_base → src}/generation/input_classifier.py +1 -1
- package/{knowledge_base → src}/generation/prompts.py +1 -1
- package/{knowledge_base → src}/generation/tc_transformer.py +10 -10
- package/{knowledge_base → src}/generation/test_generator.py +56 -10
- package/{knowledge_base → src}/graph_db/__init__.py +1 -1
- package/{knowledge_base → src}/graph_db/graphiti_client.py +2 -2
- package/{knowledge_base → src}/graph_db/kg_traversal.py +3 -3
- package/{knowledge_base → src}/graph_db/migrate_kg.py +4 -4
- package/{knowledge_base → src}/graph_db/neo4j_client.py +1 -1
- package/{knowledge_base → src}/graph_db/temporal_ingest.py +1 -1
- package/{knowledge_base → src}/ingestion/kg_extractor.py +6 -6
- package/{knowledge_base → src}/ingestion/web_ingest.py +6 -6
- package/src/intelligence/__pycache__/__init__.cpython-311.pyc +0 -0
- package/src/intelligence/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/intelligence/__pycache__/diff_analyzer.cpython-311.pyc +0 -0
- package/src/intelligence/__pycache__/diff_analyzer.cpython-313.pyc +0 -0
- package/src/intelligence/__pycache__/routing_engine.cpython-311.pyc +0 -0
- package/src/intelligence/__pycache__/routing_engine.cpython-313.pyc +0 -0
- package/src/intelligence/diff_analyzer.py +109 -0
- package/{knowledge_base → src}/intelligence/execution_ingest.py +3 -3
- package/src/intelligence/routing_engine.py +74 -0
- package/src/mcp/server.ts +384 -0
- package/src/memory/__init__.py +6 -0
- package/src/memory/__pycache__/__init__.cpython-314.pyc +0 -0
- package/src/memory/__pycache__/cognee_client.cpython-314.pyc +0 -0
- package/src/memory/__pycache__/memory_types.cpython-314.pyc +0 -0
- package/{knowledge_base → src}/memory/cognee_client.py +3 -3
- package/src/models/__pycache__/test_requirement.cpython-311.pyc +0 -0
- package/src/models/__pycache__/test_requirement.cpython-313.pyc +0 -0
- package/src/models/__pycache__/test_requirement.cpython-314.pyc +0 -0
- package/{knowledge_base → src}/models/test_requirement.py +12 -7
- package/{knowledge_base → src}/parsers/csv_parser.py +1 -1
- package/{knowledge_base → src}/parsers/doc_parser.py +1 -1
- package/{knowledge_base → src}/parsers/html_parser.py +1 -1
- package/{knowledge_base → src}/parsers/pdf_parser.py +1 -1
- package/src/project/__pycache__/__init__.cpython-311.pyc +0 -0
- package/src/project/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/project/__pycache__/ai_folder.cpython-311.pyc +0 -0
- package/src/project/__pycache__/ai_folder.cpython-313.pyc +0 -0
- package/src/project/__pycache__/context_enricher.cpython-313.pyc +0 -0
- package/src/project/__pycache__/context_projection_builder.cpython-311.pyc +0 -0
- package/src/project/__pycache__/context_projection_builder.cpython-313.pyc +0 -0
- package/src/project/__pycache__/context_requirement_sync.cpython-311.pyc +0 -0
- package/src/project/__pycache__/context_requirement_sync.cpython-313.pyc +0 -0
- package/src/project/ai_folder.py +602 -0
- package/src/project/context_enricher.py +333 -0
- package/src/project/context_projection_builder.py +167 -0
- package/src/project/context_requirement_sync.py +205 -0
- package/src/project/init_check.py +214 -0
- package/src/prompts/__pycache__/prompt_loader.cpython-313.pyc +0 -0
- package/src/prompts/automation_design.md +12 -0
- package/src/prompts/policies/automation_generation_policy.md +11 -0
- package/src/prompts/policies/generation_instructions.md +24 -0
- package/src/prompts/policies/guardrails.md +6 -0
- package/src/prompts/policies/traceability_policy.md +9 -0
- package/src/prompts/prompt_loader.py +56 -0
- package/src/prompts/requirement_understanding.md +17 -0
- package/src/prompts/scenario_generator.md +17 -0
- package/src/prompts/script_generator.md +13 -0
- package/src/prompts/test_case_generator.md +23 -0
- package/src/retrieval/__pycache__/__init__.cpython-311.pyc +0 -0
- package/src/retrieval/__pycache__/__init__.cpython-313.pyc +0 -0
- package/src/retrieval/__pycache__/__init__.cpython-314.pyc +0 -0
- package/src/retrieval/__pycache__/knowledge_graph.cpython-311.pyc +0 -0
- package/src/retrieval/__pycache__/knowledge_graph.cpython-313.pyc +0 -0
- package/src/retrieval/__pycache__/knowledge_graph.cpython-314.pyc +0 -0
- package/src/retrieval/__pycache__/retriever.cpython-311.pyc +0 -0
- package/src/retrieval/__pycache__/retriever.cpython-313.pyc +0 -0
- package/src/retrieval/__pycache__/retriever.cpython-314.pyc +0 -0
- package/src/retrieval/__pycache__/unified_query.cpython-313.pyc +0 -0
- package/src/retrieval/__pycache__/unified_query.cpython-314.pyc +0 -0
- package/{knowledge_base → src}/retrieval/context_fusion.py +3 -3
- package/{knowledge_base → src}/retrieval/knowledge_graph.py +4 -4
- package/{knowledge_base → src}/retrieval/reranker.py +2 -2
- package/{knowledge_base → src}/retrieval/retriever.py +11 -11
- package/{knowledge_base → src}/retrieval/unified_query.py +7 -7
- package/{knowledge_base → src}/retrieval/web_retriever.py +6 -6
- package/{knowledge_base → src}/validators/step_fidelity.py +1 -1
- package/src/vision/__init__.py +0 -0
- package/{knowledge_base → src}/vision/image_describer.py +1 -1
- package/knowledge_base/__pycache__/__init__.cpython-314.pyc +0 -0
- package/knowledge_base/agents/__init__.py +0 -6
- package/knowledge_base/agents/confidence_agent.py +0 -94
- package/knowledge_base/agents/feedback_agent.py +0 -56
- package/knowledge_base/agents/intent_agent.py +0 -76
- package/knowledge_base/agents/requirement_agent.py +0 -71
- package/knowledge_base/agents/testcase_agent.py +0 -111
- package/knowledge_base/agents/workflow_engine.py +0 -87
- package/knowledge_base/cli/generate_qcapps134.py +0 -391
- package/knowledge_base/cli/workflow_cli.py +0 -93
- package/knowledge_base/config/.env +0 -100
- package/knowledge_base/config/.env.example +0 -75
- package/knowledge_base/connectors/bitbucket_connector.py +0 -25
- package/knowledge_base/db/__pycache__/__init__.cpython-314.pyc +0 -0
- package/knowledge_base/db/__pycache__/client.cpython-314.pyc +0 -0
- package/knowledge_base/db/migrations.py +0 -22
- package/knowledge_base/embeddings/__pycache__/__init__.cpython-314.pyc +0 -0
- package/knowledge_base/ingestion/ingest.py +0 -346
- package/knowledge_base/ingestion/ingest_images.py +0 -330
- package/knowledge_base/memory/__init__.py +0 -6
- package/knowledge_base/memory/ingest_memory.py +0 -60
- /package/{knowledge_base → src}/__init__.py +0 -0
- /package/{knowledge_base → src}/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/confidence.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/config.cpython-314.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/config.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/config.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/context_fusion.cpython-314.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/context_fusion.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/feedback_analytics.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/feedback_applier.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/feedback_cli.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/feedback_curator.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/feedback_handler.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/generate.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/generate_qcapps134.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/input_classifier.cpython-314.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/input_classifier.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/kg_extractor.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/knowledge_graph.cpython-314.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/knowledge_graph.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/manual_tc_parser.cpython-314.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/manual_tc_parser.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/precedence.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/prompts.cpython-314.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/prompts.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/reranker.cpython-314.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/reranker.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/retrieval_debug.cpython-314.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/retrieval_debug.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/retriever.cpython-314.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/retriever.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/server.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/tc_transformer.cpython-314.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/tc_transformer.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/test_generator.cpython-314.pyc +0 -0
- /package/{knowledge_base → src}/__pycache__/test_generator.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/fusion_agent.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/fusion_agent.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/graph.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/graph.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/healing_agent.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/intent_agent.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/intent_agent.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/kg_agent.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/kg_agent.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/memory_agent.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/memory_agent.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/rca_agent.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/reflection_agent.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/reflection_agent.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/regression_agent.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/retrieval_agent.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/retrieval_agent.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/script_agent.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/script_agent.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/state.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/state.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/temporal_agent.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/temporal_agent.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/validation_agent.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/agents/__pycache__/validation_agent.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/agents/state.py +0 -0
- /package/{knowledge_base → src}/alembic/__pycache__/env.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/alembic/__pycache__/env.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/alembic/versions/.gitkeep +0 -0
- /package/{knowledge_base → src}/alembic/versions/001_phase0_feedback.py +0 -0
- /package/{knowledge_base → src}/alembic/versions/002_feedback_promotions.py +0 -0
- /package/{knowledge_base → src}/alembic/versions/003_enterprise_hardening.py +0 -0
- /package/{knowledge_base → src}/alembic/versions/__pycache__/001_phase0_feedback.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/alembic/versions/__pycache__/001_phase0_feedback.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/alembic/versions/__pycache__/002_feedback_promotions.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/alembic/versions/__pycache__/002_feedback_promotions.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/api/__init__.py +0 -0
- /package/{knowledge_base → src}/api/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/api/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/api/__pycache__/middleware.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/api/__pycache__/server.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/api/__pycache__/server.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/chunking/__init__.py +0 -0
- /package/{knowledge_base → src}/chunking/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/chunking/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/chunking/__pycache__/chunker.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/chunking/__pycache__/chunker.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/chunking/__pycache__/validators.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/chunking/__pycache__/validators.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/chunking/validators.py +0 -0
- /package/{knowledge_base → src}/cli/__init__.py +0 -0
- /package/{knowledge_base → src}/cli/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/cli/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/cli/__pycache__/feedback_cli.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/cli/__pycache__/feedback_cli.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/cli/__pycache__/generate.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/cli/__pycache__/generate.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/cli/__pycache__/generate_qcapps134.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/config/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/config/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/config/__pycache__/settings.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/config/__pycache__/settings.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/base.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/base.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/bitbucket_connector.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/bitbucket_connector.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/community_connector.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/confluence_connector.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/confluence_connector.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/jira_connector.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/jira_connector.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/kb_igel_connector.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/playwright_fetcher.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/query_bridge.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/search_backends.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/serviceNow_connector.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/serviceNow_connector.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/sync_scheduler.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/sync_scheduler.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/teamcity_connector.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/teamcity_connector.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/testRail_connector.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/testRail_connector.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/connectors/__pycache__/web_fetcher.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/connectors/base.py +0 -0
- /package/{knowledge_base → src}/connectors/playwright_fetcher.py +0 -0
- /package/{knowledge_base → src}/core/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/core/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/core/__pycache__/cache.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/core/__pycache__/circuit_breaker.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/core/__pycache__/confidence.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/core/__pycache__/confidence.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/core/__pycache__/logging_setup.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/core/__pycache__/metrics.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/core/__pycache__/precedence.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/core/__pycache__/precedence.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/core/__pycache__/request_context.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/core/circuit_breaker.py +0 -0
- /package/{knowledge_base → src}/core/metrics.py +0 -0
- /package/{knowledge_base → src}/core/precedence.py +0 -0
- /package/{knowledge_base → src}/core/request_context.py +0 -0
- /package/{knowledge_base → src}/db/__init__.py +0 -0
- /package/{knowledge_base → src}/db/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/db/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/db/__pycache__/client.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/db/__pycache__/client.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/db/__pycache__/connector_sync.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/db/__pycache__/feedback_schema.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/db/__pycache__/feedback_schema.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/db/__pycache__/kg_introspect.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/db/__pycache__/kg_introspect.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/db/__pycache__/schema.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/db/__pycache__/schema.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/embeddings/__init__.py +0 -0
- /package/{knowledge_base → src}/embeddings/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/embeddings/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/embeddings/__pycache__/azure_embedder.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/embeddings/__pycache__/azure_embedder.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/eval/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/eval/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/eval/__pycache__/__main__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/eval/__pycache__/baseline.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/eval/__pycache__/baseline.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/eval/__pycache__/harness.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/eval/__pycache__/harness.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/eval/__pycache__/scorers.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/eval/__pycache__/scorers.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/eval/baseline.py +0 -0
- /package/{knowledge_base → src}/eval/queries_50.json +0 -0
- /package/{knowledge_base → src}/eval/scorers.py +0 -0
- /package/{knowledge_base → src}/exemplars/README.md +0 -0
- /package/{knowledge_base → src}/exemplars/__pycache__/pytest_reference_snippet.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/exemplars/gold_manual_concise_snippet.md +0 -0
- /package/{knowledge_base → src}/exemplars/gold_manual_detailed_snippet.md +0 -0
- /package/{knowledge_base → src}/exemplars/pytest_reference_snippet.py +0 -0
- /package/{knowledge_base → src}/feedback/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/feedback/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/feedback/__pycache__/analytics.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/feedback/__pycache__/analytics.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/feedback/__pycache__/applier.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/feedback/__pycache__/applier.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/feedback/__pycache__/curator.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/feedback/__pycache__/curator.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/feedback/__pycache__/handler.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/feedback/__pycache__/handler.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/generation/__init__.py +0 -0
- /package/{knowledge_base → src}/generation/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/generation/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/generation/__pycache__/input_classifier.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/generation/__pycache__/input_classifier.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/generation/__pycache__/manual_tc_parser.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/generation/__pycache__/manual_tc_parser.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/generation/__pycache__/prompts.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/generation/__pycache__/prompts.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/generation/__pycache__/tc_transformer.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/generation/__pycache__/test_generator.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/generation/__pycache__/test_generator.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/generation/manual_tc_parser.py +0 -0
- /package/{knowledge_base → src}/graph_db/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/graph_db/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/graph_db/__pycache__/graphiti_client.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/graph_db/__pycache__/kg_traversal.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/graph_db/__pycache__/migrate_kg.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/graph_db/__pycache__/neo4j_client.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/graph_db/__pycache__/neo4j_client.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/graph_db/__pycache__/schema.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/graph_db/__pycache__/temporal_ingest.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/graph_db/schema.py +0 -0
- /package/{knowledge_base → src}/ingestion/__init__.py +0 -0
- /package/{knowledge_base → src}/ingestion/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/ingestion/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/ingestion/__pycache__/ingest.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/ingestion/__pycache__/ingest.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/ingestion/__pycache__/ingest_images.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/ingestion/__pycache__/ingest_images.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/ingestion/__pycache__/kg_extractor.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/ingestion/__pycache__/kg_extractor.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/ingestion/__pycache__/web_ingest.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/intelligence/__init__.py +0 -0
- /package/{knowledge_base → src}/intelligence/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/intelligence/__pycache__/execution_ingest.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/intelligence/__pycache__/predictive_engine.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/intelligence/__pycache__/risk_scorer.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/intelligence/predictive_engine.py +0 -0
- /package/{knowledge_base → src}/intelligence/risk_scorer.py +0 -0
- /package/{knowledge_base → src}/memory/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/memory/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/memory/__pycache__/cognee_client.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/memory/__pycache__/cognee_client.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/memory/__pycache__/ingest_memory.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/memory/__pycache__/memory_types.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/memory/__pycache__/memory_types.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/memory/memory_types.py +0 -0
- /package/{knowledge_base → src}/parsers/__init__.py +0 -0
- /package/{knowledge_base → src}/parsers/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/parsers/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/parsers/__pycache__/csv_parser.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/parsers/__pycache__/csv_parser.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/parsers/__pycache__/doc_parser.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/parsers/__pycache__/doc_parser.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/parsers/__pycache__/html_parser.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/parsers/__pycache__/image_extractor.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/parsers/__pycache__/image_extractor.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/parsers/__pycache__/markdown_parser.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/parsers/__pycache__/markdown_parser.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/parsers/__pycache__/pdf_parser.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/parsers/__pycache__/pdf_parser.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/parsers/image_extractor.py +0 -0
- /package/{knowledge_base → src}/parsers/markdown_parser.py +0 -0
- /package/{knowledge_base/vision → src/project}/__init__.py +0 -0
- /package/{knowledge_base → src}/retrieval/__init__.py +0 -0
- /package/{knowledge_base → src}/retrieval/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/retrieval/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/retrieval/__pycache__/context_fusion.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/retrieval/__pycache__/context_fusion.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/retrieval/__pycache__/knowledge_graph.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/retrieval/__pycache__/knowledge_graph.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/retrieval/__pycache__/reranker.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/retrieval/__pycache__/reranker.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/retrieval/__pycache__/retrieval_debug.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/retrieval/__pycache__/retrieval_debug.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/retrieval/__pycache__/retriever.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/retrieval/__pycache__/retriever.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/retrieval/__pycache__/unified_query.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/retrieval/__pycache__/web_retriever.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/retrieval/retrieval_debug.py +0 -0
- /package/{knowledge_base → src}/validators/__init__.py +0 -0
- /package/{knowledge_base → src}/validators/__pycache__/__init__.cpython-314.pyc +0 -0
- /package/{knowledge_base → src}/validators/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/validators/__pycache__/step_fidelity.cpython-314.pyc +0 -0
- /package/{knowledge_base → src}/validators/__pycache__/step_fidelity.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/vision/__pycache__/__init__.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/vision/__pycache__/__init__.cpython-38.pyc +0 -0
- /package/{knowledge_base → src}/vision/__pycache__/image_describer.cpython-37.pyc +0 -0
- /package/{knowledge_base → src}/vision/__pycache__/image_describer.cpython-38.pyc +0 -0
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -12,7 +12,7 @@ from datetime import datetime
|
|
|
12
12
|
from pathlib import Path
|
|
13
13
|
from typing import Any
|
|
14
14
|
|
|
15
|
-
from
|
|
15
|
+
from src.eval.scorers import (
|
|
16
16
|
DomainScorer,
|
|
17
17
|
EvaluationResult,
|
|
18
18
|
ExecutabilityScorer,
|
|
@@ -293,8 +293,8 @@ class EvaluationHarness:
|
|
|
293
293
|
def _persist_run_to_db(self, run: HarnessRun, query_file: Path | str) -> None:
|
|
294
294
|
"""Persist evaluation run to PostgreSQL when EVAL_ENABLED."""
|
|
295
295
|
try:
|
|
296
|
-
from
|
|
297
|
-
from
|
|
296
|
+
from src.config import cfg
|
|
297
|
+
from src.db.feedback_schema import insert_eval_run, insert_eval_results_batch
|
|
298
298
|
|
|
299
299
|
eval_uuid = insert_eval_run(
|
|
300
300
|
run_id=run.run_id,
|
|
@@ -344,14 +344,14 @@ class EvaluationHarness:
|
|
|
344
344
|
backends: tuple[str, ...] = ("postgres", "neo4j"),
|
|
345
345
|
) -> dict:
|
|
346
346
|
"""Compare KG backend quality across queries (Phase 3)."""
|
|
347
|
-
from
|
|
347
|
+
from src.config import cfg
|
|
348
348
|
|
|
349
349
|
queries = self.load_queries(query_file)
|
|
350
350
|
comparison = {"backends": backends, "results": {}}
|
|
351
351
|
|
|
352
352
|
original_backend = cfg.KG_BACKEND
|
|
353
353
|
for backend in backends:
|
|
354
|
-
import
|
|
354
|
+
import src.config as config_module
|
|
355
355
|
config_module.cfg.KG_BACKEND = backend
|
|
356
356
|
run_id = f"backend_{backend}_{Path(query_file).stem}"
|
|
357
357
|
try:
|
|
@@ -363,7 +363,7 @@ class EvaluationHarness:
|
|
|
363
363
|
except Exception as e:
|
|
364
364
|
comparison["results"][backend] = {"error": str(e)}
|
|
365
365
|
|
|
366
|
-
import
|
|
366
|
+
import src.config as config_module
|
|
367
367
|
config_module.cfg.KG_BACKEND = original_backend
|
|
368
368
|
return comparison
|
|
369
369
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"""Human feedback capture, curation, and application."""
|
|
2
2
|
|
|
3
|
-
from
|
|
3
|
+
from src.feedback.handler import apply_feedback, apply_promotion, capture_feedback, curate_feedback
|
|
4
4
|
|
|
5
5
|
__all__ = [
|
|
6
6
|
"apply_feedback",
|
|
@@ -5,10 +5,10 @@ import logging
|
|
|
5
5
|
import re
|
|
6
6
|
from typing import Any
|
|
7
7
|
|
|
8
|
-
from
|
|
9
|
-
from
|
|
10
|
-
from
|
|
11
|
-
from
|
|
8
|
+
from src.db.client import get_conn
|
|
9
|
+
from src.db.feedback_schema import get_feedback_event, list_promotions
|
|
10
|
+
from src.db.schema import ensure_knowledge_graph_tables
|
|
11
|
+
from src.feedback.handler import apply_feedback, apply_promotion
|
|
12
12
|
|
|
13
13
|
logger = logging.getLogger(__name__)
|
|
14
14
|
|
|
@@ -3,8 +3,8 @@ from __future__ import annotations
|
|
|
3
3
|
|
|
4
4
|
import logging
|
|
5
5
|
|
|
6
|
-
from
|
|
7
|
-
from
|
|
6
|
+
from src.db.feedback_schema import get_feedback_event, list_feedback_events, list_promotions
|
|
7
|
+
from src.feedback.handler import apply_feedback, apply_promotion, curate_feedback
|
|
8
8
|
|
|
9
9
|
logger = logging.getLogger(__name__)
|
|
10
10
|
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -9,7 +9,7 @@ import re
|
|
|
9
9
|
from dataclasses import dataclass
|
|
10
10
|
from enum import Enum
|
|
11
11
|
|
|
12
|
-
from
|
|
12
|
+
from src.generation.manual_tc_parser import parse_manual_tc, count_parsed_steps
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
class InputMode(str, Enum):
|
|
@@ -10,14 +10,14 @@ import re
|
|
|
10
10
|
import time
|
|
11
11
|
from dataclasses import dataclass, field
|
|
12
12
|
|
|
13
|
-
from
|
|
13
|
+
from src.generation.input_classifier import (
|
|
14
14
|
Classification,
|
|
15
15
|
DetailLevel,
|
|
16
16
|
InputMode,
|
|
17
17
|
classify_input,
|
|
18
18
|
)
|
|
19
|
-
from
|
|
20
|
-
from
|
|
19
|
+
from src.generation.manual_tc_parser import parse_manual_tc
|
|
20
|
+
from src.generation.prompts import (
|
|
21
21
|
EXPAND_SYSTEM_ADDON,
|
|
22
22
|
TRANSFORM_SYSTEM_ADDON,
|
|
23
23
|
build_expand_markdown_user_prompt,
|
|
@@ -30,8 +30,8 @@ from knowledge_base.generation.prompts import (
|
|
|
30
30
|
kb_trace_lines,
|
|
31
31
|
load_pytest_exemplar,
|
|
32
32
|
)
|
|
33
|
-
from
|
|
34
|
-
from
|
|
33
|
+
from src.retrieval.unified_query import unified_query
|
|
34
|
+
from src.validators.step_fidelity import (
|
|
35
35
|
validate_expand_preservation,
|
|
36
36
|
validate_transform_fidelity,
|
|
37
37
|
)
|
|
@@ -61,31 +61,31 @@ def _bundle_kg_entities(bundle) -> dict | None:
|
|
|
61
61
|
|
|
62
62
|
|
|
63
63
|
def _tg_call_gpt(system: str, user: str, **kwargs):
|
|
64
|
-
from
|
|
64
|
+
from src.generation import test_generator as tg
|
|
65
65
|
|
|
66
66
|
return tg._call_gpt(system, user, **kwargs)
|
|
67
67
|
|
|
68
68
|
|
|
69
69
|
def _tg_strip(code: str) -> str:
|
|
70
|
-
from
|
|
70
|
+
from src.generation import test_generator as tg
|
|
71
71
|
|
|
72
72
|
return tg._strip_code_fences(code)
|
|
73
73
|
|
|
74
74
|
|
|
75
75
|
def _tg_validate_py(code: str):
|
|
76
|
-
from
|
|
76
|
+
from src.generation import test_generator as tg
|
|
77
77
|
|
|
78
78
|
return tg._validate_python_syntax(code)
|
|
79
79
|
|
|
80
80
|
|
|
81
81
|
def _tg_import_warnings(code: str):
|
|
82
|
-
from
|
|
82
|
+
from src.generation import test_generator as tg
|
|
83
83
|
|
|
84
84
|
return tg._check_required_imports(code)
|
|
85
85
|
|
|
86
86
|
|
|
87
87
|
def _infer_feature(topic: str) -> str:
|
|
88
|
-
from
|
|
88
|
+
from src.generation import test_generator as tg
|
|
89
89
|
|
|
90
90
|
return tg._infer_feature_area(topic)
|
|
91
91
|
|
|
@@ -19,9 +19,13 @@ from pathlib import Path
|
|
|
19
19
|
from openai import AzureOpenAI, RateLimitError, APIConnectionError, APITimeoutError
|
|
20
20
|
from tenacity import retry, stop_after_attempt, wait_exponential, retry_if_exception_type
|
|
21
21
|
|
|
22
|
-
from
|
|
23
|
-
from
|
|
24
|
-
from
|
|
22
|
+
from src.config import cfg
|
|
23
|
+
from src.core.model_router import ModelRouter
|
|
24
|
+
from src.retrieval.unified_query import unified_query
|
|
25
|
+
|
|
26
|
+
# Module-level router instance shared across all calls in this process
|
|
27
|
+
_model_router = ModelRouter()
|
|
28
|
+
from src.generation.prompts import (
|
|
25
29
|
PromptContext,
|
|
26
30
|
build_system_prompt,
|
|
27
31
|
build_markdown_user_prompt,
|
|
@@ -135,7 +139,7 @@ def generate_test_cases(
|
|
|
135
139
|
output_dir = output_dir or DEFAULT_OUTPUT_DIR
|
|
136
140
|
output_dir.mkdir(parents=True, exist_ok=True)
|
|
137
141
|
|
|
138
|
-
from
|
|
142
|
+
from src.generation.input_classifier import DetailLevel, InputMode, classify_input
|
|
139
143
|
|
|
140
144
|
try:
|
|
141
145
|
dl = DetailLevel((detail_level or "auto").lower())
|
|
@@ -144,7 +148,7 @@ def generate_test_cases(
|
|
|
144
148
|
cls = classify_input(topic, source_tc, detail_level=dl)
|
|
145
149
|
|
|
146
150
|
if cls.mode in (InputMode.TRANSFORM, InputMode.EXPAND):
|
|
147
|
-
from
|
|
151
|
+
from src.generation.tc_transformer import run_faithful_generation
|
|
148
152
|
|
|
149
153
|
resolved_test_id = test_id or _resolve_test_id(output_dir)
|
|
150
154
|
resolved_feature = feature_area or _infer_feature_area(topic)
|
|
@@ -209,7 +213,7 @@ def generate_test_cases(
|
|
|
209
213
|
if not bundle.results:
|
|
210
214
|
raise ValueError(
|
|
211
215
|
f"No KB content found for topic '{topic}'. "
|
|
212
|
-
"Ensure documents are ingested: python -m
|
|
216
|
+
"Ensure documents are ingested: python -m src.ingestion.ingest"
|
|
213
217
|
)
|
|
214
218
|
|
|
215
219
|
retrieval_debug_json: str | None = bundle.debug.to_json() if debug_retrieval else None
|
|
@@ -223,6 +227,9 @@ def generate_test_cases(
|
|
|
223
227
|
|
|
224
228
|
tokens_used = bundle.debug.total_tokens_used
|
|
225
229
|
|
|
230
|
+
# Step 2b: Load capped feedback for the topic/test_id to inject into context
|
|
231
|
+
feedback_block = _build_feedback_block(resolved_test_id)
|
|
232
|
+
|
|
226
233
|
ctx = PromptContext(
|
|
227
234
|
topic=topic,
|
|
228
235
|
test_id=resolved_test_id,
|
|
@@ -238,6 +245,9 @@ def generate_test_cases(
|
|
|
238
245
|
)
|
|
239
246
|
|
|
240
247
|
system_prompt = build_system_prompt()
|
|
248
|
+
# Append capped feedback to system prompt if available
|
|
249
|
+
if feedback_block:
|
|
250
|
+
system_prompt = system_prompt + "\n\n" + feedback_block
|
|
241
251
|
warnings: list[str] = []
|
|
242
252
|
md_path: Path | None = None
|
|
243
253
|
py_path: Path | None = None
|
|
@@ -247,7 +257,18 @@ def generate_test_cases(
|
|
|
247
257
|
if output_format in ("md", "both"):
|
|
248
258
|
logger.info("Generating markdown for '%s'...", topic)
|
|
249
259
|
markdown_user_prompt = build_markdown_user_prompt(ctx)
|
|
250
|
-
|
|
260
|
+
# Canary: use model router for testcase_generation; other steps use default
|
|
261
|
+
_tc_model = _model_router.route(
|
|
262
|
+
"testcase_generation",
|
|
263
|
+
context_size=len(markdown_user_prompt),
|
|
264
|
+
)
|
|
265
|
+
logger.debug("ModelRouter: testcase_generation → %s", _tc_model.deployment)
|
|
266
|
+
markdown_content = _call_gpt(
|
|
267
|
+
system_prompt, markdown_user_prompt,
|
|
268
|
+
max_tokens=_tc_model.max_tokens,
|
|
269
|
+
temperature=_tc_model.temperature,
|
|
270
|
+
deployment=_tc_model.deployment,
|
|
271
|
+
)
|
|
251
272
|
md_filename = f"{resolved_test_id}_{_slugify(topic)}.md"
|
|
252
273
|
md_path = _safe_write_path(output_dir / md_filename)
|
|
253
274
|
md_ref = format_kb_retrieval_references_markdown(bundle.results)
|
|
@@ -404,10 +425,12 @@ def _call_gpt(
|
|
|
404
425
|
user_prompt: str,
|
|
405
426
|
max_tokens: int = 4096,
|
|
406
427
|
temperature: float = 0.2,
|
|
428
|
+
deployment: str | None = None,
|
|
407
429
|
) -> str:
|
|
430
|
+
"""Call Azure OpenAI. deployment overrides cfg.AZURE_DEPLOYMENT when provided."""
|
|
408
431
|
client = _get_llm_client()
|
|
409
432
|
response = client.chat.completions.create(
|
|
410
|
-
model=cfg.AZURE_DEPLOYMENT,
|
|
433
|
+
model=deployment or cfg.AZURE_DEPLOYMENT,
|
|
411
434
|
messages=[
|
|
412
435
|
{"role": "system", "content": system_prompt},
|
|
413
436
|
{"role": "user", "content": user_prompt},
|
|
@@ -422,6 +445,29 @@ def _call_gpt(
|
|
|
422
445
|
|
|
423
446
|
# ── Post-Processing ───────────────────────────────────────────────────────────
|
|
424
447
|
|
|
448
|
+
def _build_feedback_block(test_id: str) -> str:
|
|
449
|
+
"""Retrieve capped feedback for test_id and format as a system prompt appendix.
|
|
450
|
+
|
|
451
|
+
Returns an empty string if no feedback is found or on any error.
|
|
452
|
+
Cap: 5 items / 800 chars total (enforced by FeedbackAgent.get_feedback_for_target).
|
|
453
|
+
"""
|
|
454
|
+
try:
|
|
455
|
+
from src.agents.feedback_agent import FeedbackAgent
|
|
456
|
+
items = FeedbackAgent().get_feedback_for_target(test_id, limit=5, max_chars=800)
|
|
457
|
+
if not items:
|
|
458
|
+
return ""
|
|
459
|
+
lines = ["## Historical Feedback (apply these corrections)"]
|
|
460
|
+
for i, fb in enumerate(items, 1):
|
|
461
|
+
fb_type = fb.get("type", "correction")
|
|
462
|
+
comment = fb.get("comment", "").strip()
|
|
463
|
+
if comment:
|
|
464
|
+
lines.append(f"{i}. [{fb_type}] {comment}")
|
|
465
|
+
return "\n".join(lines) if len(lines) > 1 else ""
|
|
466
|
+
except Exception as e:
|
|
467
|
+
logger.debug("_build_feedback_block: non-fatal error for %s: %s", test_id, e)
|
|
468
|
+
return ""
|
|
469
|
+
|
|
470
|
+
|
|
425
471
|
def _strip_code_fences(code: str) -> str:
|
|
426
472
|
code = re.sub(r"^```python\s*\n?", "", code, flags=re.MULTILINE)
|
|
427
473
|
code = re.sub(r"^```\s*\n?", "", code, flags=re.MULTILINE)
|
|
@@ -499,7 +545,7 @@ def _build_minimal_spec(ctx: PromptContext) -> str:
|
|
|
499
545
|
f"Product: {ctx.product or 'IGEL OS 12'}\n\n"
|
|
500
546
|
"Generate full executable test steps from the KNOWLEDGE BASE CONTEXT in the same prompt:\n"
|
|
501
547
|
"- Match exact paths, commands, and UI strings from the KB; do not generalize.\n"
|
|
502
|
-
"- See repository guide:
|
|
548
|
+
"- See repository guide: src/TEST_GENERATION_GUIDE.md\n"
|
|
503
549
|
)
|
|
504
550
|
|
|
505
551
|
|
|
@@ -540,7 +586,7 @@ def _score_output(
|
|
|
540
586
|
"""Compute confidence scores when evaluation is enabled."""
|
|
541
587
|
if not cfg.EVAL_ENABLED:
|
|
542
588
|
return None
|
|
543
|
-
from
|
|
589
|
+
from src.core.confidence import flatten_confidence_for_api, score_generation
|
|
544
590
|
|
|
545
591
|
raw = score_generation(
|
|
546
592
|
query=topic,
|
|
@@ -5,9 +5,9 @@ import logging
|
|
|
5
5
|
import re
|
|
6
6
|
from typing import Any
|
|
7
7
|
|
|
8
|
-
from
|
|
9
|
-
from
|
|
10
|
-
from
|
|
8
|
+
from src.config import cfg
|
|
9
|
+
from src.graph_db.neo4j_client import get_neo4j_client
|
|
10
|
+
from src.retrieval.knowledge_graph import KGContext
|
|
11
11
|
|
|
12
12
|
logger = logging.getLogger(__name__)
|
|
13
13
|
|
|
@@ -2,16 +2,16 @@
|
|
|
2
2
|
Migrate PostgreSQL knowledge graph to Neo4j (Phase 3).
|
|
3
3
|
|
|
4
4
|
Usage:
|
|
5
|
-
python -m
|
|
5
|
+
python -m src.graph_db.migrate_kg [--dry-run]
|
|
6
6
|
"""
|
|
7
7
|
from __future__ import annotations
|
|
8
8
|
|
|
9
9
|
import argparse
|
|
10
10
|
import logging
|
|
11
11
|
|
|
12
|
-
from
|
|
13
|
-
from
|
|
14
|
-
from
|
|
12
|
+
from src.db.client import get_conn, init_pool
|
|
13
|
+
from src.graph_db.neo4j_client import get_neo4j_client, should_write_neo4j
|
|
14
|
+
from src.graph_db.schema import apply_schema
|
|
15
15
|
|
|
16
16
|
logger = logging.getLogger(__name__)
|
|
17
17
|
|
|
@@ -11,10 +11,10 @@ import argparse
|
|
|
11
11
|
import logging
|
|
12
12
|
import re
|
|
13
13
|
|
|
14
|
-
from
|
|
15
|
-
from
|
|
16
|
-
from
|
|
17
|
-
from
|
|
14
|
+
from src.config import cfg
|
|
15
|
+
from src.db.client import close_pool, get_conn, init_pool
|
|
16
|
+
from src.db.kg_introspect import clear_kg_layout_cache
|
|
17
|
+
from src.db.schema import ensure_knowledge_graph_tables
|
|
18
18
|
|
|
19
19
|
logger = logging.getLogger(__name__)
|
|
20
20
|
|
|
@@ -141,7 +141,7 @@ _CROSS_REF_RE = re.compile(r"(?:see|refer to|documented in|depends on)\s+([^\n.]
|
|
|
141
141
|
def _llm_extract_entities(content: str, title: str | None) -> dict:
|
|
142
142
|
"""LLM-assisted entity extraction for orphan parent chunks."""
|
|
143
143
|
try:
|
|
144
|
-
from
|
|
144
|
+
from src.generation.test_generator import _call_gpt
|
|
145
145
|
prompt = f"""Extract structured entities from this IGEL documentation section.
|
|
146
146
|
Return JSON only with keys: registry_keys (list), ui_paths (list), products (list),
|
|
147
147
|
versions (list), error_codes (list), cli_commands (list), related_features (list).
|
|
@@ -307,7 +307,7 @@ def _extract_single_parent(cur, pid: str, content: str, title: str | None) -> tu
|
|
|
307
307
|
def _shadow_write_neo4j(feature_name: str, blob: str) -> None:
|
|
308
308
|
"""Dual-write extracted entities to Neo4j when shadow mode is enabled (Phase 3)."""
|
|
309
309
|
try:
|
|
310
|
-
from
|
|
310
|
+
from src.graph_db.neo4j_client import get_neo4j_client, should_write_neo4j
|
|
311
311
|
|
|
312
312
|
if not should_write_neo4j():
|
|
313
313
|
return
|
|
@@ -5,10 +5,10 @@ from __future__ import annotations
|
|
|
5
5
|
import hashlib
|
|
6
6
|
import logging
|
|
7
7
|
|
|
8
|
-
from
|
|
9
|
-
from
|
|
10
|
-
from
|
|
11
|
-
from
|
|
8
|
+
from src.chunking.chunker import chunk_sections
|
|
9
|
+
from src.config import cfg
|
|
10
|
+
from src.db.client import init_pool
|
|
11
|
+
from src.db.schema import (
|
|
12
12
|
clear_document_chunks,
|
|
13
13
|
document_exists,
|
|
14
14
|
document_has_chunks,
|
|
@@ -34,7 +34,7 @@ def ingest_web_items(items: list[dict], *, source_label: str = "web") -> int:
|
|
|
34
34
|
product = item.get("product", "IGEL")
|
|
35
35
|
|
|
36
36
|
if not sections and item.get("raw_text"):
|
|
37
|
-
from
|
|
37
|
+
from src.parsers.markdown_parser import Section
|
|
38
38
|
|
|
39
39
|
sections = [
|
|
40
40
|
Section(
|
|
@@ -57,7 +57,7 @@ def ingest_web_items(items: list[dict], *, source_label: str = "web") -> int:
|
|
|
57
57
|
for w in warnings[:5]:
|
|
58
58
|
logger.debug("web_ingest warning: %s", w)
|
|
59
59
|
|
|
60
|
-
from
|
|
60
|
+
from src.embeddings.azure_embedder import embed_texts, format_for_pgvector
|
|
61
61
|
|
|
62
62
|
_, _, doc_children, _ = ingest_document_atomic(
|
|
63
63
|
file_name=file_name,
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
"""Diff Analyzer for scope-limited framework analysis.
|
|
2
|
+
|
|
3
|
+
Purpose:
|
|
4
|
+
- Compute impacted scope from changed files before heavy analysis/indexing.
|
|
5
|
+
- Prevent full-repo processing on pull/merge when only a subset changed.
|
|
6
|
+
"""
|
|
7
|
+
from __future__ import annotations
|
|
8
|
+
|
|
9
|
+
import ast
|
|
10
|
+
from pathlib import Path
|
|
11
|
+
from typing import Iterable
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
def _to_repo_relative(path: Path, repo_root: Path) -> Path:
|
|
15
|
+
try:
|
|
16
|
+
return path.resolve().relative_to(repo_root.resolve())
|
|
17
|
+
except Exception:
|
|
18
|
+
return path
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
def _module_name(py_file: Path, repo_root: Path) -> str:
|
|
22
|
+
rel = _to_repo_relative(py_file, repo_root)
|
|
23
|
+
no_suffix = rel.with_suffix("")
|
|
24
|
+
return ".".join(no_suffix.parts)
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
def _extract_imported_modules(py_file: Path) -> set[str]:
|
|
28
|
+
try:
|
|
29
|
+
tree = ast.parse(py_file.read_text(encoding="utf-8"))
|
|
30
|
+
except Exception:
|
|
31
|
+
return set()
|
|
32
|
+
|
|
33
|
+
modules: set[str] = set()
|
|
34
|
+
for node in ast.walk(tree):
|
|
35
|
+
if isinstance(node, ast.Import):
|
|
36
|
+
for alias in node.names:
|
|
37
|
+
modules.add(alias.name)
|
|
38
|
+
elif isinstance(node, ast.ImportFrom):
|
|
39
|
+
if node.module:
|
|
40
|
+
modules.add(node.module)
|
|
41
|
+
return modules
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
def _is_script_path(path: Path) -> bool:
|
|
45
|
+
p = str(path).lower()
|
|
46
|
+
return (
|
|
47
|
+
p.startswith("tests/")
|
|
48
|
+
or p.startswith("test/")
|
|
49
|
+
or "script" in p
|
|
50
|
+
or p.endswith(".feature")
|
|
51
|
+
)
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
def analyze_diff_scope(repo_root: Path, changed_files: Iterable[Path]) -> dict:
|
|
55
|
+
"""Return impacted scope package for downstream analyzers.
|
|
56
|
+
|
|
57
|
+
Args:
|
|
58
|
+
repo_root: Repository root path.
|
|
59
|
+
changed_files: Changed paths (relative or absolute).
|
|
60
|
+
|
|
61
|
+
Returns:
|
|
62
|
+
dict containing changed modules/files and impacted dependency hints.
|
|
63
|
+
"""
|
|
64
|
+
repo_root = repo_root.resolve()
|
|
65
|
+
normalized: list[Path] = []
|
|
66
|
+
for p in changed_files:
|
|
67
|
+
p = Path(p)
|
|
68
|
+
full = p if p.is_absolute() else (repo_root / p)
|
|
69
|
+
if full.exists():
|
|
70
|
+
normalized.append(full.resolve())
|
|
71
|
+
|
|
72
|
+
changed_rel = [_to_repo_relative(p, repo_root) for p in normalized]
|
|
73
|
+
changed_modules = {
|
|
74
|
+
_module_name(p, repo_root)
|
|
75
|
+
for p in normalized
|
|
76
|
+
if p.suffix == ".py"
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
dependent_files: set[Path] = set()
|
|
80
|
+
dependent_scripts: set[Path] = set()
|
|
81
|
+
|
|
82
|
+
# Reverse-import approximation for Python files in repo.
|
|
83
|
+
for py_file in repo_root.rglob("*.py"):
|
|
84
|
+
if "/.venv/" in str(py_file) or "/node_modules/" in str(py_file):
|
|
85
|
+
continue
|
|
86
|
+
imports = _extract_imported_modules(py_file)
|
|
87
|
+
if any(any(m == imp or imp.startswith(m + ".") for imp in imports) for m in changed_modules):
|
|
88
|
+
rel = _to_repo_relative(py_file, repo_root)
|
|
89
|
+
dependent_files.add(rel)
|
|
90
|
+
if _is_script_path(rel):
|
|
91
|
+
dependent_scripts.add(rel)
|
|
92
|
+
|
|
93
|
+
impacted_assets = {
|
|
94
|
+
p for p in changed_rel
|
|
95
|
+
if str(p).startswith(("core/", "ui/", "bussiness/", "src/"))
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
analysis_targets = sorted({*changed_rel, *dependent_files}, key=lambda x: str(x))
|
|
99
|
+
|
|
100
|
+
return {
|
|
101
|
+
"changed_files": [str(p) for p in sorted(changed_rel, key=lambda x: str(x))],
|
|
102
|
+
"changed_modules": sorted(changed_modules),
|
|
103
|
+
"dependent_files": [str(p) for p in sorted(dependent_files, key=lambda x: str(x))],
|
|
104
|
+
"dependent_scripts": [str(p) for p in sorted(dependent_scripts, key=lambda x: str(x))],
|
|
105
|
+
"impacted_assets": [str(p) for p in sorted(impacted_assets, key=lambda x: str(x))],
|
|
106
|
+
# Placeholder until business rule registry links are fully wired.
|
|
107
|
+
"impacted_business_rules": [],
|
|
108
|
+
"analysis_targets": [str(p) for p in analysis_targets],
|
|
109
|
+
}
|
|
@@ -3,9 +3,9 @@ from __future__ import annotations
|
|
|
3
3
|
|
|
4
4
|
import logging
|
|
5
5
|
|
|
6
|
-
from
|
|
7
|
-
from
|
|
8
|
-
from
|
|
6
|
+
from src.config import cfg
|
|
7
|
+
from src.memory.cognee_client import get_cognee_client
|
|
8
|
+
from src.memory.memory_types import MemoryType
|
|
9
9
|
|
|
10
10
|
logger = logging.getLogger(__name__)
|
|
11
11
|
|