agent-framework-lib 0.8.4.post5__tar.gz → 0.8.5__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.
- {agent_framework_lib-0.8.4.post5/agent_framework_lib.egg-info → agent_framework_lib-0.8.5}/PKG-INFO +1 -1
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/__init__.py +1 -1
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/base_agent.py +41 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/implementation_validator.py +1 -1
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/memory/hypothesis_engine.py +177 -131
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/tools/shell_tool.py +40 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/workspace/client.py +71 -1
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/workspace/models.py +37 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/workspace/router.py +371 -15
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/workspace/subscription.py +15 -2
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5/agent_framework_lib.egg-info}/PKG-INFO +1 -1
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/pyproject.toml +1 -1
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/ARCHITECTURE.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/LICENSE +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/MANIFEST.in +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/README.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/a2a/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/a2a/base.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/a2a/endpoints/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/a2a/endpoints/a2a_router.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/a2a/endpoints/agent_card_builder.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/a2a/endpoints/agent_card_skill_builder.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/a2a/endpoints/jsonrpc_dispatcher.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/a2a/endpoints/models_jsonrpc.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/a2a/endpoints/sse_wrapper.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/a2a/endpoints/translation_layer.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/a2a/models.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/a2a/providers/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/a2a/providers/elasticsearch_provider.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/a2a/providers/postgres_provider.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/capabilities/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/capabilities/resolver.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/activity_formatter.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/agent_interface.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/agent_provider.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/context_budget.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/context_summarizer.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/elasticsearch_config_provider.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/execution_controller.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/interruption_message.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/knowledge_state.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/loop_detector.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/model_clients.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/model_config.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/model_router.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/models.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/provider_calibration.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/scratchpad_compressor.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/scratchpad_serializer.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/state_manager.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/step_display_config.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/streaming_parts_accumulator.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/implementations/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/implementations/budget_aware_agent.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/implementations/llamaindex_agent.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/implementations/llamaindex_memory_adapter.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/implementations/microsoft_agent.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/memory/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/memory/agent_mixin.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/memory/base.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/memory/config.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/memory/implicit_feedback.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/memory/manager.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/memory/personalization.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/memory/providers/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/memory/providers/graphiti_provider.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/memory/providers/memori_provider.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/memory/response_lessons.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/memory/tools.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/memory/work_patterns.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/api_timing_tracker.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/elasticsearch_circuit_breaker.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/elasticsearch_logging.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/error_handling.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/error_logging.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/llm_auto_instrumentor.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/llm_metrics.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/llm_metrics_collector.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/llm_metrics_extractor.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/metrics_aggregator.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/metrics_config.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/observability_manager.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/otel_instrumentor.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/otel_logging_handler.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/otel_metrics_recorder.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/otel_setup.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/performance_monitor.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/progress_tracker.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/resource_manager.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/resource_metrics_collector.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/streaming_latency_tracer.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/timing_tracker.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/token_counter.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/monitoring/tracing_context.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/notifications/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/notifications/hub.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/notifications/webhook_notifier.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/processing/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/processing/ai_content_management.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/processing/markdown_converter.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/processing/multimodal_integration.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/processing/rich_content_validation.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/py.typed +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/session/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/session/elasticsearch_session_storage.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/session/session_storage.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/agent_mixin.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/base.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/scripts/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/scripts/create_and_register.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/scripts/register_to_storage.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/chart/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/chart/chart_to_image.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/code_format/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/code_format/format_python.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/csv/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/csv/create_csv.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/csv/read_csv.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/csv/transform_csv.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/data_format/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/data_format/json_to_yaml.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/data_format/yaml_to_json.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/drawio/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/drawio/create_drawio.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/email_template/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/excel/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/excel/create_excel.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/file/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/file/create_file.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/file/list_files.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/file/read_file.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/file_access/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/file_access/download_to_local.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/file_access/get_file_path.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/form/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/image_display/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/image_gen/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/image_gen/create_image.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/image_gen/generate_image.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/mermaid/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/mermaid/mermaid_to_image.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/multimodal/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/optionsblock/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/powerpoint/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/powerpoint/create_powerpoint.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/powerpoint/templates/Big Data Infographics.pptx +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/powerpoint/templates/Executive Design Pitch Deck.pptx +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/powerpoint/templates/Management Consulting Toolkit.pptx +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/powerpoint/templates/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/powerpoint/templates/generate_templates.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/skill_creator/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/skill_creator/skill_api.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/table/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/table/table_to_image.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/unified_pdf/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/unified_pdf/create_pdf.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/web_news_search/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/web_news_search/web_news_search.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/word/SKILL.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/builtin/skills/word/create_word.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/custom_skill_manager.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/discovery_prompt.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/markdown_loader.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/skills/tools.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/storage/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/storage/file_storages.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/storage/file_system_management.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/storage/storage_optimizer.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/subagents/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/subagents/executor.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/subagents/message_injector.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/subagents/message_queue.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/subagents/retrigger.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/subagents/spawn_tool.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/tools/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/tools/activity_callback.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/tools/adaptive_pdf_css.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/tools/base.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/tools/html_content_analyzer.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/tools/multimodal_tools.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/tools/pdf_image_scaler.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/tools/sizing_config.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/tools/web_fetch_tool.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/tools/web_search_tool.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/utils/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/utils/path_utils.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/utils/post_install.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/utils/session_title_generator.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/utils/source_detector.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/utils/special_blocks.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/admin_auth.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/admin_models.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/admin_router.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/admin_services.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/api_timing_middleware.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/A2A_GUIDE.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/BUILTIN_SKILLS_REFERENCE.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/CREATING_AGENTS.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/CUSTOM_SKILLS_GUIDE.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/DOCKER_SETUP.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/Dockerfile +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/GETTING_STARTED.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/GITNEXUS_USER_GUIDE.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/MEMORY_INSTALLATION.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/README.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/TOOLS_AND_MCP_GUIDE.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/WORKSPACE_INTEGRATION.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/api-reference.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/configuration.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/docker-compose.yml +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/examples/agent_example_multi_skills.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/examples/agent_with_file_storage.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/examples/agent_with_mcp.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/examples/agent_with_memory.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/examples/agent_with_memory_graphiti.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/examples/agent_with_memory_hybrid.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/examples/agent_with_memory_simple.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/examples/custom_framework_agent.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/examples/simple_agent.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/examples/skills_demo_agent.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/docs/installation-guide.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/documentation_generator.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/gitnexus_client.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/helper_agent.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/helper_ui.html +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/modern_ui.html +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/observability/kibana-llm-dashboard-setup.json +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/observability/kibana-resource-metrics-dashboard.json +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/otel_tracing_middleware.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/server.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/skills_router.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/web/test_app.html +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/workspace/__init__.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/workspace/artefacts.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/workspace/config.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/workspace/context.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/workspace/cursor.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/workspace/memory.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/workspace/poller.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/workspace/preferences.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/workspace/session.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework_lib.egg-info/SOURCES.txt +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework_lib.egg-info/dependency_links.txt +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework_lib.egg-info/entry_points.txt +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework_lib.egg-info/requires.txt +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework_lib.egg-info/top_level.txt +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/A2A_GUIDE.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/ACTIVITY_OUTPUT_PART.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/ARCHITECTURE_DIAGRAM.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/BUILTIN_SKILLS_REFERENCE.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/CANCEL_AND_INTERRUPT_FRONTEND.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/CONCURRENCE_VS_PARALLELISME_GUIDE.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/CREATING_AGENTS.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/CUSTOM_SKILLS_GUIDE.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/DEEPEVAL_TEST_REPORT.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/DOCKER_SETUP.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/ELASTICSEARCH_DATA_STRUCTURES.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/FILE_DOWNLOAD_LINKS.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/FILE_STORAGE_GUIDE.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/GETTING_STARTED.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/GITNEXUS_USER_GUIDE.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/HISTORY_MESSAGE_FORMAT.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/IMPLEMENTATION_GUIDE_NEW_AGENT.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/MEMORY_INSTALLATION.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/MODIFICATIONS_CONCURRENCE.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/MULTIMODAL_TOOLS_GUIDE.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/OBSERVABILITY_GUIDE.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/PYPI_PUBLISHING.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/QA_STREAMING_LATENCY.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/SCREENSHOTS_GUIDE.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/SPEC_CROSS_MODEL_HISTORY_CONVERSION.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/SSE_NOTIFICATIONS_GUIDE.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/STREAMING_EVENTS_FRONTEND.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/TOOLS_AND_MCP_GUIDE.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/WORKSPACE_INTEGRATION.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/api-reference.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/configuration.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/framework_audit_remarques.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/helper_agent.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/index.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/docs/installation-guide.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/README.md +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/agent_context_budget_test.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/agent_example_multi_skills.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/agent_exemple_test.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/agent_training_with_apo.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/agent_with_custom_tools_file_storage.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/agent_with_file_storage.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/agent_with_mcp.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/agent_with_memory_graphiti.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/agent_with_memory_hybrid.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/agent_with_memory_simple.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/agent_with_personalization.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/biagenttest.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/custom_framework_agent.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/dependencies/docker-compose.yaml +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/pyproject.toml +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/simple_agent.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/skills_demo_agent.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/test_work_patterns_live.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/examples/workspace_test_agent.py +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/setup.cfg +0 -0
- {agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/setup.py +0 -0
{agent_framework_lib-0.8.4.post5/agent_framework_lib.egg-info → agent_framework_lib-0.8.5}/PKG-INFO
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: agent-framework-lib
|
|
3
|
-
Version: 0.8.
|
|
3
|
+
Version: 0.8.5
|
|
4
4
|
Summary: A comprehensive Python framework for building and serving conversational AI agents with FastAPI
|
|
5
5
|
Author-email: Sebastian Pavel <sebastian@cinco.ai>, Elliott Girard <elliott.girard@icloud.com>
|
|
6
6
|
Maintainer-email: Sebastian Pavel <sebastian@cinco.ai>
|
{agent_framework_lib-0.8.4.post5 → agent_framework_lib-0.8.5}/agent_framework/core/base_agent.py
RENAMED
|
@@ -31,6 +31,8 @@ if TYPE_CHECKING:
|
|
|
31
31
|
from ..subagents.executor import SubagentExecutor
|
|
32
32
|
from ..subagents.message_queue import SessionMessageQueue
|
|
33
33
|
from ..subagents.spawn_tool import SubagentSpawnTool
|
|
34
|
+
from ..tools.shell_tool import ShellTool
|
|
35
|
+
from ..workspace.models import Workspace
|
|
34
36
|
|
|
35
37
|
from ..monitoring.streaming_latency_tracer import get_streaming_latency_tracer
|
|
36
38
|
from ..utils.special_blocks import parse_special_blocks_from_text
|
|
@@ -248,6 +250,13 @@ class BaseAgent(SkillsMixin, MemoryMixin, AgentInterface):
|
|
|
248
250
|
self._current_spawn_depth: int = 0
|
|
249
251
|
self._file_storage_session_id: str | None = None
|
|
250
252
|
|
|
253
|
+
# Workspace context (optional, injected by workspace router)
|
|
254
|
+
self._workspace_secrets: dict[str, str] = {}
|
|
255
|
+
self._workspace_context: Workspace | None = None
|
|
256
|
+
self._live_shell_tool: ShellTool | None = None
|
|
257
|
+
self._pending_workspace_update: Workspace | None = None
|
|
258
|
+
self._pending_workspace_apply: Any | None = None
|
|
259
|
+
|
|
251
260
|
# Initialize parent classes (including SkillsMixin and MemoryMixin if available)
|
|
252
261
|
super().__init__()
|
|
253
262
|
|
|
@@ -351,6 +360,22 @@ class BaseAgent(SkillsMixin, MemoryMixin, AgentInterface):
|
|
|
351
360
|
"""
|
|
352
361
|
return None
|
|
353
362
|
|
|
363
|
+
def set_workspace_metadata(self, workspace: Workspace | None) -> None:
|
|
364
|
+
"""Store workspace context + secrets on the agent.
|
|
365
|
+
|
|
366
|
+
Updates the live ``ShellTool`` (if any) immediately so the next
|
|
367
|
+
``shell_exec`` call sees fresh secrets without an agent rebuild.
|
|
368
|
+
Does NOT trigger a rebuild on its own — callers control when the
|
|
369
|
+
system prompt is refreshed (see ``configure_session``).
|
|
370
|
+
"""
|
|
371
|
+
self._workspace_context = workspace
|
|
372
|
+
self._workspace_secrets = workspace.secret_entries() if workspace else {}
|
|
373
|
+
if self._live_shell_tool is not None:
|
|
374
|
+
try:
|
|
375
|
+
self._live_shell_tool.set_workspace_secrets(self._workspace_secrets)
|
|
376
|
+
except Exception as e:
|
|
377
|
+
logger.warning(f"Could not propagate workspace secrets to live ShellTool: {e}")
|
|
378
|
+
|
|
354
379
|
def set_subagent_executor(self, executor: SubagentExecutor | None) -> None:
|
|
355
380
|
"""Inject or remove the shared SubagentExecutor.
|
|
356
381
|
|
|
@@ -607,6 +632,8 @@ class BaseAgent(SkillsMixin, MemoryMixin, AgentInterface):
|
|
|
607
632
|
user_id=getattr(self, "_current_user_id", None),
|
|
608
633
|
session_id=getattr(self, "_current_session_id", None),
|
|
609
634
|
)
|
|
635
|
+
shell_tool.set_workspace_secrets(self._workspace_secrets)
|
|
636
|
+
self._live_shell_tool = shell_tool
|
|
610
637
|
tools.append(shell_tool.get_tool_function())
|
|
611
638
|
except Exception as e:
|
|
612
639
|
logger.warning(f"Could not create ShellTool: {e}")
|
|
@@ -1239,6 +1266,20 @@ class BaseAgent(SkillsMixin, MemoryMixin, AgentInterface):
|
|
|
1239
1266
|
yield StructuredAgentOutput(response_text="Input query cannot be empty.", parts=[])
|
|
1240
1267
|
return
|
|
1241
1268
|
|
|
1269
|
+
# Apply any workspace update that was deferred because a previous
|
|
1270
|
+
# turn was streaming. Runs before _async_ensure_agent_built() so the
|
|
1271
|
+
# rebuild (if needed) sees the fresh context. Last-writer-wins.
|
|
1272
|
+
pending_apply = self._pending_workspace_apply
|
|
1273
|
+
if pending_apply is not None:
|
|
1274
|
+
self._pending_workspace_apply = None
|
|
1275
|
+
self._pending_workspace_update = None
|
|
1276
|
+
try:
|
|
1277
|
+
result = pending_apply()
|
|
1278
|
+
if hasattr(result, "__await__"):
|
|
1279
|
+
await result
|
|
1280
|
+
except Exception as e:
|
|
1281
|
+
logger.warning(f"Pending workspace update failed to apply: {e}")
|
|
1282
|
+
|
|
1242
1283
|
# Get tracer for instrumentation
|
|
1243
1284
|
tracer = get_streaming_latency_tracer()
|
|
1244
1285
|
|
|
@@ -312,7 +312,7 @@ class AgentImplementationValidator:
|
|
|
312
312
|
hints = get_type_hints(run_agent) if hasattr(run_agent, "__annotations__") else {}
|
|
313
313
|
except NameError:
|
|
314
314
|
hints = {}
|
|
315
|
-
return_hint = hints.get("return"
|
|
315
|
+
return_hint = hints.get("return")
|
|
316
316
|
if return_hint is None:
|
|
317
317
|
self.report.add_warning(
|
|
318
318
|
"signature",
|
|
@@ -37,6 +37,7 @@ from datetime import datetime
|
|
|
37
37
|
from enum import Enum
|
|
38
38
|
from typing import Any
|
|
39
39
|
|
|
40
|
+
|
|
40
41
|
logger = logging.getLogger(__name__)
|
|
41
42
|
|
|
42
43
|
|
|
@@ -216,7 +217,7 @@ class Hypothesis:
|
|
|
216
217
|
}
|
|
217
218
|
|
|
218
219
|
@classmethod
|
|
219
|
-
def from_dict(cls, data: dict[str, Any]) ->
|
|
220
|
+
def from_dict(cls, data: dict[str, Any]) -> Hypothesis:
|
|
220
221
|
"""Désérialise depuis un dictionnaire.
|
|
221
222
|
|
|
222
223
|
Args:
|
|
@@ -516,14 +517,16 @@ class ConversationalPairAnalyzer:
|
|
|
516
517
|
|
|
517
518
|
followup_nature = self.classify_followup_nature(current_preview)
|
|
518
519
|
|
|
519
|
-
pairs.append(
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
520
|
+
pairs.append(
|
|
521
|
+
ConversationalPair(
|
|
522
|
+
agent_response_preview=prev_preview,
|
|
523
|
+
user_followup_preview=current_preview,
|
|
524
|
+
initial_intent=initial_intent,
|
|
525
|
+
followup_nature=followup_nature,
|
|
526
|
+
resource_context=resource_context,
|
|
527
|
+
timestamp=timestamp,
|
|
528
|
+
)
|
|
529
|
+
)
|
|
527
530
|
|
|
528
531
|
# --- Source 2: implicit_feedback entries ---
|
|
529
532
|
for entry in feedback_entries:
|
|
@@ -538,14 +541,16 @@ class ConversationalPairAnalyzer:
|
|
|
538
541
|
|
|
539
542
|
followup_nature = self.classify_followup_nature(user_preview)
|
|
540
543
|
|
|
541
|
-
pairs.append(
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
544
|
+
pairs.append(
|
|
545
|
+
ConversationalPair(
|
|
546
|
+
agent_response_preview=agent_preview,
|
|
547
|
+
user_followup_preview=user_preview,
|
|
548
|
+
initial_intent=initial_intent,
|
|
549
|
+
followup_nature=followup_nature,
|
|
550
|
+
resource_context=None,
|
|
551
|
+
timestamp=timestamp,
|
|
552
|
+
)
|
|
553
|
+
)
|
|
549
554
|
|
|
550
555
|
# Sort by timestamp (oldest first)
|
|
551
556
|
pairs.sort(key=lambda p: p.timestamp)
|
|
@@ -573,11 +578,26 @@ class ConversationalPairAnalyzer:
|
|
|
573
578
|
return FollowupNature.COMPLEMENT_CONTEXTUEL
|
|
574
579
|
|
|
575
580
|
scores: list[tuple[FollowupNature, int]] = [
|
|
576
|
-
(
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
(
|
|
581
|
+
(
|
|
582
|
+
FollowupNature.SUPPORT_VISUEL,
|
|
583
|
+
_count_pattern_matches(user_followup, _VISUAL_SUPPORT_PATTERNS),
|
|
584
|
+
),
|
|
585
|
+
(
|
|
586
|
+
FollowupNature.APPROFONDISSEMENT,
|
|
587
|
+
_count_pattern_matches(user_followup, _DEEPENING_PATTERNS),
|
|
588
|
+
),
|
|
589
|
+
(
|
|
590
|
+
FollowupNature.REFORMATAGE,
|
|
591
|
+
_count_pattern_matches(user_followup, _REFORMATTING_PATTERNS),
|
|
592
|
+
),
|
|
593
|
+
(
|
|
594
|
+
FollowupNature.ILLUSTRATION_CONCRETE,
|
|
595
|
+
_count_pattern_matches(user_followup, _CONCRETE_ILLUSTRATION_PATTERNS),
|
|
596
|
+
),
|
|
597
|
+
(
|
|
598
|
+
FollowupNature.COMPLEMENT_CONTEXTUEL,
|
|
599
|
+
_count_pattern_matches(user_followup, _CONTEXTUAL_COMPLEMENT_PATTERNS),
|
|
600
|
+
),
|
|
581
601
|
]
|
|
582
602
|
|
|
583
603
|
# Pick the nature with the highest score
|
|
@@ -648,17 +668,18 @@ class ConversationalPairAnalyzer:
|
|
|
648
668
|
|
|
649
669
|
# Collect up to 3 representative examples
|
|
650
670
|
examples: list[tuple[str, str]] = [
|
|
651
|
-
(p.agent_response_preview, p.user_followup_preview)
|
|
652
|
-
for p in group_pairs[:3]
|
|
671
|
+
(p.agent_response_preview, p.user_followup_preview) for p in group_pairs[:3]
|
|
653
672
|
]
|
|
654
673
|
|
|
655
|
-
recurring_needs.append(
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
674
|
+
recurring_needs.append(
|
|
675
|
+
{
|
|
676
|
+
"initial_intent": intent,
|
|
677
|
+
"followup_nature": nature,
|
|
678
|
+
"occurrences": len(group_pairs),
|
|
679
|
+
"resource_contexts": resource_contexts,
|
|
680
|
+
"examples": examples,
|
|
681
|
+
}
|
|
682
|
+
)
|
|
662
683
|
|
|
663
684
|
# Sort by occurrence count descending
|
|
664
685
|
recurring_needs.sort(key=lambda x: x["occurrences"], reverse=True)
|
|
@@ -757,12 +778,9 @@ class HypothesisEngine:
|
|
|
757
778
|
# ------------------------------------------------------------------
|
|
758
779
|
|
|
759
780
|
# 1a. Preferences via PersonalizationAnalyzer (Requirement 3.1)
|
|
760
|
-
preferences: dict[str, Any] = {}
|
|
761
781
|
try:
|
|
762
782
|
pa = UserPersonalizationAnalyzer(self._provider)
|
|
763
|
-
|
|
764
|
-
user_id=user_id, agent_id=agent_id
|
|
765
|
-
)
|
|
783
|
+
_ = await pa.analyze_user_preferences(user_id=user_id, agent_id=agent_id)
|
|
766
784
|
except Exception as exc:
|
|
767
785
|
logger.warning("Failed to read preferences for user %s: %s", user_id, exc)
|
|
768
786
|
|
|
@@ -780,9 +798,7 @@ class HypothesisEngine:
|
|
|
780
798
|
resource_profile = ResourceProfile()
|
|
781
799
|
try:
|
|
782
800
|
wpt = WorkPatternTracker(self._provider)
|
|
783
|
-
rp_dict = await wpt.get_resource_profile(
|
|
784
|
-
user_id=user_id, agent_id=agent_id
|
|
785
|
-
)
|
|
801
|
+
rp_dict = await wpt.get_resource_profile(user_id=user_id, agent_id=agent_id)
|
|
786
802
|
resource_profile = ResourceProfile.from_dict(rp_dict)
|
|
787
803
|
except Exception as exc:
|
|
788
804
|
logger.warning("Failed to read resource profile for user %s: %s", user_id, exc)
|
|
@@ -800,7 +816,7 @@ class HypothesisEngine:
|
|
|
800
816
|
),
|
|
801
817
|
limit=200,
|
|
802
818
|
)
|
|
803
|
-
for fact in
|
|
819
|
+
for fact in wp_context.facts if wp_context else []:
|
|
804
820
|
meta = getattr(fact, "metadata", None)
|
|
805
821
|
if isinstance(meta, dict) and meta.get("type") == "work_pattern":
|
|
806
822
|
# Apply temporal windowing (Requirement 10.2)
|
|
@@ -829,7 +845,7 @@ class HypothesisEngine:
|
|
|
829
845
|
),
|
|
830
846
|
limit=200,
|
|
831
847
|
)
|
|
832
|
-
for fact in
|
|
848
|
+
for fact in fb_context.facts if fb_context else []:
|
|
833
849
|
meta = getattr(fact, "metadata", None)
|
|
834
850
|
if isinstance(meta, dict) and meta.get("type") == "implicit_feedback":
|
|
835
851
|
# Apply temporal windowing (Requirement 10.2)
|
|
@@ -987,14 +1003,16 @@ class HypothesisEngine:
|
|
|
987
1003
|
hypothesis.last_updated = now
|
|
988
1004
|
|
|
989
1005
|
# Record decay event in history
|
|
990
|
-
hypothesis.history.append(
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
1006
|
+
hypothesis.history.append(
|
|
1007
|
+
{
|
|
1008
|
+
"event": "temporal_decay",
|
|
1009
|
+
"timestamp": now.isoformat(),
|
|
1010
|
+
"old_confidence": old_confidence,
|
|
1011
|
+
"new_confidence": hypothesis.confidence,
|
|
1012
|
+
"decay_amount": 0.1,
|
|
1013
|
+
"inactive_days": (now - hypothesis.last_updated).days,
|
|
1014
|
+
}
|
|
1015
|
+
)
|
|
998
1016
|
|
|
999
1017
|
# Invalidate if confidence drops below 0.05
|
|
1000
1018
|
if hypothesis.confidence < 0.05:
|
|
@@ -1002,12 +1020,14 @@ class HypothesisEngine:
|
|
|
1002
1020
|
hypothesis.invalidation_reason = (
|
|
1003
1021
|
f"Confiance tombée à {hypothesis.confidence:.4f} par décroissance temporelle"
|
|
1004
1022
|
)
|
|
1005
|
-
hypothesis.history.append(
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1023
|
+
hypothesis.history.append(
|
|
1024
|
+
{
|
|
1025
|
+
"event": "invalidation",
|
|
1026
|
+
"timestamp": now.isoformat(),
|
|
1027
|
+
"reason": hypothesis.invalidation_reason,
|
|
1028
|
+
"confidence_at_invalidation": hypothesis.confidence,
|
|
1029
|
+
}
|
|
1030
|
+
)
|
|
1011
1031
|
|
|
1012
1032
|
await self._persist_hypothesis(hypothesis, user_id, agent_id)
|
|
1013
1033
|
decayed.append(hypothesis)
|
|
@@ -1123,9 +1143,7 @@ class HypothesisEngine:
|
|
|
1123
1143
|
]
|
|
1124
1144
|
|
|
1125
1145
|
# Total interactions for learning rate computation
|
|
1126
|
-
total_interactions = sum(
|
|
1127
|
-
h.validation_count + h.correction_count for h in active
|
|
1128
|
-
)
|
|
1146
|
+
total_interactions = sum(h.validation_count + h.correction_count for h in active)
|
|
1129
1147
|
|
|
1130
1148
|
lr_state = self.compute_learning_rate(total_interactions, avg_confidence)
|
|
1131
1149
|
|
|
@@ -1137,12 +1155,8 @@ class HypothesisEngine:
|
|
|
1137
1155
|
"top_3_hypotheses": top_3,
|
|
1138
1156
|
"learning_rate_state": {
|
|
1139
1157
|
"phase": lr_state.phase,
|
|
1140
|
-
"current_validation_increment": round(
|
|
1141
|
-
|
|
1142
|
-
),
|
|
1143
|
-
"current_correction_decrement": round(
|
|
1144
|
-
lr_state.current_correction_decrement, 4
|
|
1145
|
-
),
|
|
1158
|
+
"current_validation_increment": round(lr_state.current_validation_increment, 4),
|
|
1159
|
+
"current_correction_decrement": round(lr_state.current_correction_decrement, 4),
|
|
1146
1160
|
"total_interactions": lr_state.total_interactions,
|
|
1147
1161
|
"avg_confidence": round(lr_state.avg_confidence, 4),
|
|
1148
1162
|
},
|
|
@@ -1200,9 +1214,7 @@ class HypothesisEngine:
|
|
|
1200
1214
|
try:
|
|
1201
1215
|
hypothesis = Hypothesis.from_dict(metadata)
|
|
1202
1216
|
except (ValueError, TypeError) as exc:
|
|
1203
|
-
logger.warning(
|
|
1204
|
-
"Failed to deserialize hypothesis %s: %s", hypothesis_id, exc
|
|
1205
|
-
)
|
|
1217
|
+
logger.warning("Failed to deserialize hypothesis %s: %s", hypothesis_id, exc)
|
|
1206
1218
|
continue
|
|
1207
1219
|
|
|
1208
1220
|
# Apply status filter
|
|
@@ -1285,13 +1297,11 @@ class HypothesisEngine:
|
|
|
1285
1297
|
alpha = 1.0 / (1.0 + math.exp(-sigmoid_input))
|
|
1286
1298
|
|
|
1287
1299
|
# --- Interpolate rates ---
|
|
1288
|
-
current_validation_increment = (
|
|
1289
|
-
cfg.initial_validation_increment
|
|
1290
|
-
+ alpha * (cfg.mature_validation_increment - cfg.initial_validation_increment)
|
|
1300
|
+
current_validation_increment = cfg.initial_validation_increment + alpha * (
|
|
1301
|
+
cfg.mature_validation_increment - cfg.initial_validation_increment
|
|
1291
1302
|
)
|
|
1292
|
-
current_correction_decrement = (
|
|
1293
|
-
cfg.initial_correction_decrement
|
|
1294
|
-
+ alpha * (cfg.mature_correction_decrement - cfg.initial_correction_decrement)
|
|
1303
|
+
current_correction_decrement = cfg.initial_correction_decrement + alpha * (
|
|
1304
|
+
cfg.mature_correction_decrement - cfg.initial_correction_decrement
|
|
1295
1305
|
)
|
|
1296
1306
|
|
|
1297
1307
|
# --- Phase label ---
|
|
@@ -1437,8 +1447,8 @@ class HypothesisEngine:
|
|
|
1437
1447
|
# Check if resource profile adds converging evidence
|
|
1438
1448
|
if resource_profile is not None:
|
|
1439
1449
|
freq_resources = getattr(resource_profile, "frequent_resources", {})
|
|
1440
|
-
for
|
|
1441
|
-
for
|
|
1450
|
+
for _rtype, items in freq_resources.items():
|
|
1451
|
+
for _res_name, res_count in items:
|
|
1442
1452
|
if res_count >= 5:
|
|
1443
1453
|
factors.append("resource_frequency")
|
|
1444
1454
|
break
|
|
@@ -1537,8 +1547,8 @@ class HypothesisEngine:
|
|
|
1537
1547
|
trigger_context = f"{trigger_context} impliquant {resource_mention}"
|
|
1538
1548
|
|
|
1539
1549
|
# Map followup nature to implicit need and proposed action
|
|
1540
|
-
implicit_need, proposed_action, category = (
|
|
1541
|
-
|
|
1550
|
+
implicit_need, proposed_action, category = self._followup_nature_to_components(
|
|
1551
|
+
nature, resource_mention
|
|
1542
1552
|
)
|
|
1543
1553
|
|
|
1544
1554
|
if not implicit_need or not proposed_action:
|
|
@@ -1604,11 +1614,7 @@ class HypothesisEngine:
|
|
|
1604
1614
|
correction_counts[correction_type] += 1
|
|
1605
1615
|
|
|
1606
1616
|
# Collect context for richer hypothesis formulation
|
|
1607
|
-
context = (
|
|
1608
|
-
entry.get("user_followup_preview")
|
|
1609
|
-
or entry.get("message_preview")
|
|
1610
|
-
or ""
|
|
1611
|
-
)
|
|
1617
|
+
context = entry.get("user_followup_preview") or entry.get("message_preview") or ""
|
|
1612
1618
|
if context:
|
|
1613
1619
|
correction_contexts[correction_type].append(context)
|
|
1614
1620
|
|
|
@@ -1664,9 +1670,7 @@ class HypothesisEngine:
|
|
|
1664
1670
|
if resource_profile is None:
|
|
1665
1671
|
return hypotheses
|
|
1666
1672
|
|
|
1667
|
-
associations: list = getattr(
|
|
1668
|
-
resource_profile, "resource_output_associations", []
|
|
1669
|
-
)
|
|
1673
|
+
associations: list = getattr(resource_profile, "resource_output_associations", [])
|
|
1670
1674
|
|
|
1671
1675
|
for assoc in associations:
|
|
1672
1676
|
if not isinstance(assoc, (list, tuple)) or len(assoc) < 3:
|
|
@@ -2069,18 +2073,18 @@ class HypothesisEngine:
|
|
|
2069
2073
|
# Reactivation of invalidated hypothesis (Requirement 5.6)
|
|
2070
2074
|
if hypothesis.status == HypothesisStatus.INVALIDATED:
|
|
2071
2075
|
# Reactivate at 50% of standard initial confidence
|
|
2072
|
-
initial_confidence = self._compute_initial_confidence(
|
|
2073
|
-
len(hypothesis.trigger_factors)
|
|
2074
|
-
)
|
|
2076
|
+
initial_confidence = self._compute_initial_confidence(len(hypothesis.trigger_factors))
|
|
2075
2077
|
hypothesis.confidence = initial_confidence * 0.5
|
|
2076
2078
|
hypothesis.status = HypothesisStatus.ACTIVE
|
|
2077
2079
|
hypothesis.invalidation_reason = None
|
|
2078
2080
|
hypothesis.invalidation_context = None
|
|
2079
|
-
hypothesis.history.append(
|
|
2080
|
-
|
|
2081
|
-
|
|
2082
|
-
|
|
2083
|
-
|
|
2081
|
+
hypothesis.history.append(
|
|
2082
|
+
{
|
|
2083
|
+
"event": "reactivation",
|
|
2084
|
+
"timestamp": now.isoformat(),
|
|
2085
|
+
"new_confidence": hypothesis.confidence,
|
|
2086
|
+
}
|
|
2087
|
+
)
|
|
2084
2088
|
hypothesis.last_updated = now
|
|
2085
2089
|
await self._persist_hypothesis(hypothesis, user_id, agent_id)
|
|
2086
2090
|
return hypothesis
|
|
@@ -2093,19 +2097,23 @@ class HypothesisEngine:
|
|
|
2093
2097
|
|
|
2094
2098
|
# Increment confidence (Requirement 5.1)
|
|
2095
2099
|
old_confidence = hypothesis.confidence
|
|
2096
|
-
hypothesis.confidence = min(
|
|
2100
|
+
hypothesis.confidence = min(
|
|
2101
|
+
1.0, hypothesis.confidence + lr_state.current_validation_increment
|
|
2102
|
+
)
|
|
2097
2103
|
hypothesis.validation_count += 1
|
|
2098
2104
|
hypothesis.last_updated = now
|
|
2099
2105
|
|
|
2100
2106
|
# Record event in history (Requirement 5.5)
|
|
2101
|
-
hypothesis.history.append(
|
|
2102
|
-
|
|
2103
|
-
|
|
2104
|
-
|
|
2105
|
-
|
|
2106
|
-
|
|
2107
|
-
|
|
2108
|
-
|
|
2107
|
+
hypothesis.history.append(
|
|
2108
|
+
{
|
|
2109
|
+
"event": "validation",
|
|
2110
|
+
"timestamp": now.isoformat(),
|
|
2111
|
+
"old_confidence": old_confidence,
|
|
2112
|
+
"new_confidence": hypothesis.confidence,
|
|
2113
|
+
"increment": lr_state.current_validation_increment,
|
|
2114
|
+
"learning_rate_phase": lr_state.phase,
|
|
2115
|
+
}
|
|
2116
|
+
)
|
|
2109
2117
|
|
|
2110
2118
|
await self._persist_hypothesis(hypothesis, user_id, agent_id)
|
|
2111
2119
|
return hypothesis
|
|
@@ -2156,7 +2164,9 @@ class HypothesisEngine:
|
|
|
2156
2164
|
|
|
2157
2165
|
# Decrement confidence (Requirement 5.2)
|
|
2158
2166
|
old_confidence = hypothesis.confidence
|
|
2159
|
-
hypothesis.confidence = max(
|
|
2167
|
+
hypothesis.confidence = max(
|
|
2168
|
+
0.0, hypothesis.confidence - lr_state.current_correction_decrement
|
|
2169
|
+
)
|
|
2160
2170
|
hypothesis.correction_count += 1
|
|
2161
2171
|
hypothesis.last_updated = now
|
|
2162
2172
|
|
|
@@ -2181,12 +2191,14 @@ class HypothesisEngine:
|
|
|
2181
2191
|
f"de type '{correction_type}'"
|
|
2182
2192
|
)
|
|
2183
2193
|
hypothesis.invalidation_context = correction_context
|
|
2184
|
-
hypothesis.history.append(
|
|
2185
|
-
|
|
2186
|
-
|
|
2187
|
-
|
|
2188
|
-
|
|
2189
|
-
|
|
2194
|
+
hypothesis.history.append(
|
|
2195
|
+
{
|
|
2196
|
+
"event": "invalidation",
|
|
2197
|
+
"timestamp": now.isoformat(),
|
|
2198
|
+
"reason": hypothesis.invalidation_reason,
|
|
2199
|
+
"confidence_at_invalidation": hypothesis.confidence,
|
|
2200
|
+
}
|
|
2201
|
+
)
|
|
2190
2202
|
|
|
2191
2203
|
await self._persist_hypothesis(hypothesis, user_id, agent_id)
|
|
2192
2204
|
return hypothesis
|
|
@@ -2271,13 +2283,15 @@ class HypothesisEngine:
|
|
|
2271
2283
|
target.trigger_factors.append(factor)
|
|
2272
2284
|
seen.add(factor)
|
|
2273
2285
|
|
|
2274
|
-
target.history.append(
|
|
2275
|
-
|
|
2276
|
-
|
|
2277
|
-
|
|
2278
|
-
|
|
2279
|
-
|
|
2280
|
-
|
|
2286
|
+
target.history.append(
|
|
2287
|
+
{
|
|
2288
|
+
"event": "merge",
|
|
2289
|
+
"timestamp": now.isoformat(),
|
|
2290
|
+
"merged_hypothesis_id": source.hypothesis_id,
|
|
2291
|
+
"merged_confidence": source.confidence,
|
|
2292
|
+
"resulting_confidence": target.confidence,
|
|
2293
|
+
}
|
|
2294
|
+
)
|
|
2281
2295
|
|
|
2282
2296
|
return target
|
|
2283
2297
|
|
|
@@ -2518,8 +2532,7 @@ class WorkPatternBuilder:
|
|
|
2518
2532
|
|
|
2519
2533
|
# --- Pass 1: Group by project context --------------------------------
|
|
2520
2534
|
project_hypotheses = [
|
|
2521
|
-
h for h in hypotheses
|
|
2522
|
-
if h.category == HypothesisCategory.PROJET_CONTEXTE
|
|
2535
|
+
h for h in hypotheses if h.category == HypothesisCategory.PROJET_CONTEXTE
|
|
2523
2536
|
]
|
|
2524
2537
|
if project_hypotheses:
|
|
2525
2538
|
project_groups = self._cluster_by_trigger_overlap(project_hypotheses)
|
|
@@ -2578,9 +2591,7 @@ class WorkPatternBuilder:
|
|
|
2578
2591
|
# Multiple hypotheses — synthesise a workflow directive.
|
|
2579
2592
|
# Sort by confidence descending so the most confident hypothesis
|
|
2580
2593
|
# drives the primary description.
|
|
2581
|
-
sorted_group = sorted(
|
|
2582
|
-
hypothesis_group, key=lambda h: h.confidence, reverse=True
|
|
2583
|
-
)
|
|
2594
|
+
sorted_group = sorted(hypothesis_group, key=lambda h: h.confidence, reverse=True)
|
|
2584
2595
|
|
|
2585
2596
|
primary = sorted_group[0]
|
|
2586
2597
|
|
|
@@ -2599,10 +2610,7 @@ class WorkPatternBuilder:
|
|
|
2599
2610
|
|
|
2600
2611
|
# Build a combined workflow directive
|
|
2601
2612
|
actions_str = " ; ".join(additional_actions)
|
|
2602
|
-
return
|
|
2603
|
-
f"{primary.description} "
|
|
2604
|
-
f"De plus : {actions_str}."
|
|
2605
|
-
)
|
|
2613
|
+
return f"{primary.description} " f"De plus : {actions_str}."
|
|
2606
2614
|
|
|
2607
2615
|
# -- Internal helpers ----------------------------------------------------
|
|
2608
2616
|
|
|
@@ -2621,13 +2629,51 @@ class WorkPatternBuilder:
|
|
|
2621
2629
|
Set of lower-cased meaningful tokens.
|
|
2622
2630
|
"""
|
|
2623
2631
|
_STOP_WORDS: set[str] = {
|
|
2624
|
-
"les",
|
|
2625
|
-
"
|
|
2626
|
-
"
|
|
2627
|
-
"
|
|
2628
|
-
"
|
|
2629
|
-
"
|
|
2630
|
-
"
|
|
2632
|
+
"les",
|
|
2633
|
+
"des",
|
|
2634
|
+
"une",
|
|
2635
|
+
"que",
|
|
2636
|
+
"qui",
|
|
2637
|
+
"est",
|
|
2638
|
+
"dans",
|
|
2639
|
+
"pour",
|
|
2640
|
+
"par",
|
|
2641
|
+
"sur",
|
|
2642
|
+
"avec",
|
|
2643
|
+
"son",
|
|
2644
|
+
"ses",
|
|
2645
|
+
"aux",
|
|
2646
|
+
"pas",
|
|
2647
|
+
"mais",
|
|
2648
|
+
"sont",
|
|
2649
|
+
"ont",
|
|
2650
|
+
"été",
|
|
2651
|
+
"fait",
|
|
2652
|
+
"quand",
|
|
2653
|
+
"après",
|
|
2654
|
+
"avant",
|
|
2655
|
+
"entre",
|
|
2656
|
+
"cette",
|
|
2657
|
+
"ces",
|
|
2658
|
+
"tout",
|
|
2659
|
+
"tous",
|
|
2660
|
+
"elle",
|
|
2661
|
+
"lui",
|
|
2662
|
+
"leur",
|
|
2663
|
+
"nous",
|
|
2664
|
+
"vous",
|
|
2665
|
+
"the",
|
|
2666
|
+
"and",
|
|
2667
|
+
"for",
|
|
2668
|
+
"with",
|
|
2669
|
+
"from",
|
|
2670
|
+
"this",
|
|
2671
|
+
"that",
|
|
2672
|
+
"when",
|
|
2673
|
+
"after",
|
|
2674
|
+
"before",
|
|
2675
|
+
"user",
|
|
2676
|
+
"utilisateur",
|
|
2631
2677
|
}
|
|
2632
2678
|
tokens = set(re.findall(r"[a-zA-Z0-9_./\\-]{3,}", trigger_context.lower()))
|
|
2633
2679
|
return tokens - _STOP_WORDS
|