fred-runtime 3.5.0__tar.gz → 3.5.2__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.
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/PKG-INFO +1 -1
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/app/_catalogs.py +96 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/app/agent_app.py +253 -79
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/app/config.py +41 -1
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/app/context.py +33 -3
- fred_runtime-3.5.2/fred_runtime/app/platform_sql.py +307 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/assembly.py +14 -1
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/document_access/capability.py +12 -8
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/document_extract/capability.py +13 -2
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/document_read_common.py +36 -2
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/document_summarize/capability.py +12 -1
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/mcp.py +38 -46
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/common/kf_document_client.py +4 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/common/mcp_runtime.py +20 -5
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/common/mcp_utils.py +27 -2
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/deep/deep_runtime.py +101 -90
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/integrations/v2_runtime/adapters.py +412 -35
- fred_runtime-3.5.0/fred_runtime/migrations.py → fred_runtime-3.5.2/fred_runtime/migrations/__init__.py +5 -5
- fred_runtime-3.5.2/fred_runtime/migrations/env.py +50 -0
- fred_runtime-3.5.2/fred_runtime/migrations/script.py.mako +32 -0
- fred_runtime-3.5.2/fred_runtime/migrations/versions/__init__.py +1 -0
- fred_runtime-3.5.2/fred_runtime/migrations/versions/a1e2f3c4d5b6_create_session_history.py +75 -0
- fred_runtime-3.5.2/fred_runtime/migrations/versions/b2f3a4e5c6d7_add_exchange_id.py +49 -0
- fred_runtime-3.5.2/fred_runtime/migrations/versions/c3d4b5a6f7e8_add_team_and_instance.py +70 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/model_routing/contracts.py +42 -1
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/model_routing/provider.py +9 -3
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/model_routing/resolver.py +2 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/react_message_codec.py +1 -8
- fred_runtime-3.5.2/fred_runtime/react/react_prompting.py +485 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/react_runtime.py +173 -67
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/react_tool_binding.py +140 -45
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/react_tool_rendering.py +23 -16
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/react_tool_resolution.py +19 -1
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/runtime_context.py +75 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/runtime_support/__init__.py +2 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/runtime_support/checkpoints.py +5 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/runtime_support/request_context_helpers.py +26 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/runtime_support/sql_checkpointer.py +1 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/runtime_support/trace_payloads.py +10 -2
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/support/thinking.py +9 -5
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime.egg-info/PKG-INFO +1 -1
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime.egg-info/SOURCES.txt +18 -1
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/pyproject.toml +9 -3
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_agent_app.py +43 -63
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_capability_document_access_1906.py +25 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_capability_document_reading.py +42 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_capability_endpoints_1974.py +63 -0
- fred_runtime-3.5.2/tests/test_deep_agent_dispatch.py +209 -0
- fred_runtime-3.5.2/tests/test_deep_agent_hitl_integration.py +613 -0
- fred_runtime-3.5.2/tests/test_deep_agent_middleware.py +415 -0
- fred_runtime-3.5.2/tests/test_document_read_scope.py +236 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_hitl_resume_langgraph_integration.py +87 -0
- fred_runtime-3.5.2/tests/test_migrations.py +114 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_model_enforcement.py +50 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_model_reasoning_enablement.py +69 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_model_routing.py +47 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_models_catalog_projection.py +99 -0
- fred_runtime-3.5.2/tests/test_platform_sql.py +175 -0
- fred_runtime-3.5.2/tests/test_platform_sql_postgres_integration.py +285 -0
- fred_runtime-3.5.2/tests/test_react_checkpoint_namespace.py +188 -0
- fred_runtime-3.5.2/tests/test_react_prompting.py +985 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_react_thinking.py +177 -1
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_react_token_usage_totals.py +1 -0
- fred_runtime-3.5.2/tests/test_react_tool_binding_span_status.py +138 -0
- fred_runtime-3.5.2/tests/test_react_tool_error_final_2244.py +572 -0
- fred_runtime-3.5.2/tests/test_react_tool_resolution.py +128 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_runtime_context_prompt_injection.py +14 -3
- fred_runtime-3.5.2/tests/test_similarity_search_tool_invoker.py +128 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_sql_checkpointer_owner.py +25 -0
- fred_runtime-3.5.2/tests/test_team_wiki_adapter.py +340 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_tool_carrier_middleware_naming.py +5 -3
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_trace_payloads.py +30 -0
- fred_runtime-3.5.0/fred_runtime/react/react_prompting.py +0 -354
- fred_runtime-3.5.0/tests/test_deep_agent_middleware.py +0 -174
- fred_runtime-3.5.0/tests/test_react_checkpoint_namespace.py +0 -94
- fred_runtime-3.5.0/tests/test_react_prompting.py +0 -281
- fred_runtime-3.5.0/tests/test_react_tool_error_final_2244.py +0 -261
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/README.md +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/__main__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/app/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/app/chat_input_limit.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/app/config_loader.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/app/container.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/app/dependencies.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/app/mcp_config.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/app/observability_factory.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/app/openai_compat_router.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/assets.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/demo.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/demo_migrations/env.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/demo_migrations/versions/d1e2m0a0b0c0_create_demo_echo_notes.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/document_access/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/document_extract/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/document_label_search/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/document_label_search/capability.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/document_similarity/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/document_similarity/capability.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/document_summarize/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/document_verbatim/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/document_verbatim/capability.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/errors.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/openapi_dump.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/capabilities/registry.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/cli/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/cli/completion.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/cli/entrypoint.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/cli/history_display.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/cli/kpi_display.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/cli/pod_client.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/cli/repl.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/cli/repl_helpers.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/cli/url_helpers.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/client.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/common/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/common/context_aware_tool.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/common/kf_base_client.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/common/kf_fast_text_client.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/common/kf_http_client.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/common/kf_markdown_media_client.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/common/kf_tag_client.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/common/kf_vectorsearch_client.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/common/kf_workspace_client.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/common/mcp_interceptors.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/common/mcp_toolkit.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/common/structures.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/common/table_hits.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/common/token_expiry.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/common/tool_node_utils.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/deep/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/eval/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/eval/collector.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/graph/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/graph/graph_runtime.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/integrations/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/integrations/inprocess_toolkit_registry.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/integrations/kf_vector_search/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/integrations/kf_vector_search/toolkit.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/integrations/v2_runtime/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/model_routing/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/model_routing/authz.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/model_routing/catalog.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/middleware/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/middleware/checkpoint_hygiene.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/middleware/dynamic_prompt.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/middleware/frame.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/middleware/hitl.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/middleware/shared.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/middleware/tool_observability.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/middleware/tracing_kpi.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/react_langchain_adapter.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/react_model_adapter.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/react_stream_adapter.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/react_tool_loop.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/react_tool_utils.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/react/react_tracing.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/runtime_support/model_metadata.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/runtime_support/user_token_refresher.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/support/__init__.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/support/filesystem_context.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime/support/tool_loop.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime.egg-info/dependency_links.txt +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime.egg-info/entry_points.txt +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime.egg-info/requires.txt +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/fred_runtime.egg-info/top_level.txt +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/setup.cfg +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_capability_agent_1973.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_capability_chat_controls_1976.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_capability_chat_parts_1977.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_capability_document_label_search.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_capability_document_similarity.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_capability_document_summarize.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_capability_registry_1973.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_capability_routes_tables_1979.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_capability_selection_1974.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_capability_tool_return_convention.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_chat_input_limit.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_checkpoint_namespace.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_client.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_config_loader.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_context.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_context_aware_tool.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_conversational_memory.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_document_port_error_redaction.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_document_similarity_adapter.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_eval_collector.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_eval_trace.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_fred_workspace_fs.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_graph_capability_bridge.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_graph_checkpoint_namespace.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_graph_runtime_invoke_agent.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_graph_runtime_observability.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_graph_runtime_token_usage_totals.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_history.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_history_display.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_kf_base_client_refresh_shapes.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_kf_vector_search_toolkit.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_kf_workspace_client.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_knowledge_search_table_ordering.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_knowledge_search_tool_invoker_sources.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_kpi_display.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_langfuse_tracing.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_langgraph_interrupt_id_semantics.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_mcp_config.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_model_metadata_cache_tokens.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_model_routing_provider.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_openai_compat_router.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_pod_client.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_react_loop_regressions_1972.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_react_message_codec_resume.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_react_middleware_frame.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_repl_helpers.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_smoke.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_spike_capability_state_1971.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_sql_checkpointer_hitl_claim.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_table_repair_wiring.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_token_expiry.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_tool_loop_trim.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_tool_observability_middleware.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_tracing_kpi_content_confinement.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_url_helpers.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_user_token_refresher.py +0 -0
- {fred_runtime-3.5.0 → fred_runtime-3.5.2}/tests/test_vector_similarity_search_retry.py +0 -0
|
@@ -32,6 +32,7 @@ Example:
|
|
|
32
32
|
|
|
33
33
|
from __future__ import annotations
|
|
34
34
|
|
|
35
|
+
import json
|
|
35
36
|
import logging
|
|
36
37
|
import os
|
|
37
38
|
from pathlib import Path
|
|
@@ -47,8 +48,10 @@ logger = logging.getLogger(__name__)
|
|
|
47
48
|
|
|
48
49
|
MCP_CATALOG_ENV = "FRED_MCP_CATALOG_FILE"
|
|
49
50
|
MODELS_CATALOG_ENV = "FRED_MODELS_CATALOG_FILE"
|
|
51
|
+
PLATFORM_PROMPT_ENV = "FRED_PLATFORM_PROMPT_FILE"
|
|
50
52
|
MCP_CATALOG_DEFAULT_PATH = "./config/mcp_catalog.yaml"
|
|
51
53
|
MODELS_CATALOG_DEFAULT_PATH = "./config/models_catalog.yaml"
|
|
54
|
+
PLATFORM_PROMPT_DEFAULT_PATH = "./config/platform_prompt.json"
|
|
52
55
|
|
|
53
56
|
|
|
54
57
|
class _CatalogFile(BaseModel):
|
|
@@ -211,6 +214,80 @@ def resolve_models_catalog_path() -> Path:
|
|
|
211
214
|
return Path(MODELS_CATALOG_DEFAULT_PATH)
|
|
212
215
|
|
|
213
216
|
|
|
217
|
+
class PlatformPromptFile(BaseModel):
|
|
218
|
+
"""
|
|
219
|
+
Shape of `config/platform_prompt.json` — the two blocks that open every
|
|
220
|
+
agent's system prompt, in the order the model receives them.
|
|
221
|
+
|
|
222
|
+
Why one file with two fields:
|
|
223
|
+
- they are one thing, the head of the prompt, and reading them side by side
|
|
224
|
+
is the only way to see whether they contradict each other.
|
|
225
|
+
|
|
226
|
+
They differ in exactly one way, which the field names carry:
|
|
227
|
+
- `platform_prompt` is a STARTING POINT. A platform admin edits it in the
|
|
228
|
+
admin UI; the saved value lives in Postgres and reaches the runtime per
|
|
229
|
+
turn on `BoundRuntimeContext.platform_prompt`, after which this text is
|
|
230
|
+
no longer used.
|
|
231
|
+
- `platform_instructions` is SHIPPED. Nothing edits it; the admin UI renders
|
|
232
|
+
it read-only. It is what keeps agents coherent (call the tools you were
|
|
233
|
+
given, never fake a call, recover from a failed one) however the prompt
|
|
234
|
+
above it is rewritten.
|
|
235
|
+
|
|
236
|
+
Both are required under `extra="forbid"`: making either optional is what
|
|
237
|
+
would let a bad edit silently drop a block, since the runtime renders
|
|
238
|
+
nothing for an empty one and nothing else would fail.
|
|
239
|
+
|
|
240
|
+
`version` is not a schema version to branch on — it lets a future migration
|
|
241
|
+
tell a hand-edited file from a shipped default. `_comment` documents the
|
|
242
|
+
file for whoever opens it and is accepted but unused.
|
|
243
|
+
|
|
244
|
+
How to use:
|
|
245
|
+
- resolved and loaded once at pod boot by `apply_external_catalog_overrides`
|
|
246
|
+
- served to control-plane by `GET /agents/platform-prompt`
|
|
247
|
+
"""
|
|
248
|
+
|
|
249
|
+
model_config = ConfigDict(extra="forbid", populate_by_name=True)
|
|
250
|
+
|
|
251
|
+
version: int
|
|
252
|
+
platform_prompt: str
|
|
253
|
+
platform_instructions: str
|
|
254
|
+
comment: str | None = Field(default=None, alias="_comment")
|
|
255
|
+
|
|
256
|
+
|
|
257
|
+
def resolve_platform_prompt_path() -> Path:
|
|
258
|
+
"""
|
|
259
|
+
Resolve the canonical platform-prompt file path for one pod startup.
|
|
260
|
+
|
|
261
|
+
Why this exists:
|
|
262
|
+
- same env-override contract as the two catalogs above, so operators have
|
|
263
|
+
one mental model for "pod-shipped config file" across all three.
|
|
264
|
+
|
|
265
|
+
How to use it:
|
|
266
|
+
- call during config bootstrap.
|
|
267
|
+
|
|
268
|
+
Example:
|
|
269
|
+
- `path = resolve_platform_prompt_path()`
|
|
270
|
+
"""
|
|
271
|
+
|
|
272
|
+
return Path(os.getenv(PLATFORM_PROMPT_ENV, PLATFORM_PROMPT_DEFAULT_PATH))
|
|
273
|
+
|
|
274
|
+
|
|
275
|
+
def load_platform_prompt_file(path: str | Path) -> PlatformPromptFile:
|
|
276
|
+
"""
|
|
277
|
+
Read and validate `platform_prompt.json`.
|
|
278
|
+
|
|
279
|
+
Why this exists:
|
|
280
|
+
- one loader keeps the file's shape validated in a single place, for both
|
|
281
|
+
the prompt composer and the endpoint that serves it to control-plane.
|
|
282
|
+
|
|
283
|
+
How to use it:
|
|
284
|
+
- `file = load_platform_prompt_file("./config/platform_prompt.json")`
|
|
285
|
+
"""
|
|
286
|
+
|
|
287
|
+
raw = json.loads(Path(path).read_text(encoding="utf-8"))
|
|
288
|
+
return PlatformPromptFile.model_validate(raw)
|
|
289
|
+
|
|
290
|
+
|
|
214
291
|
def resolve_mcp_catalog_path() -> Path:
|
|
215
292
|
"""
|
|
216
293
|
Resolve the canonical MCP catalog path for one pod startup.
|
|
@@ -257,6 +334,25 @@ def apply_external_catalog_overrides(config: AgentPodConfig) -> AgentPodConfig:
|
|
|
257
334
|
models_catalog_path,
|
|
258
335
|
)
|
|
259
336
|
|
|
337
|
+
platform_prompt_path = resolve_platform_prompt_path()
|
|
338
|
+
if platform_prompt_path.exists():
|
|
339
|
+
config.set_platform_prompt_file(load_platform_prompt_file(platform_prompt_path))
|
|
340
|
+
logger.info(
|
|
341
|
+
"[fred-runtime][config] platform prompt file loaded from %s",
|
|
342
|
+
platform_prompt_path,
|
|
343
|
+
)
|
|
344
|
+
else:
|
|
345
|
+
# Optional, unlike models_catalog.yaml: a pod with no file contributes
|
|
346
|
+
# neither head block, and an admin-saved platform prompt (which arrives
|
|
347
|
+
# per turn, not from here) still applies. Logged at WARNING, not INFO:
|
|
348
|
+
# a pod running without the platform instructions has lost the tool
|
|
349
|
+
# discipline every agent depends on, which is worth noticing.
|
|
350
|
+
logger.warning(
|
|
351
|
+
"[fred-runtime][config] no platform prompt file at %s; this pod "
|
|
352
|
+
"contributes no platform prompt and no platform instructions",
|
|
353
|
+
platform_prompt_path,
|
|
354
|
+
)
|
|
355
|
+
|
|
260
356
|
mcp_catalog_path = resolve_mcp_catalog_path()
|
|
261
357
|
if not mcp_catalog_path.exists():
|
|
262
358
|
config.set_mcp_configuration(None)
|