unique_toolkit 1.63.1__tar.gz → 1.64.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/PKG-INFO +1 -1
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/pyproject.toml +1 -1
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/openai_builtin/base.py +10 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/openai_builtin/code_interpreter/config.py +11 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/openai_builtin/code_interpreter/postprocessors/code_display.py +16 -18
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/openai_builtin/code_interpreter/postprocessors/generated_files.py +169 -26
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/openai_builtin/code_interpreter/service.py +19 -6
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/openai_builtin/manager.py +12 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/tool_manager.py +6 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/README.md +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/_base_service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/_time_utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/api_calling/human_verification_manager.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/base_model_type_attribute.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/chunk_relevancy_sorter/config.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/chunk_relevancy_sorter/exception.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/chunk_relevancy_sorter/schemas.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/chunk_relevancy_sorter/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/chunk_relevancy_sorter/tests/test_service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/config_checker/README.md +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/config_checker/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/config_checker/__main__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/config_checker/cli.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/config_checker/differ.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/config_checker/exporter.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/config_checker/models.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/config_checker/registry.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/config_checker/validator.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/default_language_model.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/docx_generator/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/docx_generator/config.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/docx_generator/pandoc_converter.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/docx_generator/schemas.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/docx_generator/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/docx_generator/template/Doc Template.docx +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/endpoint_builder.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/endpoint_requestor.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/event_bus.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/exception.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/execution.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/endpoint_builder.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/endpoint_requestor.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/README.md +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/agent.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/config.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/examples/data.csv +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/examples/example_usage.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/schemas.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/services/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/services/dataframe_handler/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/services/dataframe_handler/exceptions.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/services/dataframe_handler/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/services/dataframe_handler/utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/services/generation_handler/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/services/generation_handler/config.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/services/generation_handler/exceptions.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/services/generation_handler/prompts/config.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/services/generation_handler/prompts/system_prompt.j2 +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/services/generation_handler/prompts/user_prompt.j2 +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/services/generation_handler/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/services/template_handler/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/services/template_handler/default_template.j2 +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/services/template_handler/exceptions.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/services/template_handler/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/services/template_handler/utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/experimental/write_up_agent/utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/feature_flags/schema.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/pydantic/rjsf_tags.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/pydantic_helpers.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/referencing.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/string_utilities.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/tests/test_referencing.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/tests/test_string_utilities.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/token/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/token/image_token_counting.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/token/token_counting.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/token/tokenizers/deepseek/tokenizer.json +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/token/tokenizers/qwen/tokenizer.json +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/utils/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/utils/files.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/utils/image/encode.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/utils/jinja/helpers.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/utils/jinja/render.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/utils/jinja/schema.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/utils/jinja/utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/utils/structured_output/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/utils/structured_output/schema.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/utils/write_configuration.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/validate_required_values.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/validators.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/debug_info_manager/debug_info_manager.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/debug_info_manager/test/test_debug_info_manager.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/config.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/context_relevancy/prompts/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/context_relevancy/prompts/system_prompt.j2 +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/context_relevancy/prompts/user_prompt.j2 +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/context_relevancy/schema.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/context_relevancy/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/evaluation_manager.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/exception.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/hallucination/constants.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/hallucination/hallucination_evaluation.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/hallucination/prompts/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/hallucination/prompts/system_prompt.j2 +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/hallucination/prompts/user_prompt.j2 +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/hallucination/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/hallucination/utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/output_parser.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/schemas.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/tests/fixtures.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/tests/test_config.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/tests/test_context_relevancy_service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/tests/test_hallucination_constants.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/tests/test_hallucination_utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/tests/test_output_parser.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/tests/test_prompt_loaders.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/evaluation/utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/feature_flags/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/feature_flags/feature_flags.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/history_manager/history_construction_with_contents.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/history_manager/history_manager.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/history_manager/loop_token_reducer.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/history_manager/utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/loop_runner/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/loop_runner/_iteration_handler_utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/loop_runner/_responses_iteration_handler_utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/loop_runner/_responses_stream_handler_utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/loop_runner/_stream_handler_utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/loop_runner/base.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/loop_runner/middleware/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/loop_runner/middleware/planning/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/loop_runner/middleware/planning/planning.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/loop_runner/middleware/planning/schema.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/loop_runner/runners/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/loop_runner/runners/basic.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/loop_runner/runners/mistral/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/loop_runner/runners/mistral/mistral_runner.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/loop_runner/runners/qwen/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/loop_runner/runners/qwen/helpers.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/loop_runner/runners/qwen/qwen_runner.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/message_log_manager/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/message_log_manager/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/postprocessor/postprocessor_manager.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/reference_manager/reference_manager.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/responses_api/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/responses_api/postprocessors/code_display.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/responses_api/postprocessors/generated_files.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/responses_api/stream_handler.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/short_term_memory_manager/persistent_short_term_memory_manager.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/thinking_manager/thinking_manager.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/config.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/evaluation/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/evaluation/_utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/evaluation/config.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/evaluation/evaluator.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/evaluation/summarization_user_message.j2 +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/manager.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/postprocessing/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/postprocessing/_display_utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/postprocessing/_ref_utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/postprocessing/config.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/postprocessing/display.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/postprocessing/references.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/postprocessing/test/test_display.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/postprocessing/test/test_display_utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/postprocessing/test/test_ref_utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/prompts.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/response_watcher/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/response_watcher/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/tool/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/tool/_memory.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/tool/_schema.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/tool/config.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/tool/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/a2a/tool/test/test_service_utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/agent_chunks_hanlder.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/config.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/factory.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/mcp/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/mcp/manager.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/mcp/models.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/mcp/tool_wrapper.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/openai_builtin/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/openai_builtin/code_interpreter/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/openai_builtin/code_interpreter/postprocessors/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/openai_builtin/code_interpreter/schemas.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/schemas.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/test/test_mcp_manager.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/test/test_tool_progress_reporter.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/tool.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/tool_progress_reporter.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/utils/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/utils/source_handling/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/utils/source_handling/schema.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/utils/source_handling/source_formatting.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/utils/source_handling/tests/test_source_formatting.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic_table/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic_table/schemas.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic_table/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/app/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/app/dev_util.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/app/fast_api_factory.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/app/init_logging.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/app/init_sdk.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/app/performance/async_tasks.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/app/performance/async_wrapper.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/app/schemas.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/app/unique_settings.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/app/verification.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/app/webhook.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/chat/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/chat/cancellation.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/chat/constants.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/chat/deprecated/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/chat/functions.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/chat/rendering.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/chat/responses_api.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/chat/schemas.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/chat/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/chat/state.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/chat/utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/content/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/content/constants.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/content/functions.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/content/schemas.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/content/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/content/smart_rules.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/content/utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/data_extraction/README.md +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/data_extraction/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/data_extraction/augmented/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/data_extraction/augmented/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/data_extraction/base.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/data_extraction/basic/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/data_extraction/basic/config.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/data_extraction/basic/prompt.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/data_extraction/basic/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/elicitation/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/elicitation/constants.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/elicitation/exceptions.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/elicitation/functions.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/elicitation/schemas.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/elicitation/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/embedding/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/embedding/constants.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/embedding/functions.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/embedding/schemas.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/embedding/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/embedding/utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/framework_utilities/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/framework_utilities/langchain/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/framework_utilities/langchain/client.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/framework_utilities/langchain/history.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/framework_utilities/openai/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/framework_utilities/openai/client.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/framework_utilities/openai/message_builder.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/framework_utilities/utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/language_model/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/language_model/_responses_api_utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/language_model/builder.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/language_model/constants.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/language_model/default_language_model.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/language_model/functions.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/language_model/infos.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/language_model/prompt.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/language_model/reference.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/language_model/schemas.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/language_model/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/language_model/stream_transform.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/language_model/utils.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/protocols/support.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/services/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/services/chat_service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/services/factory.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/services/knowledge_base.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/short_term_memory/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/short_term_memory/constants.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/short_term_memory/functions.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/short_term_memory/schemas.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/short_term_memory/service.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/smart_rules/__init__.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/smart_rules/compile.py +0 -0
- {unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/test_utilities/events.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: unique-toolkit
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.64.0
|
|
4
4
|
Summary:
|
|
5
5
|
Author: Cedric Klinkert, Martin Fadler, Sadique Sheik, Fabian Schläpfer, Pascal Hauri, Ejiroghene Oki-Peter, Rami Azouz, Ricardo Visini, Sanzio Monti
|
|
6
6
|
Author-email: Cedric Klinkert <cedric.klinkert@unique.ch>, Martin Fadler <martin.fadler@unique.ch>, Sadique Sheik <sadique@unique.ch>, Fabian Schläpfer <fabian@unique.ch>, Pascal Hauri <pascal@unique.ch>, Ejiroghene Oki-Peter <oki-peter.ejiroghene@unique.ai>, Rami Azouz <rami.ext@unique.ch>, Ricardo Visini <ricardo.visini@unique.ch>, Sanzio Monti <sanzio.monti@unique.ai>
|
{unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/openai_builtin/base.py
RENAMED
|
@@ -2,6 +2,7 @@ from abc import ABC, abstractmethod
|
|
|
2
2
|
from enum import StrEnum
|
|
3
3
|
from typing import Generic, TypeVar
|
|
4
4
|
|
|
5
|
+
from openai.types.responses import ResponseIncludable
|
|
5
6
|
from openai.types.responses.tool_param import CodeInterpreter
|
|
6
7
|
|
|
7
8
|
from unique_toolkit.agentic.tools.schemas import ToolPrompts
|
|
@@ -44,3 +45,12 @@ class OpenAIBuiltInTool(ABC, Generic[ToolType]):
|
|
|
44
45
|
@abstractmethod
|
|
45
46
|
def display_name(self) -> str:
|
|
46
47
|
raise NotImplementedError()
|
|
48
|
+
|
|
49
|
+
def get_required_include_params(self) -> list[ResponseIncludable]:
|
|
50
|
+
"""Return Responses API `include` values required by this tool.
|
|
51
|
+
|
|
52
|
+
Subclasses override this when they need additional data attached to the
|
|
53
|
+
response (e.g. code interpreter execution logs). The default is an
|
|
54
|
+
empty list, meaning no extra includes are needed.
|
|
55
|
+
"""
|
|
56
|
+
return []
|
|
@@ -87,6 +87,17 @@ IMPORTANT: ALWAYS place a blank line before AND after each file reference link s
|
|
|
87
87
|
- Only the following file types are allowed to be uploaded to the platform, anything else will FAIL: PDF, DOCX, XLSX, PPTX, CSV, HTML, MD, TXT, PNG, JPG, JPEG.
|
|
88
88
|
- You MUST always use this syntax, otherwise the files will not be displayed in the chat.
|
|
89
89
|
|
|
90
|
+
HTML files — CRITICAL rules:
|
|
91
|
+
- NEVER write raw HTML markup directly in your text response. HTML content MUST only ever appear as a saved `.html` file in `/mnt/data/`.
|
|
92
|
+
- Whenever you create HTML (dashboards, charts, tables, reports, interactive widgets), you MUST save it as a `.html` file and reference it using the sandbox link format above.
|
|
93
|
+
- HTML files MUST follow these best practices so they render correctly in the UI:
|
|
94
|
+
- Use a valid HTML5 document structure: `<!DOCTYPE html>`, `<html>`, `<head>` (with `<meta charset="UTF-8">` and `<meta name="viewport" content="width=device-width, initial-scale=1.0">`), and `<body>`.
|
|
95
|
+
- Make the layout self-contained: inline all CSS in a `<style>` block and all JavaScript in a `<script>` block. Do NOT rely on external CDN links that may be blocked.
|
|
96
|
+
- Use relative or fluid sizing (%, vw/vh, flexbox, CSS grid) rather than fixed pixel widths so the content fits any iframe size.
|
|
97
|
+
- Apply clean, readable typography: prefer system fonts (`-apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif`) and sufficient contrast (WCAG AA minimum).
|
|
98
|
+
- Use semantic HTML elements (`<table>` for tabular data, `<button>` for actions, `<h1>`–`<h6>` for headings, `alt` attributes on `<img>` tags). Avoid using `<div>` for everything.
|
|
99
|
+
- Do NOT use `window.parent`, `window.top`, or any attempt to access the parent frame.
|
|
100
|
+
|
|
90
101
|
|
|
91
102
|
# Displaying Dataframes/Tables:
|
|
92
103
|
- Whenever asked to display a dataframe/table, it is CRITICAL to represent it faithfully as a markdown table in your response.
|
|
@@ -6,6 +6,7 @@ from typing import override
|
|
|
6
6
|
from pydantic import BaseModel, Field
|
|
7
7
|
from pydantic.json_schema import SkipJsonSchema
|
|
8
8
|
|
|
9
|
+
from unique_toolkit.agentic.feature_flags.feature_flags import feature_flags
|
|
9
10
|
from unique_toolkit.agentic.postprocessor.postprocessor_manager import (
|
|
10
11
|
ResponsesApiPostprocessor,
|
|
11
12
|
)
|
|
@@ -24,22 +25,6 @@ _TEMPLATE = """
|
|
|
24
25
|
|
|
25
26
|
""".lstrip()
|
|
26
27
|
|
|
27
|
-
# Pattern matching the block emitted by _TEMPLATE (including trailing </br>).
|
|
28
|
-
# Used when another postprocessor supersedes this content (e.g. fence injection).
|
|
29
|
-
_EXECUTED_CODE_BLOCK_RE = re.compile(
|
|
30
|
-
r"\n*<details><summary>Code Interpreter Call</summary>.*?</details>[ \t]*\n*(?:[ \t]*</br>[ \t]*\n*)?",
|
|
31
|
-
re.DOTALL,
|
|
32
|
-
)
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
def strip_executed_code_blocks(text: str) -> str:
|
|
36
|
-
"""Remove all executed-code <details> blocks emitted by this postprocessor.
|
|
37
|
-
|
|
38
|
-
Call this when the same content is represented elsewhere (e.g. imgWithSource
|
|
39
|
-
/ fileWithSource fences) so the message does not contain duplicate code blocks.
|
|
40
|
-
"""
|
|
41
|
-
return _EXECUTED_CODE_BLOCK_RE.sub("", text)
|
|
42
|
-
|
|
43
28
|
|
|
44
29
|
logger = logging.getLogger(__name__)
|
|
45
30
|
|
|
@@ -59,18 +44,32 @@ class ShowExecutedCodePostprocessorConfig(BaseModel):
|
|
|
59
44
|
|
|
60
45
|
|
|
61
46
|
class ShowExecutedCodePostprocessor(ResponsesApiPostprocessor):
|
|
62
|
-
def __init__(
|
|
47
|
+
def __init__(
|
|
48
|
+
self,
|
|
49
|
+
config: ShowExecutedCodePostprocessorConfig,
|
|
50
|
+
company_id: str | None = None,
|
|
51
|
+
):
|
|
63
52
|
super().__init__(self.__class__.__name__)
|
|
64
53
|
self._config = config
|
|
54
|
+
self._company_id = company_id
|
|
65
55
|
|
|
66
56
|
@override
|
|
67
57
|
async def run(self, loop_response: ResponsesLanguageModelStreamResponse) -> None:
|
|
58
|
+
if feature_flags.enable_code_execution_fence_un_17972.is_enabled(
|
|
59
|
+
self._company_id
|
|
60
|
+
):
|
|
61
|
+
return
|
|
68
62
|
await asyncio.sleep(self._config.sleep_time_before_display)
|
|
69
63
|
|
|
70
64
|
@override
|
|
71
65
|
def apply_postprocessing_to_response(
|
|
72
66
|
self, loop_response: ResponsesLanguageModelStreamResponse
|
|
73
67
|
) -> bool:
|
|
68
|
+
if feature_flags.enable_code_execution_fence_un_17972.is_enabled(
|
|
69
|
+
self._company_id
|
|
70
|
+
):
|
|
71
|
+
return False
|
|
72
|
+
|
|
74
73
|
prepended_text = ""
|
|
75
74
|
for output in loop_response.code_interpreter_calls:
|
|
76
75
|
prepended_text += _TEMPLATE.format(code=output.code)
|
|
@@ -83,6 +82,5 @@ class ShowExecutedCodePostprocessor(ResponsesApiPostprocessor):
|
|
|
83
82
|
async def remove_from_text(self, text) -> str:
|
|
84
83
|
if not self._config.remove_from_history:
|
|
85
84
|
return text
|
|
86
|
-
# Remove code interpreter blocks using regex
|
|
87
85
|
pattern = r"<details><summary>Code Interpreter Call</summary>.*?</details>"
|
|
88
86
|
return re.sub(pattern, "", text, flags=re.DOTALL)
|
|
@@ -6,6 +6,7 @@ from mimetypes import guess_type
|
|
|
6
6
|
from typing import NamedTuple, override
|
|
7
7
|
|
|
8
8
|
from openai import AsyncOpenAI
|
|
9
|
+
from openai.types.responses import ResponseCodeInterpreterToolCall
|
|
9
10
|
from openai.types.responses.response_output_text import AnnotationContainerFileCitation
|
|
10
11
|
from pydantic import BaseModel, Field, RootModel
|
|
11
12
|
from pydantic.json_schema import SkipJsonSchema
|
|
@@ -20,9 +21,6 @@ from unique_toolkit.agentic.short_term_memory_manager.persistent_short_term_memo
|
|
|
20
21
|
PersistentShortMemoryManager,
|
|
21
22
|
)
|
|
22
23
|
from unique_toolkit.agentic.tools.config import get_configuration_dict
|
|
23
|
-
from unique_toolkit.agentic.tools.openai_builtin.code_interpreter.postprocessors.code_display import (
|
|
24
|
-
strip_executed_code_blocks,
|
|
25
|
-
)
|
|
26
24
|
from unique_toolkit.agentic.tools.openai_builtin.code_interpreter.schemas import (
|
|
27
25
|
CodeInterpreterBlock,
|
|
28
26
|
CodeInterpreterFile,
|
|
@@ -110,6 +108,7 @@ class DisplayCodeInterpreterFilesPostProcessor(
|
|
|
110
108
|
if self._chat_service is None:
|
|
111
109
|
raise ValueError("ChatService is required if uploadToChat is True")
|
|
112
110
|
|
|
111
|
+
self._orphan_code_blocks: list[CodeInterpreterBlock] = []
|
|
113
112
|
self._short_term_memory_manager = None
|
|
114
113
|
if chat_id is not None and user_id is not None and company_id is not None:
|
|
115
114
|
self._short_term_memory_manager = _init_short_term_memory_manager(
|
|
@@ -150,10 +149,23 @@ class DisplayCodeInterpreterFilesPostProcessor(
|
|
|
150
149
|
]
|
|
151
150
|
)
|
|
152
151
|
|
|
152
|
+
if feature_flags.enable_code_execution_fence_un_17972.is_enabled(
|
|
153
|
+
self._company_id
|
|
154
|
+
):
|
|
155
|
+
self._orphan_code_blocks = await self._upload_orphan_code_as_txt(
|
|
156
|
+
loop_response
|
|
157
|
+
)
|
|
158
|
+
else:
|
|
159
|
+
self._orphan_code_blocks = []
|
|
160
|
+
|
|
153
161
|
@override
|
|
154
162
|
def apply_postprocessing_to_response(
|
|
155
163
|
self, loop_response: ResponsesLanguageModelStreamResponse
|
|
156
164
|
) -> bool:
|
|
165
|
+
if loop_response.message.references is None:
|
|
166
|
+
loop_response.message.references = []
|
|
167
|
+
if loop_response.message.text is None:
|
|
168
|
+
loop_response.message.text = ""
|
|
157
169
|
ref_number = _get_next_ref_number(loop_response.message.references)
|
|
158
170
|
changed = False
|
|
159
171
|
|
|
@@ -169,6 +181,9 @@ class DisplayCodeInterpreterFilesPostProcessor(
|
|
|
169
181
|
|
|
170
182
|
is_image = (guess_type(filename)[0] or "").startswith("image/")
|
|
171
183
|
is_html = (guess_type(filename)[0] or "") == "text/html"
|
|
184
|
+
fence_ff_on = feature_flags.enable_code_execution_fence_un_17972.is_enabled(
|
|
185
|
+
self._company_id
|
|
186
|
+
)
|
|
172
187
|
|
|
173
188
|
# Images
|
|
174
189
|
if is_image:
|
|
@@ -181,9 +196,13 @@ class DisplayCodeInterpreterFilesPostProcessor(
|
|
|
181
196
|
)
|
|
182
197
|
changed |= replaced
|
|
183
198
|
|
|
184
|
-
# HTML
|
|
185
|
-
elif
|
|
186
|
-
|
|
199
|
+
# HTML rendered as legacy HtmlRendering block — only when fence FF is off
|
|
200
|
+
elif (
|
|
201
|
+
is_html
|
|
202
|
+
and not fence_ff_on
|
|
203
|
+
and feature_flags.enable_html_rendering_un_15131.is_enabled(
|
|
204
|
+
self._company_id
|
|
205
|
+
)
|
|
187
206
|
):
|
|
188
207
|
loop_response.message.text, replaced = _replace_container_html_citation(
|
|
189
208
|
text=loop_response.message.text,
|
|
@@ -192,13 +211,8 @@ class DisplayCodeInterpreterFilesPostProcessor(
|
|
|
192
211
|
)
|
|
193
212
|
changed |= replaced
|
|
194
213
|
|
|
195
|
-
# Files (
|
|
214
|
+
# Files and HTML (fence FF on: HTML → htmlWithSource; others → fileWithSource)
|
|
196
215
|
else:
|
|
197
|
-
fence_ff_on = (
|
|
198
|
-
feature_flags.enable_code_execution_fence_un_17972.is_enabled(
|
|
199
|
-
self._company_id
|
|
200
|
-
)
|
|
201
|
-
)
|
|
202
216
|
loop_response.message.text, replaced = _replace_container_file_citation(
|
|
203
217
|
text=loop_response.message.text,
|
|
204
218
|
filename=filename,
|
|
@@ -210,11 +224,19 @@ class DisplayCodeInterpreterFilesPostProcessor(
|
|
|
210
224
|
|
|
211
225
|
is_html_rendered = (
|
|
212
226
|
is_html
|
|
227
|
+
and not fence_ff_on
|
|
213
228
|
and feature_flags.enable_html_rendering_un_15131.is_enabled(
|
|
214
229
|
self._company_id
|
|
215
230
|
)
|
|
216
231
|
)
|
|
217
|
-
|
|
232
|
+
# htmlWithSource fences carry contentId directly — no separate reference needed
|
|
233
|
+
is_html_fenced = is_html and fence_ff_on
|
|
234
|
+
if (
|
|
235
|
+
replaced
|
|
236
|
+
and not is_image
|
|
237
|
+
and not is_html_rendered
|
|
238
|
+
and not is_html_fenced
|
|
239
|
+
):
|
|
218
240
|
loop_response.message.references.append(
|
|
219
241
|
ContentReference(
|
|
220
242
|
sequence_number=ref_number,
|
|
@@ -238,6 +260,27 @@ class DisplayCodeInterpreterFilesPostProcessor(
|
|
|
238
260
|
)
|
|
239
261
|
changed |= loop_response.message.text != text_before
|
|
240
262
|
|
|
263
|
+
if self._orphan_code_blocks:
|
|
264
|
+
fence_id = _get_next_fence_id(loop_response.message.text)
|
|
265
|
+
orphan_fences = _build_orphan_fences(self._orphan_code_blocks, fence_id)
|
|
266
|
+
loop_response.message.text = (
|
|
267
|
+
loop_response.message.text.rstrip() + "\n\n" + orphan_fences
|
|
268
|
+
)
|
|
269
|
+
ref_number = _get_next_ref_number(loop_response.message.references)
|
|
270
|
+
for block in self._orphan_code_blocks:
|
|
271
|
+
for file in block.files:
|
|
272
|
+
loop_response.message.references.append(
|
|
273
|
+
ContentReference(
|
|
274
|
+
sequence_number=ref_number,
|
|
275
|
+
source_id=file.content_id,
|
|
276
|
+
source="node-ingestion-chunks",
|
|
277
|
+
url=f"unique://content/{file.content_id}",
|
|
278
|
+
name=file.filename,
|
|
279
|
+
)
|
|
280
|
+
)
|
|
281
|
+
ref_number += 1
|
|
282
|
+
changed = True
|
|
283
|
+
|
|
241
284
|
_warn_missing_content_ids(loop_response.message.text, self._content_map)
|
|
242
285
|
loop_response.message.text, dangling_replaced = _replace_dangling_sandbox_links(
|
|
243
286
|
loop_response.message.text, self._config.file_download_failed_message
|
|
@@ -307,6 +350,110 @@ class DisplayCodeInterpreterFilesPostProcessor(
|
|
|
307
350
|
_DisplayedFilesShortTermMemorySchema(root=content_infos)
|
|
308
351
|
)
|
|
309
352
|
|
|
353
|
+
async def _upload_orphan_code_as_txt(
|
|
354
|
+
self, loop_response: ResponsesLanguageModelStreamResponse
|
|
355
|
+
) -> list[CodeInterpreterBlock]:
|
|
356
|
+
"""Upload stdout (or code) from calls that produced no container files as .txt artifacts.
|
|
357
|
+
|
|
358
|
+
When code interpreter runs but generates no files or images, the response
|
|
359
|
+
text has no sandbox links for fence injection to hook onto. This method
|
|
360
|
+
converts those "orphan" calls into downloadable .txt files so the fence
|
|
361
|
+
postprocessor can attach a fileWithSource component and the new Code
|
|
362
|
+
Execution UI is shown instead of the legacy <details> block.
|
|
363
|
+
|
|
364
|
+
Called only when the fence feature flag is enabled. Skipped entirely if
|
|
365
|
+
any container files were produced (normal fencing handles those).
|
|
366
|
+
"""
|
|
367
|
+
if loop_response.container_files:
|
|
368
|
+
return []
|
|
369
|
+
|
|
370
|
+
calls = loop_response.code_interpreter_calls
|
|
371
|
+
if not calls:
|
|
372
|
+
return []
|
|
373
|
+
|
|
374
|
+
assert self._chat_service is not None # Checked in __init__
|
|
375
|
+
|
|
376
|
+
use_numeric_suffix = len(calls) > 1
|
|
377
|
+
orphan_blocks: list[CodeInterpreterBlock] = []
|
|
378
|
+
|
|
379
|
+
for i, call in enumerate(calls):
|
|
380
|
+
if not call.code:
|
|
381
|
+
continue
|
|
382
|
+
|
|
383
|
+
# Code interpreter logs are only present on each code_interpreter_call when
|
|
384
|
+
# the create/retrieve request sets include=["code_interpreter_call.outputs"]
|
|
385
|
+
# (see OpenAI Responses API `include` and manual examples in
|
|
386
|
+
# docs/manual_examples_for_docs/code_execution_openai_client.py). If
|
|
387
|
+
# `outputs` is omitted, call.outputs is null and we fall back to the
|
|
388
|
+
# source code as the downloadable txt.
|
|
389
|
+
txt_content = _collect_stdout(call) or call.code
|
|
390
|
+
filename = f"code_{i + 1}.txt" if use_numeric_suffix else "code.txt"
|
|
391
|
+
|
|
392
|
+
try:
|
|
393
|
+
content = await self._chat_service.upload_to_chat_from_bytes_async(
|
|
394
|
+
content=txt_content.encode("utf-8"),
|
|
395
|
+
content_name=filename,
|
|
396
|
+
mime_type="text/plain",
|
|
397
|
+
skip_ingestion=True,
|
|
398
|
+
hide_in_chat=True,
|
|
399
|
+
)
|
|
400
|
+
except Exception:
|
|
401
|
+
logger.exception(
|
|
402
|
+
"Failed to upload orphan code block as txt for call %d ('%s'); "
|
|
403
|
+
"falling back to legacy code block display.",
|
|
404
|
+
i,
|
|
405
|
+
filename,
|
|
406
|
+
)
|
|
407
|
+
continue
|
|
408
|
+
|
|
409
|
+
orphan_file = CodeInterpreterFile(
|
|
410
|
+
filename=filename,
|
|
411
|
+
content_id=content.id,
|
|
412
|
+
type="document",
|
|
413
|
+
)
|
|
414
|
+
orphan_blocks.append(
|
|
415
|
+
CodeInterpreterBlock(code=call.code, files=[orphan_file])
|
|
416
|
+
)
|
|
417
|
+
logger.info(
|
|
418
|
+
"Uploaded orphan code block as '%s' (content_id=%s)",
|
|
419
|
+
filename,
|
|
420
|
+
content.id,
|
|
421
|
+
)
|
|
422
|
+
|
|
423
|
+
return orphan_blocks
|
|
424
|
+
|
|
425
|
+
|
|
426
|
+
def _collect_stdout(call: ResponseCodeInterpreterToolCall) -> str:
|
|
427
|
+
"""Collect all stdout logs from a code interpreter call's outputs."""
|
|
428
|
+
if not call.outputs:
|
|
429
|
+
return ""
|
|
430
|
+
return "\n".join(output.logs for output in call.outputs if output.type == "logs")
|
|
431
|
+
|
|
432
|
+
|
|
433
|
+
def _get_next_fence_id(text: str) -> int:
|
|
434
|
+
"""Return the next available fence id by scanning existing fences in the text."""
|
|
435
|
+
existing = re.findall(r"````(?:imgWithSource|fileWithSource)\(id='(\d+)'", text)
|
|
436
|
+
if not existing:
|
|
437
|
+
return 1
|
|
438
|
+
return max(int(fid) for fid in existing) + 1
|
|
439
|
+
|
|
440
|
+
|
|
441
|
+
def _build_orphan_fences(
|
|
442
|
+
blocks: list[CodeInterpreterBlock], start_fence_id: int
|
|
443
|
+
) -> str:
|
|
444
|
+
"""Build concatenated fence text for orphan code blocks.
|
|
445
|
+
|
|
446
|
+
Orphan blocks have no inline ref in the message text, so their fences are
|
|
447
|
+
appended directly rather than injected via pattern replacement.
|
|
448
|
+
"""
|
|
449
|
+
fence_id = start_fence_id
|
|
450
|
+
parts: list[str] = []
|
|
451
|
+
for block in blocks:
|
|
452
|
+
for file in block.files:
|
|
453
|
+
parts.append(_build_file_fence(file, block.code, fence_id))
|
|
454
|
+
fence_id += 1
|
|
455
|
+
return "\n".join(parts)
|
|
456
|
+
|
|
310
457
|
|
|
311
458
|
def _get_file_type(filename: str) -> CodeInterpreterFileType:
|
|
312
459
|
mime = guess_type(filename)[0] or ""
|
|
@@ -382,6 +529,8 @@ def _build_file_fence(file: CodeInterpreterFile, code: str, fence_id: int) -> st
|
|
|
382
529
|
outer = "````"
|
|
383
530
|
if file.type == "image":
|
|
384
531
|
tag = f"imgWithSource(id='{fence_id}', contentId='{file.content_id}', title=\"{title}\", code=\"{escaped}\")"
|
|
532
|
+
elif file.type == "html":
|
|
533
|
+
tag = f"htmlWithSource(id='{fence_id}', contentId='{file.content_id}', title=\"{title}\", code=\"{escaped}\")"
|
|
385
534
|
else:
|
|
386
535
|
ftype = _file_frontend_type(file.filename)
|
|
387
536
|
tag = f'fileWithSource(id=\'{fence_id}\', contentId=\'{file.content_id}\', title="{title}", type="{ftype}", code="{escaped}")'
|
|
@@ -394,23 +543,18 @@ def _inline_ref_pattern(file: CodeInterpreterFile) -> re.Pattern[str]:
|
|
|
394
543
|
After apply_postprocessing_to_response replaces sandbox paths, each file type
|
|
395
544
|
has a distinct inline form in the text:
|
|
396
545
|
image → 
|
|
546
|
+
html → [{filename}](unique://content/{content_id})
|
|
397
547
|
document → [{filename}](unique://content/{content_id})
|
|
398
|
-
html → ```HtmlRendering\\n100%\\n500px\\n\\nunique://content/{content_id}\\n\\n```
|
|
399
548
|
"""
|
|
400
549
|
cid = re.escape(file.content_id)
|
|
401
550
|
fname = re.escape(file.filename)
|
|
402
551
|
if file.type == "image":
|
|
403
552
|
return re.compile(rf"!\[image\]\(unique://content/{cid}\)")
|
|
404
|
-
if file.type == "html":
|
|
405
|
-
return re.compile(
|
|
406
|
-
rf"```HtmlRendering\n100%\n500px\n\nunique://content/{cid}\n\n```",
|
|
407
|
-
re.DOTALL,
|
|
408
|
-
)
|
|
409
553
|
return re.compile(rf"\[{fname}\]\(unique://content/{cid}\)")
|
|
410
554
|
|
|
411
555
|
|
|
412
556
|
_FENCE_BLOCK_START = re.compile(
|
|
413
|
-
r"^[^\n`]+?(````(?:imgWithSource|fileWithSource)\()",
|
|
557
|
+
r"^[^\n`]+?(````(?:imgWithSource|fileWithSource|htmlWithSource)\()",
|
|
414
558
|
re.MULTILINE,
|
|
415
559
|
)
|
|
416
560
|
|
|
@@ -420,9 +564,9 @@ _FENCE_BLOCK_START = re.compile(
|
|
|
420
564
|
# - cross-line: 1 or 2 newlines optionally surrounded by horizontal whitespace
|
|
421
565
|
# (list-item linebreak, or blank-line paragraph gap)
|
|
422
566
|
_CONSECUTIVE_FENCES_RE = re.compile(
|
|
423
|
-
r"(````(?:imgWithSource|fileWithSource)\([^\n]*\)````)"
|
|
567
|
+
r"(````(?:imgWithSource|fileWithSource|htmlWithSource)\([^\n]*\)````)"
|
|
424
568
|
r"(?:[^\n`]*|[ \t]*\n{1,2}[ \t]*)"
|
|
425
|
-
r"(?=````(?:imgWithSource|fileWithSource)\()"
|
|
569
|
+
r"(?=````(?:imgWithSource|fileWithSource|htmlWithSource)\()"
|
|
426
570
|
)
|
|
427
571
|
|
|
428
572
|
|
|
@@ -453,8 +597,6 @@ def _inject_code_execution_fences(
|
|
|
453
597
|
|
|
454
598
|
Each file gets its own fence placed at the position of its inline ref. Duplicate
|
|
455
599
|
refs for the same file (overwrite case) are removed after the first is replaced.
|
|
456
|
-
When at least one fence was injected, executed-code <details> blocks are
|
|
457
|
-
stripped via strip_executed_code_blocks() from the code_display postprocessor.
|
|
458
600
|
|
|
459
601
|
fence_id is a message-level counter so each fence has a unique id.
|
|
460
602
|
"""
|
|
@@ -480,7 +622,6 @@ def _inject_code_execution_fences(
|
|
|
480
622
|
# Remove duplicate refs (overwrite case)
|
|
481
623
|
text = re.sub(pattern, "", text)
|
|
482
624
|
if any_fence_injected:
|
|
483
|
-
text = strip_executed_code_blocks(text)
|
|
484
625
|
text = _ensure_fences_are_standalone(text)
|
|
485
626
|
text = _CONSECUTIVE_FENCES_RE.sub(r"\1\n", text)
|
|
486
627
|
return text
|
|
@@ -687,7 +828,9 @@ def _warn_unmatched_code_blocks(
|
|
|
687
828
|
)
|
|
688
829
|
|
|
689
830
|
|
|
690
|
-
def _get_next_ref_number(references: list[ContentReference]) -> int:
|
|
831
|
+
def _get_next_ref_number(references: list[ContentReference] | None) -> int:
|
|
832
|
+
if not references:
|
|
833
|
+
return 1
|
|
691
834
|
max_ref_number = 0
|
|
692
835
|
for ref in references:
|
|
693
836
|
max_ref_number = max(max_ref_number, ref.sequence_number)
|
|
@@ -2,7 +2,7 @@ import logging
|
|
|
2
2
|
from typing import Any, override
|
|
3
3
|
|
|
4
4
|
from openai import AsyncOpenAI, BaseModel, NotFoundError
|
|
5
|
-
from openai.types.responses import ResponseCodeInterpreterToolCall
|
|
5
|
+
from openai.types.responses import ResponseCodeInterpreterToolCall, ResponseIncludable
|
|
6
6
|
from openai.types.responses.tool_param import CodeInterpreter
|
|
7
7
|
|
|
8
8
|
from unique_toolkit import ContentService, ShortTermMemoryService
|
|
@@ -251,14 +251,19 @@ class OpenAICodeInterpreterTool(OpenAIBuiltInTool[CodeInterpreter]):
|
|
|
251
251
|
fence_ff_on = feature_flags.enable_code_execution_fence_un_17972.is_enabled(
|
|
252
252
|
self._company_id
|
|
253
253
|
)
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
)
|
|
254
|
+
# A prompt is considered operator-customised only when it differs from every
|
|
255
|
+
# known default variant. Comparing against both defaults ensures spaces whose
|
|
256
|
+
# stored value was written by an earlier deployment (which may have used the
|
|
257
|
+
# non-fence default) are still treated as uncustomised once the fence FF is on.
|
|
258
|
+
stored = self._config.tool_description_for_system_prompt
|
|
259
|
+
operator_customised = stored not in {
|
|
260
|
+
DEFAULT_TOOL_DESCRIPTION_FOR_SYSTEM_PROMPT,
|
|
261
|
+
DEFAULT_TOOL_DESCRIPTION_FOR_SYSTEM_PROMPT_FENCE,
|
|
262
|
+
}
|
|
258
263
|
if fence_ff_on and not operator_customised:
|
|
259
264
|
system_prompt = DEFAULT_TOOL_DESCRIPTION_FOR_SYSTEM_PROMPT_FENCE
|
|
260
265
|
else:
|
|
261
|
-
system_prompt =
|
|
266
|
+
system_prompt = stored
|
|
262
267
|
|
|
263
268
|
return ToolPrompts(
|
|
264
269
|
name="python", # https://platform.openai.com/docs/guides/tools-code-interpreter
|
|
@@ -275,6 +280,14 @@ class OpenAICodeInterpreterTool(OpenAIBuiltInTool[CodeInterpreter]):
|
|
|
275
280
|
def display_name(self) -> str:
|
|
276
281
|
return self.DISPLAY_NAME
|
|
277
282
|
|
|
283
|
+
@override
|
|
284
|
+
def get_required_include_params(self) -> list[ResponseIncludable]:
|
|
285
|
+
if feature_flags.enable_code_execution_fence_un_17972.is_enabled(
|
|
286
|
+
self._company_id
|
|
287
|
+
):
|
|
288
|
+
return ["code_interpreter_call.outputs"]
|
|
289
|
+
return []
|
|
290
|
+
|
|
278
291
|
@classmethod
|
|
279
292
|
def get_debug_info(cls, call: ResponseCodeInterpreterToolCall) -> dict[str, Any]:
|
|
280
293
|
return {
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
from openai import AsyncOpenAI
|
|
2
|
+
from openai.types.responses import ResponseIncludable
|
|
2
3
|
|
|
3
4
|
from unique_toolkit.agentic.tools.config import ToolBuildConfig
|
|
4
5
|
from unique_toolkit.agentic.tools.openai_builtin.base import (
|
|
@@ -79,3 +80,14 @@ class OpenAIBuiltInToolManager:
|
|
|
79
80
|
|
|
80
81
|
def get_all_openai_builtin_tools(self) -> list[OpenAIBuiltInTool]:
|
|
81
82
|
return self._builtin_tools.copy()
|
|
83
|
+
|
|
84
|
+
def get_required_include_params(self) -> list[ResponseIncludable]:
|
|
85
|
+
"""Aggregate include params required by all active built-in tools."""
|
|
86
|
+
seen: set[str] = set()
|
|
87
|
+
result: list[ResponseIncludable] = []
|
|
88
|
+
for tool in self._builtin_tools:
|
|
89
|
+
for param in tool.get_required_include_params():
|
|
90
|
+
if param not in seen:
|
|
91
|
+
seen.add(param)
|
|
92
|
+
result.append(param)
|
|
93
|
+
return result
|
{unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/agentic/tools/tool_manager.py
RENAMED
|
@@ -7,6 +7,7 @@ from openai.types.chat import (
|
|
|
7
7
|
ChatCompletionNamedToolChoiceParam,
|
|
8
8
|
)
|
|
9
9
|
from openai.types.responses import (
|
|
10
|
+
ResponseIncludable,
|
|
10
11
|
ToolParam,
|
|
11
12
|
response_create_params,
|
|
12
13
|
)
|
|
@@ -490,6 +491,7 @@ class ResponsesApiToolManager(_ToolManager[Literal["responses"]]):
|
|
|
490
491
|
a2a_manager: A2AManager,
|
|
491
492
|
builtin_tool_manager: OpenAIBuiltInToolManager,
|
|
492
493
|
) -> None:
|
|
494
|
+
self._builtin_tool_manager = builtin_tool_manager
|
|
493
495
|
super().__init__(
|
|
494
496
|
logger=logger,
|
|
495
497
|
config=config,
|
|
@@ -500,3 +502,7 @@ class ResponsesApiToolManager(_ToolManager[Literal["responses"]]):
|
|
|
500
502
|
api_mode="responses",
|
|
501
503
|
builtin_tool_manager=builtin_tool_manager,
|
|
502
504
|
)
|
|
505
|
+
|
|
506
|
+
def get_required_include_params(self) -> list[ResponseIncludable]:
|
|
507
|
+
"""Return Responses API include params required by all active built-in tools."""
|
|
508
|
+
return self._builtin_tool_manager.get_required_include_params()
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/base_model_type_attribute.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/config_checker/README.md
RENAMED
|
File without changes
|
{unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/config_checker/__init__.py
RENAMED
|
File without changes
|
{unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/config_checker/__main__.py
RENAMED
|
File without changes
|
{unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/config_checker/cli.py
RENAMED
|
File without changes
|
{unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/config_checker/differ.py
RENAMED
|
File without changes
|
{unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/config_checker/exporter.py
RENAMED
|
File without changes
|
{unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/config_checker/models.py
RENAMED
|
File without changes
|
{unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/config_checker/registry.py
RENAMED
|
File without changes
|
{unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/config_checker/validator.py
RENAMED
|
File without changes
|
{unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/default_language_model.py
RENAMED
|
File without changes
|
{unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/docx_generator/__init__.py
RENAMED
|
File without changes
|
{unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/docx_generator/config.py
RENAMED
|
File without changes
|
|
File without changes
|
{unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/docx_generator/schemas.py
RENAMED
|
File without changes
|
{unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/docx_generator/service.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
{unique_toolkit-1.63.1 → unique_toolkit-1.64.0}/unique_toolkit/_common/endpoint_requestor.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|