databricks-tellr-app 0.4.3.dev3435__tar.gz → 0.4.3.dev3436__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.
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/PKG-INFO +1 -1
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/databricks_tellr_app.egg-info/PKG-INFO +1 -1
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/pyproject.toml +1 -1
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/chat.py +32 -2
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/services/session_manager.py +61 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/graph/builder.py +55 -66
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/graph/nodes.py +209 -28
- databricks_tellr_app-0.4.3.dev3436/src/services/graph/routers.py +130 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/graph/state.py +10 -4
- databricks_tellr_app-0.4.3.dev3435/src/services/graph/routers.py +0 -234
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/README.md +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/databricks_tellr_app/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/databricks_tellr_app/run.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/databricks_tellr_app.egg-info/SOURCES.txt +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/databricks_tellr_app.egg-info/dependency_links.txt +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/databricks_tellr_app.egg-info/requires.txt +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/databricks_tellr_app.egg-info/top_level.txt +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/setup.cfg +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/setup.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/_otel_bootstrap.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/fixtures/tour_demo_deck.json +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/main.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/mcp_auth.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/mcp_server.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/middleware/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/middleware/csrf.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/middleware/request_logging.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/middleware/security_headers.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/_authz.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/admin.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/admin_usage.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/agent_config.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/agent_definitions.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/deck_contributors.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/export.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/feedback.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/google_slides.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/images.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/local_version.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/profiles.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/sessions.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/settings/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/settings/contributors.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/settings/deck_prompts.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/settings/design_systems.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/settings/identities.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/settings/slide_styles.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/setup.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/slides.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/tools.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/tour.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/verification.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/version.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/schemas/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/schemas/agent_config.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/schemas/agent_definitions.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/schemas/feedback.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/schemas/graph_release_history.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/schemas/graph_releases.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/schemas/requests.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/schemas/responses.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/schemas/settings/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/schemas/settings/requests.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/schemas/settings/responses.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/schemas/streaming.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/services/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/services/chat_service.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/services/deck_level_writer.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/services/export_job_queue.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/services/feedback_service.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/services/job_queue.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/services/session_naming.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/services/slide_repository.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/services/usage_events.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/services/usage_service.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/utils/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/utils/validation.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/backfill_session_slides_startup.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/checkpointer.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/config_loader.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/context_utils.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/database.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/databricks_client.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/defaults.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/encryption.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/init_default_profile.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/lakebase.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/migrate_profiles_to_agent_config.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/mlflow_agent_spans.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/mlflow_tracing.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/otel_logging.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/permission_context.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/prompt_modules.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/settings_db.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/skills/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/skills/architect.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/skills/build_reviewer.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/skills/builder.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/skills/data_analyst.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/skills/deck_reviewer.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/skills/fix_reviewer.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/skills/fixer.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/strip_retired_prompt_keys.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/core/user_context.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/deck_contributor.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/deck_review.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/design_system.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/encryption_key.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/feedback.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/genie_space.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/google_global_credentials.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/google_oauth_token.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/graph_checkpoint.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/graph_configuration.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/identity.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/image.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/profile.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/profile_contributor.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/prompts.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/request_log.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/session.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/slide_deck_prompt.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/slide_style_library.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/usage_event.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/models/user_preference.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/database/types.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/domain/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/domain/conversation_engine.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/domain/deck_spec.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/domain/finding.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/domain/skill_io.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/domain/slide.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/domain/slide_deck.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/agent.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/agent_definition_manifest_v1.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/agent_factory.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/agent_model_payload.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/agent_resolution.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/agent_runtime.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/agent_runtime_identity.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/agent_schema_registry.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/agent_schema_types.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/agent_test_workbench.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/collaboration_history.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/config_service.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/config_validator.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/conversation_pins.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/converter_jail/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/converter_jail/ast_guard.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/converter_jail/codeprep.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/converter_jail/gslides_runner.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/converter_jail/jail.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/converter_jail/pptx_runner.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/converter_jail/protocol.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/deck_css_aggregator.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/deck_review_store.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/design_system_compiler.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/design_system_service.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/design_system_templates.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/drive_uploader.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/evaluation/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/evaluation/llm_judge.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/foreman_service.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/gateway_openai.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/genie_service.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/google_slides_auth.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/google_slides_prompts_defaults.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/graph/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/graph/event_emitter.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/graph_configuration.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/graph_configuration_bootstrap.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/graph_configuration_content.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/graph_configuration_draft.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/graph_configuration_publication.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/graph_configuration_rollback.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/graph_configuration_seed.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/graph_configuration_workbench.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/graph_definition_manifest.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/graph_release_evidence.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/graph_release_history.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/html_to_google_slides.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/html_to_pptx.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/identity_provider.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/identity_providers/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/identity_providers/account_provider.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/identity_providers/local_provider.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/identity_providers/workspace_provider.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/image_service.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/image_tools.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/model_endpoint_catalog.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/model_endpoint_probe.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/permission_service.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/persisted_graph_release.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/pptx_from_html_huashu.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/pptx_from_records.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/pptx_prompts_defaults.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/profile_service.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/prompt_assembler.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/shared_deck_attribution.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/spec_sync.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/streaming_callback.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/template_sections.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/tools/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/tools/agent_bricks_tool.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/tools/ds_asset_tool.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/tools/genie_tool.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/tools/mcp_tool.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/tools/model_endpoint_tool.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/tools/vector_tool.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/services/validator.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/utils/__init__.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/utils/css_utils.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/utils/ds_asset_utils.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/utils/error_handling.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/utils/graph_safety.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/utils/html_safety.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/utils/html_utils.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/utils/image_utils.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/utils/js_validator.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/utils/logging_config.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/utils/pi_filter.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/utils/slide_hash.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/utils/spotlight.py +0 -0
- {databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/utils/text_caps.py +0 -0
{databricks_tellr_app-0.4.3.dev3435 → databricks_tellr_app-0.4.3.dev3436}/src/api/routes/chat.py
RENAMED
|
@@ -15,6 +15,7 @@ Chat access is controlled by session permissions:
|
|
|
15
15
|
import asyncio
|
|
16
16
|
import contextvars
|
|
17
17
|
import logging
|
|
18
|
+
import time
|
|
18
19
|
from typing import AsyncGenerator, Optional, Tuple
|
|
19
20
|
|
|
20
21
|
from fastapi import APIRouter, Depends, HTTPException, Query
|
|
@@ -779,6 +780,10 @@ async def poll_chat(
|
|
|
779
780
|
slide_cursor: int = Query(
|
|
780
781
|
default=0, description="Lowest slide position not yet delivered"
|
|
781
782
|
),
|
|
783
|
+
revisions_after: Optional[float] = Query(
|
|
784
|
+
default=None,
|
|
785
|
+
description="The previous response's revision_mark; omit on the first poll",
|
|
786
|
+
),
|
|
782
787
|
):
|
|
783
788
|
"""Poll for chat request status, new messages, and newly released slides.
|
|
784
789
|
|
|
@@ -802,15 +807,23 @@ async def poll_chat(
|
|
|
802
807
|
(the default) asks for every released slide. Positions are 0-based,
|
|
803
808
|
so this is inclusive — unlike ``after_message_id``, whose ids start
|
|
804
809
|
at 1. Hand back the ``slide_cursor`` from the previous response.
|
|
810
|
+
revisions_after: The previous response's ``revision_mark``. A slide's
|
|
811
|
+
builder draft is committed before its review, so a slide the client
|
|
812
|
+
already holds can be replaced later in the turn; ``slide_revisions``
|
|
813
|
+
carries those replacements (positions below ``slide_cursor`` whose
|
|
814
|
+
row changed since the mark). The client replaces by position.
|
|
805
815
|
|
|
806
816
|
Returns:
|
|
807
|
-
Dictionary with status, events, last_message_id, result, error, slides
|
|
808
|
-
and
|
|
817
|
+
Dictionary with status, events, last_message_id, result, error, slides,
|
|
818
|
+
slide_cursor, slide_revisions and revision_mark
|
|
809
819
|
|
|
810
820
|
Raises:
|
|
811
821
|
HTTPException: 404 if request not found
|
|
812
822
|
"""
|
|
813
823
|
session_manager = get_session_manager()
|
|
824
|
+
# Taken BEFORE any read, so a row rewritten while this poll runs is newer
|
|
825
|
+
# than the mark the client hands back and is returned on the next poll.
|
|
826
|
+
revision_mark = time.time()
|
|
814
827
|
|
|
815
828
|
# SDR-4437 (chat-poll IDOR): a request_id must not grant access to another
|
|
816
829
|
# user's chat events/result. ChatRequest rows are session-bound — resolve
|
|
@@ -867,6 +880,21 @@ async def poll_chat(
|
|
|
867
880
|
)
|
|
868
881
|
]
|
|
869
882
|
|
|
883
|
+
slide_revisions = [
|
|
884
|
+
{
|
|
885
|
+
"position": row["position"],
|
|
886
|
+
"html": row["html"],
|
|
887
|
+
"scripts": row["scripts"],
|
|
888
|
+
"agent": row["agent"],
|
|
889
|
+
}
|
|
890
|
+
for row in await asyncio.to_thread(
|
|
891
|
+
session_manager.slide_revisions_since,
|
|
892
|
+
session_id,
|
|
893
|
+
slide_cursor,
|
|
894
|
+
revisions_after,
|
|
895
|
+
)
|
|
896
|
+
]
|
|
897
|
+
|
|
870
898
|
return {
|
|
871
899
|
"status": chat_request["status"],
|
|
872
900
|
"events": events,
|
|
@@ -880,4 +908,6 @@ async def poll_chat(
|
|
|
880
908
|
"slide_cursor": (
|
|
881
909
|
released_slides[-1]["position"] + 1 if released_slides else slide_cursor
|
|
882
910
|
),
|
|
911
|
+
"slide_revisions": slide_revisions,
|
|
912
|
+
"revision_mark": revision_mark,
|
|
883
913
|
}
|
|
@@ -2307,6 +2307,67 @@ class SessionManager:
|
|
|
2307
2307
|
)
|
|
2308
2308
|
return released
|
|
2309
2309
|
|
|
2310
|
+
#: How far before the client's mark a revision is still returned. The mark
|
|
2311
|
+
#: is taken before this poll's reads, but a row stamped just before the mark
|
|
2312
|
+
#: may commit just after it; returning a revision twice is harmless (the
|
|
2313
|
+
#: client replaces a slide by position), missing one is not.
|
|
2314
|
+
REVISION_OVERLAP_S = 2.0
|
|
2315
|
+
|
|
2316
|
+
def slide_revisions_since(
|
|
2317
|
+
self, session_id: str, cursor: int, since: Optional[float]
|
|
2318
|
+
) -> List[Dict[str, Any]]:
|
|
2319
|
+
"""Already-delivered slides whose row was rewritten after *since*.
|
|
2320
|
+
|
|
2321
|
+
The reorder buffer (:meth:`slides_since_cursor`) releases each position
|
|
2322
|
+
ONCE. Since a slide's builder draft is committed before its review
|
|
2323
|
+
(``slide_pipeline_node``), the row a client received may later be
|
|
2324
|
+
replaced by its reviewed or fixed version within the same turn; this is
|
|
2325
|
+
how a polling client learns of that.
|
|
2326
|
+
|
|
2327
|
+
Only positions BELOW *cursor* are considered — anything at or above it
|
|
2328
|
+
is still the reorder buffer's to release, with its latest content.
|
|
2329
|
+
*since* is the ``revision_mark`` the previous poll returned (epoch
|
|
2330
|
+
seconds, naive UTC like ``modified_at``); ``None`` means the client has
|
|
2331
|
+
no mark yet, so it has received nothing that could have been revised.
|
|
2332
|
+
|
|
2333
|
+
Args:
|
|
2334
|
+
session_id: Session (a contributor session resolves to the deck owner).
|
|
2335
|
+
cursor: Lowest position not yet delivered to this caller.
|
|
2336
|
+
since: The previous poll's ``revision_mark``, or ``None``.
|
|
2337
|
+
|
|
2338
|
+
Returns:
|
|
2339
|
+
Ascending list shaped exactly like :meth:`slides_since_cursor`'s.
|
|
2340
|
+
|
|
2341
|
+
Raises:
|
|
2342
|
+
SessionNotFoundError: if session_id does not match any session.
|
|
2343
|
+
"""
|
|
2344
|
+
ceiling = max(0, int(cursor))
|
|
2345
|
+
if since is None or ceiling == 0:
|
|
2346
|
+
return []
|
|
2347
|
+
threshold = datetime.utcfromtimestamp(float(since) - self.REVISION_OVERLAP_S)
|
|
2348
|
+
with get_db_session() as db:
|
|
2349
|
+
session = self._get_session_or_raise(db, session_id)
|
|
2350
|
+
deck_owner = self._get_deck_owner_session(db, session)
|
|
2351
|
+
rows = (
|
|
2352
|
+
db.query(SessionSlide)
|
|
2353
|
+
.filter(
|
|
2354
|
+
SessionSlide.session_id == deck_owner.id,
|
|
2355
|
+
SessionSlide.position < ceiling,
|
|
2356
|
+
SessionSlide.modified_at > threshold,
|
|
2357
|
+
)
|
|
2358
|
+
.order_by(SessionSlide.position)
|
|
2359
|
+
.all()
|
|
2360
|
+
)
|
|
2361
|
+
return [
|
|
2362
|
+
{
|
|
2363
|
+
"position": row.position,
|
|
2364
|
+
"html": row.html or "",
|
|
2365
|
+
"scripts": row.scripts or "",
|
|
2366
|
+
"agent": row.modified_by or row.created_by,
|
|
2367
|
+
}
|
|
2368
|
+
for row in rows
|
|
2369
|
+
]
|
|
2370
|
+
|
|
2310
2371
|
def get_verification_map(self, session_id: str) -> Dict[str, Any]:
|
|
2311
2372
|
"""Aggregate the verification map from per-row session_slides records.
|
|
2312
2373
|
|
|
@@ -9,48 +9,59 @@ The topology, which IS the product
|
|
|
9
9
|
build: foreman, edit: foreman,
|
|
10
10
|
confirm_design_contract: END}
|
|
11
11
|
data_analyst --static------> architect
|
|
12
|
-
foreman --conditional-> [
|
|
12
|
+
foreman --conditional-> [slide_pipeline(Send), placeholder,
|
|
13
13
|
deck_reviewer, END]
|
|
14
|
-
|
|
15
|
-
build_reviewer --static------> foreman # measured clean; NO router here
|
|
16
|
-
fixer --conditional-> [fix_reviewer, foreman]
|
|
17
|
-
fix_reviewer --static------> foreman
|
|
14
|
+
slide_pipeline --static------> foreman
|
|
18
15
|
placeholder --static------> foreman
|
|
19
16
|
deck_reviewer --static------> END
|
|
20
17
|
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
Why
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
18
|
+
Six nodes. ``START``/``END`` are the imported sentinels, never the strings.
|
|
19
|
+
|
|
20
|
+
Why one ``slide_pipeline`` per slide, not four fanned nodes — measured
|
|
21
|
+
----------------------------------------------------------------------
|
|
22
|
+
LangGraph runs in supersteps, and a superstep ends only when its slowest task
|
|
23
|
+
does. With ``builder``, ``build_reviewer``, ``fixer`` and ``fix_reviewer`` as
|
|
24
|
+
separate nodes, a real 10-slide deck (local, real Gateway models, 2026-10-12)
|
|
25
|
+
spent its time like this::
|
|
26
|
+
|
|
27
|
+
SS1 0- 55s architect
|
|
28
|
+
SS3 55- 67s builder x10 slide 0 done at 62s, waited to 67s
|
|
29
|
+
SS4 67-115s build_reviewer x10 slide 0 done at 91s, waited to 115s
|
|
30
|
+
SS5-32 115-301s foreman -> fixer -> fix_reviewer, x9, ONE AT A TIME
|
|
31
|
+
SS33 301-308s deck_reviewer
|
|
32
|
+
|
|
33
|
+
9 of 10 slides were flagged, and the fixer took the lowest pending position per
|
|
34
|
+
superstep, so 186s of the 308s turn was a queue. Fanning the fixers out with
|
|
35
|
+
``Send`` removes the queue but not the barriers: every slide would still wait
|
|
36
|
+
for the slowest builder, the slowest reviewer and the slowest fixer before it
|
|
37
|
+
could land. Folding each slide's whole chain into one task removes both; the
|
|
38
|
+
only barrier left is the foreman's wake after the slowest whole chain, and a
|
|
39
|
+
slide is committed (and visible to a polling client) the moment its own chain
|
|
40
|
+
writes the row.
|
|
41
|
+
|
|
42
|
+
Hazards this topology must keep closed, each pinned in
|
|
43
|
+
``tests/unit/test_slide_pipeline.py``:
|
|
44
|
+
|
|
45
|
+
* **Fan-in keys.** A slide's fix state (``fix_map``, ``fix_target``,
|
|
46
|
+
``fixed``) and the single-writer ``error_state`` never leave its pipeline;
|
|
47
|
+
every key a pipeline does return carries a reducer.
|
|
48
|
+
* **The deck reviewer ran twice** when a branch with nothing to review woke the
|
|
49
|
+
foreman in the same superstep as its siblings' reviewers (measured on a
|
|
50
|
+
three-slide turn with one failed builder: SS4 held ``build_reviewer(0)``,
|
|
51
|
+
``build_reviewer(2)`` AND ``foreman``, and deck review then fired in SS6 and
|
|
52
|
+
SS7). Every pipeline now ends on the same static edge, so all of a batch's
|
|
53
|
+
branches reach the foreman together however they split, and it wakes once.
|
|
54
|
+
* **Empty wakes** are unchanged: the foreman still records a wake on every
|
|
55
|
+
entry and the router still never recomputes the batch (see
|
|
56
|
+
``foreman_router``).
|
|
57
|
+
* **Exactly one fix round per slide** holds by construction — a pipeline runs
|
|
58
|
+
its fixer at most once — and ``in_flight`` remains the fixer's own guard.
|
|
59
|
+
|
|
60
|
+
What still waits: a deck over ``CAP`` slides dispatches its next batch only when
|
|
61
|
+
the whole previous batch's pipelines have finished, and the SSE transport (dev
|
|
62
|
+
only — production polls) releases slides at the foreman's wakes, i.e. after the
|
|
63
|
+
batch. The polling transport reads committed rows, so it sees each slide as
|
|
64
|
+
soon as its draft, and then its reviewed row, is written.
|
|
54
65
|
|
|
55
66
|
Configuration
|
|
56
67
|
-------------
|
|
@@ -87,19 +98,14 @@ from src.services.graph.event_emitter import (
|
|
|
87
98
|
)
|
|
88
99
|
from src.services.graph.nodes import (
|
|
89
100
|
architect_node,
|
|
90
|
-
build_reviewer_node,
|
|
91
|
-
builder_node,
|
|
92
101
|
data_analyst_node,
|
|
93
102
|
deck_reviewer_node,
|
|
94
|
-
fix_reviewer_node,
|
|
95
|
-
fixer_node,
|
|
96
103
|
foreman_node,
|
|
97
104
|
placeholder_node,
|
|
105
|
+
slide_pipeline_node,
|
|
98
106
|
)
|
|
99
107
|
from src.services.graph.routers import (
|
|
100
108
|
architect_router,
|
|
101
|
-
build_reviewer_refan_router,
|
|
102
|
-
fixer_router,
|
|
103
109
|
foreman_router,
|
|
104
110
|
)
|
|
105
111
|
from src.services.graph.state import GraphState, scoped
|
|
@@ -128,10 +134,7 @@ def build_graph(checkpointer: Any = None):
|
|
|
128
134
|
graph.add_node("architect", architect_node)
|
|
129
135
|
graph.add_node("data_analyst", data_analyst_node)
|
|
130
136
|
graph.add_node("foreman", foreman_node)
|
|
131
|
-
graph.add_node("
|
|
132
|
-
graph.add_node("build_reviewer", build_reviewer_node)
|
|
133
|
-
graph.add_node("fixer", fixer_node)
|
|
134
|
-
graph.add_node("fix_reviewer", fix_reviewer_node)
|
|
137
|
+
graph.add_node("slide_pipeline", slide_pipeline_node)
|
|
135
138
|
graph.add_node("placeholder", placeholder_node)
|
|
136
139
|
graph.add_node("deck_reviewer", deck_reviewer_node)
|
|
137
140
|
|
|
@@ -149,31 +152,17 @@ def build_graph(checkpointer: Any = None):
|
|
|
149
152
|
"foreman",
|
|
150
153
|
foreman_router,
|
|
151
154
|
{
|
|
152
|
-
"
|
|
153
|
-
"fixer": "fixer",
|
|
155
|
+
"slide_pipeline": "slide_pipeline",
|
|
154
156
|
"placeholder": "placeholder",
|
|
155
157
|
"deck_reviewer": "deck_reviewer",
|
|
156
158
|
END: END,
|
|
157
159
|
},
|
|
158
160
|
)
|
|
159
|
-
graph.add_conditional_edges(
|
|
160
|
-
"builder",
|
|
161
|
-
build_reviewer_refan_router,
|
|
162
|
-
# "placeholder", not "foreman", for a branch with nothing to review — see
|
|
163
|
-
# build_reviewer_refan_router's docstring for the measured trace. Routing
|
|
164
|
-
# a placeheld branch to the foreman wakes it in the reviewers' superstep
|
|
165
|
-
# and the deck reviewer then runs TWICE.
|
|
166
|
-
{"build_reviewer": "build_reviewer", "placeholder": "placeholder"},
|
|
167
|
-
)
|
|
168
|
-
graph.add_conditional_edges(
|
|
169
|
-
"fixer",
|
|
170
|
-
fixer_router,
|
|
171
|
-
{"fix_reviewer": "fix_reviewer", "foreman": "foreman"},
|
|
172
|
-
)
|
|
173
161
|
|
|
174
162
|
graph.add_edge("data_analyst", "architect")
|
|
175
|
-
|
|
176
|
-
|
|
163
|
+
# Static, so every pipeline in a batch reaches the foreman in ONE superstep
|
|
164
|
+
# and it wakes once — see the module docstring.
|
|
165
|
+
graph.add_edge("slide_pipeline", "foreman")
|
|
177
166
|
graph.add_edge("placeholder", "foreman")
|
|
178
167
|
graph.add_edge("deck_reviewer", END)
|
|
179
168
|
|
|
@@ -1,20 +1,26 @@
|
|
|
1
|
-
"""The
|
|
1
|
+
"""The nodes of the deck-generation graph.
|
|
2
2
|
|
|
3
|
-
``architect``, ``data_analyst``, ``foreman``,
|
|
4
|
-
``
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
Six graph nodes: ``architect``, ``data_analyst``, ``foreman``,
|
|
4
|
+
``slide_pipeline``, ``placeholder``, ``deck_reviewer``.
|
|
5
|
+
|
|
6
|
+
``slide_pipeline`` runs four STAGE functions in sequence for one slide:
|
|
7
|
+
``builder_node``, ``build_reviewer_node``, ``fixer_node`` and
|
|
8
|
+
``fix_reviewer_node``. They were graph nodes until the superstep barrier was
|
|
9
|
+
measured to serialise every deck behind its slowest slide and run fixes one at a
|
|
10
|
+
time (see :func:`slide_pipeline_node`); they keep their own contracts and
|
|
11
|
+
tests, and the pipeline folds their updates with ``GraphState``'s reducers.
|
|
7
12
|
|
|
8
13
|
Two node kinds, and the difference decides everything
|
|
9
14
|
-----------------------------------------------------
|
|
10
|
-
*Edge-reached* nodes (``architect``, ``data_analyst``, ``foreman``,
|
|
11
|
-
``
|
|
15
|
+
*Edge-reached* nodes (``architect``, ``data_analyst``, ``foreman``,
|
|
16
|
+
``placeholder``, ``deck_reviewer``) receive ``GraphState``.
|
|
12
17
|
|
|
13
|
-
*``Send``-reached*
|
|
14
|
-
|
|
18
|
+
The *``Send``-reached* node (``slide_pipeline``) receives **only its payload** —
|
|
19
|
+
measured: a Send-reached node saw ``['batch', 'position']`` and no state key at
|
|
15
20
|
all. That is why :func:`build_branch_payload` pre-copies everything a branch
|
|
16
|
-
needs
|
|
17
|
-
|
|
21
|
+
needs. Within the pipeline, ``builder_node`` and ``build_reviewer_node`` take
|
|
22
|
+
payload-shaped input, and ``fixer_node`` / ``fix_reviewer_node`` take a
|
|
23
|
+
slide-local state the pipeline assembles from that payload.
|
|
18
24
|
|
|
19
25
|
What each node may return
|
|
20
26
|
-------------------------
|
|
@@ -41,7 +47,7 @@ from __future__ import annotations
|
|
|
41
47
|
import json
|
|
42
48
|
import logging
|
|
43
49
|
import time
|
|
44
|
-
from typing import Any, Dict, List, Optional, Set
|
|
50
|
+
from typing import Any, Dict, List, Optional, Set, get_type_hints
|
|
45
51
|
|
|
46
52
|
from src.api.schemas.agent_config import AgentConfig, resolve_agent_config
|
|
47
53
|
from src.api.schemas.streaming import StreamEvent, StreamEventType
|
|
@@ -82,7 +88,7 @@ from src.services.graph.event_emitter import (
|
|
|
82
88
|
get_event_emitter,
|
|
83
89
|
get_slide_cursor,
|
|
84
90
|
)
|
|
85
|
-
from src.services.graph.state import
|
|
91
|
+
from src.services.graph.state import GraphState, scoped, scoped_vals
|
|
86
92
|
from src.services.persisted_graph_release import PersistedRuntimeError
|
|
87
93
|
from src.services.shared_deck_attribution import (
|
|
88
94
|
DeckMutationContext,
|
|
@@ -2009,9 +2015,11 @@ def _with_wake_appended(state: dict, turn_id: str, batch: List[int]) -> dict:
|
|
|
2009
2015
|
def foreman_node(state: dict) -> Dict[str, Any]:
|
|
2010
2016
|
"""Decide what happens next, and record the decision for the router.
|
|
2011
2017
|
|
|
2012
|
-
**The decision order is ``
|
|
2013
|
-
|
|
2014
|
-
|
|
2018
|
+
**The decision order is ``dispatch -> stall -> all-committed -> END``**
|
|
2019
|
+
(Ruling C-2, with its leading ``fix`` limb removed: a slide's fix round now
|
|
2020
|
+
runs inside its own ``slide_pipeline_node``, so no fix is ever pending at a
|
|
2021
|
+
wake and nothing preempts dispatch). Stall must come AFTER dispatch, not
|
|
2022
|
+
before as the plan had it. The two orders are mutually unsatisfiable: after the superstep barrier, a position left
|
|
2015
2023
|
uncommitted by a completed batch is **always in** the most recent
|
|
2016
2024
|
``foreman_wakes`` batch, so ``stalled_positions``' limb 1 — which excludes
|
|
2017
2025
|
that batch — would exclude exactly the case it exists for, and the turn
|
|
@@ -2052,16 +2060,10 @@ def foreman_node(state: dict) -> Dict[str, Any]:
|
|
|
2052
2060
|
# 0. ws4d D3 — release committed slides BEFORE the ladder, so every wake
|
|
2053
2061
|
# delivers what the previous superstep committed no matter which limb this
|
|
2054
2062
|
# wake then takes. Inside the ladder it would sit on one branch and miss
|
|
2055
|
-
# the others: the
|
|
2056
|
-
#
|
|
2063
|
+
# the others: the all-committed limb is the wake that carries the LAST
|
|
2064
|
+
# slide of the deck.
|
|
2057
2065
|
_release_slides(state)
|
|
2058
2066
|
|
|
2059
|
-
# 1. A pending fix preempts dispatch entirely. A 31-slide deck stops
|
|
2060
|
-
# dispatching new builders until every fix completes; fix rounds
|
|
2061
|
-
# serialise one position per superstep.
|
|
2062
|
-
if has_pending_fix(state):
|
|
2063
|
-
return {"foreman_wakes": scoped(turn_id, [[]])}
|
|
2064
|
-
|
|
2065
2067
|
# 2/3. Compute the batch ONCE. The router reads it back out of the last
|
|
2066
2068
|
# wake and never recomputes it (Ruling C-1).
|
|
2067
2069
|
batch = next_dispatch_batch(state)
|
|
@@ -2805,10 +2807,11 @@ def fix_reviewer_node(state: dict) -> Dict[str, Any]:
|
|
|
2805
2807
|
updates: Dict[str, Any] = {
|
|
2806
2808
|
"fix_map": scoped(turn_id, {position: None}),
|
|
2807
2809
|
"fix_target": None,
|
|
2808
|
-
# Unlike the
|
|
2809
|
-
# `error_state`:
|
|
2810
|
-
#
|
|
2811
|
-
# `
|
|
2810
|
+
# Unlike the build-stage failure paths this stage may write
|
|
2811
|
+
# `error_state`: it runs strictly after its own fixer inside one
|
|
2812
|
+
# slide's pipeline. The pipeline keeps the key branch-local
|
|
2813
|
+
# (`_PIPELINE_LOCAL_KEYS`), because two pipelines returning it in
|
|
2814
|
+
# one superstep WOULD raise `InvalidUpdateError`.
|
|
2812
2815
|
"error_state": {
|
|
2813
2816
|
"node": "fix_reviewer",
|
|
2814
2817
|
"code": "fix_review_delivery_failed",
|
|
@@ -2839,6 +2842,184 @@ def fix_reviewer_node(state: dict) -> Dict[str, Any]:
|
|
|
2839
2842
|
}
|
|
2840
2843
|
|
|
2841
2844
|
|
|
2845
|
+
# ---------------------------------------------------------------------------
|
|
2846
|
+
# slide_pipeline_node
|
|
2847
|
+
# ---------------------------------------------------------------------------
|
|
2848
|
+
|
|
2849
|
+
|
|
2850
|
+
#: The reducer of every fan-in key, read off ``GraphState`` itself so the
|
|
2851
|
+
#: pipeline folds its stages' updates exactly as the runtime would fold them
|
|
2852
|
+
#: across supersteps — never a hand-copied second definition of the merge.
|
|
2853
|
+
_FAN_IN_REDUCERS: Dict[str, Any] = {
|
|
2854
|
+
name: hint.__metadata__[0]
|
|
2855
|
+
for name, hint in get_type_hints(GraphState, include_extras=True).items()
|
|
2856
|
+
if getattr(hint, "__metadata__", None)
|
|
2857
|
+
}
|
|
2858
|
+
|
|
2859
|
+
#: Keys a slide's own fix round reads and writes, and which therefore never
|
|
2860
|
+
#: leave its pipeline. ``fix_map``/``fix_target``/``fixed`` describe ONE
|
|
2861
|
+
#: slide's fix and are meaningless to its siblings; ``error_state`` is
|
|
2862
|
+
#: single-writer with no reducer, so two pipelines returning it in one superstep
|
|
2863
|
+
#: would raise ``InvalidUpdateError`` and kill the turn — the very failure the
|
|
2864
|
+
#: fanned failure paths already avoid by surfacing an ``info`` notice instead.
|
|
2865
|
+
_PIPELINE_LOCAL_KEYS = frozenset({"fix_map", "fix_target", "fixed", "error_state"})
|
|
2866
|
+
|
|
2867
|
+
|
|
2868
|
+
def _fold(acc: Dict[str, Any], update: Dict[str, Any]) -> None:
|
|
2869
|
+
"""Fold one stage's *update* into *acc* with ``GraphState``'s reducers."""
|
|
2870
|
+
for key, value in update.items():
|
|
2871
|
+
reducer = _FAN_IN_REDUCERS.get(key)
|
|
2872
|
+
if key in acc and reducer is not None:
|
|
2873
|
+
acc[key] = reducer(acc[key], value)
|
|
2874
|
+
else:
|
|
2875
|
+
acc[key] = value
|
|
2876
|
+
|
|
2877
|
+
|
|
2878
|
+
def _write_draft_row(record: dict, mutation: DeckMutationContext) -> None:
|
|
2879
|
+
"""Commit the builder's HTML so the slide is visible before it is reviewed.
|
|
2880
|
+
|
|
2881
|
+
Product decision (2026-10-12): show the draft, then replace it once the
|
|
2882
|
+
slide's own review — and fix, if any — lands. The polling transport
|
|
2883
|
+
releases committed rows, so this write is what makes the slide visible;
|
|
2884
|
+
the reviewed write later overwrites it in place.
|
|
2885
|
+
|
|
2886
|
+
**A draft only ever fills an EMPTY position.** On an edit or a rebuild the
|
|
2887
|
+
position already holds a committed slide, and a turn that then dies on a
|
|
2888
|
+
persisted runtime failure (a removed pinned endpoint, say) would leave the
|
|
2889
|
+
user's good slide replaced by an unreviewed draft and report an error. So
|
|
2890
|
+
a position with a row keeps it until the reviewed write replaces it.
|
|
2891
|
+
|
|
2892
|
+
**No ``verification_record``**: ``write_slide`` preserves the row's existing
|
|
2893
|
+
record when given ``None``, and that record is keyed by content hash, so
|
|
2894
|
+
the draft's own hash carries no verdict and reads as unreviewed rather than
|
|
2895
|
+
clean. The HTML has already been through ``gate_emitted_html`` in the
|
|
2896
|
+
builder.
|
|
2897
|
+
|
|
2898
|
+
Best-effort: a failed draft write costs only the early preview, so it is
|
|
2899
|
+
logged and the slide carries on to review, which writes the row anyway.
|
|
2900
|
+
"""
|
|
2901
|
+
position = record["position"]
|
|
2902
|
+
slide_spec = record.get("slide_spec")
|
|
2903
|
+
try:
|
|
2904
|
+
writer = SlideWriter()
|
|
2905
|
+
if writer.get_slide(record["session_id"], position) is not None:
|
|
2906
|
+
return
|
|
2907
|
+
writer.write_slide(
|
|
2908
|
+
session_id=record["session_id"],
|
|
2909
|
+
position=position,
|
|
2910
|
+
html=record["html"],
|
|
2911
|
+
scripts=record.get("scripts") or "",
|
|
2912
|
+
deck_spec_slide=slide_spec if isinstance(slide_spec, dict) else None,
|
|
2913
|
+
modified_by=record.get("initiated_by"),
|
|
2914
|
+
mutation=mutation,
|
|
2915
|
+
)
|
|
2916
|
+
except Exception:
|
|
2917
|
+
logger.warning(
|
|
2918
|
+
"Could not commit the draft of slide %s; it will appear once reviewed",
|
|
2919
|
+
position,
|
|
2920
|
+
exc_info=True,
|
|
2921
|
+
)
|
|
2922
|
+
|
|
2923
|
+
|
|
2924
|
+
def build_review_payload(record: dict, authority: dict) -> Dict[str, Any]:
|
|
2925
|
+
"""The build reviewer's input: the builder's *record*, provenance re-declared.
|
|
2926
|
+
|
|
2927
|
+
*authority* is the branch payload ``build_branch_payload`` built from state
|
|
2928
|
+
(or state itself). Provenance is RE-DECLARED from it, never inherited from
|
|
2929
|
+
the record: the reviewer is the WRITER of the row, and the mutation event's
|
|
2930
|
+
actor is built from ``session_id`` (``_deck_mutation_context``), so a record
|
|
2931
|
+
carrying a different root, actor, release or session would make the trace
|
|
2932
|
+
and the evidence row name different actors. Pinned by
|
|
2933
|
+
``test_the_review_payload_overwrites_a_hostile_root_actor_and_release_in_the_record``.
|
|
2934
|
+
|
|
2935
|
+
``session_id`` falls back to the record's own value rather than to ``None``:
|
|
2936
|
+
the authority always carries it in production, so the fallback is
|
|
2937
|
+
unreachable there, and this line can only ever HARDEN a value.
|
|
2938
|
+
"""
|
|
2939
|
+
return {
|
|
2940
|
+
**dict(record),
|
|
2941
|
+
"session_id": authority.get("session_id") or record.get("session_id"),
|
|
2942
|
+
"graph_release_id": authority["graph_release_id"],
|
|
2943
|
+
"root_session_id": authority.get("root_session_id") or "",
|
|
2944
|
+
"actor_session_id": authority.get("actor_session_id") or "",
|
|
2945
|
+
}
|
|
2946
|
+
|
|
2947
|
+
|
|
2948
|
+
def slide_pipeline_node(payload: dict) -> Dict[str, Any]:
|
|
2949
|
+
"""Carry ONE slide from build to its final reviewed row, without its siblings.
|
|
2950
|
+
|
|
2951
|
+
``builder -> draft row -> build_reviewer -> [fixer -> fix_reviewer]``, run
|
|
2952
|
+
in sequence inside one ``Send``-reached task. This replaces the
|
|
2953
|
+
``builder``, ``build_reviewer``, ``fixer`` and ``fix_reviewer`` graph nodes,
|
|
2954
|
+
and the reason is the runtime's superstep barrier, measured on a real
|
|
2955
|
+
10-slide deck: every slide waited for the slowest builder and then the
|
|
2956
|
+
slowest reviewer, and the flagged slides' fixes then ran ONE AT A TIME
|
|
2957
|
+
(``fixer`` took the lowest pending position per superstep) — 186s of a 308s
|
|
2958
|
+
turn. Fanning the fixers out with ``Send`` would have removed the queue but
|
|
2959
|
+
not the barriers; folding the chain into one task removes both, so a slide
|
|
2960
|
+
is done when ITS chain is done and the batch's only barrier is the foreman's
|
|
2961
|
+
wake after the slowest whole chain.
|
|
2962
|
+
|
|
2963
|
+
The four stages are the shipped node functions, called unchanged, and their
|
|
2964
|
+
updates are folded with ``GraphState``'s own reducers (``_fold``):
|
|
2965
|
+
|
|
2966
|
+
* a builder that placeholds ends the chain — nothing to review;
|
|
2967
|
+
* the builder's HTML is committed as a draft (``_write_draft_row``) before
|
|
2968
|
+
review, so the slide is visible while it is reviewed;
|
|
2969
|
+
* the review payload is the builder's record with provenance re-declared
|
|
2970
|
+
from this payload, which ``build_branch_payload`` built from state
|
|
2971
|
+
(:func:`build_review_payload`);
|
|
2972
|
+
* a review that opens a fix hands the fixer and fix reviewer a slide-local
|
|
2973
|
+
state carrying only this slide's ``fix_map`` entry, so "exactly one fix
|
|
2974
|
+
round per slide" holds by construction and ``in_flight`` stays the
|
|
2975
|
+
fixer's own guard against a re-entry.
|
|
2976
|
+
|
|
2977
|
+
Only fan-in keys reach graph state; ``_PIPELINE_LOCAL_KEYS`` stay here.
|
|
2978
|
+
Every stage's failure path is the one its node already had (placehold on a
|
|
2979
|
+
failed build or review, land the original on a failed fix, placehold on a
|
|
2980
|
+
fix review that cannot deliver), so the turn continues to deck review.
|
|
2981
|
+
"""
|
|
2982
|
+
position = payload["position"]
|
|
2983
|
+
acc: Dict[str, Any] = {}
|
|
2984
|
+
|
|
2985
|
+
_fold(acc, builder_node(payload))
|
|
2986
|
+
record = ((acc.get("slides") or {}).get("vals") or {}).get(position)
|
|
2987
|
+
if record is None:
|
|
2988
|
+
return {k: v for k, v in acc.items() if k not in _PIPELINE_LOCAL_KEYS}
|
|
2989
|
+
|
|
2990
|
+
_write_draft_row(
|
|
2991
|
+
record,
|
|
2992
|
+
_deck_mutation_context(
|
|
2993
|
+
payload["session_id"],
|
|
2994
|
+
payload.get("graph_release_id"),
|
|
2995
|
+
operation="write_slide",
|
|
2996
|
+
object_type="slide",
|
|
2997
|
+
),
|
|
2998
|
+
)
|
|
2999
|
+
|
|
3000
|
+
_fold(acc, build_reviewer_node(build_review_payload(record, payload)))
|
|
3001
|
+
|
|
3002
|
+
entry = ((acc.get("fix_map") or {}).get("vals") or {}).get(position)
|
|
3003
|
+
if entry is not None:
|
|
3004
|
+
fix_state: Dict[str, Any] = {
|
|
3005
|
+
"turn_id": payload["turn_id"],
|
|
3006
|
+
"session_id": payload["session_id"],
|
|
3007
|
+
"graph_release_id": payload["graph_release_id"],
|
|
3008
|
+
"initiated_by": payload.get("initiated_by"),
|
|
3009
|
+
"root_session_id": payload.get("root_session_id") or "",
|
|
3010
|
+
"actor_session_id": payload.get("actor_session_id") or "",
|
|
3011
|
+
"design_system_active": payload.get("design_system_active"),
|
|
3012
|
+
"fix_map": acc["fix_map"],
|
|
3013
|
+
}
|
|
3014
|
+
fixer_update = fixer_node(fix_state)
|
|
3015
|
+
_fold(acc, fixer_update)
|
|
3016
|
+
_fold(fix_state, fixer_update)
|
|
3017
|
+
if fix_state.get("fix_target") is not None:
|
|
3018
|
+
_fold(acc, fix_reviewer_node(fix_state))
|
|
3019
|
+
|
|
3020
|
+
return {k: v for k, v in acc.items() if k not in _PIPELINE_LOCAL_KEYS}
|
|
3021
|
+
|
|
3022
|
+
|
|
2842
3023
|
# ---------------------------------------------------------------------------
|
|
2843
3024
|
# placeholder_node
|
|
2844
3025
|
# ---------------------------------------------------------------------------
|